aboutsummaryrefslogtreecommitdiff
path: root/gui
diff options
context:
space:
mode:
authorWillem Jan Palenstijn2009-02-15 22:07:19 +0000
committerWillem Jan Palenstijn2009-02-15 22:07:19 +0000
commit26f45be083d67eafe1e2f6f30a2e717b43d3d31d (patch)
treef148a607df0bdbcfe8df42aaf6a505439f81755f /gui
parent4eff1002f99c15c213144c2aef1bf49c1bbb65e6 (diff)
downloadscummvm-rg350-26f45be083d67eafe1e2f6f30a2e717b43d3d31d.tar.gz
scummvm-rg350-26f45be083d67eafe1e2f6f30a2e717b43d3d31d.tar.bz2
scummvm-rg350-26f45be083d67eafe1e2f6f30a2e717b43d3d31d.zip
properly (re)select game after adding/editing domain name in launcher
svn-id: r38313
Diffstat (limited to 'gui')
-rw-r--r--gui/launcher.cpp7
-rw-r--r--gui/options.h1
2 files changed, 5 insertions, 3 deletions
diff --git a/gui/launcher.cpp b/gui/launcher.cpp
index 2cf6d4c478..4748ac5468 100644
--- a/gui/launcher.cpp
+++ b/gui/launcher.cpp
@@ -703,7 +703,7 @@ void LauncherDialog::addGame() {
// Update the ListWidget, select the new item, and force a redraw
updateListing();
- selectGame(domain);
+ selectGame(editDialog.getDomain());
draw();
} else {
// User aborted, remove the the new domain again
@@ -773,7 +773,7 @@ void LauncherDialog::removeGame(int item) {
}
void LauncherDialog::editGame(int item) {
- // Set game specifc options. Most of these should be "optional", i.e. by
+ // Set game specific options. Most of these should be "optional", i.e. by
// default set nothing and use the global ScummVM settings. E.g. the user
// can set here an optional alternate music volume, or for specific games
// a different music driver etc.
@@ -790,8 +790,9 @@ void LauncherDialog::editGame(int item) {
// Write config to disk
ConfMan.flushToDisk();
- // Update the ListWidget and force a redraw
+ // Update the ListWidget, reselect the edited game and force a redraw
updateListing();
+ selectGame(editDialog.getDomain());
draw();
}
}
diff --git a/gui/options.h b/gui/options.h
index 63caf68c32..aca5db83cd 100644
--- a/gui/options.h
+++ b/gui/options.h
@@ -53,6 +53,7 @@ public:
void open();
void close();
void handleCommand(CommandSender *sender, uint32 cmd, uint32 data);
+ const Common::String& getDomain() const { return _domain; }
virtual void reflowLayout();