Closed
Bug 618352
Opened 14 years ago
Closed 14 years ago
Shift and Fn keys not working on HTC Desire Z with hardware keyboard
Categories
(Firefox for Android Graveyard :: General, defect)
Tracking
(fennec2.0+)
VERIFIED
FIXED
fennec2.0b4
Tracking | Status | |
---|---|---|
fennec | 2.0+ | --- |
People
(Reporter: tero.koskinen, Assigned: mwu)
References
Details
Attachments
(4 files, 2 obsolete files)
9.75 KB,
text/plain
|
Details | |
3.50 KB,
patch
|
Details | Diff | Splinter Review | |
681 bytes,
patch
|
crowderbt
:
review+
|
Details | Diff | Splinter Review |
703 bytes,
patch
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (X11; U; OpenBSD amd64; en-US; rv:1.9.2.8) Gecko/20100810 Firefox/3.6.8
Build Identifier: Mozilla/5.0 (Android; Linux armv7l; rv:2. 0b8pre) Gecko/20101210 Firefox/4.0b8pre Fennec/4.0b3pre
On HTC Desire Z Shift and Fn keys are not working when the hardware keyboard is used.
Reproducible: Always
Steps to Reproduce:
1. Open hardware keyboard
2. Start Fennec
3. Open a new tab
4. Click on the address bar and try to type "ABOUT:CONFIG" using the hardware keyboard. Use Fn + . to get : character and Shift + letter to get uppercase character.
Actual Results:
Text "about.config" is entered.
Expected Results:
Text "ABOUT:CONFIG" is entered.
It does not matter do you type Fn and . at the same time or Fn first and then .
Shift and Fn work as expected if you first close the hardware keyboard and start typing with the virtual keyboard:
1. Close hardware keyboard
2. Tap on the address bar
3. Press Shift from the virtual keyboard
4. Press A from the virtual keyboard
5. Open the hardware keyboard (virtual keyboard disappears automatically)
6. Type BOUT:CONFIG normally. Shift and Fn work as expected!
The HTC Desire Z is the scandinavian (Finnish) model with åäö keys and Android 2.2.
Updated•14 years ago
|
tracking-fennec: --- → ?
Reporter | ||
Updated•14 years ago
|
OS: Linux → Android
Hardware: Other → ARM
Comment 1•14 years ago
|
||
confirmed with German HTC Desire Z, Android 2.2
Mozilla/5.0 (Android; Linux armv71; rv:2.0b8pre) Gecko/20101210
Firefox/4.0b8pre Fennec/4.0b3pre
Comment 2•14 years ago
|
||
this is working for me on the droid 2
Comment 3•14 years ago
|
||
I can't reproduce this on a T-Mobile G2, which is a US version of the Desire Z. Unlike the Desire Z, the G2 does not have the HTC Sense custom UI. Possibly related to bug 618252, which involves another Sense device (HTC Incredible).
Comment 4•14 years ago
|
||
Also confirming with German HTC Desire Z (Android 2.2 + Firefox 4.0b2): FN + keys and SHIFT + keys don't work with hardware keyboard.
Updated•14 years ago
|
Assignee: nobody → blassey.bugs
tracking-fennec: ? → 2.0+
Comment 5•14 years ago
|
||
is anyone who is seeing this in Mountain View this week?
Reporter | ||
Comment 6•14 years ago
|
||
I did some debugging with the latest sources, here is a log snippet. It seems that Java code at least sees the Fn and Shift presses.
Reporter | ||
Comment 7•14 years ago
|
||
Here are my used logging statements. I tried turn on also logging in nsWindow.cpp, but I couldn't figure out how to enable it.
Reporter | ||
Comment 9•14 years ago
|
||
(In reply to comment #8)
> I wonder if the patch in bug 619519 will fix this...
Nope, it didn't fix this. Shift and Fn keys are still ignored.
However, I noticed that if I press Home and restart Fennec from the application list, the Shift and Fn keys are working:
0. Open hardware keyboard
1. Start Fennec
2. Click on the address bar
3. Try to type something (Shift and Fn not working)
4. Press Home button to get the default view
5. Start Fennec again (from the application list or from the recent list)
6. Continue typing without touching the screen, Shift and Fn work as expected
Shift and Fn stop working again, if I let the device go idle and the screen goes blank.
This sounds like some platform related issue, but on the other hand, Shift and Fn keys are working fine in other apps (the default browser on the device, ConnectBot from Android Market, etc.).
Comment 10•14 years ago
|
||
Confirmed with HTC Desire Z, with latest Firefox Mobile available on the market.
Comment 11•14 years ago
|
||
Doesn't work either with 4.0b4 build of today.
Comment 12•14 years ago
|
||
This change fixes some possibly similar issues in the "connectbot" SSH app:
http://code.google.com/p/connectbot/issues/detail?id=396
https://github.com/iiuusit/connectbot/commit/fcf930ee87dfef5ad1819a3dfb601b14f06aec34
...but it looks like that bug was limited only to certain key combinations, rather than all shift/fn combos. It also relies on setting a pref to enable the quirks for this specific device. (Thanks to @bcpk on Twitter for the link.)
Comment 14•14 years ago
|
||
Bug confirmed with 4.0b3 from Market on Russian HTC Desire Z. Also can confirm that restarting procedure described by Tero Koskinen in comment #9 temporary helps.
Updated•14 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Reporter | ||
Comment 15•14 years ago
|
||
I noticed that the attached patch allows Fn and Shift keys to work on Desire Z. With the patch, upper case and special characters are correctly entered.
However, as a side-effect, long pressing keys no longer works (instead, the pressed key is repeated). There might be some other unwanted behaviour with the patch, I did only some light testing.
Note: I am not familiar with Android development, attached patch was just a lucky guess (after I did some debugging with jdb).
Assignee | ||
Updated•14 years ago
|
Assignee: blassey.bugs → mwu
Assignee | ||
Comment 16•14 years ago
|
||
(In reply to comment #15)
> Created attachment 502815 [details] [diff] [review]
> Work-around for Fn and Shift keys, long press is disabled as a side-effect
>
Some ideas to try:
Does this continue to work if you make it:
if (keyCode == KeyEvent.KEYCODE_BACK || keyCode == KeyEvent.KEYCODE_MENU)
return super.onKeyPreIme(keyCode, event);
or
if (mIMEState != IME_STATE_DISABLED || keyCode == KeyEvent.KEYCODE_BACK || keyCode == KeyEvent.KEYCODE_MENU)
return false;
Reporter | ||
Comment 17•14 years ago
|
||
> Does this continue to work if you make it:
>
> if (keyCode == KeyEvent.KEYCODE_BACK || keyCode == KeyEvent.KEYCODE_MENU)
> return super.onKeyPreIme(keyCode, event);
This allowed long press to work and fixed also the Shift and Fn keys. Thanks!
Patch attached.
> or
>
> if (mIMEState != IME_STATE_DISABLED || keyCode == KeyEvent.KEYCODE_BACK ||
> keyCode == KeyEvent.KEYCODE_MENU)
> return false;
With this, Shift and Fn keys didn't work.
Attachment #502815 -
Attachment is obsolete: true
Assignee | ||
Comment 18•14 years ago
|
||
Tero, can you check this patch and make sure it works for you? This basically the same patch, except we use isSystem() to check for back and menu and all other keys that the system should be responsible for handling. I had to sit and think for a while about whether getting rid of the mIMEState check is correct. Fairly convinced that it is now.
Attachment #506599 -
Flags: review?
Attachment #506599 -
Flags: feedback?
Assignee | ||
Updated•14 years ago
|
Attachment #506599 -
Flags: review?(crowderbt)
Attachment #506599 -
Flags: review?
Attachment #506599 -
Flags: feedback?(tero.koskinen)
Attachment #506599 -
Flags: feedback?
Reporter | ||
Comment 19•14 years ago
|
||
Comment on attachment 506599 [details] [diff] [review]
Handle all key events in onKeyPreIme when possible
The patch fixes the Shift and Fn keys. Long-press also works as expected. (This comment is written using the latest m-c + m-b + the patch on my Desire Z.)
For some reason (lacking some permission bits?), I couldn't give feedback+.
Comment 20•14 years ago
|
||
Not yet commited ?
Comment 21•14 years ago
|
||
Comment on attachment 506599 [details] [diff] [review]
Handle all key events in onKeyPreIme when possible
Might this fix bug 624334?
Attachment #506599 -
Flags: review?(crowderbt) → review+
Assignee | ||
Comment 22•14 years ago
|
||
(In reply to comment #21)
> Comment on attachment 506599 [details] [diff] [review]
> Handle all key events in onKeyPreIme when possible
>
> Might this fix bug 624334?
I wouldn't count on it, but I guess it's worth checking after this patch lands.
Assignee | ||
Updated•14 years ago
|
Attachment #506599 -
Flags: feedback?(tero.koskinen)
Assignee | ||
Comment 23•14 years ago
|
||
Attachment #503051 -
Attachment is obsolete: true
Assignee | ||
Updated•14 years ago
|
Keywords: checkin-needed
Comment 24•14 years ago
|
||
Status: NEW → RESOLVED
Closed: 14 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → fennec2.0b4
Comment 26•14 years ago
|
||
Verified using G2/Desire Z Mozilla/5.0 (Android; Linux armv7l; rv:2.0b13pre)
Gecko/20110315 Firefox/4.0b13pre Fennec/4.0b6pre ID:20110315035936
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•