aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEngin Manap2011-04-15 17:15:36 +0300
committerEngin Manap2011-04-17 16:18:32 +0300
commit8463649f49fd07736389113e08c3f6a7b1e2bc73 (patch)
treecae96e6b1b287c1b7539cb2a3532de1a6ad53a85
parenta1509af8b67a8d1419eb81ce63aca2eee9932d88 (diff)
downloadscummvm-rg350-8463649f49fd07736389113e08c3f6a7b1e2bc73.tar.gz
scummvm-rg350-8463649f49fd07736389113e08c3f6a7b1e2bc73.tar.bz2
scummvm-rg350-8463649f49fd07736389113e08c3f6a7b1e2bc73.zip
GUI: Fix apply old theme even if theme is not changed.
There was no control if theme was changed. If you click cancel, it always changes theme to which options panel opened with. This is unneccessery if theme is not changed so a if statement added before applying old theme.
-rw-r--r--gui/options.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/gui/options.cpp b/gui/options.cpp
index 5752702f5c..1dd358d7e4 100644
--- a/gui/options.cpp
+++ b/gui/options.cpp
@@ -511,8 +511,10 @@ void OptionsDialog::handleCommand(CommandSender *sender, uint32 cmd, uint32 data
close();
break;
case kCloseCmd:
+ if (g_gui.theme()->getThemeId() != _oldTheme ) {
g_gui.loadNewTheme(_oldTheme);
ConfMan.set("gui_theme", _oldTheme);
+ }
close();
break;
default: