The Battle for Wesnoth
1.19.5+dev
gui
dialogs
gamestate_inspector.hpp
Go to the documentation of this file.
1
/*
2
Copyright (C) 2009 - 2024
3
by Yurii Chernyi <terraninfo@terraninfo.net>
4
Part of the Battle for Wesnoth Project https://www.wesnoth.org/
5
6
This program is free software; you can redistribute it and/or modify
7
it under the terms of the GNU General Public License as published by
8
the Free Software Foundation; either version 2 of the License, or
9
(at your option) any later version.
10
This program is distributed in the hope that it will be useful,
11
but WITHOUT ANY WARRANTY.
12
13
See the COPYING file for more details.
14
*/
15
16
#pragma once
17
18
#include "
gui/dialogs/modal_dialog.hpp
"
19
#include "
variable.hpp
"
20
21
namespace
game_events
{
class
manager; }
22
class
display_context
;
23
24
namespace
gui2::dialogs
25
{
26
27
class
gamestate_inspector
:
public
modal_dialog
28
{
29
public
:
30
class
model
;
31
class
view
;
32
class
controller
;
33
gamestate_inspector
(
const
config
& vars,
const
game_events::manager
&
events
,
const
display_context
& dc,
const
std::string& title =
""
);
34
35
DEFINE_SIMPLE_DISPLAY_WRAPPER
(
gamestate_inspector
);
36
37
private
:
38
virtual
void
pre_show
()
override
;
39
40
virtual
const
std::string&
window_id
()
const override
;
41
42
std::shared_ptr<view>
view_
;
43
std::shared_ptr<model>
model_
;
44
std::shared_ptr<controller>
controller_
;
45
std::string
title_
;
46
const
config
&
vars_
;
47
const
game_events::manager
&
events_
;
48
const
display_context
&
dc_
;
49
};
50
}
// namespace dialogs
config
A config object defines a single node in a WML file, with access to child nodes.
Definition:
config.hpp:172
display_context
Abstract class for exposing game data that doesn't depend on the GUI, however which for historical re...
Definition:
display_context.hpp:35
game_events::manager
The game event manager loads the scenario configuration object, and ensures that events are handled a...
Definition:
manager.hpp:45
gui2::dialogs::gamestate_inspector::controller
Definition:
gamestate_inspector.cpp:299
gui2::dialogs::gamestate_inspector::model
Definition:
gamestate_inspector.cpp:71
gui2::dialogs::gamestate_inspector::view
Definition:
gamestate_inspector.cpp:161
gui2::dialogs::gamestate_inspector
Definition:
gamestate_inspector.hpp:28
gui2::dialogs::gamestate_inspector::events_
const game_events::manager & events_
Definition:
gamestate_inspector.hpp:47
gui2::dialogs::gamestate_inspector::vars_
const config & vars_
Definition:
gamestate_inspector.hpp:46
gui2::dialogs::gamestate_inspector::view_
std::shared_ptr< view > view_
Definition:
gamestate_inspector.hpp:42
gui2::dialogs::gamestate_inspector::window_id
virtual const std::string & window_id() const override
The ID of the window to build.
gui2::dialogs::gamestate_inspector::model_
std::shared_ptr< model > model_
Definition:
gamestate_inspector.hpp:43
gui2::dialogs::gamestate_inspector::pre_show
virtual void pre_show() override
Actions to be taken before showing the window.
Definition:
gamestate_inspector.cpp:915
gui2::dialogs::gamestate_inspector::title_
std::string title_
Definition:
gamestate_inspector.hpp:45
gui2::dialogs::gamestate_inspector::controller_
std::shared_ptr< controller > controller_
Definition:
gamestate_inspector.hpp:44
gui2::dialogs::gamestate_inspector::dc_
const display_context & dc_
Definition:
gamestate_inspector.hpp:48
gui2::dialogs::gamestate_inspector::DEFINE_SIMPLE_DISPLAY_WRAPPER
DEFINE_SIMPLE_DISPLAY_WRAPPER(gamestate_inspector)
gui2::dialogs::gamestate_inspector::gamestate_inspector
gamestate_inspector(const config &vars, const game_events::manager &events, const display_context &dc, const std::string &title="")
Definition:
gamestate_inspector.cpp:905
gui2::dialogs::modal_dialog
Abstract base class for all modal dialogs.
Definition:
modal_dialog.hpp:146
modal_dialog.hpp
events
Handling of system events.
Definition:
chat_command_handler.cpp:25
game_events
Domain specific events.
Definition:
callable_objects.hpp:30
gui2::dialogs
Definition:
achievements_dialog.cpp:36
variable.hpp
Generated by
1.9.1