Reputation: 11050
I have an app that shows upcoming music events.
When you select an event, you can see its details and the bands that play in that event. If you select a band, you can see its details and upcoming events where that band plays. If you select an event, you can see that event.
So, you can get an Event, see its Artists, see an Artist, see an Event where that artist plays, see an artist playing in that event, see its events... you can go as deep as you want.
Should I overwrite the intents with Intent.FLAG_ACTIVITY_CLEAR_TOP
so the app doesn't ever run out of memory, or leave it as it is and let the app flow for as long as Android can handle?
Upvotes: 2
Views: 165
Reputation: 11185
It depends. From what I understand about your app, wont this option destroy your user's ability to go back (by pressing the back button) to say the artist the event was for ? May be you can get around that by providing a bread crumb that will launch the activity with the right data in the intent (say provide the event ID / artist ID in the intent for the activity to load).
That way you can go several levels deep, maintaining only 2 instances of the activity (for events and bands ) and still load relevant data based on what is passed on your intent.
Upvotes: 1