[ 
https://issues.apache.org/jira/browse/FLEX-33371?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13565968#comment-13565968
 ] 

Erik Thomas commented on FLEX-33371:
------------------------------------

Hi OmPrakash:

This is almost a perfect workaround. Unfortunately, listening for the 
NativeApplication.DEACTIVATE event to unload is not reliable. It seems to fire 
randomly and not related to orientation changes. I've only tried a couple 
times, but as I work through my app workflows, everything is working great on 
Android now, just like iOS, but something is triggering the DEACTIVATE event 
during a workflow and the app is unloading because I'm calling exit().

So I'm not out of the woods yet, but this is a huge improvement.

Erik

Erik J. Thomas
CEO | Principal Developer
E. J. Thomas & Associates, LLC 
266 Peakview Rd, Boulder, CO 80302
303-440-8384 (office) | 303-304-1466 (mobile) 
ejtho...@ejthomas.com 
CONFIDENTIALITY NOTICE: This e-mail and any attachments may contain 
confidential information that is legally privileged. The information is solely 
for the use of the intended recipient(s). Any disclosure, copying, 
distribution, or other use of this information is strictly prohibited. If you 
have received this e-mail in error, please notify the sender by return e-mail 
and delete this message.



                
> On Android, changing orientation fires Event.DEACTIVATE and 
> FlexEvent.VIEW_DEACTIVATE events
> --------------------------------------------------------------------------------------------
>
>                 Key: FLEX-33371
>                 URL: https://issues.apache.org/jira/browse/FLEX-33371
>             Project: Apache Flex
>          Issue Type: Bug
>          Components: Mobile: MobileApplication
>    Affects Versions: Adobe Flex SDK 4.6 (Release)
>         Environment: Samsung Galaxy Express and Galaxy S III Android Phones, 
> FlashBuilder 4.7 Premium on Windows 7, debugging through USB as well as 
> deployed release builds, iPhone and iPad, but the problem doesn't exist on 
> iOS devices, only Android
>            Reporter: Erik Thomas
>            Priority: Critical
>             Fix For: Adobe Flex SDK 4.6 (Release)
>
>         Attachments: AndroidDeactivateOnOrientationChangeDefect.zip
>
>
> Orientation changes on Android devices always fire the following events in 
> this order:
> ViewNavigatorEvent.VIEW_DEACTIVATE
> Event.DEACTIVATE
> StageOrientationEvent.ORIENTATION_CHANGE
> The first two events are a defect. They must not fire simply because the user 
> changed the orientation of the phone.
> The result of this defect is that we cannot do two very important things:
> 1. Use view state changes to hide/show layouts, using includeIn property on 
> containers and components. On Android, components that are not included for a 
> given state are destroyed yet they have state we want to maintain which is 
> why we don't change Views.
> 2. We cannot know when the user navigates away from our application, for 
> example to press the Home key. We have certain cleanup we must do in our 
> complex connected app that streams FMS data, etc., and cannot keep sockets 
> open for hours or days.
> On iOS, this is not a problem. Only Android has this bug and it's blocking us 
> from releasing our product on Android. iOS does not have this defect.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to