Re: [android-developers] What should I use for common parts of UI in Android application?

2011-08-09 Thread TreKing
On Mon, Aug 8, 2011 at 11:50 PM, Alexey Zakharov alexey.v.zaha...@gmail.com
 wrote:

 Should this screens be separate activities?


It can't as you're using Maps which requires one MapActivity.


 Is fragments API right thing to implement this?


Maybe, I don't know. Take a gander at the Strategy Pattern.

-
TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago
transit tracking app for Android-powered devices

-- 
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

Re: [android-developers] What should I use for common parts of UI in Android application?

2011-08-09 Thread Shane Isbell
In general, it is a good idea to start leveraging fragments. This will make
it easier to rebuild the UI on tablets. Fragments allows reuse and well as
storing of history state of each component.

If you are only interested in handsets and don't care about component reuse
or history state, then just use an activity and swap out components by
setting view visibility. Also the complexity of the UI component is a factor
(simple click events may not warrant a fragment but more complicated logic
may).

On Tue, Aug 9, 2011 at 10:25 AM, TreKing treking...@gmail.com wrote:

 On Mon, Aug 8, 2011 at 11:50 PM, Alexey Zakharov 
 alexey.v.zaha...@gmail.com wrote:

 Should this screens be separate activities?


 It can't as you're using Maps which requires one MapActivity.


 Is fragments API right thing to implement this?


 Maybe, I don't know. Take a gander at the Strategy Pattern.


 -
 TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago
 transit tracking app for Android-powered devices


  --
 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


-- 
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

Re: [android-developers] What should I use for common parts of UI in Android application?

2011-08-09 Thread Alexey Zakharov
Yep, from my searches in Uber's code it uses ViewStabs and single map 
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] What should I use for common parts of UI in Android application?

2011-08-08 Thread Alexey Zakharov
Here is Uber Android application. As you see each of screen has some common 
elements: header, map control etc. But each view has different header 
buttons and subview with some view specific details.

Should this screens be separate activities?
Is fragments API right thing to implement this?

http://i.stack.imgur.com/w0GQI.jpg

http://i.stack.imgur.com/zdKIE.jpg

http://i.stack.imgur.com/Ir43Y.jpg




-- 
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