Cockatrice/cockatrice/src/window_sets.h
ctrlaltca b29bd9e070
Clang-format (#3028)
* 1/3 Add .clang-format file and travis compilation check

* 2/3 Run clang-format

* 3/3 Fix compilation problems due to include reordering

* 3bis/3 AfterControlStatement: false
2018-01-27 10:41:32 +01:00

57 lines
1.2 KiB
C++

#ifndef WINDOW_SETS_H
#define WINDOW_SETS_H
#include <QDialogButtonBox>
#include <QGridLayout>
#include <QLabel>
#include <QMainWindow>
#include <QSet>
class SetsModel;
class SetsProxyModel;
class QPushButton;
class CardDatabase;
class QItemSelection;
class QTreeView;
class WndSets : public QMainWindow
{
Q_OBJECT
private:
SetsModel *model;
QTreeView *view;
QPushButton *toggleAllButton, *toggleSelectedButton;
QPushButton *enableAllButton, *disableAllButton, *enableSomeButton, *disableSomeButton;
QAction *aUp, *aDown, *aBottom, *aTop;
QToolBar *setsEditToolBar;
QDialogButtonBox *buttonBox;
QLabel *labNotes;
QGridLayout *mainLayout;
void rebuildMainLayout(int actionToTake);
enum
{
NO_SETS_SELECTED,
SOME_SETS_SELECTED
};
public:
WndSets(QWidget *parent = 0);
~WndSets();
protected:
void selectRows(QSet<int> rows);
private slots:
void actEnableAll();
void actDisableAll();
void actEnableSome();
void actDisableSome();
void actSave();
void actRestore();
void actUp();
void actDown();
void actTop();
void actBottom();
void actToggleButtons(const QItemSelection &selected, const QItemSelection &deselected);
};
#endif