#include <hotkey_handler_sp.hpp>
Public Member Functions | |
hotkey_handler (playsingle_controller &, saved_game &) | |
~hotkey_handler () | |
virtual void | recruit () override |
virtual void | repeat_recruit () override |
virtual void | recall () override |
virtual bool | can_execute_command (const hotkey::ui_command &cmd) const override |
Check if a command can be executed. More... | |
virtual void | toggle_shroud_updates () override |
virtual void | update_shroud_now () override |
virtual void | end_turn () override |
virtual void | rename_unit () override |
virtual void | create_unit () override |
virtual void | change_side () override |
virtual void | select_teleport () override |
virtual void | kill_unit () override |
virtual void | label_terrain (bool) override |
virtual void | clear_labels () override |
virtual void | label_settings () override |
virtual void | continue_move () override |
virtual void | unit_hold_position () override |
virtual void | end_unit_turn () override |
virtual void | user_command () override |
virtual void | custom_command () override |
virtual void | ai_formula () override |
virtual void | clear_messages () override |
virtual void | whiteboard_toggle () override |
virtual void | whiteboard_execute_action () override |
virtual void | whiteboard_execute_all_actions () override |
virtual void | whiteboard_delete_action () override |
virtual void | whiteboard_bump_up_action () override |
virtual void | whiteboard_bump_down_action () override |
virtual void | whiteboard_suppose_dead () override |
replay_controller & | get_replay_controller () |
virtual void | stop_replay () override |
virtual void | play_replay () override |
virtual void | replay_next_turn () override |
virtual void | replay_next_side () override |
virtual void | replay_next_move () override |
virtual void | replay_show_everything () override |
virtual void | replay_show_each () override |
virtual void | replay_show_team1 () override |
virtual void | reset_replay () override |
virtual void | replay_exit () override |
virtual void | load_autosave (const std::string &filename, bool start_replay=false) override |
virtual hotkey::ACTION_STATE | get_action_state (const hotkey::ui_command &) const override |
Public Member Functions inherited from play_controller::hotkey_handler | |
hotkey_handler (play_controller &, saved_game &) | |
~hotkey_handler () | |
virtual void | objectives () override |
virtual void | show_statistics () override |
virtual void | unit_list () override |
virtual void | left_mouse_click () override |
virtual void | move_action () override |
virtual void | select_and_action () override |
virtual void | touch_hex () override |
virtual void | select_hex () override |
virtual void | deselect_hex () override |
virtual void | right_mouse_click () override |
virtual void | status_table () override |
virtual void | save_game () override |
virtual void | save_replay () override |
virtual void | save_map () override |
virtual void | load_game () override |
virtual void | preferences () override |
virtual void | speak () override |
virtual void | show_chat_log () override |
virtual void | show_help () override |
virtual void | cycle_units () override |
virtual void | cycle_back_units () override |
virtual void | undo () override |
virtual void | redo () override |
virtual void | show_enemy_moves (bool ignore_units) override |
virtual void | goto_leader () override |
virtual void | unit_description () override |
virtual void | terrain_description () override |
virtual void | toggle_ellipses () override |
virtual void | toggle_grid () override |
virtual void | search () override |
virtual void | toggle_accelerated_speed () override |
virtual void | scroll_up (bool on) override |
virtual void | scroll_down (bool on) override |
virtual void | scroll_left (bool on) override |
virtual void | scroll_right (bool on) override |
virtual void | replay_skip_animation () override |
virtual std::string | get_action_image (const hotkey::ui_command &) const override |
virtual bool | do_execute_command (const hotkey::ui_command &command, bool press=true, bool release=false) override |
void | show_menu (const std::vector< config > &items_arg, int xloc, int yloc, bool context_menu, display &disp) override |
bool | in_context_menu (const hotkey::ui_command &cmd) const |
Determines whether the command should be in the context menu or not. More... | |
Public Member Functions inherited from hotkey::command_executor_default | |
void | set_button_state () |
void | recalculate_minimap () |
void | lua_console () |
void | zoom_in () |
void | zoom_out () |
void | zoom_default () |
void | map_screenshot () |
void | quit_to_main_menu () |
Public Member Functions inherited from hotkey::command_executor | |
virtual void | whisper () |
virtual void | shout () |
virtual void | stop_network () |
virtual void | start_network () |
virtual void | change_language () |
virtual void | surrender_quit_game () |
std::string | get_menu_image (display &disp, const std::string &command, int index=-1) const |
void | get_menu_images (display &, std::vector< config > &items) |
void | surrender_game () |
void | execute_action (const std::vector< std::string > &items_arg, int xloc, int yloc, bool context_menu, display &gui) |
void | queue_command (const SDL_Event &event, int index=-1) |
bool | run_queued_commands () |
void | execute_quit_command () |
void | handle_keyup () |
Protected Member Functions | |
bool | is_observer () const |
Protected Member Functions inherited from play_controller::hotkey_handler | |
display & | get_display () override |
game_display * | gui () const |
game_state & | gamestate () |
const game_state & | gamestate () const |
bool | browse () const |
bool | linger () const |
Protected Member Functions inherited from hotkey::command_executor | |
virtual | ~command_executor () |
Protected Attributes | |
playsingle_controller & | playsingle_controller_ |
std::shared_ptr< wb::manager > | whiteboard_manager_ |
Protected Attributes inherited from play_controller::hotkey_handler | |
play_controller & | play_controller_ |
References to parent object / constituents. More... | |
events::menu_handler & | menu_handler_ |
events::mouse_handler & | mouse_handler_ |
saved_game & | saved_game_ |
Additional Inherited Members | |
Static Public Attributes inherited from play_controller::hotkey_handler | |
static const std::string | wml_menu_hotkey_prefix = "wml_menu:" |
Definition at line 28 of file hotkey_handler_sp.hpp.
playsingle_controller::hotkey_handler::hotkey_handler | ( | playsingle_controller & | pc, |
saved_game & | sg | ||
) |
Definition at line 42 of file hotkey_handler_sp.cpp.
playsingle_controller::hotkey_handler::~hotkey_handler | ( | ) |
Definition at line 48 of file hotkey_handler_sp.cpp.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 135 of file hotkey_handler_sp.cpp.
References events::menu_handler::ai_formula(), and play_controller::menu_handler_.
|
overridevirtual |
Check if a command can be executed.
Reimplemented from play_controller::hotkey_handler.
Reimplemented in playmp_controller::hotkey_handler.
Definition at line 206 of file hotkey_handler_sp.cpp.
References replay::at_end(), play_controller::hotkey_handler::can_execute_command(), events::commands_disabled, events::menu_handler::current_unit(), game_config::debug, play_controller::gamestate(), game_events::wmi_manager::get_item(), events::mouse_handler::get_last_hex(), events::mouse_handler::get_selected_hex(), game_state::get_wml_menu_items(), hotkey::HOTKEY_CHANGE_SIDE, hotkey::HOTKEY_CLEAR_LABELS, hotkey::ui_command::hotkey_command, hotkey::HOTKEY_CONTINUE_MOVE, hotkey::HOTKEY_CREATE_UNIT, hotkey::HOTKEY_DELAY_SHROUD, hotkey::HOTKEY_END_UNIT_TURN, hotkey::HOTKEY_ENDTURN, hotkey::HOTKEY_KILL_UNIT, hotkey::HOTKEY_LABEL_TEAM_TERRAIN, hotkey::HOTKEY_LABEL_TERRAIN, hotkey::HOTKEY_NULL, hotkey::HOTKEY_RECALL, hotkey::HOTKEY_RECRUIT, hotkey::HOTKEY_REPEAT_RECRUIT, hotkey::HOTKEY_REPLAY_EXIT, hotkey::HOTKEY_REPLAY_NEXT_MOVE, hotkey::HOTKEY_REPLAY_NEXT_SIDE, hotkey::HOTKEY_REPLAY_NEXT_TURN, hotkey::HOTKEY_REPLAY_PLAY, hotkey::HOTKEY_REPLAY_RESET, hotkey::HOTKEY_REPLAY_SHOW_EACH, hotkey::HOTKEY_REPLAY_SHOW_EVERYTHING, hotkey::HOTKEY_REPLAY_SHOW_TEAM1, hotkey::HOTKEY_REPLAY_SKIP_ANIMATION, hotkey::HOTKEY_REPLAY_STOP, hotkey::HOTKEY_SAVE_GAME, hotkey::HOTKEY_TELEPORT_UNIT, hotkey::HOTKEY_UNIT_HOLD_POSITION, hotkey::HOTKEY_UPDATE_SHROUD, hotkey::HOTKEY_WB_BUMP_DOWN_ACTION, hotkey::HOTKEY_WB_BUMP_UP_ACTION, hotkey::HOTKEY_WB_DELETE_ACTION, hotkey::HOTKEY_WB_EXECUTE_ACTION, hotkey::HOTKEY_WB_EXECUTE_ALL_ACTIONS, hotkey::HOTKEY_WB_SUPPOSE_DEAD, hotkey::HOTKEY_WB_TOGGLE, hotkey::HOTKEY_WML, i, hotkey::ui_command::id, play_controller::is_observer(), label, playsingle_controller::linger(), play_controller::menu_handler_, play_controller::mouse_handler_, resources::recorder, unit_map::iterator_base< iter_types >::valid(), and play_controller::whiteboard_manager_.
Referenced by playmp_controller::hotkey_handler::can_execute_command().
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 93 of file hotkey_handler_sp.cpp.
References events::menu_handler::change_side(), play_controller::menu_handler_, and play_controller::mouse_handler_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 109 of file hotkey_handler_sp.cpp.
References events::menu_handler::clear_labels(), and play_controller::menu_handler_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 139 of file hotkey_handler_sp.cpp.
References events::menu_handler::clear_messages(), and play_controller::menu_handler_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 113 of file hotkey_handler_sp.cpp.
References events::menu_handler::continue_move(), play_controller::menu_handler_, and play_controller::mouse_handler_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 89 of file hotkey_handler_sp.cpp.
References events::menu_handler::create_unit(), play_controller::menu_handler_, and play_controller::mouse_handler_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 131 of file hotkey_handler_sp.cpp.
References events::menu_handler::custom_command(), and play_controller::menu_handler_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 81 of file hotkey_handler_sp.cpp.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 122 of file hotkey_handler_sp.cpp.
References events::menu_handler::end_unit_turn(), play_controller::menu_handler_, and play_controller::mouse_handler_.
|
overridevirtual |
Reimplemented from play_controller::hotkey_handler.
Definition at line 196 of file hotkey_handler_sp.cpp.
References hotkey::ACTION_OFF, hotkey::ACTION_ON, play_controller::hotkey_handler::get_action_state(), hotkey::ui_command::hotkey_command, hotkey::HOTKEY_WB_TOGGLE, and play_controller::whiteboard_manager_.
|
inline |
Definition at line 73 of file hotkey_handler_sp.hpp.
References playsingle_controller::get_replay_controller(), and playsingle_controller_.
Referenced by play_replay(), replay_next_move(), replay_next_side(), replay_next_turn(), replay_show_each(), replay_show_everything(), replay_show_team1(), and stop_replay().
|
protected |
Definition at line 50 of file hotkey_handler_sp.cpp.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 97 of file hotkey_handler_sp.cpp.
References events::menu_handler::kill_unit(), play_controller::menu_handler_, and play_controller::mouse_handler_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 143 of file hotkey_handler_sp.cpp.
References events::menu_handler::label_settings(), and play_controller::menu_handler_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 105 of file hotkey_handler_sp.cpp.
References events::menu_handler::label_terrain(), play_controller::menu_handler_, and play_controller::mouse_handler_.
|
overridevirtual |
Reimplemented from play_controller::hotkey_handler.
Definition at line 317 of file hotkey_handler_sp.cpp.
References _(), gui2::CANCEL, filename, filesystem::get_saves_dir(), play_controller::hotkey_handler::load_autosave(), wfl::msg(), savegame::read_save_file(), gui2::show_error_message(), gui2::show_message(), and gui2::dialogs::message::yes_no_buttons.
|
inlineoverridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 80 of file hotkey_handler_sp.hpp.
References get_replay_controller(), and replay_controller::play_replay().
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 66 of file hotkey_handler_sp.cpp.
References events::mouse_handler::get_last_hex(), play_controller::menu_handler_, play_controller::mouse_handler_, events::menu_handler::recall(), and play_controller::whiteboard_manager_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 52 of file hotkey_handler_sp.cpp.
References events::mouse_handler::get_last_hex(), play_controller::menu_handler_, play_controller::mouse_handler_, events::menu_handler::recruit(), and play_controller::whiteboard_manager_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 85 of file hotkey_handler_sp.cpp.
References play_controller::menu_handler_, and events::menu_handler::rename_unit().
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 59 of file hotkey_handler_sp.cpp.
References events::mouse_handler::get_last_hex(), play_controller::menu_handler_, play_controller::mouse_handler_, events::menu_handler::repeat_recruit(), and play_controller::whiteboard_manager_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 355 of file hotkey_handler_sp.cpp.
References replay::delete_upcoming_commands(), and resources::recorder.
|
inlineoverridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 86 of file hotkey_handler_sp.hpp.
References get_replay_controller(), and replay_controller::replay_next_move().
|
inlineoverridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 84 of file hotkey_handler_sp.hpp.
References get_replay_controller(), and replay_controller::replay_next_side().
|
inlineoverridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 82 of file hotkey_handler_sp.hpp.
References get_replay_controller(), and replay_controller::replay_next_turn().
|
inlineoverridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 90 of file hotkey_handler_sp.hpp.
References get_replay_controller(), and replay_controller::replay_show_each().
|
inlineoverridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 88 of file hotkey_handler_sp.hpp.
References get_replay_controller(), and replay_controller::replay_show_everything().
|
inlineoverridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 92 of file hotkey_handler_sp.hpp.
References get_replay_controller(), and replay_controller::replay_show_team1().
|
inlineoverridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 94 of file hotkey_handler_sp.hpp.
References playsingle_controller_, and playsingle_controller::reset_replay().
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 101 of file hotkey_handler_sp.cpp.
References play_controller::mouse_handler_, and events::mouse_handler::select_teleport().
|
inlineoverridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 78 of file hotkey_handler_sp.hpp.
References get_replay_controller(), and replay_controller::stop_replay().
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 73 of file hotkey_handler_sp.cpp.
References play_controller::menu_handler_, and events::menu_handler::toggle_shroud_updates().
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 117 of file hotkey_handler_sp.cpp.
References play_controller::menu_handler_, play_controller::mouse_handler_, and events::menu_handler::unit_hold_position().
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 77 of file hotkey_handler_sp.cpp.
References play_controller::menu_handler_, and events::menu_handler::update_shroud_now().
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 127 of file hotkey_handler_sp.cpp.
References play_controller::menu_handler_, and events::menu_handler::user_command().
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 180 of file hotkey_handler_sp.cpp.
References play_controller::whiteboard_manager_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 175 of file hotkey_handler_sp.cpp.
References play_controller::whiteboard_manager_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 171 of file hotkey_handler_sp.cpp.
References play_controller::whiteboard_manager_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 163 of file hotkey_handler_sp.cpp.
References play_controller::whiteboard_manager_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 167 of file hotkey_handler_sp.cpp.
References play_controller::whiteboard_manager_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 185 of file hotkey_handler_sp.cpp.
References events::menu_handler::current_unit(), unit::get_location(), loc, play_controller::menu_handler_, and play_controller::whiteboard_manager_.
|
overridevirtual |
Reimplemented from hotkey::command_executor.
Definition at line 147 of file hotkey_handler_sp.cpp.
References _(), hotkey::hotkey_command::get_command_by_command(), hotkey::get_names(), hotkey::HOTKEY_WB_TOGGLE, font::NORMAL_COLOR, VGETTEXT, and play_controller::whiteboard_manager_.
|
protected |
Definition at line 31 of file hotkey_handler_sp.hpp.
Referenced by get_replay_controller(), and reset_replay().
|
protected |
Definition at line 33 of file hotkey_handler_sp.hpp.