Closed Bug 341772 Opened 18 years ago Closed 15 years ago

don't pop up software keyboard when hardware keyboard exists

Categories

(Core :: Widget: Win32, defect)

x86
Windows CE
defect
Not set
normal

Tracking

()

VERIFIED FIXED
Tracking Status
status1.9.2 --- beta1-fixed
fennec 1.0-wm+ ---

People

(Reporter: jym.brittain, Assigned: dougt)

References

Details

(Keywords: mobile)

Attachments

(2 files, 3 obsolete files)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.4) Gecko/20060508 Firefox/1.5.0.4
Build Identifier: minimo 0.016

Clicking on a text entry space, even the address bar, causes the software keyboard to pop up. On devices with keyboards, ie the Cingular 8125/HTC Wizard this action should be optional. Other applications for this device have an input selection icon in the bottom menu bar so the user can choose whether to use the software keyboard, the included hardware keyboard or touch screen character input.

The user CAN use the hardware keyboard but the software keyboard remains. This obscures valuable screen space.

Reproducible: Always

Steps to Reproduce:
1.Launch minimo on a device with hardware keyboard
2. Click on text entry space
3.

Actual Results:  
software keyboard pops up

Expected Results:  
software keyboard should pop up, but the application should have the input selection icon to, in effect, dismiss the software keyboard to give greater screen space and the use of the hardware keyboard
in preferences, you can disable the software keyboard.  if you do this, does the problem go away for you?
Status: UNCONFIRMED → NEW
Ever confirmed: true
I have yet to find a way to access the preferences for Minimo. Changing the input method in the Windows settings does not change the behavor.
After disabling the software keyboard the problem does go away. Thank you explaining how to access the preferences.
We should do a better job of figuring out if there is a keyboard available and if it is, not use the softkeys.  Last I checked, the API didn't behave as documented.  Time to take another look.
Assignee: dougt → nobody
Component: Device Specific → Widget: Win32
OS: Windows XP → Windows CE
Product: Minimo → Core
QA Contact: chofmann → win32
Version: WinCE → unspecified
Keywords: mobile
Summary: devices with keyboards → don't pop up software keyboard when hardware keyboard exists
tracking-fennec: --- → 1.0-wm+
Depends on: 474734
tacking..
Assignee: nobody → bugmail
Status: NEW → ASSIGNED
Assignee: bugmail → doug.turner
Palm Treo Pro is another test case for this.  I'll try disabling keyboard in prefs.
Ah, can't get to prefs on the Treo Pro -- it uses the large theme, so the prefs button doesn't show up.
Attached patch hide software keyboard on i780 (obsolete) — Splinter Review
This patch detects hardware keyboard and make the software keyboard hide when Fennec starts up on Samsung i780.
The problem is that the softkey menu bar is still shown. It has to be hided when the user doesn't input anything.
(In reply to comment #11)
> The problem is that the softkey menu bar is still shown. It has to be hided
> when the user doesn't input anything.

That's because this patch returns early if the hardware keyboard is present.  ToggleSoftKB() hides the sip button/toolbar further down, so it would be better to adjust show based on the presence of a hardware keyboard.

Also, one problem I see with this patch is for devices with slide out keyboards. Any thoughts on how to handle those?
Attached patch hide the SIP button (obsolete) — Splinter Review
I fixed this patch as Blassey advised, so it also hides the SIP button.

Regarding devices with slide out keyboard, we can use the SmiSliderGetState API on Samsung devices. For more information, please refer to http://tinyurl.com/lfksrq
Attachment #388474 - Attachment is patch: true
Attachment #388474 - Attachment mime type: application/octet-stream → text/plain
Attachment #388221 - Attachment is obsolete: true
Comment on attachment 388474 [details] [diff] [review]
hide the SIP button

>+  result = ::RegQueryValueEx(hKey, L"HasKeyboard", NULL, &entryType, 
>+                      (LPBYTE)&hwkbd, &paramSize);

This is just a matter of opinion, but I think using GetKeyboardStatus() would be cleaner.
Attached patch use of the GetKeyboardStatus() (obsolete) — Splinter Review
Ok, I changed the function with GetKeyboardStatus().
It would be a proper name for this role.
Thanks
Attachment #388474 - Attachment is obsolete: true
Are we talking about this GetKeyboardStatus()

http://msdn.microsoft.com/en-us/library/ms929253.aspx
I misunderstood Blassey's comment.
Anyway, I tried to use the GetKeyboardStatus() for checking if the hardware keyboard is present. But, it always returns the same value on Samsung i780 and the emulator.

Other people reported the similar result as follows:
http://tinyurl.com/lv79mf

So I think this API seems not working well.
so much for using MS APIs.  :-(
I changed the name of GetKeyboardStatus() in the last patch to CheckKeyboardStatus().
If the GetKeyboardStatus() doesn't really work, we had better use my CheckKeyboardStatus().
Attachment #388715 - Attachment is obsolete: true
Joone, are you asking for a review on the above patch?
Sure, if there are no further issues.
Attachment #389374 - Flags: review?(doug.turner)
Comment on attachment 389374 [details] [diff] [review]
changed the function name again

does this actually work?  on the htc touch pro, i am pretty sure that CheckKeyboardStatus will always return true no matter if you are in landscape or portrait.  So, when in portrait mode, you will not get a software keyboard.
I'm sorry. I missed testing this function on the HTC touch pro, but there is related information for HTC dual touch.
http://forum.xda-developers.com/archive/index.php/t-353387.html

We may be able to check the state from HKLM\Software\OEM\KeyBoard\SlidingOut.

I will try to test it when I get a HTC touch pro.
Comment on attachment 389374 [details] [diff] [review]
changed the function name again

space than curl brace:

+  if (sHardKBPresence == TRI_TRUE){



drop the :: in front of the WINAPIs.

do you want to set the sHardKBPresense state in the error condition under the RegQueryValueEx call (back) to unknown?

Also my comment #22
Attachment #389374 - Flags: review?(doug.turner) → review-
This patch enables Fennec to detect the current state of the slide out keyboard of HTC touch pro.

We can check the current state of slide out keyboard from the registry "HKEY_LOCAL_MACHINE\System\GDI\Rotation\Slidekey"
Attachment #395322 - Flags: review?(doug.turner)
Comment on attachment 395322 [details] [diff] [review]
Support for slide out keyboard

this is great.  good find on how to detect this!
Attachment #395322 - Flags: review?(doug.turner) → review+
http://hg.mozilla.org/mozilla-central/rev/3072dcbbd285
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Attachment #395322 - Flags: approval1.9.2?
Attachment #395322 - Flags: approval1.9.2? → approval1.9.2+
verified with 20090828 1.9.2 nightly winmo build
Status: RESOLVED → VERIFIED
I need to look at this again with my Treo Pro.  The last build I tried failed to detect the hardware keyboard there, but it this was fixed in the last week, I'll be happy.
wfm on my HTC Touch.  In fact, better in this respect than Opera Mobile ;)
Just tried last WM nightly on my Treo Pro running WM 6.1.  Software keyboard pops up when I tap in AwesomeBar even though the device has a hardware keyboard.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: