Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Closed or circular Horizontal ListView Android

I have an Horizontal listview i want listview should be closed. For example if the last item is reached in Listview then show the first item below the last item. It means item should be in circular format. And if i scroll from first item it should show last item before first item. I want scrolling for both side.

Below image can tell u what exactly i want Horizontal Listview

In the First image it is showing 5 items and when scroll the Listview it should scroll the items As shown in Second image Thanks In Advance.

like image 832
W I Z A R D Avatar asked Apr 22 '14 06:04

W I Z A R D


People also ask

How do you create a horizontal list in flutter?

You might want to create a list that scrolls horizontally rather than vertically. The ListView widget supports horizontal lists. Use the standard ListView constructor, passing in a horizontal scrollDirection , which overrides the default vertical direction.


1 Answers

As per your requirement you want circular/infinite scrolling horizontal list view,

This is InfiniteScrollView which may help.You need to update this library as per your requirement and change ImageView to any other view which you want to scroll horizontally.

Edit - Solution below works for scrolling list view circularly only on one side ::

Check this circular-list for implementing a circular list adapter. And as your list view is horizontal check this library to create a custom horizontal list view.

Happy Coding :)

like image 66
Dory Avatar answered Nov 01 '22 02:11

Dory