17#pragma warning(disable:4251)
56 void setText(
const std::string& _text) { m_text = _text; };
57 const std::string
text(
void)
const {
return m_text; };
59 void setIconPath(
const std::string& _iconPath) { m_iconPath = _iconPath; };
60 const std::string&
iconPath(
void)
const {
return m_iconPath; };
63 void setChildItems(
const std::list<NavigationTreeItem>& _items);
64 const std::list<NavigationTreeItem>&
childItems(
void)
const {
return m_childs; };
72 std::string itemPath(
char _delimiter =
'/',
const std::string& _suffix = std::string())
const;
86 std::string m_iconPath;
87 std::list<NavigationTreeItem> m_childs;
#define OT_ADD_FLAG_FUNCTIONS(___enumName)
Will add the default bitwise operations for the provided private 32/64 bit bitfield....
Definition Flags.h:129
#define OT_GUI_API_EXPORT
Definition OTGuiAPIExport.h:9
The Flags class is a wrapper around a enum that allows bitwise operations (flags)....
Definition Flags.h:214
Definition NavigationTreeItem.h:35
void setIconPath(const std::string &_iconPath)
Definition NavigationTreeItem.h:59
const std::string text(void) const
Definition NavigationTreeItem.h:57
void setFlag(NavigationTreeItemFlag _flag, bool _active=true)
Definition NavigationTreeItem.h:66
void setFlags(ot::NavigationTreeItemFlags _flags)
Definition NavigationTreeItem.h:67
void setText(const std::string &_text)
Definition NavigationTreeItem.h:56
const std::list< NavigationTreeItem > & childItems(void) const
Definition NavigationTreeItem.h:64
ot::NavigationTreeItemFlags flags(void) const
Definition NavigationTreeItem.h:68
NavigationTreeItem * parentNavigationTreeItem(void) const
Definition NavigationTreeItem.h:80
const std::string & iconPath(void) const
Definition NavigationTreeItem.h:60
void setParentNavigationTreeItem(NavigationTreeItem *_parent)
Definition NavigationTreeItem.h:79
The Serializable class is the default interface of serializable objects.
Definition Serializable.h:17
OT_GUI_API_EXPORT std::list< std::string > toStringList(const LockTypeFlags &_flags)
Definition GuiTypes.cpp:426
rapidjson::Value JsonValue
Writable JSON value.
Definition JSON.h:27
rapidjson::GenericObject< true, rapidjson::GenericValue< rapidjson::UTF8<>, rapidjson::MemoryPoolAllocator< rapidjson::CrtAllocator > > > ConstJsonObject
Read only JSON Object.
Definition JSON.h:35
OT_GUI_API_EXPORT std::string toString(ColorStyleName _colorStyleName)
Definition ColorStyleTypes.cpp:10
Flags< NavigationTreeItemFlag > NavigationTreeItemFlags
Definition NavigationTreeItem.h:28
rapidjson::MemoryPoolAllocator< rapidjson::CrtAllocator > JsonAllocator
Allocator used for writing to JSON values.
Definition JSON.h:30
NavigationTreeItemFlag
Definition NavigationTreeItem.h:21
@ ItemMayBeAdded
If set the item will be removed when all the child items are removed.
Definition NavigationTreeItem.h:24
@ ItemIsSelected
If set the item may be added/dragged/dropped.
Definition NavigationTreeItem.h:25
@ ItemIsInvisible
If set this item is selected.
Definition NavigationTreeItem.h:26
@ RemoveItemWhenEmpty
Empty mask, no flags set.
Definition NavigationTreeItem.h:23
@ NoNavigationTreeItemFlags
Definition NavigationTreeItem.h:22
OT_GUI_API_EXPORT NavigationTreeItemFlag stringToNavigationItemFlag(const std::string &_flag)
Definition NavigationTreeItem.cpp:39
OT_GUI_API_EXPORT NavigationTreeItemFlags stringListToNavigationItemFlags(const std::list< std::string > &_flags)
Definition NavigationTreeItem.cpp:50