diff options
author | Kenneth Russel <[email protected]> | 2009-03-08 07:11:54 +0000 |
---|---|---|
committer | Kenneth Russel <[email protected]> | 2009-03-08 07:11:54 +0000 |
commit | 3481005944d8f7f2ce1ec09158bd177a2b379e0a (patch) | |
tree | 4c2b09bbc89752844200c75c7b44e9fe165e1df6 /src/classes/com/sun/javafx/newt/macosx/MacWindow.java | |
parent | 7ff4877e1d4d1f77e16025c64a223a902d9cdf14 (diff) |
Fixed problem with conversion of key code for enter key on Mac OS X;
similar problems may exist on other platforms
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1858 232f8b59-042b-4e1e-8c03-345bb8c30851
Diffstat (limited to 'src/classes/com/sun/javafx/newt/macosx/MacWindow.java')
-rwxr-xr-x | src/classes/com/sun/javafx/newt/macosx/MacWindow.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/classes/com/sun/javafx/newt/macosx/MacWindow.java b/src/classes/com/sun/javafx/newt/macosx/MacWindow.java index 73cdbad04..345ebe0e1 100755 --- a/src/classes/com/sun/javafx/newt/macosx/MacWindow.java +++ b/src/classes/com/sun/javafx/newt/macosx/MacWindow.java @@ -250,6 +250,11 @@ public class MacWindow extends Window { } private char convertKeyChar(char keyChar) { + if (keyChar == '\r') { + // Turn these into \n + return '\n'; + } + if (keyChar >= NSUpArrowFunctionKey && keyChar <= NSModeSwitchFunctionKey) { switch (keyChar) { case NSUpArrowFunctionKey: return KeyEvent.VK_UP; |