[Scummvm-cvs-logs] SF.net SVN: scummvm:[34975] scummvm/trunk/gui/launcher.cpp
lordhoto at users.sourceforge.net
lordhoto at users.sourceforge.net
Sun Nov 9 21:33:15 CET 2008
Revision: 34975
http://scummvm.svn.sourceforge.net/scummvm/?rev=34975&view=rev
Author: lordhoto
Date: 2008-11-09 20:33:15 +0000 (Sun, 09 Nov 2008)
Log Message:
-----------
Cleanup (and a little bug fix :-P).
Modified Paths:
--------------
scummvm/trunk/gui/launcher.cpp
Modified: scummvm/trunk/gui/launcher.cpp
===================================================================
--- scummvm/trunk/gui/launcher.cpp 2008-11-09 20:22:43 UTC (rev 34974)
+++ scummvm/trunk/gui/launcher.cpp 2008-11-09 20:33:15 UTC (rev 34975)
@@ -714,9 +714,16 @@
}
- // Disable these buttons if nothing is selected, or if an empty
- // list item is selected.
- _chooseButton->setEnabled(selItem >= 0 && ((!_list->getSelectedString().empty())) || (_list->isEditable() && !isWriteProtected));
+ if (_list->isEditable()) {
+ // Disable the save button if nothing is selected, or if the selected
+ // game is write protected
+ _chooseButton->setEnabled(selItem >= 0 && !isWriteProtected);
+ } else {
+ // Disable the load button if nothing is selected, or if an empty
+ // list item is selected.
+ _chooseButton->setEnabled(selItem >= 0 && !_list->getSelectedString().empty());
+ }
+
// Delete will always be disabled if the engine doesn't support it.
_deleteButton->setEnabled(isDeletable && (selItem >= 0) && (!_list->getSelectedString().empty()));
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list