Marc Reichelt wrote:
> I program on an application where different views are arranged
> horizontally, each view of screen size. The user should be able to
> switch between these views using his finger. I first used the
> ViewFlipper, which was great for simple layouts, but which is *way*
> too slow if the layouts of the views are more complex, because all
> Views are drawn.

Step #1: Put only the first screen's worth of content into the
ViewFlipper in your layout upon creation of your activity.

Step #2: On the first swipe/tap/gesture/whatever to a never-before-seen
"page", inflate the content, add it to the ViewFlipper, and make it the
displayed child.

Step #3: On the second and subsequent moves to the page, just make it
the displayed child.

> A much better method would be to place one layout per activity and
> switch between these activities using the slide in / slide out
> animations.
> Is something in this direction possible with Android right now? Any
> recommendations or best practices?

Users control the animations between activities (Settings > Sound &
display > Animation), not developers. You are welcome to use a
swipe/tap/gesture/whatever to elect to start or finish an activity, but
the user will control whether or not there are animations between them.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://twitter.com/commonsguy

_Beginning Android_ from Apress Now Available!

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