Japanese composition keys don't generate correct events or |code|s |
||||||||
Issue descriptionSteps to reproduce: Setup: Mac with with 106 Japanese keyboard (external USB keyboard). (1) Go to Keyboard Event Test page: https://cdn.rawgit.com/w3c/uievents/gh-pages/tools/key-event-viewer.html (2) Type the following keys: * Key to left of Spacebar (NonConvert) * The 2 keys to the right of the Spacebar (Convert and KanaMode). What is the expected output? Foreach key: 1 Keydown and 1 keyup event with correct |code| values. What do you see instead? 2 keydown events and no keyup event. None of the events have the |code| value set. Note: * Same behavior observed regardless of whether keyboard is setup as ISO, ANSI or JIS. * On linux, the keyboard events (with |code|s) are generated correctly. * On Mac Firefox 45.0.1, pressing these keys generates *no* keyboard events.
,
Apr 19 2016
,
Apr 22 2016
,
Apr 22 2016
,
Apr 25 2016
,
Apr 25 2016
Tested on OS X 10.11.4 with a JIS PC keyboard, all these three keys (NonConvert, Convert and KanaMode) will generate NSEvent with "type:NSFlagsChanged keyCode:255 modifierFlags:256(default flag)", so there is no way to identify them. Also I cannot find these keys on Apple's JIS keyboard (http://www.apple.com/jp/shop/product/MB110J/B/apple-keyboard-%E3%83%86%E3%83%B3%E3%82%AD%E3%83%BC%E4%BB%98%E3%81%8D-jis), maybe they are not supported by OS X? I think it makes sense to match Firefox's behavior since there is no useful information in these key events.
,
Apr 26 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/bac970b73d720af26ca715c1e001703217e2cfa3 commit bac970b73d720af26ca715c1e001703217e2cfa3 Author: chongz <chongz@chromium.org> Date: Tue Apr 26 21:00:54 2016 [Mac] Pressing unsupported key should not generate keyevents On Mac with an external JIS PC keyboard, pressing "Convert", "NonConvert" and "KanaMode" keys will always produce |NSFlagsChanged| NSEvent with |keycode| == 255. Which will then cause blink to fire two "keydown" events. These three keys do not exist in Apple's Japanese keyboard, and there is no way for us to distinguish them or get any useful information (and it requires hack to mock "keydown"/"keyup"). Safari generates two "keydown"s (with no useful information). Firefox does not generate keyevents for these keys, this CL matches Firefox's bahavior. BUG= 601964 Review URL: https://codereview.chromium.org/1923023002 Cr-Commit-Position: refs/heads/master@{#389878} [modify] https://crrev.com/bac970b73d720af26ca715c1e001703217e2cfa3/content/browser/renderer_host/render_widget_host_view_mac.mm [modify] https://crrev.com/bac970b73d720af26ca715c1e001703217e2cfa3/content/browser/renderer_host/render_widget_host_view_mac_unittest.mm
,
Apr 26 2016
,
Apr 26 2016
|
||||||||
►
Sign in to add a comment |
||||||||
Comment 1 by ellyjo...@chromium.org
, Apr 12 2016