aboutsummaryrefslogtreecommitdiff
path: root/backends/events/default
diff options
context:
space:
mode:
authorMax Horn2008-11-11 12:28:46 +0000
committerMax Horn2008-11-11 12:28:46 +0000
commitd08192cb04e391b9b148a4bc3921c546476339eb (patch)
tree41546ba143243d01f68c282e4a286086fb7bac50 /backends/events/default
parenta39c78a1bab1f734ccb9fd54bbb23ca8d3b26279 (diff)
downloadscummvm-rg350-d08192cb04e391b9b148a4bc3921c546476339eb.tar.gz
scummvm-rg350-d08192cb04e391b9b148a4bc3921c546476339eb.tar.bz2
scummvm-rg350-d08192cb04e391b9b148a4bc3921c546476339eb.zip
If confirm_exit is set, also ask the user if he really wants to return to the launcher (after all, as with quit, all data is lost)
svn-id: r35003
Diffstat (limited to 'backends/events/default')
-rw-r--r--backends/events/default/default-events.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/backends/events/default/default-events.cpp b/backends/events/default/default-events.cpp
index 739987d64c..80c1b872c7 100644
--- a/backends/events/default/default-events.cpp
+++ b/backends/events/default/default-events.cpp
@@ -469,14 +469,22 @@ bool DefaultEventManager::pollEvent(Common::Event &event) {
break;
case Common::EVENT_RTL:
- _shouldRTL = true;
+ if (ConfMan.getBool("confirm_exit")) {
+ if (g_engine)
+ g_engine->pauseEngine(true);
+ GUI::MessageDialog alert("Do you really want to return to the Launcher?", "Launcher", "Cancel");
+ result = _shouldRTL = (alert.runModal() == GUI::kMessageOK);
+ if (g_engine)
+ g_engine->pauseEngine(false);
+ } else
+ _shouldRTL = true;
break;
case Common::EVENT_QUIT:
if (ConfMan.getBool("confirm_exit")) {
if (g_engine)
g_engine->pauseEngine(true);
- GUI::MessageDialog alert("Do you really want to quit?", "Yes", "No");
+ GUI::MessageDialog alert("Do you really want to quit?", "Quit", "Cancel");
result = _shouldQuit = (alert.runModal() == GUI::kMessageOK);
if (g_engine)
g_engine->pauseEngine(false);