← Back to team overview

widelands-dev team mailing list archive

[Merge] lp:~widelands-dev/widelands/bug-1800182-focus-save-menu into lp:widelands

 

Notabilis has proposed merging lp:~widelands-dev/widelands/bug-1800182-focus-save-menu into lp:widelands.

Commit message:
Setting focus to edit box when opening the game save menu.

Requested reviews:
  Widelands Developers (widelands-dev)
Related bugs:
  Bug #1800182 in widelands: "Focus missing when saving game from replay"
  https://bugs.launchpad.net/widelands/+bug/1800182

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/bug-1800182-focus-save-menu/+merge/358284

When the game save menu is opened, the keyboard focus isn't set to the filename input edit box. Besides the inconvenience of having to click in the edit box before entering the filename, keyboard input also modifies the state of the game, e.g., opening the minimap.
-- 
Your team Widelands Developers is requested to review the proposed merge of lp:~widelands-dev/widelands/bug-1800182-focus-save-menu into lp:widelands.
=== modified file 'src/wui/game_main_menu_save_game.cc'
--- src/wui/game_main_menu_save_game.cc	2018-10-26 07:09:29 +0000
+++ src/wui/game_main_menu_save_game.cc	2018-11-04 08:51:30 +0000
@@ -115,6 +115,7 @@
 	center_to_parent();
 	move_to_top();
 
+	filename_editbox_.focus();
 	pause_game(true);
 	set_thinks(false);
 	layout();


Follow ups