You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@flex.apache.org by agm65 <ag...@gmx.de> on 2014/04/15 10:20:55 UTC

ScrollingStageTextInputSkin in scroller does not scroll when focus

Hi everybody,

i changed my textinput field from spark.skins.mobile.TextInputSkin to the
new spark.skins.mobile.ScrollingStageTextInputSkin to enable the
softKeyboardType. But now when i focus the textinputs (they are in a
scroller) the scroller does not scroll them over the softkeyboard like
before.
So i am not able to enter data cause they are under the softkeyboard.

Any idea?



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by agm65 <ag...@gmx.de>.
hi,

not really. I use the skin class in a popup (SkinnablePopUpContainer) with:
resizeForSoftKeyboard = false;
moveForSoftKeyboard = false;

maybe thats the problem?



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6241.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by Maurice Amsellem <ma...@systar.com>.
So does it work now ?

-----Message d'origine-----
De : agm65 [mailto:agm65maverick@gmx.de] 
Envoyé : jeudi 17 avril 2014 09:02
À : users@flex.apache.org
Objet : RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

thx alot for the info.



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6159.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by agm65 <ag...@gmx.de>.
thx alot for the info.



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6159.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by Maurice Amsellem <ma...@systar.com>.
>I really wish there was a way to remove the stale information on that page.

I agree.

Flex is in a sort of schizophrenic situation.

So let's take the good side of it, and be happy that at least this kind of documentation exists, even if it's not 100% accurate.

PS:  even if this was possible,  how long and how much people would it take to review all the doc/blogs on Flex and make sure everything is up to date with SDK 4.12 ;-)

Maurice 

-----Message d'origine-----
De : omuppi1@gmail.com [mailto:omuppi1@gmail.com] De la part de OmPrakash Muppirala
Envoyé : mercredi 16 avril 2014 19:21
À : users@flex.apache.org
Objet : RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

On Apr 16, 2014 9:53 AM, "Maurice Amsellem" <ma...@systar.com>
wrote:
>
> TextInputSkin uses Flex-based text input and 
> ScrollingStageTextInputSkin
uses native device input field.
>
> The difference is that TextInputSkin will not support native control 
> of
the soft keyboard, such as autoCapitalize,  autoCorrect, softKeyboardType  ( you will get the default keyboard behavior).
>
> This is explained in detailed here:
>
http://help.adobe.com/en_US/flex/mobileapps/WS82181550ec4a666a39bafe0312d9a274c00-8000.html#WSc71dc4a5c6f1e0e0-1ee7fed313283418436-7ffe
>
> (note:  replace StageTextInputSkin by ScrollingStageTextInputSkin, and
all the section about scrolling is obsolete, as ScrollingStageTextInputSkin now allows scrolling).

I really wish there was a way to remove the stale information on that page.

Thanks,
Om

>
> Maurice
>
>
> -----Message d'origine-----
> De : agm65 [mailto:agm65maverick@gmx.de] Envoyé : mercredi 16 avril 
> 2014 16:37 À : users@flex.apache.org Objet : RE: 
> ScrollingStageTextInputSkin in scroller does not scroll when
focus
>
> Hello,
>
> thats strange if i change my code to
> skinClass="spark.skins.mobile.TextInputSkin". It works with the
softkeyboard and scroll with with
spark.skins.mobile.ScrollingStageTextInputSkin it does not work.
> What is the deifferent between those classes?
>
>
>
> --
> View this message in context:
http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6149.html
> Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by OmPrakash Muppirala <bi...@gmail.com>.
On Apr 16, 2014 9:53 AM, "Maurice Amsellem" <ma...@systar.com>
wrote:
>
> TextInputSkin uses Flex-based text input and ScrollingStageTextInputSkin
uses native device input field.
>
> The difference is that TextInputSkin will not support native control of
the soft keyboard, such as autoCapitalize,  autoCorrect, softKeyboardType
 ( you will get the default keyboard behavior).
>
> This is explained in detailed here:
>
http://help.adobe.com/en_US/flex/mobileapps/WS82181550ec4a666a39bafe0312d9a274c00-8000.html#WSc71dc4a5c6f1e0e0-1ee7fed313283418436-7ffe
>
> (note:  replace StageTextInputSkin by ScrollingStageTextInputSkin, and
all the section about scrolling is obsolete, as ScrollingStageTextInputSkin
now allows scrolling).

I really wish there was a way to remove the stale information on that page.

Thanks,
Om

>
> Maurice
>
>
> -----Message d'origine-----
> De : agm65 [mailto:agm65maverick@gmx.de]
> Envoyé : mercredi 16 avril 2014 16:37
> À : users@flex.apache.org
> Objet : RE: ScrollingStageTextInputSkin in scroller does not scroll when
focus
>
> Hello,
>
> thats strange if i change my code to
> skinClass="spark.skins.mobile.TextInputSkin". It works with the
softkeyboard and scroll with with
spark.skins.mobile.ScrollingStageTextInputSkin it does not work.
> What is the deifferent between those classes?
>
>
>
> --
> View this message in context:
http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6149.html
> Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by Maurice Amsellem <ma...@systar.com>.
TextInputSkin uses Flex-based text input and ScrollingStageTextInputSkin uses native device input field.

The difference is that TextInputSkin will not support native control of the soft keyboard, such as autoCapitalize,  autoCorrect, softKeyboardType  ( you will get the default keyboard behavior).

This is explained in detailed here:
http://help.adobe.com/en_US/flex/mobileapps/WS82181550ec4a666a39bafe0312d9a274c00-8000.html#WSc71dc4a5c6f1e0e0-1ee7fed313283418436-7ffe

(note:  replace StageTextInputSkin by ScrollingStageTextInputSkin, and all the section about scrolling is obsolete, as ScrollingStageTextInputSkin now allows scrolling).

Maurice 


-----Message d'origine-----
De : agm65 [mailto:agm65maverick@gmx.de] 
Envoyé : mercredi 16 avril 2014 16:37
À : users@flex.apache.org
Objet : RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Hello,

thats strange if i change my code to
skinClass="spark.skins.mobile.TextInputSkin". It works with the softkeyboard and scroll with with spark.skins.mobile.ScrollingStageTextInputSkin it does not work.
What is the deifferent between those classes?



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6149.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by agm65 <ag...@gmx.de>.
Hello,

thats strange if i change my code to
skinClass="spark.skins.mobile.TextInputSkin". It works with the softkeyboard
and scroll with with spark.skins.mobile.ScrollingStageTextInputSkin it does
not work.
What is the deifferent between those classes?



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6149.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by agm65 <ag...@gmx.de>.
Hello again,

i will tests it and write back..



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6148.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by Maurice Amsellem <ma...@systar.com>.
Hi agm65,

I have checked your code on an iPad retina.
There is nothing wrong with the TextInput scrolling skin, the problem is in the application  code.

I am assuming you have "wrapped" an existing code inside a scroller, so that the textinput scrolls when the keyboard appears. 
This is not enough, you should adapt your code for scrolling.

Issues in the current code:
- You are using "placement" properties which are preventing scrolling from happening, such as verticalAlign="middle" or verticalCenter="0".
- The nested VGroups are unnecessary, especially if they include only one item.
- Also, don't set the height of the TextInput. It should size correctly.
- if you are using "hard-coded" dimensions (such as font size=20, top=60),  make sure to set the applicationDPI to a fixed value, so that your app will scale correctly on  different density devices (if you are doing it already, please ignore this comment).

Possible solutions:
I seems from your code that you want to display a vertically centered  text input.
So this is how it could be done, and still have the scrolling work:

    <s:Scroller bottom="60" top="60" width="100%" height="100%">
        <s:Group width="100%"  height="100%" >
                <s:TextInput softKeyboardType="number" width="100%"   verticalCenter="0"
                             id="txtMins" restrict="0-9" focusColor="#FFFFFF" color="#9c9a9c"
                             borderVisible="false" autoCapitalize="none" autoCorrect="false"/>
        </s:Group>
    </s:Scroller>

Two things:
The scroller must be tall enough so that there is room to scroll ( == height=100)
The scroller viewport (=direct child) must be tall enough so that it can scroll 

Does this solve your problem ?

Maurice 
____________

Original code below:
<s:Scroller bottom="60" top="60" width="100%"> <s:VGroup width="100%" verticalAlign="middle" horizontalAlign="center"
verticalCenter="0" horizontalCenter="0"> <s:Label  styleName="labelHCE35thin" fontSize="20" width="90%"
textAlign="left" color="#9c9a9c"  />
<s:VGroup verticalAlign="middle" horizontalAlign="left" width="90%"  
gap="2" >		
<s:TextInput softKeyboardType="number"   width="100%" height="42" 
								 id="txtMins" restrict="0-9" focusColor="#FFFFFF" color="#9c9a9c"
borderVisible="false" autoCapitalize="none" autoCorrect="false"					
skinClass="spark.skins.mobile.ScrollingStageTextInputSkin"/>
</s:VGroup>			
</s:VGroup>
</s:Scroller>	

-----Message d'origine-----
De : agm65 [mailto:agm65maverick@gmx.de] 
Envoyé : mardi 15 avril 2014 14:36
À : users@flex.apache.org
Objet : RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Hi,

okay cool i'll wait and try some other things..



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6133.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by agm65 <ag...@gmx.de>.
Hi,

okay cool i'll wait and try some other things..



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6133.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by Maurice Amsellem <ma...@systar.com>.
Ok, that looks good.
I will check that tonight , because I don't have my iPad now to test.

BTW, you don't need to set the skinClass to ScrollingStageTextInputSkin, as it's the default.

Maurice 

-----Message d'origine-----
De : agm65 [mailto:agm65maverick@gmx.de] 
Envoyé : mardi 15 avril 2014 12:22
À : users@flex.apache.org
Objet : RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Hi Maurice,

i am using the new 4.12 sdk, air 1.30 beta.
This is my code:

<s:Scroller bottom="60" top="60" width="100%"> <s:VGroup width="100%" verticalAlign="middle" horizontalAlign="center"
verticalCenter="0" horizontalCenter="0"> <s:Label  styleName="labelHCE35thin" fontSize="20" width="90%"
textAlign="left" color="#9c9a9c"  />
<s:VGroup verticalAlign="middle" horizontalAlign="left" width="90%"  
gap="2" >		
<s:TextInput softKeyboardType="number"   width="100%" height="42" 
								 id="txtMins" restrict="0-9" focusColor="#FFFFFF" color="#9c9a9c"
borderVisible="false" autoCapitalize="none" autoCorrect="false"					
skinClass="spark.skins.mobile.ScrollingStageTextInputSkin"/>
</s:VGroup>			
</s:VGroup>
</s:Scroller>	




--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6131.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by agm65 <ag...@gmx.de>.
Hi Maurice,

i am using the new 4.12 sdk, air 1.30 beta.
This is my code:

<s:Scroller bottom="60" top="60" width="100%">
<s:VGroup width="100%" verticalAlign="middle" horizontalAlign="center"
verticalCenter="0" horizontalCenter="0">
<s:Label  styleName="labelHCE35thin" fontSize="20" width="90%"
textAlign="left" color="#9c9a9c"  />
<s:VGroup verticalAlign="middle" horizontalAlign="left" width="90%"  
gap="2" >		
<s:TextInput softKeyboardType="number"   width="100%" height="42" 
								 id="txtMins" restrict="0-9" focusColor="#FFFFFF" color="#9c9a9c"
borderVisible="false" autoCapitalize="none" autoCorrect="false"					
skinClass="spark.skins.mobile.ScrollingStageTextInputSkin"/>
</s:VGroup>			
</s:VGroup>
</s:Scroller>	




--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124p6131.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

RE: ScrollingStageTextInputSkin in scroller does not scroll when focus

Posted by Maurice Amsellem <ma...@systar.com>.
- Can you post simple code showing the issue ?
- What version of the SDK are you using ?

Maurice 

-----Message d'origine-----
De : agm65 [mailto:agm65maverick@gmx.de] 
Envoyé : mardi 15 avril 2014 10:21
À : users@flex.apache.org
Objet : ScrollingStageTextInputSkin in scroller does not scroll when focus

Hi everybody,

i changed my textinput field from spark.skins.mobile.TextInputSkin to the new spark.skins.mobile.ScrollingStageTextInputSkin to enable the softKeyboardType. But now when i focus the textinputs (they are in a
scroller) the scroller does not scroll them over the softkeyboard like before.
So i am not able to enter data cause they are under the softkeyboard.

Any idea?



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/ScrollingStageTextInputSkin-in-scroller-does-not-scroll-when-focus-tp6124.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.