TDME2
1.9.121
src
tdme
tools
editor
misc
PopUps.cpp
Go to the documentation of this file.
1
#include <
tdme/tools/editor/misc/PopUps.h
>
2
3
#include <
tdme/tdme.h
>
4
#include <
tdme/engine/Engine.h
>
5
#include <
tdme/gui/nodes/GUIScreenNode.h
>
6
#include <
tdme/gui/GUI.h
>
7
#include <
tdme/tools/editor/controllers/AboutDialogScreenController.h
>
8
#include <
tdme/tools/editor/controllers/ColorPickerScreenController.h
>
9
#include <
tdme/tools/editor/controllers/ContextMenuScreenController.h
>
10
#include <
tdme/tools/editor/controllers/FileDialogScreenController.h
>
11
#include <
tdme/tools/editor/controllers/InfoDialogScreenController.h
>
12
#include <
tdme/tools/editor/controllers/ProgressBarScreenController.h
>
13
14
using
tdme::engine::Engine
;
15
using
tdme::gui::nodes::GUIScreenNode
;
16
using
tdme::gui::GUI
;
17
using
tdme::tools::editor::controllers::AboutDialogScreenController
;
18
using
tdme::tools::editor::controllers::ColorPickerScreenController
;
19
using
tdme::tools::editor::controllers::ContextMenuScreenController
;
20
using
tdme::tools::editor::controllers::FileDialogScreenController
;
21
using
tdme::tools::editor::controllers::InfoDialogScreenController
;
22
using
tdme::tools::editor::controllers::ProgressBarScreenController
;
23
using
tdme::tools::editor::misc::PopUps
;
24
25
PopUps::PopUps()
26
{
27
fileDialogScreenController
=
new
FileDialogScreenController
();
28
infoDialogScreenController
=
new
InfoDialogScreenController
();
29
aboutDialogScreenController
=
new
AboutDialogScreenController
();
30
progressBarScreenController
=
new
ProgressBarScreenController
();
31
colorPickerScreenController
=
new
ColorPickerScreenController
();
32
contextMenuScreenController
=
new
ContextMenuScreenController
();
33
}
34
35
PopUps::~PopUps
() {
36
delete
fileDialogScreenController
;
37
delete
infoDialogScreenController
;
38
delete
aboutDialogScreenController
;
39
delete
progressBarScreenController
;
40
delete
colorPickerScreenController
;
41
delete
contextMenuScreenController
;
42
}
43
44
void
PopUps::initialize
()
45
{
46
fileDialogScreenController
->
initialize
();
47
infoDialogScreenController
->
initialize
();
48
aboutDialogScreenController
->
initialize
();
49
progressBarScreenController
->
initialize
();
50
colorPickerScreenController
->
initialize
();
51
contextMenuScreenController
->
initialize
();
52
Engine::getInstance()->getGUI()->addScreen(
fileDialogScreenController
->
getScreenNode
()->
getId
(),
fileDialogScreenController
->
getScreenNode
());
53
Engine::getInstance()->getGUI()->addScreen(
infoDialogScreenController
->
getScreenNode
()->
getId
(),
infoDialogScreenController
->
getScreenNode
());
54
Engine::getInstance()->getGUI()->addScreen(
aboutDialogScreenController
->
getScreenNode
()->
getId
(),
aboutDialogScreenController
->
getScreenNode
());
55
Engine::getInstance()->getGUI()->addScreen(
progressBarScreenController
->
getScreenNode
()->
getId
(),
progressBarScreenController
->
getScreenNode
());
56
Engine::getInstance()->getGUI()->addScreen(
colorPickerScreenController
->
getScreenNode
()->
getId
(),
colorPickerScreenController
->
getScreenNode
());
57
Engine::getInstance()->getGUI()->addScreen(
contextMenuScreenController
->
getScreenNode
()->
getId
(),
contextMenuScreenController
->
getScreenNode
());
58
}
59
60
void
PopUps::dispose
()
61
{
62
Engine::getInstance()->getGUI()->removeScreen(
fileDialogScreenController
->
getScreenNode
()->
getId
());
63
Engine::getInstance()->getGUI()->removeScreen(
infoDialogScreenController
->
getScreenNode
()->
getId
());
64
Engine::getInstance()->getGUI()->removeScreen(
aboutDialogScreenController
->
getScreenNode
()->
getId
());
65
Engine::getInstance()->getGUI()->removeScreen(
progressBarScreenController
->
getScreenNode
()->
getId
());
66
Engine::getInstance()->getGUI()->removeScreen(
colorPickerScreenController
->
getScreenNode
()->
getId
());
67
Engine::getInstance()->getGUI()->removeScreen(
contextMenuScreenController
->
getScreenNode
()->
getId
());
68
fileDialogScreenController
->
dispose
();
69
infoDialogScreenController
->
dispose
();
70
aboutDialogScreenController
->
dispose
();
71
progressBarScreenController
->
dispose
();
72
colorPickerScreenController
->
dispose
();
73
contextMenuScreenController
->
dispose
();
74
}
AboutDialogScreenController.h
ColorPickerScreenController.h
ContextMenuScreenController.h
Engine.h
FileDialogScreenController.h
GUIScreenNode.h
GUI.h
InfoDialogScreenController.h
PopUps.h
ProgressBarScreenController.h
tdme::engine::Engine
Engine main class.
Definition:
Engine.h:122
tdme::gui::GUI
GUI module class.
Definition:
GUI.h:66
tdme::gui::nodes::GUINode::getId
const string & getId()
Definition:
GUINode.h:329
tdme::gui::nodes::GUIScreenNode
GUI screen node that represents a screen that can be rendered via GUI system.
Definition:
GUIScreenNode.h:57
tdme::tools::editor::controllers::AboutDialogScreenController
About dialog screen controller.
Definition:
AboutDialogScreenController.h:28
tdme::tools::editor::controllers::AboutDialogScreenController::dispose
void dispose() override
Dispose.
Definition:
AboutDialogScreenController.cpp:67
tdme::tools::editor::controllers::AboutDialogScreenController::initialize
void initialize() override
Init.
Definition:
AboutDialogScreenController.cpp:52
tdme::tools::editor::controllers::AboutDialogScreenController::getScreenNode
GUIScreenNode * getScreenNode() override
Definition:
AboutDialogScreenController.cpp:47
tdme::tools::editor::controllers::ColorPickerScreenController
Color picker screen controller.
Definition:
ColorPickerScreenController.h:37
tdme::tools::editor::controllers::ColorPickerScreenController::dispose
void dispose() override
Dispose.
Definition:
ColorPickerScreenController.cpp:90
tdme::tools::editor::controllers::ColorPickerScreenController::initialize
void initialize() override
Init.
Definition:
ColorPickerScreenController.cpp:68
tdme::tools::editor::controllers::ColorPickerScreenController::getScreenNode
GUIScreenNode * getScreenNode() override
Definition:
ColorPickerScreenController.cpp:63
tdme::tools::editor::controllers::ContextMenuScreenController
Context menu screen controller.
Definition:
ContextMenuScreenController.h:34
tdme::tools::editor::controllers::ContextMenuScreenController::dispose
void dispose() override
Dispose.
Definition:
ContextMenuScreenController.cpp:77
tdme::tools::editor::controllers::ContextMenuScreenController::initialize
void initialize() override
Init.
Definition:
ContextMenuScreenController.cpp:63
tdme::tools::editor::controllers::ContextMenuScreenController::getScreenNode
GUIScreenNode * getScreenNode() override
Definition:
ContextMenuScreenController.cpp:58
tdme::tools::editor::controllers::FileDialogScreenController
File dialog screen controller.
Definition:
FileDialogScreenController.h:41
tdme::tools::editor::controllers::FileDialogScreenController::dispose
void dispose() override
Dispose.
Definition:
FileDialogScreenController.cpp:107
tdme::tools::editor::controllers::FileDialogScreenController::initialize
void initialize() override
Init.
Definition:
FileDialogScreenController.cpp:85
tdme::tools::editor::controllers::FileDialogScreenController::getScreenNode
GUIScreenNode * getScreenNode() override
Definition:
FileDialogScreenController.cpp:66
tdme::tools::editor::controllers::InfoDialogScreenController
Info dialog screen controller.
Definition:
InfoDialogScreenController.h:31
tdme::tools::editor::controllers::InfoDialogScreenController::dispose
void dispose() override
Dispose.
Definition:
InfoDialogScreenController.cpp:62
tdme::tools::editor::controllers::InfoDialogScreenController::initialize
void initialize() override
Init.
Definition:
InfoDialogScreenController.cpp:48
tdme::tools::editor::controllers::InfoDialogScreenController::getScreenNode
GUIScreenNode * getScreenNode() override
Definition:
InfoDialogScreenController.cpp:43
tdme::tools::editor::controllers::ProgressBarScreenController
Progress bar screen controller.
Definition:
ProgressBarScreenController.h:28
tdme::tools::editor::controllers::ProgressBarScreenController::dispose
void dispose() override
Dispose.
Definition:
ProgressBarScreenController.cpp:62
tdme::tools::editor::controllers::ProgressBarScreenController::initialize
void initialize() override
Init.
Definition:
ProgressBarScreenController.cpp:48
tdme::tools::editor::controllers::ProgressBarScreenController::getScreenNode
GUIScreenNode * getScreenNode() override
Definition:
ProgressBarScreenController.cpp:43
tdme::tools::editor::misc::PopUps
Pop ups controller accessor class.
Definition:
PopUps.h:19
tdme::tools::editor::misc::PopUps::~PopUps
~PopUps()
Destructor.
Definition:
PopUps.cpp:35
tdme::tools::editor::misc::PopUps::initialize
void initialize()
Init.
Definition:
PopUps.cpp:44
tdme::tools::editor::misc::PopUps::infoDialogScreenController
InfoDialogScreenController * infoDialogScreenController
Definition:
PopUps.h:21
tdme::tools::editor::misc::PopUps::colorPickerScreenController
ColorPickerScreenController * colorPickerScreenController
Definition:
PopUps.h:24
tdme::tools::editor::misc::PopUps::progressBarScreenController
ProgressBarScreenController * progressBarScreenController
Definition:
PopUps.h:23
tdme::tools::editor::misc::PopUps::aboutDialogScreenController
AboutDialogScreenController * aboutDialogScreenController
Definition:
PopUps.h:26
tdme::tools::editor::misc::PopUps::contextMenuScreenController
ContextMenuScreenController * contextMenuScreenController
Definition:
PopUps.h:25
tdme::tools::editor::misc::PopUps::dispose
void dispose()
Dispose.
Definition:
PopUps.cpp:60
tdme::tools::editor::misc::PopUps::fileDialogScreenController
FileDialogScreenController * fileDialogScreenController
Definition:
PopUps.h:22
tdme.h
Generated by
1.9.3