Emergency 20 Dokumentation  4.2.0
PreferencesGameWindow.h
Go to the documentation of this file.
1 // Copyright (C) 2012-2018 Promotion Software GmbH
2 
3 
4 //[-------------------------------------------------------]
5 //[ Header guard ]
6 //[-------------------------------------------------------]
7 #pragma once
8 
9 
10 //[-------------------------------------------------------]
11 //[ Includes ]
12 //[-------------------------------------------------------]
15 
16 
17 //[-------------------------------------------------------]
18 //[ Namespace ]
19 //[-------------------------------------------------------]
20 namespace em5
21 {
22 
23 
24  //[-------------------------------------------------------]
25  //[ Classes ]
26  //[-------------------------------------------------------]
32  {
33 
34 
35  //[-------------------------------------------------------]
36  //[ Public definitions ]
37  //[-------------------------------------------------------]
38  public:
39  struct GameSettings
40  {
41  bool tooltip;
42  bool tutorial;
45  };
46 
47 
48  //[-------------------------------------------------------]
49  //[ Public methods ]
50  //[-------------------------------------------------------]
51  public:
52  explicit PreferencesGameWindow(qsf::GuiContext& guiContext);
53  void setBackButton(bool main);
54 
55 
56  //[-------------------------------------------------------]
57  //[ Public virtual qsf::GuiDocument methods ]
58  //[-------------------------------------------------------]
59  public:
60  virtual void processEvent(const std::string& eventKey, Rocket::Core::Event& event) override;
61 
62 
63  //[-------------------------------------------------------]
64  //[ Protected virtual em5::MainMenuWindowBase methods ]
65  //[-------------------------------------------------------]
66  protected:
67  virtual void onGoingBack() override;
68 
69 
70  //[-------------------------------------------------------]
71  //[ Private methods ]
72  //[-------------------------------------------------------]
73  private:
74  void loadSettings();
75  void setOldStates();
76 
77 
78  //[-------------------------------------------------------]
79  //[ Private data ]
80  //[-------------------------------------------------------]
81  private:
82  GameSettings mCurrentGameSettings;
83  GameSettings mNewGameSettings;
84  bool mInMainMenu;
85 
86 
87  };
88 
89 
90 //[-------------------------------------------------------]
91 //[ Namespace ]
92 //[-------------------------------------------------------]
93 } // em5
Definition: ActionPriority.h:13
bool tooltip
Definition: PreferencesGameWindow.h:41
GameSettingsGroup::AutomatismValue automatic
Definition: PreferencesGameWindow.h:43
void setBackButton(bool main)
virtual void processEvent(const std::string &eventKey, Rocket::Core::Event &event) override
Base window for main menu windows.
Definition: MainMenuWindowBase.h:40
Game preferences window.
Definition: PreferencesGameWindow.h:31
Ingame Graphical User Interface (GUI) context class.
Definition: GuiContext.h:62
Definition: PreferencesGameWindow.h:39
PreferencesGameWindow(qsf::GuiContext &guiContext)
bool tutorial
Definition: PreferencesGameWindow.h:42
AutomatismValue
The amount of used unit automatism. Eg. the doctor logic has an automatically treatment of injured pe...
Definition: GameSettingsGroup.h:143
bool driveBackWithoutSirens
Definition: PreferencesGameWindow.h:44
virtual void onGoingBack() override