Menu

[c54480]: / flagrow.h  Maximize  Restore  History

Download this file

52 lines (42 with data), 1.4 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#ifndef FLAGROW_H
#define FLAGROW_H
#include <QStringList>
#include <QToolBar>
#include "flag.h"
#include "xmlobj.h"
/*! \brief A set of flags (Flag).
A toolbar can be created from the flags in this row.
The data needed for represention in a vym map
is stored in FlagRowObj.
*/
class FlagRow:public XMLObj {
public:
FlagRow ();
~FlagRow ();
void addFlag (Flag *flag);
Flag *getFlag (const QString &name);
QStringList activeFlagNames();
bool isActive(const QString &name);
/*! \brief Toggle a Flag
To activate a flag it will be copied from masterRow to current row.
*/
bool toggle (const QString&, FlagRow *masterRow=NULL);
bool activate(const QString&);
bool deactivate(const QString&);
bool deactivateGroup(const QString&);
void deactivateAll();
void setEnabled (bool);
void resetUsedCounter();
QString saveToDir (const QString &,const QString &,bool);
void setName (const QString&); // prefix for exporting flags to dir
void setToolBar (QToolBar *tb);
void setMasterRow (FlagRow *row);
void updateToolBar(const QStringList &activeNames);
private:
QToolBar *toolBar;
FlagRow *masterRow;
QList <Flag*> flags;
QStringList activeNames; //! Lists all names of currently active flags
QString rowName; //! Name of this collection of flags
};
#endif
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.