]> git.sven.stormbind.net Git - sven/vym.git/blob - src/flagrow.h
Replace Pierre as the maintainer
[sven/vym.git] / src / flagrow.h
1 #ifndef FLAGROW_H
2 #define FLAGROW_H
3
4 #include <QList>
5 #include <QStringList>
6 #include <QToolBar>
7
8 #include "flagrowmaster.h"
9 #include "xmlobj.h"
10
11 class FlagRow 
12 {
13   public:
14     FlagRow ();
15     ~FlagRow ();
16     const QStringList activeFlagNames();
17     const QList<QUuid> activeFlagUids();
18     bool isActive(const QString &name);
19     bool isActive(const QUuid &uuid);
20
21     /*! \brief Toggle a Flag
22     To activate a flag its uid will be copied from masterRow to activeUids in
23     current row.
24     */
25     bool toggle(const QString &, bool useGroups = true);
26     bool toggle(const QUuid &, bool useGroups = true);
27     bool activate(const QString &);
28     bool activate(const QUuid &);
29     bool deactivate(const QString &);
30     bool deactivate(const QUuid &);
31     bool deactivateGroup(const QString &);
32     void deactivateAll();
33     QString saveState();
34     void setMasterRow(FlagRowMaster *row);
35
36   private:
37     FlagRowMaster *masterRow;
38     QList<QUuid> activeUids; //! Used in treeitems: Lists all uids of currently
39                              //! active flags
40 };
41 #endif