aboutsummaryrefslogtreecommitdiff
path: root/gui
diff options
context:
space:
mode:
authorMax Horn2002-07-27 14:19:59 +0000
committerMax Horn2002-07-27 14:19:59 +0000
commitf73c1658c85db49b0c59ff7dec835aef1219587b (patch)
tree63bbbc971ea9e34b472ebf5dba3ccb26ce3f878b /gui
parent39670a73c04e3e35b4c68d98ec4956ba7ed9710c (diff)
downloadscummvm-rg350-f73c1658c85db49b0c59ff7dec835aef1219587b.tar.gz
scummvm-rg350-f73c1658c85db49b0c59ff7dec835aef1219587b.tar.bz2
scummvm-rg350-f73c1658c85db49b0c59ff7dec835aef1219587b.zip
changing the selection aborts editing, too!
svn-id: r4657
Diffstat (limited to 'gui')
-rw-r--r--gui/ListWidget.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/gui/ListWidget.cpp b/gui/ListWidget.cpp
index 2b438f2153..d19833dbe8 100644
--- a/gui/ListWidget.cpp
+++ b/gui/ListWidget.cpp
@@ -68,8 +68,8 @@ void ListWidget::handleMouseDown(int x, int y, int button, int clickCount)
_selectedItem = (y - 2) / LINE_HEIGHT + _currentPos;
if (_editMode && oldSelectedItem != _selectedItem) {
- // loose caret
- _list[_selectedItem].deleteLastChar();
+ // undo any changes made
+ _list[oldSelectedItem] = _backupString;
_editMode = false;
}
draw();