You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flex.apache.org by "kevin.godell" <ke...@gmail.com> on 2015/03/04 02:05:18 UTC

flex/air does not resize app when "call in use" statusbar showing on iphone

I just noticed that if I launch my app, minimize it to make a call, and then
maximize it while staying on the call, that the enlarged "call in use"
statusbar of iOS pans my app content downward, making some of my buttons
difficult to interact with because they are at the bottom of my view. I
tested this a little further and found that if I make a call first, then
launch the app fresh(not from minimized state), that the app will load and
use the available screen space beneath the enlarged statusbar and position
content without being pushed off screen. But when the person on the other
line terminates the call, the statusbar returns to a normal height, pulling
the app content upward, creating a gap at the bottom.

I compared the experience of my flex app to other professionally made apps
on my phone. All of the other apps resize their content to use the visible
screen beneath the enlarged "call in use" statusbar.

Expected behavior: app should resize to use visible screen space while
iphone displays "call in use" statusbar, allowing content to reposition
based on visible screen size

I found an old bug for the "hot spot" statusbar @
https://bugbase.adobe.com/index.cfm?event=bug&id=3621841

A phonegap user had similar issue as I do with flex/air with "call in use"
statusbar  @
http://stackoverflow.com/questions/3947226/iphone-how-to-resize-view-when-call-status-bar-is-toggled?lq=1

Just to be thorough, I tested out a fresh app using the latest nightly
flex15 and air17 and experienced the same results. Tested on iphone 5c ios
8.1 using the following simple app code:

<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" 
			   xmlns:s="library://ns.adobe.com/flex/spark" applicationDPI="160"
backgroundColor="0xFFFF00">
	<s:Rect width="100%" height="100%" radiusX="40" radiusY="40">
		<s:fill>
			<s:SolidColor color="0xFF0000"/>
		</s:fill>
	</s:Rect>
</s:Application>

Any thoughts on this? Is there a setting or style that I can target to
prevent my view from panning off screen?



--
View this message in context: http://apache-flex-development.2333347.n4.nabble.com/flex-air-does-not-resize-app-when-call-in-use-statusbar-showing-on-iphone-tp45391.html
Sent from the Apache Flex Development mailing list archive at Nabble.com.

Re: flex/air does not resize app when "call in use" statusbar showing on iphone

Posted by OmPrakash Muppirala <bi...@gmail.com>.
On Mar 22, 2015 8:32 PM, "kevin.godell" <ke...@gmail.com> wrote:
>
> The Kohler Generators app(found in the apache flex community showcase)
> handles the statusbar size change perfectly.
> I looked inside their .ipa and found that they had
> <renderMode>gpu</renderMode>, along with using flex 4.14 and air 16.
>
> I set the rendermode to gpu in my TabbedViewNavigatorApplication and now
the
> statusbar size change is handled slightly better,
> with the app shrinking to accommodate the larger statusbar, and the bottom
> content is no longer pushed off the screen.
> Still, no resize event is triggered when this happens. When rotating the
> phone, the app resizes to the full height(triggering a resize event) and
> underlaps the enlarged statusbar, but this is acceptable until I can find
> out the trick to making it work as good as the Kohler app.
>

That is good to know!  Thanks for the follow up rmail.

Regards,
Om

>
>
> --
> View this message in context:
http://apache-flex-development.2333347.n4.nabble.com/flex-air-does-not-resize-app-when-call-in-use-statusbar-showing-on-iphone-tp45391p45713.html
> Sent from the Apache Flex Development mailing list archive at Nabble.com.

Re: flex/air does not resize app when "call in use" statusbar showing on iphone

Posted by "kevin.godell" <ke...@gmail.com>.
The Kohler Generators app(found in the apache flex community showcase)
handles the statusbar size change perfectly. 
I looked inside their .ipa and found that they had
<renderMode>gpu</renderMode>, along with using flex 4.14 and air 16. 

I set the rendermode to gpu in my TabbedViewNavigatorApplication and now the
statusbar size change is handled slightly better, 
with the app shrinking to accommodate the larger statusbar, and the bottom
content is no longer pushed off the screen. 
Still, no resize event is triggered when this happens. When rotating the
phone, the app resizes to the full height(triggering a resize event) and 
underlaps the enlarged statusbar, but this is acceptable until I can find
out the trick to making it work as good as the Kohler app.



--
View this message in context: http://apache-flex-development.2333347.n4.nabble.com/flex-air-does-not-resize-app-when-call-in-use-statusbar-showing-on-iphone-tp45391p45713.html
Sent from the Apache Flex Development mailing list archive at Nabble.com.

Re: flex/air does not resize app when "call in use" statusbar showing on iphone

Posted by "kevin.godell" <ke...@gmail.com>.
I wish it was just my app, but alas, I created a new app and had the same
results:

<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" 
			   xmlns:s="library://ns.adobe.com/flex/spark" applicationDPI="160"
backgroundColor="0xFFFF00">
	
	<s:Rect width="100%" height="100%" radiusX="40" radiusY="40">
		<s:fill>
			<s:SolidColor color="0xFF0000"/>
		</s:fill>
	</s:Rect>

</s:Application>

list of 4 images that correspond to original 4 images of app:

- normal
<http://apache-flex-development.2333347.n4.nabble.com/file/n45482/IMG_0170.jpg> 

- app launced first, then minimized to make phone call, maximized app after
call in use. content pushed off bottom of screen when statusbar doubled in
height
<http://apache-flex-development.2333347.n4.nabble.com/file/n45482/IMG_0171.jpg> 

- app launched fresh after statusbar already enlarged due to phone call in
use
<http://apache-flex-development.2333347.n4.nabble.com/file/n45482/IMG_0172.jpg> 

- app content slides upward after statusbar shrinks when phone call ends
<http://apache-flex-development.2333347.n4.nabble.com/file/n45482/IMG_0173.jpg> 

I added some resize listeners and never had 1 trigger when the statusbar
height changed.

I voted for the existing bug [1] that is pretty much the same thing as I am
experiencing. I am hoping that others here can also vote for it. Or even
better, tell me that I am simply overlooking something.

[1] https://bugbase.adobe.com/index.cfm?event=bug&id=3621841



--
View this message in context: http://apache-flex-development.2333347.n4.nabble.com/flex-air-does-not-resize-app-when-call-in-use-statusbar-showing-on-iphone-tp45391p45482.html
Sent from the Apache Flex Development mailing list archive at Nabble.com.

Re: flex/air does not resize app when "call in use" statusbar showing on iphone

Posted by OmPrakash Muppirala <bi...@gmail.com>.
I am wondering if the application ever receives a resize even when the
resize happens.  Can you attach an event listener and see if that works?
If it does, we can hopefully fix this within your app.

If not, I am afraid it is either an Adobe AIR bug or a bug with the iOS
itself.  Perhaps reaching out to the AIR team might be a better idea.

Thanks,
Om

On Sun, Mar 8, 2015 at 6:33 PM, kevin.godell <ke...@gmail.com> wrote:

> Looking into this further, it is not just the "phone in use" or "wifi
> hotspot" statusbars that cause this situation,
> but any other app that manipulates the height of the native ios statusbar,
> such as google maps and the built-in ios map program.
> While it not only creates a bad looking gap at the bottom, which could be
> acceptable if it just affected the appearance,
> it also shifts the hit area of the items on the screen. For example, any
> content that has been shifted upward on the screen after the
> statusbar returns to normal will have a hit area that is not vertically
> lined up with the visual display of the item. Its only off by about 40
> pixels,
> but that seems to be enough to make the app feel poorly made.
>
>
>
> --
> View this message in context:
> http://apache-flex-development.2333347.n4.nabble.com/flex-air-does-not-resize-app-when-call-in-use-statusbar-showing-on-iphone-tp45391p45453.html
> Sent from the Apache Flex Development mailing list archive at Nabble.com.
>

Re: flex/air does not resize app when "call in use" statusbar showing on iphone

Posted by "kevin.godell" <ke...@gmail.com>.
Looking into this further, it is not just the "phone in use" or "wifi
hotspot" statusbars that cause this situation, 
but any other app that manipulates the height of the native ios statusbar,
such as google maps and the built-in ios map program. 
While it not only creates a bad looking gap at the bottom, which could be
acceptable if it just affected the appearance, 
it also shifts the hit area of the items on the screen. For example, any
content that has been shifted upward on the screen after the 
statusbar returns to normal will have a hit area that is not vertically
lined up with the visual display of the item. Its only off by about 40
pixels, 
but that seems to be enough to make the app feel poorly made.



--
View this message in context: http://apache-flex-development.2333347.n4.nabble.com/flex-air-does-not-resize-app-when-call-in-use-statusbar-showing-on-iphone-tp45391p45453.html
Sent from the Apache Flex Development mailing list archive at Nabble.com.

Re: flex/air does not resize app when "call in use" statusbar showing on iphone

Posted by "kevin.godell" <ke...@gmail.com>.
first scenario: app is launched before making phone call

image 1 shows app normal, completely using the available space

<http://apache-flex-development.2333347.n4.nabble.com/file/n45412/IMG_0175.jpg> 

image 2  follows image 1 chronologically showing phone in use after app was
already launched, app gets minimized to background to take incoming call,
then re-maximize app to use it while still on phone call.
result: pushes content off bottom of screen by doubling the height of the
statusbar

<http://apache-flex-development.2333347.n4.nabble.com/file/n45412/IMG_0176.jpg> 

second scenario: app is launched after making phone call

image 3 shows a scenario where phone call is in use before the app is
launched(not from a minimized state). App uses entire (shorter) space, not
pushing any content off bottom of screen.

<http://apache-flex-development.2333347.n4.nabble.com/file/n45412/IMG_0177.jpg> 

image 4 follows image 3 chronologically showing call terminated, statusbar
shrinks back to normal height, pulling content upward.
result: gap left at bottom of content

<http://apache-flex-development.2333347.n4.nabble.com/file/n45412/IMG_0178.jpg> 



--
View this message in context: http://apache-flex-development.2333347.n4.nabble.com/flex-air-does-not-resize-app-when-call-in-use-statusbar-showing-on-iphone-tp45391p45412.html
Sent from the Apache Flex Development mailing list archive at Nabble.com.

Re: flex/air does not resize app when "call in use" statusbar showing on iphone

Posted by OmPrakash Muppirala <bi...@gmail.com>.
Screenshots or perhaps a video might give a better idea of the bug.

Thanks,
Om

On Wed, Mar 4, 2015 at 5:37 PM, kevin.godell <ke...@gmail.com> wrote:

> I was testing this again, and found something a little off. On the
> viewnavigatorapplication addedToStage handler, I added some trace
> statements
> to get the sizes of height:
>
> trace(this.height);
> trace(this.stage.height);
> trace(this.stage.stageHeight);
> trace(Capabilities.screenResolutionY);
>
> each had a value of 1136 on my iphone 5c, as expected.
>
> 1136
> 1136
> 1136
> 1136
>
> If I launched my app while the phone call was in use, then values were a
> bit
> off.
>
> 1096
> 1096
> 1096
> 1136
>
> After terminating the call, the app slides upward toward the shrinking
> statusbar, leaving a gap at the bottom, never resizing to use the full
> height found in Capabilities.screenResolutionY. If this is not clear, I can
> add some screenshots.
>
>
>
>
>
> --
> View this message in context:
> http://apache-flex-development.2333347.n4.nabble.com/flex-air-does-not-resize-app-when-call-in-use-statusbar-showing-on-iphone-tp45391p45404.html
> Sent from the Apache Flex Development mailing list archive at Nabble.com.
>

Re: flex/air does not resize app when "call in use" statusbar showing on iphone

Posted by "kevin.godell" <ke...@gmail.com>.
I was testing this again, and found something a little off. On the
viewnavigatorapplication addedToStage handler, I added some trace statements
to get the sizes of height:

trace(this.height);
trace(this.stage.height);
trace(this.stage.stageHeight);
trace(Capabilities.screenResolutionY);

each had a value of 1136 on my iphone 5c, as expected.

1136
1136
1136
1136

If I launched my app while the phone call was in use, then values were a bit
off.

1096
1096
1096
1136

After terminating the call, the app slides upward toward the shrinking
statusbar, leaving a gap at the bottom, never resizing to use the full
height found in Capabilities.screenResolutionY. If this is not clear, I can
add some screenshots.





--
View this message in context: http://apache-flex-development.2333347.n4.nabble.com/flex-air-does-not-resize-app-when-call-in-use-statusbar-showing-on-iphone-tp45391p45404.html
Sent from the Apache Flex Development mailing list archive at Nabble.com.