mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-01 11:03:54 -07:00
Add support for multi-selection in set editor (#2441)
This commit is contained in:
parent
33e8a2ea95
commit
85985a9433
4 changed files with 175 additions and 74 deletions
|
|
@ -2,6 +2,10 @@
|
|||
#define WINDOW_SETS_H
|
||||
|
||||
#include <QMainWindow>
|
||||
#include <QSet>
|
||||
#include <QDialogButtonBox>
|
||||
#include <QLabel>
|
||||
#include <QGridLayout>
|
||||
|
||||
class SetsModel;
|
||||
class SetsProxyModel;
|
||||
|
|
@ -15,18 +19,25 @@ class WndSets : public QMainWindow {
|
|||
private:
|
||||
SetsModel *model;
|
||||
QTreeView *view;
|
||||
QPushButton *enableAllButton, *disableAllButton;
|
||||
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 selectRow(int row);
|
||||
void selectRows(QSet<int> rows);
|
||||
private slots:
|
||||
void actEnable();
|
||||
void actDisable();
|
||||
void actEnableAll();
|
||||
void actDisableAll();
|
||||
void actEnableSome();
|
||||
void actDisableSome();
|
||||
void actSave();
|
||||
void actRestore();
|
||||
void actUp();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue