aboutsummaryrefslogtreecommitdiff
path: root/engines/scumm/dialogs.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/scumm/dialogs.cpp')
-rw-r--r--engines/scumm/dialogs.cpp14
1 files changed, 6 insertions, 8 deletions
diff --git a/engines/scumm/dialogs.cpp b/engines/scumm/dialogs.cpp
index fc21b10b8d..b193683337 100644
--- a/engines/scumm/dialogs.cpp
+++ b/engines/scumm/dialogs.cpp
@@ -591,14 +591,6 @@ ConfigDialog::ConfigDialog()
#ifdef SMALL_SCREEN_DEVICE
new GUI::ButtonWidget(this, "ScummConfig.Keys", "Keys", kKeysCmd, 'K');
#endif
-
-#ifdef SMALL_SCREEN_DEVICE
- //
- // Create the sub dialog(s)
- //
-
- _keysDialog = new GUI::KeysDialog();
-#endif
}
ConfigDialog::~ConfigDialog() {
@@ -611,7 +603,13 @@ void ConfigDialog::handleCommand(CommandSender *sender, uint32 cmd, uint32 data)
switch (cmd) {
case kKeysCmd:
#ifdef SMALL_SCREEN_DEVICE
+ //
+ // Create the sub dialog(s)
+ //
+ _keysDialog = new GUI::KeysDialog();
_keysDialog->runModal();
+ delete _keysDialog;
+ _keysDialog = NULL;
#endif
break;
default: