Update for hotkey-patch #770
This commit is contained in:
parent
3e045365c1
commit
7f0c9b0a66
8 changed files with 16 additions and 17 deletions
|
@ -757,8 +757,8 @@ bool event_handler::handle_event_command(const queued_event& event_info,
|
|||
state_of_game->get_variable(var_name) = lexical_cast_default<std::string>(turns,"");
|
||||
}
|
||||
|
||||
//moving a 'unit' - i.e. a dummy unit that is just moving for
|
||||
//the visual effect
|
||||
// Moving a 'unit' - i.e. a dummy unit
|
||||
// that is just moving for the visual effect
|
||||
else if(cmd == "move_unit_fake") {
|
||||
std::string type = cfg["type"];
|
||||
std::string side = cfg["side"];
|
||||
|
@ -1928,7 +1928,7 @@ bool event_handler::handle_event_command(const queued_event& event_info,
|
|||
//The code in dialogs::advance_unit tests whether the unit can advance
|
||||
dialogs::advance_unit(*game_data_ptr, *game_map, *units, loc, *screen, !sel, true);
|
||||
}
|
||||
|
||||
|
||||
} else {
|
||||
player_info *player=state_of_game->get_player((*teams)[u.side()-1].save_id());
|
||||
|
||||
|
|
|
@ -131,7 +131,7 @@ const struct {
|
|||
{ hotkey::HOTKEY_LANGUAGE, "changelanguage", N_("Change the language"), true },
|
||||
|
||||
{ hotkey::HOTKEY_USER_CMD, "command", N_("Enter user command"), false },
|
||||
{ hotkey::HOTKEY_USER_CMD_1, "clearmessages", N_("Clear messages"), false },
|
||||
{ hotkey::HOTKEY_CLEAR_MSG, "clearmessages", N_("Clear messages"), false },
|
||||
#ifdef USRCMD2
|
||||
{ hotkey::HOTKEY_USER_CMD_2, "usercommand#2", N_("User-Command#2"), false },
|
||||
{ hotkey::HOTKEY_USER_CMD_3, "usercommand#3", N_("User-Command#3"), false },
|
||||
|
@ -637,8 +637,8 @@ bool command_executor::execute_command(HOTKEY_COMMAND command, int /*index*/)
|
|||
user_command();
|
||||
break;
|
||||
//%%
|
||||
case HOTKEY_USER_CMD_1:
|
||||
user_command_1();
|
||||
case HOTKEY_CLEAR_MSG:
|
||||
clear_messages();
|
||||
break;
|
||||
#ifdef USRCMD2
|
||||
case HOTKEY_USER_CMD_2:
|
||||
|
@ -646,7 +646,6 @@ bool command_executor::execute_command(HOTKEY_COMMAND command, int /*index*/)
|
|||
user_command_2();
|
||||
break;
|
||||
case HOTKEY_USER_CMD_3:
|
||||
//user_command();
|
||||
user_command_3();
|
||||
break;
|
||||
#endif
|
||||
|
|
|
@ -60,7 +60,7 @@ enum HOTKEY_COMMAND {
|
|||
|
||||
//misc.
|
||||
HOTKEY_USER_CMD,
|
||||
HOTKEY_USER_CMD_1,
|
||||
HOTKEY_CLEAR_MSG,
|
||||
#ifdef USRCMD2
|
||||
HOTKEY_USER_CMD_2,
|
||||
HOTKEY_USER_CMD_3,
|
||||
|
@ -195,7 +195,7 @@ public:
|
|||
virtual void show_help() {}
|
||||
virtual void show_chat_log() {}
|
||||
virtual void user_command() {}
|
||||
virtual void user_command_1() {}
|
||||
virtual void clear_messages() {}
|
||||
#ifdef USRCMD2
|
||||
virtual void user_command_2() {}
|
||||
virtual void user_command_3() {}
|
||||
|
|
|
@ -1973,10 +1973,10 @@ namespace events{
|
|||
{
|
||||
textbox_info_.show(gui::TEXTBOX_COMMAND,sgettext("prompt^Command:"), "", false, *gui_);
|
||||
}
|
||||
//%%
|
||||
void menu_handler::user_command_1()
|
||||
|
||||
void menu_handler::clear_messages()
|
||||
{
|
||||
gui_->clear_chat_messages(); // clear messages
|
||||
gui_->clear_chat_messages(); // also clear debug-messages and WML-error-messages
|
||||
}
|
||||
|
||||
#ifdef USRCMD2
|
||||
|
|
|
@ -105,7 +105,7 @@ public:
|
|||
void end_unit_turn(mouse_handler& mousehandler, const unsigned int team_num);
|
||||
void search();
|
||||
void user_command();
|
||||
void user_command_1();
|
||||
void clear_messages();
|
||||
#ifdef USRCMD2
|
||||
void user_command_2();
|
||||
void user_command_3();
|
||||
|
|
|
@ -505,7 +505,7 @@ bool play_controller::can_execute_command(hotkey::HOTKEY_COMMAND command, int in
|
|||
case hotkey::HOTKEY_SEARCH:
|
||||
case hotkey::HOTKEY_HELP:
|
||||
case hotkey::HOTKEY_USER_CMD:
|
||||
case hotkey::HOTKEY_USER_CMD_1:
|
||||
case hotkey::HOTKEY_CLEAR_MSG:
|
||||
#ifdef USRCMD2
|
||||
case hotkey::HOTKEY_USER_CMD_2:
|
||||
case hotkey::HOTKEY_USER_CMD_3:
|
||||
|
|
|
@ -116,8 +116,8 @@ void playsingle_controller::user_command(){
|
|||
menu_handler_.user_command();
|
||||
}
|
||||
|
||||
void playsingle_controller::user_command_1(){
|
||||
menu_handler_.user_command_1(); // clear messages
|
||||
void playsingle_controller::clear_messages(){
|
||||
menu_handler_.clear_messages();
|
||||
}
|
||||
|
||||
#ifdef USRCMD2
|
||||
|
|
|
@ -52,7 +52,7 @@ public:
|
|||
virtual void unit_hold_position();
|
||||
virtual void end_unit_turn();
|
||||
virtual void user_command();
|
||||
virtual void user_command_1();
|
||||
virtual void clear_messages();
|
||||
#ifdef USRCMD2
|
||||
virtual void user_command_2();
|
||||
virtual void user_command_3();
|
||||
|
|
Loading…
Add table
Reference in a new issue