- This topic has 13 replies, 3 voices, and was last updated 10 years, 7 months ago by support-octavio.
-
AuthorPosts
-
TurgutGuneysuMemberOS: Win7 Home Premium SP1
MOBI: 2.6.1 (20140109)
Apache Cordova 2.9 and iPhone 4/4S IOS: 6.3 and iPOD IOS: 7.0.4Hi Guys,
Is there a way to dismiss the displayed keyboard programmatically?
I looked through phoneui and saw some code checking the display status of the keyboard, but did not see anything obvious.
RELATED QUESTION:
Should M1 dismiss the keyboard if an on screen button is pressed?
Following scenario happens in IOS 7.0.4. It does NOT happen in IOS 6.3.
I am not sure if it is a bug or not, but please comment on this use case:
1. a menu selection in the MAIN program displays a mobi program to process a FORM.
2. user fills out the form and presses SUBMIT without dismissing the keyboard.
3. Program completes the updates and displays messages, followed by GO TO the MAIN mobi program.
4. Visible portion of the screen above the keyboard displays the MAIN screen all scrolled up
4. At this point the keyboard disappears and I am left with half blank screen where keyboard used to be. The MAIN screen does NOT scroll down and display in its entirety.I have read that while keyboard display is handled by the system on input fields, the dismissing of the keyboard is either done with the DONE button or by touching the background. In my case, it does NOT happen when SUBMIT is pressed. And I guess it also happens automatically when I switch from the FORM program to the MAIN program. However the screen integrity is compromised.
So I am not sure if this is a bug OR I need to find a way to dismiss the keyboard right after my updates in the FORM program, but before I switch over to the MAIN program.
What I have also noticed is that this problem only happens if I switch to a different mobi program from the FORM entry screen. If I stay in the same program, the keyboard dismissal restores the screen correctly by scrolling it down.
Any help would be appreciated.
Turgut
Pictures of the described events:
See attachment KBD1.jpg See attachment KBD2.jpg See attachment KBD3.jpg See attachment KBD4.jpgAttachments:
You must be logged in to view attached files.
support-octavioMemberHi Turgut,
This looks like a bug in the screen layout and transition code. We will initiate investigation.Could you provide an example program that demonstrates the issue to help accelerate our work?
TurgutGuneysuMemberHi Octavio,
Attaching two Test programs that work together to demonstrate the problem.
Text field in the FORM program describes what to do.
Select TAB “Go To FORM”
Touch one of the fields below description and press Submit while KBD is displayed.
You’ll observe the problem after screen transition.Turgut
See attachment KBDMain.mobi
See attachment KBDForm.mobiAttachments:
You must be logged in to view attached files.
support-michaelKeymaster@tguneysu
Thanks for the quick follow up. The team will be investigating when we come online in the morning.
TurgutGuneysuMemberHello Support,
Did you guys have a chance to look at the problem?
If it is going to be a lengthy fix, is it possible to get an answer to my question re KBD hiding?
Thanks,
Turgut
support-octavioMemberHi Turgut,
I kicked this over to the dev team. Will try to have an answer tomorrow (Thurs).
support-octavioMemberHi Turgut,
The dev team have shared next snipet to me:
if (document && document.activeElement && ('blur' in document.activeElement)) { document.activeElement.blur(); // Unfocus currently active document. }
Attach it to an action’s button and keyboard should be hidden after pushing it.
TurgutGuneysuMemberThanks Octavio,
The snippet worked great.
I hope you will let us know when the actual bug is or will be fixed.
TG
support-octavioMemberHi Turgut,
An immediate workaround is to incorp that technique in the pretransition callback. We will investigate how best to integrate it in an update soon.
support-octavioMemberHi Turgut,
There is a 2.6.2 dev build available which contains a fix for this bug, you can download it here: http://www.genuitec.com/support-genuitec/viewtopic.php?f=2&t=7007
Feedback is really apreciated.
TurgutGuneysuMemberHi Octavio;
Sorry for delayed feedback, I had to pay attention to my paying job for about a month.
Anyway, I got a chance to test everything today and ver 2.6.2 does NOT fix the problem.
I have to insert the previously provided code snippet into one of my page buttons to make it work.Let me know if you need any additional testing.
Thanks, Turgut
support-octavioMemberHi Turgut,
We worked on that bug for 2.6.2 and are unable to replicate it now on our test devices. We have built ios apps and ran tests using the current MobiOne 2.6.2 With both your original KDBx example and a similar test case. We tested on iphone5s and ipad air running ios7.1. And on Ipod with ios 6.1
Can you please try building and ios app and testing with attached project. (It’d run fine on iphone even though it’s an ipad design)
Attachments:
You must be logged in to view attached files.
TurgutGuneysuMemberHi Octavio,
I have genned the files you have sent me and created the problem as before.
Again, this is running on iPod Touch with IOS 7.1.
Same program ran OK on iPhone 4 with IOS 6.1.3I am including screenshots showing the KBD display leaving a blank gap behind.
Let me know how else I can help.
Turgut
PS: I want to learn the trick of running Android 6.1 on an iPod. 🙂
See attachment photo 1.PNG See attachment photo 2.PNG
See attachment photo 3.PNG See attachment photo 4.PNGAttachments:
You must be logged in to view attached files.
support-octavioMemberHi Turgut,
I have opened a bug with the team. We don’t have an ipod/ios7.1 atm to verify with.
-
AuthorPosts