diff options
author | Max Horn | 2005-02-18 00:28:56 +0000 |
---|---|---|
committer | Max Horn | 2005-02-18 00:28:56 +0000 |
commit | 695b0fcb5fab7803340c23c27e36940ce98a886c (patch) | |
tree | f3f22dc1e22ed2d8fff6a4fc0fc65752cbfc88fe /scumm | |
parent | 05f4bf51510cba098d6073eddea885f903b7847d (diff) | |
download | scummvm-rg350-695b0fcb5fab7803340c23c27e36940ce98a886c.tar.gz scummvm-rg350-695b0fcb5fab7803340c23c27e36940ce98a886c.tar.bz2 scummvm-rg350-695b0fcb5fab7803340c23c27e36940ce98a886c.zip |
Fix a small bug (wrong mouse cursor is briefly shown) in the F5 menu
svn-id: r16804
Diffstat (limited to 'scumm')
-rw-r--r-- | scumm/dialogs.cpp | 4 | ||||
-rw-r--r-- | scumm/dialogs.h | 1 | ||||
-rw-r--r-- | scumm/scumm.cpp | 10 | ||||
-rw-r--r-- | scumm/scumm.h | 3 |
4 files changed, 5 insertions, 13 deletions
diff --git a/scumm/dialogs.cpp b/scumm/dialogs.cpp index 73149878e4..6ef9a7de00 100644 --- a/scumm/dialogs.cpp +++ b/scumm/dialogs.cpp @@ -303,6 +303,7 @@ MainMenuDialog::MainMenuDialog(ScummEngine *scumm) // Create the sub dialog(s) // _aboutDialog = new GUI::AboutDialog(); + _optionsDialog = new ConfigDialog(scumm); #ifndef DISABLE_HELP _helpDialog = new HelpDialog(scumm); #endif @@ -312,6 +313,7 @@ MainMenuDialog::MainMenuDialog(ScummEngine *scumm) MainMenuDialog::~MainMenuDialog() { delete _aboutDialog; + delete _optionsDialog; #ifndef DISABLE_HELP delete _helpDialog; #endif @@ -331,7 +333,7 @@ void MainMenuDialog::handleCommand(CommandSender *sender, uint32 cmd, uint32 dat close(); break; case kOptionsCmd: - _vm->optionsDialog(); + _optionsDialog->runModal(); break; case kAboutCmd: _aboutDialog->runModal(); diff --git a/scumm/dialogs.h b/scumm/dialogs.h index ad4137e78b..e9eedeecb3 100644 --- a/scumm/dialogs.h +++ b/scumm/dialogs.h @@ -64,6 +64,7 @@ public: protected: GUI::Dialog *_aboutDialog; + GUI::Dialog *_optionsDialog; #ifndef DISABLE_HELP GUI::Dialog *_helpDialog; #endif diff --git a/scumm/scumm.cpp b/scumm/scumm.cpp index 06785688b7..395ae16e89 100644 --- a/scumm/scumm.cpp +++ b/scumm/scumm.cpp @@ -551,7 +551,7 @@ ScummEngine::ScummEngine(GameDetector *detector, OSystem *syst, const ScummGameS _heversion(gs.heversion), _numActors(gs.numActors), _features(gs.features), - gdi(this), _pauseDialog(0), _optionsDialog(0), _mainMenuDialog(0), _versionDialog(0), + gdi(this), _pauseDialog(0), _mainMenuDialog(0), _versionDialog(0), _targetName(detector->_targetName) { // Copy MD5 checksum @@ -641,7 +641,6 @@ ScummEngine::ScummEngine(GameDetector *detector, OSystem *syst, const ScummGameS _insaneRunning = false; _quit = false; _pauseDialog = NULL; - _optionsDialog = NULL; _mainMenuDialog = NULL; _versionDialog = NULL; _fastMode = 0; @@ -1041,7 +1040,6 @@ ScummEngine::~ScummEngine() { delete _2byteFontPtr; delete _charset; delete _pauseDialog; - delete _optionsDialog; delete _mainMenuDialog; delete _versionDialog; @@ -2585,12 +2583,6 @@ void ScummEngine::mainMenuDialog() { runDialog(*_mainMenuDialog); } -void ScummEngine::optionsDialog() { - if (!_optionsDialog) - _optionsDialog = new ConfigDialog(this); - runDialog(*_optionsDialog); -} - void ScummEngine::confirmexitDialog() { ConfirmDialog confirmExitDialog(this, "Do you really want to quit (y/n)?"); diff --git a/scumm/scumm.h b/scumm/scumm.h index ce17d6e59c..091635c8e9 100644 --- a/scumm/scumm.h +++ b/scumm/scumm.h @@ -412,7 +412,6 @@ public: protected: Dialog *_pauseDialog; Dialog *_versionDialog; - Dialog *_optionsDialog; Dialog *_mainMenuDialog; protected: @@ -422,8 +421,6 @@ protected: void pauseDialog(); void versionDialog(); void mainMenuDialog(); -public: - void optionsDialog(); // Used by MainMenuDialog::handleCommand() protected: char displayMessage(const char *altButton, const char *message, ...); |