MyGUI: MyGUI_ResourceLayout.h Source File

MyGUI 3.2.2

MyGUI_ResourceLayout.h
Go to the documentation of this file.
1 /*
2 * This source file is part of MyGUI. For the latest info, see http://mygui.info/
3 * Distributed under the MIT License
4 * (See accompanying file COPYING.MIT or copy at http://opensource.org/licenses/MIT)
5 */
6
7 #ifndef MYGUI_RESOURCE_LAYOUT_H_
8 #define MYGUI_RESOURCE_LAYOUT_H_
9
10 #include "MyGUI_Prerequest.h"
11 #include "MyGUI_IResource.h"
12 #include "MyGUI_LayoutData.h"
13
14 namespace MyGUI
15 {
16
18 class MYGUI_EXPORT ResourceLayout :
19 public IResource
20 {
21 MYGUI_RTTI_DERIVED( ResourceLayout )
22
23 public:
24 ResourceLayout();
25
26 ResourceLayout(xml::ElementPtr _node, const std::string& _file);
27
28 virtual void deserialization(xml::ElementPtr _node, Version _version);
29
30 const VectorWidgetInfo& getLayoutData() const;
31
33 VectorWidgetPtr createLayout(const std::string& _prefix = "", Widget* _parent = nullptr);
34
35 // widget info -> Widget
36 Widget* createWidget(const WidgetInfo& _widgetInfo, const std::string& _prefix = "", Widget* _parent = nullptr, bool _template = false);
37
38 protected:
39 // xml -> widget info
40 WidgetInfo parseWidget(xml::ElementEnumerator& _widget);
41
42 protected:
43 VectorWidgetInfo mLayoutData;
44 };
45
46 } // namespace MyGUI
47
48 #endif // MYGUI_RESOURCE_LAYOUT_H_
MyGUI_IResource.h
MyGUI::WidgetInfo
Definition: MyGUI_LayoutData.h:22
MyGUI::Widget
Widget properties. Skin childs. Widget widget description should be here.
Definition: MyGUI_Widget.h:29
MyGUI::VectorWidgetPtr
std::vector< Widget * > VectorWidgetPtr
Definition: MyGUI_WidgetDefines.h:19
MyGUI::xml::Element
Definition: MyGUI_XmlDocument.h:158
MyGUI::ResourceLayout::mLayoutData
VectorWidgetInfo mLayoutData
Definition: MyGUI_ResourceLayout.h:43
MyGUI::ResourceLayout
Definition: MyGUI_ResourceLayout.h:18
MyGUI::VectorWidgetInfo
std::vector< WidgetInfo > VectorWidgetInfo
Definition: MyGUI_LayoutData.h:51
MyGUI::Version
Definition: MyGUI_Version.h:17
MyGUI_Prerequest.h
MyGUI::xml::ElementEnumerator
Definition: MyGUI_XmlDocument.h:114
MYGUI_RTTI_DERIVED
#define MYGUI_RTTI_DERIVED(DerivedType)
Definition: MyGUI_RTTI.h:65
MyGUI_LayoutData.h
MYGUI_EXPORT
#define MYGUI_EXPORT
Definition: MyGUI_Platform.h:103
MyGUI::IResource
Definition: MyGUI_IResource.h:23
MyGUI
Definition: MyGUI_ActionController.h:14