Silly question on efficiency..

Put your problem here if it does not fit any of the other categories.

Silly question on efficiency..

Postby ef em el » Sat Feb 26, 2011 3:10 am

So I have an app i'm making which containers about 7 activities, and im now realizing that i could have just loaded all these functions into one class file and swapped xmls in/out instead of launching completely different activities. Is there a huge issue in efficiency, in that i launch an acitivty that loads teh functions and xml vs loading xmls from 1 file? The problem with this that i can see is that clicking a physical back button would take you out of the entire activity instead of going to previous xml.. but working around that would be worth it if the app would be more efficient?
ef em el
Junior Developer
Junior Developer
 
Posts: 18
Joined: Wed Dec 22, 2010 9:16 am

Top

Re: Silly question on efficiency..

Postby blundell » Sat Feb 26, 2011 12:46 pm

No no having seperate activites with functional back buttons is much more user friendly than one activity that switches xml's.

Although this is a tottally project specific choice and depends on the app.

Don't worry about the effiency in this situation.
User avatar
blundell
Master Developer
Master Developer
 
Posts: 1610
Joined: Tue Nov 18, 2008 12:58 pm
Location: UK

Re: Silly question on efficiency..

Postby ef em el » Sat Feb 26, 2011 11:41 pm

Thanks :P all I needed to hear.
ef em el
Junior Developer
Junior Developer
 
Posts: 18
Joined: Wed Dec 22, 2010 9:16 am

Re: Silly question on efficiency..

Postby Shattered9 » Sun Feb 27, 2011 1:15 am

For the record, I have a simple app that I simply change XMLs in (Granted it only has to go between a couple) and it works fine.

Re-working the back button isn't a problem either really. What I do is just kind of steal the back button functionality when the user is on any page except for the "main" one I call the method that switches back to that XML, and if they are on that main page I have it just use its default functionality. Of course this would depend on your own app needs.
Shattered9
Developer
Developer
 
Posts: 39
Joined: Sat Feb 12, 2011 4:41 pm

Top

Return to Other Coding-Problems

Who is online

Users browsing this forum: No registered users and 22 guests