(svn r2675) - Fix: pressing enter on a load-window resulted in saving the game (Luca)

This commit is contained in:
Darkvater 2005-07-22 09:16:34 +00:00
parent aa29ee6eda
commit 290bb2fda6
1 changed files with 8 additions and 4 deletions

View File

@ -1315,10 +1315,14 @@ static void SaveLoadDlgWndProc(Window *w, WindowEvent *e)
HandleEditBox(w, 9);
break;
case WE_KEYPRESS:
switch (HandleEditBoxKey(w, 9, e)) {
case 1:
HandleButtonClick(w, 11);
break;
if (e->keypress.keycode == WKC_ESC) {
DeleteWindow(w);
return;
}
if (_saveload_mode == SLD_SAVE_GAME || _saveload_mode == SLD_SAVE_SCENARIO) {
if (HandleEditBoxKey(w, 9, e) == 1) /* Press Enter */
HandleButtonClick(w, 11);
}
break;
case WE_TIMEOUT: