4 #include <unordered_map>
14 using std::unordered_map;
23 string GUICheckbox::NAME =
"checkbox";
25 GUICheckbox::GUICheckbox()
34 const string GUICheckbox::getTemplate(
const string& applicationPathName,
const string& applicationSubPathName,
const string& fileName)
36 return FileSystem::getInstance()->getContentAsString(applicationPathName +
"/resources/" + applicationSubPathName +
"/gui/definitions", fileName.empty() ==
true?
"checkbox.xml":fileName);
41 unordered_map<string, string> attributes;
43 attributes[
"image-unchecked"] =
"resources/engine/images/checkbox_unchecked.png";
44 attributes[
"image-checked"] =
"resources/engine/images/checkbox_checked.png";
45 attributes[
"size"] =
"25";
GUI check box controller.
GUINodeController * createController(GUINode *node) override
Create controller which is attached to this node.
unordered_map< string, string > getAttributes(GUIScreenNode *screenNode) override
Get default attributes.
const string & getName() override
const string getTemplate(const string &applicationPathName, const string &applicationSubPathName, const string &fileName=string()) override
Retrieve template from given path name and optional file name.
GUI node controller base class.
GUI screen node that represents a screen that can be rendered via GUI system.
const string allocateNodeId()
Allocate node id.
File system singleton class.