Closed Bug 712018 Opened 13 years ago Closed 12 years ago

International hardware keyboards input text as English qwerty (need implement IME support for hardware keyboard)

Categories

(Firefox for Android Graveyard :: Keyboards and IME, defect, P3)

ARM
Android
defect

Tracking

(firefox17 wontfix, firefox18+ fixed, firefox19+ fixed, fennec-)

RESOLVED FIXED
Firefox 19
Tracking Status
firefox17 --- wontfix
firefox18 + fixed
firefox19 + fixed
fennec - ---

People

(Reporter: lionel.bernhardt, Assigned: m_kato)

References

Details

(Keywords: inputmethod, Whiteboard: [HKB])

Attachments

(2 files, 1 obsolete file)

User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:8.0) Gecko/20100101 Firefox/8.0
Build ID: 20111104165243

Steps to reproduce:

I typed some url in the url bar.
I tried filling web forms with the latest nightly build.
My hardware is : ASUS TRANSFORMER with physical french keyboard.
The keyboard was correctly set in Android parameters.


Actual results:

The url was correctly typed ( a key wrote "a" in the bar)
"a" key was "q" in the textbox in the web form (Same in hidden textbox for password)


Expected results:

"a" key should have been "a" character in textboxes
OS: Windows 7 → Android
Hardware: x86_64 → ARM
Keywords: inputmethod
Whiteboard: [HKB]
Assignee: nobody → alexp
Priority: -- → P3
tracking-fennec: --- → 11+
Assignee: alex.mozilla → cpeterson
Component: General → IME
Augure, is this Fennec Native only?  

If this doesn't occurs on Fennec XUL, this is a regression of bug 699792.
(In reply to Makoto Kato from comment #1)
> Augure, is this Fennec Native only?  
> 
> If this doesn't occurs on Fennec XUL, this is a regression of bug 699792.

Hi, didn't have the time to test with the latest version but i didn't notice this bug in Fennec.
I will post this evening a clear answer to that question.
Lionel
(In reply to Augure from comment #2)
> (In reply to Makoto Kato from comment #1)
> > Augure, is this Fennec Native only?  
> > 
> > If this doesn't occurs on Fennec XUL, this is a regression of bug 699792.
> 
> Hi, didn't have the time to test with the latest version but i didn't notice
> this bug in Fennec.
> I will post this evening a clear answer to that question.
> Lionel

Hello,
tested on the Firefox release on Android Market and the "bug" is not here. I only have it (tested also this evening) with this alpha version.

Lionel
Lionel, thanks for testing. This information is a big help.
Augure, can you still reproduce it?
(In reply to Martijn Wargers [:mw22] (QA - IRC nick: mw22) from comment #5)
> Augure, can you still reproduce it?

Yes.  This is a regression of bug 699792.  Some HKB IMEs (HTC Touch Input on Desire Z and etc) have a bug, we have added workaround.  But the workaround causes this bug...
Status: UNCONFIRMED → NEW
Ever confirmed: true
tracking-fennec: 11+ → -
(In reply to Makoto Kato from comment #1)
> Augure, is this Fennec Native only?  
> 
> If this doesn't occurs on Fennec XUL, this is a regression of bug 699792.

Hi,
sorry for the delay.

I tested one week ago and this problem was still there.

Lionel
Attached patch wip (obsolete) — Splinter Review
Comment on attachment 637031 [details] [diff] [review]
wip

Makoto, since we are now finding bugs that require workarounds for specific IMEs' "quirks", we should think about consolidating the IME identification code into a common module. I'm not sure what that will look like, but I know that "com.htc.android.htcime" will not be the last IME we need to identify. :)
(In reply to Chris Peterson (:cpeterson) from comment #10)
> Comment on attachment 637031 [details] [diff] [review]
> wip
> 
> Makoto, since we are now finding bugs that require workarounds for specific
> IMEs' "quirks", we should think about consolidating the IME identification
> code into a common module. I'm not sure what that will look like, but I know
> that "com.htc.android.htcime" will not be the last IME we need to identify.
> :)

Bug 685537. HTC Touch Input sets invalid META/SHIFT state for composition string.

Android framework's BaseInputConnection.commitText uses sendKeyEvent() like https://bugzilla.mozilla.org/attachment.cgi?id=566740&action=diff. So this problem doesn't occurs on TextView.
Also, https://bugzilla.mozilla.org/attachment.cgi?id=566740&action=diff doesn't work on SHARP 007SH.  Because KeyCharacterMap.BUILT_IN_KEYBOARD isn't equal to physical keyboard mapping.
Also, Swype-specific feature request in bug 767597 and Galaxy Note-specific bug 758427.
Summary: French physical keyboard detected as ENGLISH in web forms with Asus Transformer → International hardware keyboards input text as English qwerty
Has been fixed for the TF300T by Asus Firmware Update which introduces Android 4.1. !!!
So we can close this bug?
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → WORKSFORME
Problem still there for TF 101 with latest Firefox Beta.
Android 4.0
ASUS

Lionel
Status: RESOLVED → REOPENED
Resolution: WORKSFORME → ---
@Augure: Is there no Android 4.1 firmware update available for your device?
 Norbert, Keep open status because HKB implementation has no IME support, so this depends on current keyboard system.
@Norbert : no, sadly. 
 Asus didn't found it relevant to publish JB on TF101.
Lionel
I have the same problem on my Asus TF700 with Firefox 15.0 installed today from Google Play: using the azerty hardware keyboard, URL is typed in azerty, forms are typed with querty.
Depends on: 669361
Summary: International hardware keyboards input text as English qwerty → International hardware keyboards input text as English qwerty (need implement IME support for hardware keyboard)
Blocks: 793504
Attached patch fixSplinter Review
Attachment #637031 - Attachment is obsolete: true
Comment on attachment 673135 [details] [diff] [review]
fix

add white list to support hkb with IME.  Several IMEs don't support on HKB well.
Attachment #673135 - Flags: review?(cpeterson)
Comment on attachment 673135 [details] [diff] [review]
fix

Review of attachment 673135 [details] [diff] [review]:
-----------------------------------------------------------------

LGTM with a question and a nit:

::: mobile/android/base/GeckoInputConnection.java
@@ +887,5 @@
>          return this;
>      }
>  
>      public boolean onKeyPreIme(int keyCode, KeyEvent event) {
> +        if (hasBuggyHardwareKeyboardLayout() || InputMethods.canUseInputMethodOnHKB(mCurrentInputMethod))

Makoto, does it make sense to merge hasBuggyHardwareKeyboardLayout() (which checks for Asus Transformer tablets running pre-Jelly Bean OS) into canUseInputMethodOnHKB()? Or do you think they are separate concerns that should be kept separate?

::: mobile/android/base/InputMethods.java
@@ +20,5 @@
>      public static final String METHOD_SIMEJI = "com.adamrocker.android.input.simeji/.OpenWnnSimeji";
>      public static final String METHOD_SWYPE = "com.swype.android.inputmethod/.SwypeInputMethod";
>      public static final String METHOD_SWYPE_BETA = "com.nuance.swype.input/.IME";
> +    public static final String METHOD_ATOK = "com.justsystems.atokmobile.service/.AtokInputMethodService";
> +    public static final String METHOD_IWNN = "jp.co.omronsoft.iwnnime.ml/.standardcommon.IWnnLanguageSwitcher";

Please order these new IME names alphabetically by their "METHOD_*" variable name.
Attachment #673135 - Flags: review?(cpeterson) → review+
(In reply to Chris Peterson (:cpeterson) from comment #25)
> Comment on attachment 673135 [details] [diff] [review]
> fix
> 
> Review of attachment 673135 [details] [diff] [review]:
> -----------------------------------------------------------------
> 
> LGTM with a question and a nit:
> 
> ::: mobile/android/base/GeckoInputConnection.java
> @@ +887,5 @@
> >          return this;
> >      }
> >  
> >      public boolean onKeyPreIme(int keyCode, KeyEvent event) {
> > +        if (hasBuggyHardwareKeyboardLayout() || InputMethods.canUseInputMethodOnHKB(mCurrentInputMethod))
> 
> Makoto, does it make sense to merge hasBuggyHardwareKeyboardLayout() (which
> checks for Asus Transformer tablets running pre-Jelly Bean OS) into
> canUseInputMethodOnHKB()? Or do you think they are separate concerns that
> should be kept separate?

I will merge this into InputMethods's function.

> 
> ::: mobile/android/base/InputMethods.java
> @@ +20,5 @@
> >      public static final String METHOD_SIMEJI = "com.adamrocker.android.input.simeji/.OpenWnnSimeji";
> >      public static final String METHOD_SWYPE = "com.swype.android.inputmethod/.SwypeInputMethod";
> >      public static final String METHOD_SWYPE_BETA = "com.nuance.swype.input/.IME";
> > +    public static final String METHOD_ATOK = "com.justsystems.atokmobile.service/.AtokInputMethodService";
> > +    public static final String METHOD_IWNN = "jp.co.omronsoft.iwnnime.ml/.standardcommon.IWnnLanguageSwitcher";
> 
> Please order these new IME names alphabetically by their "METHOD_*" variable
> name.

OK.
Also, several IMEs will break on physical keyboard.  (ex. HTC touch input.)  I don't know whether non-English model of ASUS uses Android keyboard or not, so I keep ASUS hacks.
Assignee: cpeterson → m_kato
Attached patch v2Splinter Review
could you review again?

Since I have no all models of ASUS transformer, I keep ASUS hacks.
Attachment #675467 - Flags: review?(cpeterson)
Comment on attachment 675467 [details] [diff] [review]
v2

Review of attachment 675467 [details] [diff] [review]:
-----------------------------------------------------------------

LGTM!

Do you think we should uplift your fix to Aurora 18? Your fix looks pretty safe and tablet IME users will appreciate it.
Attachment #675467 - Flags: review?(cpeterson) → review+
https://hg.mozilla.org/integration/mozilla-inbound/rev/8586bd350875

If possible, we should uplift this for 18.  I have tested several IMEs with bluetooth keyboard.  So I will request approval-aurora after merging into m-c.
https://hg.mozilla.org/mozilla-central/rev/8586bd350875
Status: REOPENED → RESOLVED
Closed: 12 years ago12 years ago
Flags: in-testsuite-
Resolution: --- → FIXED
Target Milestone: --- → Firefox 19
Comment on attachment 675467 [details] [diff] [review]
v2

[Approval Request Comment]
Bug caused by (feature/regressing bug #): no.  Although IME on xul fennec works even if physical keyboard, on native fennec doesn't.
User impact if declined: IME doesn't work on physical keyboard such as bluetooth keyboard.
Testing completed (on m-c, etc.): landed on mc-c.
Risk to taking this patch (and alternatives if risky): row.  If software keyboard, keyboard event isn't called almost.
String or UUID changes made by this patch: no
Attachment #675467 - Flags: approval-mozilla-aurora?
We can take this into FF18 given the low risk evaluation, how far we are from uplift (3wks), and the fact that we should get specific QA testing around this. If we find a major regression, we'll back this out immediately due to the touchiness of IME changes.
Keywords: qawanted, verifyme
QA Contact: aaron.train
Attachment #675467 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Not fixed. HTC Desire Z CM9 + FlickWnn(com.pm9.flickwnn)
fixed. HTC Desire Z CM9 + OpenWnn Plus(com.owplus.ime.openwnnplus)

This solution(white list) does not seem a good idea.
(In reply to hashiz from comment #34)
> Not fixed. HTC Desire Z CM9 + FlickWnn(com.pm9.flickwnn)
> fixed. HTC Desire Z CM9 + OpenWnn Plus(com.owplus.ime.openwnnplus)
> 
> This solution(white list) does not seem a good idea.

please file new bug
hashiz, although I test a lot of IME, a lot of IME doesn't work on physical keyboard well except to Android EditView.  So, example, Opera uses EditView for text box.  Since we doesn't use android framework for control, it is no way to support all IMEs. If Google has CTP test for IME deeply, we will be able to support all...
> please file new bug

I file new bug.
https://bugzilla.mozilla.org/show_bug.cgi?id=807204
Keywords: qawanted
Keywords: verifyme
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: