[android-developers] Re: dialog is getting dismissed when I am flipping the device

2009-05-16 Thread jose toledo
I'm trying to use a managed dialog from inside a tab in a TabActivity and it
is not behaving as I expected. The dialog is still  being killed when I flip
the screen. If I create the dialog from the TabActivity instead of its child
(using getParent().showDialog() ) it is handled correctly.

Is there an easy way to work around this other than just creating all
dialogs from the parent activity?


On Wed, May 13, 2009 at 12:10 PM, Dianne Hackborn wrote:

> Don't do that.  Do the proper thing of saving your state and restoring it,
> or use the managed dialogs API to get help from the system for that.  Doing
> this just means your app will continue to not work in other situations where
> the system kills it, such as when it needs memory for something else that is
> temporarily in the foreground.
>
> On Tue, May 12, 2009 at 5:14 AM, Android Users wrote:
>
>> Flipping the device would recreate the activity. So the dialog is getting
>> dismissed.
>>
>> Override the method onConfigurationChanged(). and for the activity, set
>> the configChanges parameter to "keyboardHidden|Orientation" in the
>> manifest file. doing this, will not recreate the activity.
>>
>>
>>
>
>
> --
> Dianne Hackborn
> Android framework engineer
> hack...@android.com
>
> Note: please don't send private questions to me, as I don't have time to
> provide private support, and so won't reply to such e-mails.  All such
> questions should be posted on public forums, where I and others can see and
> answer them.
>
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: dialog is getting dismissed when I am flipping the device

2009-05-13 Thread Android Users
Hi Dianne,
I suggested the way i followed to retain the state of the dialog, which may
not be preferred. Thanks for the suggestion.
It would be good if you could provide a sample as to how to retain the state
after flipping, so that i could implement the same.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: dialog is getting dismissed when I am flipping the device

2009-05-13 Thread Dianne Hackborn
Don't do that.  Do the proper thing of saving your state and restoring it,
or use the managed dialogs API to get help from the system for that.  Doing
this just means your app will continue to not work in other situations where
the system kills it, such as when it needs memory for something else that is
temporarily in the foreground.

On Tue, May 12, 2009 at 5:14 AM, Android Users wrote:

> Flipping the device would recreate the activity. So the dialog is getting
> dismissed.
>
> Override the method onConfigurationChanged(). and for the activity, set
> the configChanges parameter to "keyboardHidden|Orientation" in the
> manifest file. doing this, will not recreate the activity.
>
> >
>


-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: dialog is getting dismissed when I am flipping the device

2009-05-12 Thread Sudha



Thanks a lot
It worked !!
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: dialog is getting dismissed when I am flipping the device

2009-05-12 Thread Android Users
Flipping the device would recreate the activity. So the dialog is getting
dismissed.

Override the method onConfigurationChanged(). and for the activity,
set the configChanges
parameter to "keyboardHidden|Orientation" in the manifest file. doing this,
will not recreate the activity.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: dialog is getting dismissed when I am flipping the device

2009-05-12 Thread Sudha

is it a bug or desired behavior ?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---