diff options
author | Matthew Hoops | 2011-06-03 01:14:16 -0400 |
---|---|---|
committer | Matthew Hoops | 2011-06-03 01:14:16 -0400 |
commit | 224c71e483e09931ba386555ff3b436b9defe63d (patch) | |
tree | 8e6178331a7bbd3ee1be318d3fc7a7c7f478468f /gui/gui-manager.cpp | |
parent | d4c92983920cfe3b25a22d91e12c750e591b917e (diff) | |
parent | 547fd1bdcabcba0e741eb31100ba99ff73399d24 (diff) | |
download | scummvm-rg350-224c71e483e09931ba386555ff3b436b9defe63d.tar.gz scummvm-rg350-224c71e483e09931ba386555ff3b436b9defe63d.tar.bz2 scummvm-rg350-224c71e483e09931ba386555ff3b436b9defe63d.zip |
Merge remote branch 'upstream/master' into pegasus
Diffstat (limited to 'gui/gui-manager.cpp')
-rw-r--r-- | gui/gui-manager.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/gui/gui-manager.cpp b/gui/gui-manager.cpp index ef2f89df9c..af1852d56d 100644 --- a/gui/gui-manager.cpp +++ b/gui/gui-manager.cpp @@ -74,6 +74,14 @@ GuiManager::GuiManager() : _redrawStatus(kRedrawDisabled), _stateIsSaved(false), ConfMan.registerDefault("gui_renderer", ThemeEngine::findModeConfigName(ThemeEngine::_defaultRendererMode)); ThemeEngine::GraphicsMode gfxMode = (ThemeEngine::GraphicsMode)ThemeEngine::findMode(ConfMan.get("gui_renderer")); +#ifdef __DS__ + // Searching for the theme file takes ~10 seconds on the DS. + // Disable this search here because external themes are not supported. + if (!loadNewTheme("builtin", gfxMode)) { + // Loading the built-in theme failed as well. Bail out + error("Failed to load any GUI theme, aborting"); + } +#else // Try to load the theme if (!loadNewTheme(themefile, gfxMode)) { // Loading the theme failed, try to load the built-in theme @@ -82,6 +90,7 @@ GuiManager::GuiManager() : _redrawStatus(kRedrawDisabled), _stateIsSaved(false), error("Failed to load any GUI theme, aborting"); } } +#endif } GuiManager::~GuiManager() { @@ -297,7 +306,7 @@ void GuiManager::runLoop() { // dialog-related events since they were probably generated while the old dialog // was still visible, and therefore not intended for the new one. // - // This hopefully fixes strange behaviour/crashes with pop-up widgets. (Most easily + // This hopefully fixes strange behavior/crashes with pop-up widgets. (Most easily // triggered in 3x mode or when running ScummVM under Valgrind.) if (activeDialog != getTopDialog() && event.type != Common::EVENT_SCREEN_CHANGED) continue; |