Closed
Bug 825752
Opened 12 years ago
Closed 4 years ago
Minus key (-) generates 0 keycode instead of 109 on TF300T
Categories
(Firefox for Android Graveyard :: Keyboards and IME, defect)
Tracking
(Not tracked)
RESOLVED
INCOMPLETE
People
(Reporter: hwguy.siplus, Unassigned, Mentored)
Details
(Whiteboard: [lang=c++])
User Agent: Mozilla/5.0 (Android; Tablet; rv:18.0) Gecko/18.0 Firefox/18.0
Build ID: 20121227073833
Steps to reproduce:
Created a handler of window.onkeydown with alert(e.keyCode) and pressed - on ASUS Transformer TF300T dock keyboard.
Actual results:
I got 0 keycode.
Expected results:
I get 109 keycode.
It's okay to return 189 instead of 109 for '-' and 187 instead of 61 for '='. WebKit and Trident do so.
***PATCH***
source/widget/android/nsWindow.cpp
line 1434
Change entire line to:
case AndroidKeyEvent::KEYCODE_MINUS: return NS_VK_SUBTRACT;
NS_VK_HYPHEN_MINUS is probably not a good keycode, because in 2 functions it has ASCII counterpart '-' that has char code of 45, which is entirely different than the two key codes.
Updated•12 years ago
|
Assignee: nobody → nchen
Comment 5•12 years ago
|
||
(In reply to SiPlus from comment #3)
> It's okay to return 189 instead of 109 for '-' and 187 instead of 61 for
> '='. WebKit and Trident do so.
>
> ***PATCH***
>
> source/widget/android/nsWindow.cpp
> line 1434
> Change entire line to:
> case AndroidKeyEvent::KEYCODE_MINUS: return NS_VK_SUBTRACT;
Hi SiPlus, thank you for looking into this. Would you be interested in fixing this bug yourself? We welcome all contributors!
You would create a build environment to build Fennec, create a proper patch file, test the patch, and then I can review your patch. Finally, your patch would be checked into the Fennec source code, and we even mention your name in the weekly meeting! (Similar to this, https://wiki.mozilla.org/Mobile/Notes/02-Jan-2013#Contributors)
If you're interested, let me know and I can guide you through the steps. Thanks! :)
Assignee: nchen → nobody
Status: UNCONFIRMED → NEW
Ever confirmed: true
Flags: needinfo?(hwguy.siplus)
Whiteboard: [mentor=jchen][lang=c++]
Hi Jim, thank you for replying to this report.
I will try to fix the issue when I get to my PC, currently I have only an Android tablet.
Flags: needinfo?(hwguy.siplus)
Comment 7•12 years ago
|
||
(In reply to SiPlus from comment #6)
> Hi Jim, thank you for replying to this report.
>
> I will try to fix the issue when I get to my PC, currently I have only an
> Android tablet.
Sounds great! I will assign this bug to you for now.
If you have any questions, you can contact me through my Bugzilla email or ask me in the #mobile channel on irc.mozilla.org (my IRC nick is 'jchen') Thanks!
Assignee: nobody → hwguy.siplus
Comment 8•12 years ago
|
||
Hi SiPlus, I saw your question on IRC. Building on Windows is not officially supported, but you can install Linux on a virtual machine (using VMWare for example) and build Fennec in there. There is a prebuilt VM available here, http://blog.lassey.us/2011/07/22/updated-android-development-vm/
Hi Jim, thanks for the info, I already found this VM image, I have some issues with free disk space, and it's 12 Gb in size, I'll try to build it when I clear some gigabytes.
Comment 10•12 years ago
|
||
Were you able to setup your environment SiPlus? Let me know if you have questions.
Status: NEW → ASSIGNED
Updated•12 years ago
|
Flags: needinfo?(hwguy.siplus)
Reporter | ||
Comment 11•12 years ago
|
||
Oops, missed an email.
Here's what I get:
../../../mobile/android/base/tests/testAwesomebarSwipes.java:33: cannot find symbol
symbol : method getCurrentItem()
location: class android.support.v4.view.ViewPager
mAsserter.is(pager.getCurrentItem(), 0, "All pages is selected");
^
../../../mobile/android/base/tests/testAwesomebarSwipes.java:38: cannot find symbol
symbol : method getCurrentItem()
location: class android.support.v4.view.ViewPager
mAsserter.is(pager.getCurrentItem(), 1, "Bookmarks page is selected");
^
../../../mobile/android/base/tests/testAwesomebarSwipes.java:41: cannot find symbol
symbol : method getCurrentItem()
location: class android.support.v4.view.ViewPager
mAsserter.is(pager.getCurrentItem(), 0, "All pages is selected");
^
../../../mobile/android/base/tests/testAwesomebarSwipes.java:46: cannot find symbol
symbol : method getCurrentItem()
location: class android.support.v4.view.ViewPager
mAsserter.is(pager.getCurrentItem(), 1, "Clicking on tab selected bookmarks page");
^
../../../mobile/android/base/tests/testAwesomebarSwipes.java:50: cannot find symbol
symbol : method getCurrentItem()
location: class android.support.v4.view.ViewPager
mAsserter.is(pager.getCurrentItem(), 0, "Searching switched to all pages tab");
^
../../../mobile/android/base/tests/testAwesomebarSwipes.java:52: cannot find symbol
symbol : method getCurrentItem()
location: class android.support.v4.view.ViewPager
mAsserter.is(pager.getCurrentItem(), 0, "Dragging left is not allowed when searching");
^
../../../mobile/android/base/tests/testAwesomebarSwipes.java:55: cannot find symbol
symbol : method getCurrentItem()
location: class android.support.v4.view.ViewPager
mAsserter.is(pager.getCurrentItem(), 0, "Dragging right is not allowed when searching");
And then error 2.
Flags: needinfo?(hwguy.siplus)
Reporter | ||
Comment 12•12 years ago
|
||
I'm trying to build version 18. Version 8 builds properly.
Comment 13•12 years ago
|
||
(In reply to SiPlus from comment #12)
> I'm trying to build version 18. Version 8 builds properly.
Can you post your .mozconfig file on http://pastebin.mozilla.org? Thanks!
Flags: needinfo?(hwguy.siplus)
Reporter | ||
Comment 14•12 years ago
|
||
(In reply to Jim Chen [:jchen :nchen] from comment #13)
> (In reply to SiPlus from comment #12)
> > I'm trying to build version 18. Version 8 builds properly.
>
> Can you post your .mozconfig file on http://pastebin.mozilla.org? Thanks!
http://pastebin.mozilla.org/2058873
Flags: needinfo?(hwguy.siplus)
Comment 15•12 years ago
|
||
(In reply to SiPlus from comment #14)
> (In reply to Jim Chen [:jchen :nchen] from comment #13)
> > (In reply to SiPlus from comment #12)
> > > I'm trying to build version 18. Version 8 builds properly.
> >
> > Can you post your .mozconfig file on http://pastebin.mozilla.org? Thanks!
>
> http://pastebin.mozilla.org/2058873
Thanks! I added some additional instructions to https://wiki.mozilla.org/Mobile/Fennec/Android#Building_Fennec on how to make the VM build the latest Fennec. You should check to see if you are missing any steps.
Flags: needinfo?(hwguy.siplus)
Updated•12 years ago
|
Assignee: hwguy.siplus → nobody
Status: ASSIGNED → NEW
Flags: needinfo?(hwguy.siplus)
Assignee | ||
Updated•10 years ago
|
Mentor: nchen
Whiteboard: [mentor=jchen][lang=c++] → [lang=c++]
Comment 16•4 years ago
|
||
We have completed our launch of our new Firefox on Android. The development of the new versions use GitHub for issue tracking. If the bug report still reproduces in a current version of [Firefox on Android nightly](https://play.google.com/store/apps/details?id=org.mozilla.fenix) an issue can be reported at the [Fenix GitHub project](https://github.com/mozilla-mobile/fenix/). If you want to discuss your report please use [Mozilla's chat](https://wiki.mozilla.org/Matrix#Connect_to_Matrix) server https://chat.mozilla.org and join the [#fenix](https://chat.mozilla.org/#/room/#fenix:mozilla.org) channel.
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → INCOMPLETE
Updated•4 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•