"Swipe" to next screen

by Eddie Ringle » Tue, 20 Apr 2010 20:12:06 GMT

Sponsored Links
 If you look at the Google News & Weather app, you can "swipe" over to the
next page. Anyone know how this is done?
I'm suspecting that it is all one activity, the tabs at the top are a custom
TabView, and it works similar to that?

Eddie Ringle


"Swipe" to next screen

by patbenatar » Wed, 21 Apr 2010 03:26:42 GMT

 I would assume this is done by having the Views you'd like the user to
be able to switch between with a fling of the finger all contained
within one Activity and in that Activity you can listen for
MotionEvents on the currently displaying View. When you detect the
event you're looking for (a swipe, in this case.. although I don't
know how exactly to detect certain gestures) you can use an animation
(Google for "android animation") to push the current View off screen,
replacing it with the next one.

I have seen this tutorial posted on this group before regarding this
topic:  http://whyandroid.com/android/174-flipping-your-views.html  ... 
I have not tried it, however.



Sponsored Links

"Swipe" to next screen

by abisai rangel » Wed, 21 Apr 2010 04:39:29 GMT

 New HP Slate Photos here ----> Website with
photos< http://bizoppoffer.com/x/0/1320/6428/> ;

> >

"Swipe" to next screen

by Eddie Ringle » Wed, 21 Apr 2010 18:14:41 GMT

 Okay, thanks. Just wanted a second opinion.

> >

Other Threads

1. Android ANR and missing logs in traces.txt file

The ANR occurs for my application for some undefined reasons I'd like
to figure out. Unfortunately there is not stack trace in traces.txt
file. Is there any reason why there is nothing about my app in
traces.txt? There are other application's stack.

Is there any other way to figure out what cause ANR except traces.txt
and DDMS traces, which unfortunately show nothing when my app hangs. I
am not also able to use Debug.startMethodTracing as I am not able to
call stoptMethodTracing as I do not know when it hangs.

Best Regards


2. Is this a bug? Is this a forum to file bugs?

The following code makes a zip archive with a non-ASCII filename
entry. Then it reads the zip archive, and tries to recover the entry.
This is not possible, it seems. The file has now a weird encoded name.

It seems to me that with all problems zip archives have with Unicode,
the filename handling should at least be consistent between reading
and writing on the same machine.

Thanks for any hints, suggestions, or answers.


---- snip ----

        TextView tv=(TextView)this.findViewById(R.id.text);

            BufferedOutputStream out=
                new BufferedOutputStream(
                        new   FileOutputStream("/sdcard/test.zip"),
            ZipOutputStream zip=new ZipOutputStream(out);

            ZipEntry ze=new ZipEntry("test.txt");

            ZipFile zf=new ZipFile(new File("/sdcard/test.zip"));
            Enumeration en=zf.entries();
            while (en.hasMoreElements())

        catch (Exception e)


3. Service onCreate is asynchronous

4. Auto-Fill Field

5. Get WhatsApp Messenger for your smartphone

6. Droid X Screen Protecto

7. activity lifetime and lifetime of instance