Sure, but then what if right as the activity is starting, something
else happens that causes it to be destroyed? (incoming phone call,
camera app is  started, it could be anything, really)
My point was: instead of putting in all these hacks to try and prevent
your activity from being stopped and restarted at an inconvenient
time, it's ultimately easier to do the right thing. Like cleaning up
the threads in onDestroy, using a service instead of a thread, or
keeping the threads across activities.



On Wed, Mar 11, 2009 at 7:18 AM, Stoyan Damov <[email protected]> wrote:
>
> unless he traps the back button in onKeyDown
>
> On Wed, Mar 11, 2009 at 2:51 PM, Marco Nelissen <[email protected]> wrote:
>>
>> That will solve the problem when opening/closing the keyboard, but
>> won't solve it when e.g. starting the app and then immediately hitting
>> the back button to exit it.
>>
>>
>> On Wed, Mar 11, 2009 at 5:37 AM, Stoyan Damov <[email protected]> wrote:
>>>
>>> keyboardHidden|orientation
>>>
>>> On Wed, Mar 11, 2009 at 2:34 PM, mobilekid <[email protected]> 
>>> wrote:
>>>>
>>>> For some reason that seems not to work in my case. I've declared the
>>>> activity as android:configChanges="orientation" in the
>>>> AndroidManifest.xml, which I assume will call onConfigurationChanged
>>>> (Configuration). So for testing purposes I've simply implemented it as
>>>> follows:
>>>>
>>>> @Override
>>>> public void onConfigurationChanged (Configuration newConfig){
>>>>        Log.i(this.toString(), "I've been called!");
>>>>        super.onConfigurationChanged(newConfig);
>>>> }
>>>>
>>>> However, it never gets called. Am I doing anything wrong here?!
>>>> Thanks!
>>>>
>>>>
>>>>
>>>>
>>>> On Mar 11, 11:44 am, Stoyan Damov <[email protected]> wrote:
>>>>> Yes, basically if you declare your activity's orientation to be
>>>>> "sensor" there's nothing else to do (I think).
>>>>
>>>> >
>>>>
>>>
>>> >
>>>
>>
>> >
>>
>
> >
>

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

Reply via email to