aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohannes Schickel2009-09-13 20:03:04 +0000
committerJohannes Schickel2009-09-13 20:03:04 +0000
commit690ee5fa678537f03dfe1aaa78a17690a9991f15 (patch)
tree6363ee7df27365f932a53ce147415e8e0f4ea6ca
parent7cc0ff23a01556d705584273c5835c4f454e83fa (diff)
downloadscummvm-rg350-690ee5fa678537f03dfe1aaa78a17690a9991f15.tar.gz
scummvm-rg350-690ee5fa678537f03dfe1aaa78a17690a9991f15.tar.bz2
scummvm-rg350-690ee5fa678537f03dfe1aaa78a17690a9991f15.zip
Commit salty-horse's fix for bug #2854261 "GUI: Launcher list doesn't highlight after getting focus".
svn-id: r44067
-rw-r--r--gui/ListWidget.cpp7
-rw-r--r--gui/ListWidget.h1
2 files changed, 7 insertions, 1 deletions
diff --git a/gui/ListWidget.cpp b/gui/ListWidget.cpp
index 195256b66f..b71bb4701e 100644
--- a/gui/ListWidget.cpp
+++ b/gui/ListWidget.cpp
@@ -404,8 +404,13 @@ bool ListWidget::handleKeyUp(Common::KeyState state) {
return true;
}
+void ListWidget::receivedFocusWidget() {
+ // Redraw the widget so the selection color will change
+ draw();
+}
+
void ListWidget::lostFocusWidget() {
- // If we loose focus, we simply forget the user changes
+ // If we lose focus, we simply forget the user changes
_editMode = false;
g_system->setFeatureState(OSystem::kFeatureVirtualKeyboard, false);
drawCaret(true);
diff --git a/gui/ListWidget.h b/gui/ListWidget.h
index 23c12a38fc..721dae051d 100644
--- a/gui/ListWidget.h
+++ b/gui/ListWidget.h
@@ -145,6 +145,7 @@ protected:
Common::Rect getEditRect() const;
+ void receivedFocusWidget();
void lostFocusWidget();
void scrollToCurrent();