mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-04 08:17:40 +00:00
Fix for bug #1570189 (GUI: crash when pressing "delete" at the end of the name)
svn-id: r24113
This commit is contained in:
parent
a66907e276
commit
03e70bf32b
@ -110,9 +110,11 @@ bool EditableWidget::handleKeyDown(uint16 ascii, int keycode, int modifiers) {
|
||||
forcecaret = true;
|
||||
break;
|
||||
case 127: // delete
|
||||
_editString.deleteChar(_caretPos);
|
||||
if (_caretPos < (int)_editString.size()) {
|
||||
_editString.deleteChar(_caretPos);
|
||||
dirty = true;
|
||||
}
|
||||
forcecaret = true;
|
||||
dirty = true;
|
||||
break;
|
||||
case 256 + 20: // left arrow
|
||||
if (_caretPos > 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user