[Scummvm-cvs-logs] SF.net SVN: scummvm:[43441] scummvm/trunk

mthreepwood at users.sourceforge.net mthreepwood at users.sourceforge.net
Sun Aug 16 16:04:55 CEST 2009


Revision: 43441
          http://scummvm.svn.sourceforge.net/scummvm/?rev=43441&view=rev
Author:   mthreepwood
Date:     2009-08-16 14:04:54 +0000 (Sun, 16 Aug 2009)

Log Message:
-----------
Introduce a better fix for the Mac OS X backspace problem by adding the workaround to default-events.cpp.

Modified Paths:
--------------
    scummvm/trunk/backends/events/default/default-events.cpp
    scummvm/trunk/engines/agos/event.cpp
    scummvm/trunk/engines/scumm/input.cpp

Modified: scummvm/trunk/backends/events/default/default-events.cpp
===================================================================
--- scummvm/trunk/backends/events/default/default-events.cpp	2009-08-16 13:47:48 UTC (rev 43440)
+++ scummvm/trunk/backends/events/default/default-events.cpp	2009-08-16 14:04:54 UTC (rev 43441)
@@ -162,6 +162,12 @@
 				}
 			}
 #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.
+				event.kbd.ascii = Common::KEYCODE_BACKSPACE;
+			}
 			break;
 
 		case Common::EVENT_KEYUP:

Modified: scummvm/trunk/engines/agos/event.cpp
===================================================================
--- scummvm/trunk/engines/agos/event.cpp	2009-08-16 13:47:48 UTC (rev 43440)
+++ scummvm/trunk/engines/agos/event.cpp	2009-08-16 14:04:54 UTC (rev 43441)
@@ -499,10 +499,6 @@
 				}
 
 				_keyPressed = event.kbd;
-				
-				// Make sure backspace works right (this fixes a small issue on OS X)
-				if (_keyPressed.keycode == Common::KEYCODE_BACKSPACE)
-					_keyPressed.ascii = Common::KEYCODE_BACKSPACE;
 				break;
 			case Common::EVENT_MOUSEMOVE:
 				break;

Modified: scummvm/trunk/engines/scumm/input.cpp
===================================================================
--- scummvm/trunk/engines/scumm/input.cpp	2009-08-16 13:47:48 UTC (rev 43440)
+++ scummvm/trunk/engines/scumm/input.cpp	2009-08-16 14:04:54 UTC (rev 43441)
@@ -135,13 +135,6 @@
 			// Normal key press, pass on to the game.
 			_keyPressed = event.kbd;
 		}
-		
-		// WORKAROUND: On Mac OS X, the ascii value has to be set to the
-		// backspace keycode in order for the backspace to work in HE games.
-		// This includes using the backspace when entering coach names
-		// in the backyard games. 
-		if (_keyPressed.keycode == Common::KEYCODE_BACKSPACE)
-			_keyPressed.ascii = Common::KEYCODE_BACKSPACE;
 
 		// FIXME: We are using ASCII values to index the _keyDownMap here,
 		// yet later one code which checks _keyDownMap will use KEYCODEs


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