starting the same activity....

by sdphil » Sat, 24 Apr 2010 05:53:54 GMT


Sponsored Links
 I have a weird issue, and I'll describe it in somewhat abstract terms
in the hopes that someone can see something I'm obviously doing wrong.

I have an activity with some data on it (call it Activity A1).  The
user hits a button and I launch another instance of that same
activity, but with different data (call that Activity A2).  Now, I hit
the "back" button (hardware) and instead of showing the data from A1,
it shows the data from A2.  If I force an orientation change, it shows
the data from A1 correctly.

I am not using static data anywhere and I am using the default onPause
and onResume.  It's almost as if Android is reusing the GUI controls
even though it's a different instance of the activity.

thoughts?

tia.

--



starting the same activity....

by krox » Sun, 25 Apr 2010 04:09:15 GMT


 Hi!

Hmm that sounds weird, I just created a testApp and it worked as
expected (that is it did not update the UI-elements in A1 when I
updated them in A2). Would you mind posting the sourcecode?

//Erik



>


Sponsored Links


Other Threads

1. setResult crashed if portrait/landscape orientation changes

I have this scenario:
1) activity A starts activity B via startActivityForResult.
2) User changes orientation which triggered activity B to be destroyed
and its onCreate method to be called a second time.
3) Activity B calls setResult(...) and that crashes.

It seems activity B no longer knows who to return to the result to.
Is it possible to save info into the Bundle via  onSaveInstanceState
so that activity B can remember who called it?
--~--~---------~--~----~------------~-------~--~----~

2. google-framework_intermediates directory missing when building on Handy heron

after running repo, and make from terminal for the first time (with
errors), then trying to build in eclipse Ganymede,
/home/android_root/mydroid/out/target/common/obj/JAVA_LIBRARIES/google-
framework_intermediates is missing.

the folder
/home/android_root/mydroid/out/target/common/obj/JAVA_LIBRARIES/
framework_intermediates exists, and the file that eclipse Ganymede is
looking for is there.

There are also files that look for
/home/android_root/mydroid/out/target/common/obj/JAVA_LIBRARIES/
framework_intermediates also.

David
--~--~---------~--~----~------------~-------~--~----~
unsubscribe: [EMAIL PROTECTED]
website: 

3. Mobile web and Android app integration

4. pre-portability number being returned from telephony manager

5. Threads in Android

6. Contacts Performance

7. About the stats bug in Market