1 /***************************************************************************
2                           allspaceconstraintsform.h  -  description
3                              -------------------
4     begin                : Feb 13, 2005
5     copyright            : (C) 2005 by Lalescu Liviu
6     email                : Please see https://lalescu.ro/liviu/ for details about contacting Liviu Lalescu (in particular, you can find here the e-mail address)
7  ***************************************************************************/
8 
9 /***************************************************************************
10  *                                                                         *
11  *   This program is free software: you can redistribute it and/or modify  *
12  *   it under the terms of the GNU Affero General Public License as        *
13  *   published by the Free Software Foundation, either version 3 of the    *
14  *   License, or (at your option) any later version.                       *
15  *                                                                         *
16  ***************************************************************************/
17 
18 #ifndef ALLSPACECONSTRAINTSFORM_H
19 #define ALLSPACECONSTRAINTSFORM_H
20 
21 #include "ui_allspaceconstraintsform_template.h"
22 #include "timetable_defs.h"
23 #include "timetable.h"
24 #include "fet.h"
25 
26 #include "advancedfilterform.h"
27 
28 class AllSpaceConstraintsForm : public QDialog, Ui::AllSpaceConstraintsForm_template  {
29 	Q_OBJECT
30 
31 private:
32 	AdvancedFilterForm* filterForm;
33 
34 	QList<SpaceConstraint*> visibleSpaceConstraintsList;
35 
36 	bool all; //all or any, true means all, false means any
37 	QList<int> descrDetDescr;
38 	QList<int> contains;
39 	QStringList text;
40 	bool caseSensitive;
41 
42 	bool useFilter;
43 
44 public:
45 	AllSpaceConstraintsForm(QWidget* parent);
46 	~AllSpaceConstraintsForm();
47 
48 	bool filterOk(SpaceConstraint* ctr);
49 
50 	void filterChanged();
51 
52 public slots:
53 	void constraintChanged();
54 	void modifyConstraint();
55 	void removeConstraint();
56 	void filter(bool active);
57 
58 	void moveSpaceConstraintUp();
59 	void moveSpaceConstraintDown();
60 
61 	void sortedChanged(bool checked);
62 
63 	//void sortConstraintsByComments();
64 	void activateConstraint();
65 	void deactivateConstraint();
66 	void constraintComments();
67 };
68 
69 #endif
70