MyGUI
3.4.0
MyGUIEngine
include
MyGUI_LayoutManager.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_LAYOUT_MANAGER_H_
8
#define MYGUI_LAYOUT_MANAGER_H_
9
10
#include "
MyGUI_Prerequest.h
"
11
#include "
MyGUI_Singleton.h
"
12
#include "
MyGUI_XmlDocument.h
"
13
#include "
MyGUI_WidgetDefines.h
"
14
#include "
MyGUI_ResourceLayout.h
"
15
#include "
MyGUI_BackwardCompatibility.h
"
16
17
namespace
MyGUI
18
{
19
20
typedef
delegates::CMultiDelegate2<Widget*, const WidgetInfo&>
EventHandle_CreateWidgetDelegate
;
21
typedef
delegates::CMultiDelegate3<Widget*, const std::string&, const std::string&>
EventHandle_AddUserStringDelegate
;
22
23
class
MYGUI_EXPORT
LayoutManager
:
24
public
Singleton
<LayoutManager>,
25
public
MemberObsolete
<LayoutManager>
26
{
27
public
:
28
LayoutManager
();
29
30
void
initialise();
31
void
shutdown();
32
39
VectorWidgetPtr
loadLayout(
const
std::string& _file,
const
std::string& _prefix =
""
,
Widget
* _parent =
nullptr
);
40
42
void
unloadLayout(
VectorWidgetPtr
& _widgets);
43
45
ResourceLayout
* getByName(
const
std::string& _name,
bool
_throw =
true
)
const
;
46
48
bool
isExist(
const
std::string& _name)
const
;
49
57
EventHandle_CreateWidgetDelegate
eventCreateWidget
;
58
66
EventHandle_AddUserStringDelegate
eventAddUserString
;
67
68
const
std::string& getCurrentLayout()
const
;
69
70
private
:
71
void
_load(
xml::ElementPtr
_node,
const
std::string& _file,
Version
_version);
72
73
private
:
74
bool
mIsInitialise;
75
std::string mCurrentLayoutName;
76
std::string mXmlLayoutTagName;
77
};
78
79
}
// namespace MyGUI
80
81
#endif // MYGUI_LAYOUT_MANAGER_H_
MyGUI_XmlDocument.h
MyGUI::delegates::MultiDelegate
Definition:
MyGUI_Delegate.h:183
MyGUI::EventHandle_CreateWidgetDelegate
delegates::CMultiDelegate2< Widget *, const WidgetInfo & > EventHandle_CreateWidgetDelegate
Definition:
MyGUI_LayoutManager.h:20
MyGUI::LayoutManager::eventAddUserString
EventHandle_AddUserStringDelegate eventAddUserString
Definition:
MyGUI_LayoutManager.h:66
MyGUI::Widget
Widget properties. Skin childs. Widget widget description should be here.
Definition:
MyGUI_Widget.h:37
MyGUI::xml::Element
Definition:
MyGUI_XmlDocument.h:159
MyGUI::ResourceLayout
Definition:
MyGUI_ResourceLayout.h:20
MyGUI::Version
Definition:
MyGUI_Version.h:18
MyGUI_Prerequest.h
MyGUI_Singleton.h
MyGUI::LayoutManager
Definition:
MyGUI_LayoutManager.h:26
MyGUI::MemberObsolete
Definition:
MyGUI_DeprecatedTypes.h:14
MyGUI::EventHandle_AddUserStringDelegate
delegates::CMultiDelegate3< Widget *, const std::string &, const std::string & > EventHandle_AddUserStringDelegate
Definition:
MyGUI_LayoutManager.h:21
MyGUI_WidgetDefines.h
MyGUI::LayoutManager::eventCreateWidget
EventHandle_CreateWidgetDelegate eventCreateWidget
Definition:
MyGUI_LayoutManager.h:57
MYGUI_EXPORT
#define MYGUI_EXPORT
Definition:
MyGUI_Platform.h:89
MyGUI_ResourceLayout.h
MyGUI::Singleton
Definition:
MyGUI_Singleton.h:22
MyGUI_BackwardCompatibility.h
MyGUI
Definition:
MyGUI_ActionController.h:15
MyGUI::VectorWidgetPtr
std::vector< Widget * > VectorWidgetPtr
Definition:
MyGUI_WidgetDefines.h:20
Generated by
1.8.18