From 2ed53f98b478854c1df3ed43a46103bfb35596d5 Mon Sep 17 00:00:00 2001 From: Max Horn Date: Tue, 1 Sep 2009 13:02:24 +0000 Subject: Clarified the backspace key workaround: This is not a Mac OS X issue (as the comment used to imply) but rather an issue in some game engines. svn-id: r43880 --- backends/events/default/default-events.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'backends/events/default') diff --git a/backends/events/default/default-events.cpp b/backends/events/default/default-events.cpp index df85241da5..8b3fe5cdc4 100644 --- a/backends/events/default/default-events.cpp +++ b/backends/events/default/default-events.cpp @@ -163,9 +163,13 @@ bool DefaultEventManager::pollEvent(Common::Event &event) { } #endif else if (event.kbd.keycode == Common::KEYCODE_BACKSPACE) { - // WORKAROUND: On Mac OS X, the ascii value for backspace - // has to be set to the backspace keycode in order to work - // properly. + // WORKAROUND: Some engines incorrectly attempt to use the + // ascii value instead of the keycode to detect the backspace + // key (a non-portable behavior). This fails at least on + // Mac OS X, possibly also on other systems. + // As a workaround, we force the ascii value for backspace + // key pressed. A better fix would be for engines to stop + // making invalid assumptions about ascii values. event.kbd.ascii = Common::KEYCODE_BACKSPACE; } break; -- cgit v1.2.3