Bug 1027472 Support Symbol key value on Android and Gonk r=mwu+nchen+smaug
authorMasayuki Nakano <masayuki@d-toybox.com>
Tue, 30 Dec 2014 10:47:55 +0900
changeset 249145 bf9c0ad8d4bb6bb4d1e8d6697479b71085675d0c
parent 249144 c644cc4c6b9b74e4dbe1eba49ba7cbba09251cfd
child 249146 f2dbe9ace508676eb83b7de434fe94ce46f73b22
push id698
push userjlund@mozilla.com
push dateMon, 23 Mar 2015 22:08:11 +0000
treeherdermozilla-release@b0c0ae7b02a3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmwu
bugs1027472
milestone37.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1027472 Support Symbol key value on Android and Gonk r=mwu+nchen+smaug
dom/events/KeyNameList.h
widget/NativeKeyToDOMKeyName.h
widget/android/nsWindow.cpp
--- a/dom/events/KeyNameList.h
+++ b/dom/events/KeyNameList.h
@@ -41,17 +41,17 @@ DEFINE_KEYNAME_WITH_SAME_NAME(Fn)
 // DEFINE_KEYNAME_WITH_SAME_NAME(FnLock)
 // DEFINE_KEYNAME_WITH_SAME_NAME(Hyper)
 DEFINE_KEYNAME_WITH_SAME_NAME(Meta)
 DEFINE_KEYNAME_WITH_SAME_NAME(NumLock)
 DEFINE_KEYNAME_WITH_SAME_NAME(OS)
 DEFINE_KEYNAME_WITH_SAME_NAME(ScrollLock)
 DEFINE_KEYNAME_WITH_SAME_NAME(Shift)
 // DEFINE_KEYNAME_WITH_SAME_NAME(Super)
-// DEFINE_KEYNAME_WITH_SAME_NAME(Symbol)
+DEFINE_KEYNAME_WITH_SAME_NAME(Symbol)
 // DEFINE_KEYNAME_WITH_SAME_NAME(SymbolLock)
 
 /******************************************************************************
  * Whitespace Keys
  *****************************************************************************/
 DEFINE_KEYNAME_WITH_SAME_NAME(Enter)
 // DEFINE_KEYNAME_WITH_SAME_NAME(Separator)
 DEFINE_KEYNAME_WITH_SAME_NAME(Tab)
--- a/widget/NativeKeyToDOMKeyName.h
+++ b/widget/NativeKeyToDOMKeyName.h
@@ -165,16 +165,19 @@ KEY_MAP_COCOA   (Shift, kVK_Shift)
 KEY_MAP_COCOA   (Shift, kVK_RightShift)
 KEY_MAP_GTK     (Shift, GDK_Shift_L)
 KEY_MAP_GTK     (Shift, GDK_Shift_R)
 KEY_MAP_GTK     (Shift, GDK_Shift_Lock) // Let's treat as Shift key (bug 769159)
 KEY_MAP_QT      (Shift, Qt::Key_Shift)
 KEY_MAP_ANDROID (Shift, AKEYCODE_SHIFT_LEFT)
 KEY_MAP_ANDROID (Shift, AKEYCODE_SHIFT_RIGHT)
 
+// Symbol
+KEY_MAP_ANDROID (Symbol, AKEYCODE_SYM)
+
 /******************************************************************************
  * Whitespace Keys
  ******************************************************************************/
 // Enter
 KEY_MAP_WIN     (Enter, VK_RETURN)
 KEY_MAP_COCOA   (Enter, kVK_Return)
 KEY_MAP_COCOA   (Enter, kVK_ANSI_KeypadEnter)
 KEY_MAP_COCOA   (Enter, kVK_Powerbook_KeypadEnter)
--- a/widget/android/nsWindow.cpp
+++ b/widget/android/nsWindow.cpp
@@ -1370,17 +1370,16 @@ ConvertAndroidKeyCodeToKeyNameIndex(Andr
         case AKEYCODE_YEN:                // yen sign key
         case AKEYCODE_RO:                 // Japanese Ro key
             return KEY_NAME_INDEX_USE_STRING;
 
         case AKEYCODE_SOFT_LEFT:
         case AKEYCODE_SOFT_RIGHT:
         case AKEYCODE_CALL:
         case AKEYCODE_ENDCALL:
-        case AKEYCODE_SYM:                // Symbol modifier
         case AKEYCODE_NUM:                // XXX Not sure
         case AKEYCODE_HEADSETHOOK:
         case AKEYCODE_FOCUS:
         case AKEYCODE_NOTIFICATION:       // XXX Not sure
         case AKEYCODE_PICTSYMBOLS:
 
         case AKEYCODE_BUTTON_A:
         case AKEYCODE_BUTTON_B: