Open
Bug 913058
Opened 12 years ago
Updated 3 years ago
Map VolumeUp/VolumeDown event correctly
Categories
(Core :: DOM: Events, defect, P5)
Tracking
()
NEW
People
(Reporter: alive, Unassigned)
References
Details
In b2g for uncertain reason, when volumeUp/volumeDown are pressed,
we are getting event.key == KeyboardEvent.VK_DOM_PAGE_UP/PAGE_DOWN.
This is wrong. We need correct it before enabling sending key event to user app.
BTW, mwu, could you point me out are we able to resolve this from gonk or not?
Flags: needinfo?(mwu)
Comment 1•12 years ago
|
||
Easily fixed on the widget side. PAGE_UP/PAGE_DOWN was a temporary solution until we had a better option. http://hg.mozilla.org/mozilla-central/file/aa9ec17cf912/widget/gonk/GonkKeyMapping.h#l51 is where the mappings are. If you need something more complicated, the actual mapping is done at http://hg.mozilla.org/mozilla-central/file/aa9ec17cf912/widget/gonk/nsAppShell.cpp#l239
Flags: needinfo?(mwu)
Reporter | ||
Comment 2•12 years ago
|
||
Does this mean we could move this to B2G component?
Comment 3•12 years ago
|
||
No. Core::Widget:Gonk if you want to move to a more specific component.
Comment 4•12 years ago
|
||
Isn't it keyCode? I mean .key must map them correctly:
http://mxr.mozilla.org/mozilla-central/source/widget/shared/NativeKeyToDOMKeyName.h#1002
http://mxr.mozilla.org/mozilla-central/source/widget/shared/NativeKeyToDOMKeyName.h#1009
Reporter | ||
Comment 5•12 years ago
|
||
http://mxr.mozilla.org/mozilla-central/source/b2g/chrome/content/shell.js#352
Yes, KeyCode is wrong..
Comment 6•12 years ago
|
||
.key value should support most necessary keys. I believe that such strange .keyCode mapping should be removed as soon as possible. However, some .key names will be modified in next D3E draft. So, using .key is still unstable especially for applications on Firefox OS. When you need to use .key value, don't mind the compatibility. When I update the key names, I'll update the all key names in our tree too.
Comment 7•12 years ago
|
||
Note that when we support hardware keyboard connected via Bluetooth, we need to remove the strange keyCode mapping. Sharing keyCode between different keys makes .keyCode not useful on Firefox OS.
Comment 8•7 years ago
|
||
https://bugzilla.mozilla.org/show_bug.cgi?id=1472046
Move all DOM bugs that haven’t been updated in more than 3 years and has no one currently assigned to P5.
If you have questions, please contact :mdaly.
Priority: -- → P5
Updated•3 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•