Sure, it's possible... I did the same thing in a webview using Javascript. How I did it would be similiar to how you should do it with a list view...

This is assuming you are using an array list for the data for your List View. First, you need to know how many items your screen would show (the maximum for screens you want to support). Call that x. Then you add the last "x" items to your array list, and then add all your items after it. At the end you add "x" items from the beginning of your list, so that you now have an array list that has enough items at the beginning and end of your actual list to always show a full screen of items, no matter where it is positioned.

Then, when you are scrolling, and you reach the beginning or end of your list, you reset the list position and continue on... NOTE.. that I had to use this method in the webview as I was using images and an unordered list.

With a List View, using the modulus in your getView to adjust the position to the item you want to show would also work (and probably better). I would suggest that it might be helpful for the user if you displayed something (maybe the actual id of the item for each item, or a bar of some kind between the end of the list and the beginning), so that the user woud know when the list was being repeated.


On 11/07/2010 2:00 AM, RodgerWilko! wrote:
Hi,

Is it possible to have a list activity that dosen't finish? i.e. if
you scroll to the end of the list then the start of the list begins
again?

It's be best if you could also disable the scroll bar.

Thanks for your help!

RodgerWilko!


--
Sincerely,

Brad Gies
-----------------------------------------------------------------------
Bistro Bot - Bistro Blurb
http://www.bgies.com
http://www.bistroblurb.com
http://www.ihottonight.com
-----------------------------------------------------------------------

Never doubt that a small group of thoughtful, committed people can
change the world. Indeed. It is the only thing that ever has - Margaret Mead

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