You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@flex.apache.org by "kevin.godell" <ke...@gmail.com> on 2015/09/24 02:44:49 UTC

TextInput ios7 mobile skin and ScrollableStageText problems

Tested on iphone 5c ios 8.2 using flex 4.14.1 air 18 and also flex nightly
from a few months ago with air 17

I have not seen any posts lately with anybody complaining about the
textinput on ios7+, so maybe I am the only one with this problem. I had to
put a textinput below the vertical center of the screen, so when the
softkeyboard opens, the textinput and other content is scrolled up so that
it can remain visible. The textinput is contained in a group, which is
inside a scroller. The application's resizeForSoftKeyboard is set to false.
In the app descriptor file, softKeyboardBehavior is set to none and
fullScreen is set to false.

When the app first loads and nothing has been given focus, or if another ui
component such as a button has been previously focused, mousedown on the
TextInput immediately opens the softkeyboard and the TextInput scrolls up
and seems OK, although the softkeyboard events are a bit off. Softkeyboard
deactivate event is first triggered on the stage, followed by activate.
Softkeyboard activating event is not triggered in this scenario.

If a TextInput is focused and then you click an empty part of the screen
causing focus to be lost, and then you click that same TextInput, the
softkeyboard will not be activated until mouseup. Also, the softkeyboard
events trigger in the proper order: activating -> activate. What is
noticeable in this scenario is that the softkeyboard appears to popup with a
slight hesitation, and the TextInput will scroll into position but will be
empty. Clicking on this TextInput that was supposed to already have focus
causes it to immediately show it's proxy image and then close the
softkeyboard.

One more small issue, is that when the TextInput has editable = false,
clicking it will still trigger the softkeyboard to open, but the TextInput
will not scroll into position.

I have been trying to debug this and I do not have a good solution, other
than inside the ScrollableStageText in the
stageText_softKeyboardActivateHandler function, I check if
this.stageText.viewPort.bottom >= this.stage.softKeyboardRect.top, and then
call endTextEdit() and trigger a timer for 200 milliseconds which will call
startTextEdit(). I hate using timers like that, but I have not found any
other events to hook into. Maybe I can listen for the TextInput scrolling
into position?

Any suggestions?







-----
.
--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/TextInput-ios7-mobile-skin-and-ScrollableStageText-problems-tp11216.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

Re: TextInput ios7 mobile skin and ScrollableStageText problems

Posted by "kevin.godell" <ke...@gmail.com>.
Thanks for the tip about air 19. Unfortunately, I tried it and there were no
improvements for my situation.



-----
.
--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/TextInput-ios7-mobile-skin-and-ScrollableStageText-problems-tp11216p11218.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.