From 4406ac5e021e55112fdb2d1e632a7607924136a0 Mon Sep 17 00:00:00 2001 From: Marko Lindqvist Date: Sat, 15 Oct 2022 15:28:19 +0300 Subject: [PATCH 39/39] Free "m" for "Connect with Maglev" Keys rearranged to be: - Show City Output: v (All clients) - Show Fog of War: w (sdl2) - Toggle Fog of War: w (gtk) See osdn #45800 Signed-off-by: Marko Lindqvist --- client/gui-gtk-3.22/menu.c | 5 +++-- client/gui-gtk-4.0/menu.c | 5 +++-- client/gui-qt/shortcuts.cpp | 2 +- client/gui-sdl2/mapctrl.c | 14 +++++++------- data/helpdata.txt | 6 +++--- 5 files changed, 17 insertions(+), 15 deletions(-) diff --git a/client/gui-gtk-3.22/menu.c b/client/gui-gtk-3.22/menu.c index 5c255eba28..e4c24bc225 100644 --- a/client/gui-gtk-3.22/menu.c +++ b/client/gui-gtk-3.22/menu.c @@ -369,7 +369,7 @@ static struct menu_entry_info menu_entries[] = G_CALLBACK(edit_mode_callback), MGROUP_SAFE }, { "SHOW_CITY_OUTLINES", N_("Cit_y Outlines"), GDK_KEY_y, GDK_CONTROL_MASK, G_CALLBACK(show_city_outlines_callback), MGROUP_SAFE }, - { "SHOW_CITY_OUTPUT", N_("City Output"), GDK_KEY_w, GDK_CONTROL_MASK, + { "SHOW_CITY_OUTPUT", N_("City Output"), GDK_KEY_v, GDK_CONTROL_MASK, G_CALLBACK(show_city_output_callback), MGROUP_SAFE }, { "SHOW_MAP_GRID", N_("Map _Grid"), GDK_KEY_g, GDK_CONTROL_MASK, G_CALLBACK(show_map_grid_callback), MGROUP_SAFE }, @@ -424,7 +424,8 @@ static struct menu_entry_info menu_entries[] = { "RECALC_BORDERS", N_("Recalculate _Borders"), 0, 0, G_CALLBACK(recalc_borders_callback), MGROUP_EDIT }, - { "TOGGLE_FOG", N_("Toggle Fog of _War"), GDK_KEY_m, GDK_CONTROL_MASK, + { "TOGGLE_FOG", N_("Toggle Fog of _War"), GDK_KEY_w, + GDK_CONTROL_MASK | GDK_SHIFT_MASK, G_CALLBACK(toggle_fog_callback), MGROUP_EDIT }, { "SCENARIO_PROPERTIES", N_("Game/Scenario Properties"), 0, 0, G_CALLBACK(scenario_properties_callback), MGROUP_EDIT }, diff --git a/client/gui-gtk-4.0/menu.c b/client/gui-gtk-4.0/menu.c index b84bcca5b4..4027d726de 100644 --- a/client/gui-gtk-4.0/menu.c +++ b/client/gui-gtk-4.0/menu.c @@ -543,7 +543,7 @@ static struct menu_entry_info menu_entries[] = G_CALLBACK(edit_mode_callback), MGROUP_SAFE }, { "SHOW_CITY_OUTLINES", N_("Cit_y Outlines"), GDK_KEY_y, GDK_CONTROL_MASK, G_CALLBACK(show_city_outlines_callback), MGROUP_SAFE }, - { "SHOW_CITY_OUTPUT", N_("City Output"), GDK_KEY_w, GDK_CONTROL_MASK, + { "SHOW_CITY_OUTPUT", N_("City Output"), GDK_KEY_v, GDK_CONTROL_MASK, G_CALLBACK(show_city_output_callback), MGROUP_SAFE }, { "SHOW_MAP_GRID", N_("Map _Grid"), GDK_KEY_g, GDK_CONTROL_MASK, G_CALLBACK(show_map_grid_callback), MGROUP_SAFE }, @@ -598,7 +598,8 @@ static struct menu_entry_info menu_entries[] = { "RECALC_BORDERS", N_("Recalculate _Borders"), 0, 0, G_CALLBACK(recalc_borders_callback), MGROUP_EDIT }, - { "TOGGLE_FOG", N_("Toggle Fog of _War"), GDK_KEY_m, GDK_CONTROL_MASK, + { "TOGGLE_FOG", N_("Toggle Fog of _War"), GDK_KEY_w, + GDK_CONTROL_MASK | GDK_SHIFT_MASK, G_CALLBACK(toggle_fog_callback), MGROUP_EDIT }, { "SCENARIO_PROPERTIES", N_("Game/Scenario Properties"), 0, 0, G_CALLBACK(scenario_properties_callback), MGROUP_EDIT }, diff --git a/client/gui-qt/shortcuts.cpp b/client/gui-qt/shortcuts.cpp index e8a3116b9b..f34a5e784f 100644 --- a/client/gui-qt/shortcuts.cpp +++ b/client/gui-qt/shortcuts.cpp @@ -63,7 +63,7 @@ fc_shortcut default_shortcuts[] = { _("Fullscreen") }, {SC_MINIMAP, Qt::Key_M, Qt::AllButtons, Qt::ControlModifier, _("Show minimap") }, - {SC_CITY_OUTPUT, Qt::Key_W, Qt::AllButtons, Qt::ControlModifier, + {SC_CITY_OUTPUT, Qt::Key_V, Qt::AllButtons, Qt::ControlModifier, _("City Output") }, {SC_MAP_GRID, Qt::Key_G, Qt::AllButtons, Qt::ControlModifier, _("Map Grid") }, diff --git a/client/gui-sdl2/mapctrl.c b/client/gui-sdl2/mapctrl.c index 4db7f4a6a0..077b36115a 100644 --- a/client/gui-sdl2/mapctrl.c +++ b/client/gui-sdl2/mapctrl.c @@ -2645,15 +2645,15 @@ bool map_event_handler(SDL_Keysym key) /* (show focus unit) */ - /* show city output - Ctrl+w - * show fog of war - Ctrl+Shift+w */ + /* Show city output - Ctrl+v */ + case SDLK_v: + key_city_output_toggle(); + return FALSE; + + /* Show fog of war - Ctrl+w */ case SDLK_w: if (LCTRL || RCTRL) { - if (LSHIFT || RSHIFT) { - key_fog_of_war_toggle(); - } else { - key_city_output_toggle(); - } + key_fog_of_war_toggle(); } return FALSE; diff --git a/data/helpdata.txt b/data/helpdata.txt index 6bb516fa1a..f1b5255820 100644 --- a/data/helpdata.txt +++ b/data/helpdata.txt @@ -1713,7 +1713,7 @@ Main Map (Keys):\n\ Ctrl-N: show/hide city names\n\ Ctrl-P: show/hide city production\n\ Ctrl-O: show/hide city growth\n\ - Ctrl-W: show/hide city output\n\ + Ctrl-V: show/hide city output values\n\ Ctrl-Y: show/hide city outlines\n\ "), _("\ Main Map (Mouse):\n\ @@ -1799,8 +1799,8 @@ Shift-Return: Turn done\ "), _("\ Editing Mode (GTK):\n\ ===================\n\ - Ctrl-E: toggle editing mode\n\ - Ctrl-M: toggle fog of war in editing mode\n\ + Ctrl-E: toggle editing mode\n\ + Ctrl-Shift-W: toggle fog of war in editing mode\n\ "), _("\ Battle Groups (GTK):\n\ ====================\n\ -- 2.35.1