I managed to implement a GalleryView, create a custom Adapter that returns a ListView for each item of the gallery but now the the problem:
I while I can scroll the listview vertially, I can no longer scroll the GalleryView horizontally.
What I am aiming at is a UI similar to the Google Weather/News application. While you can click a 'tab-like' gallery item on the top, you can also horizontally scroll the list views that represent the news items.
How can I implement this?
I donĀ“t know the Google Weather/News app, but if I understand you correctly a ViewFlipper/ViewAnimator could help you.
Related
I want to implement in an App a horizantal selectable list of categories, exactly like the one seen on youtube. But I have no idea how youtube does it. I mean is it a tablayout, or or just a recyclerview. The images below shows the feature.
You can implement both way, using custom tablayout as well as using horizontal recyclerview. Custom tablayout is little bit difficult to implement. But horizontal recyclerview will be better choice and it's easier to put any custom view inside recyclerview and upon selecting any option, just notify the adapter using notifyDataSetChanged method and load data in vertical recyclerview.
I have to create list of gridview like section gridview where it has title and grid items below, i achieved this by using recyclerview and gridview, but the issue is, scroll doesn't goes smoother, it gives zerk while scrolling. and then i tried with recyclerview, cardview, along with GridLayoutManager, but now i'm not able to set background to the section. please see the attached image, you will get idea on what i am trying.
suggest me which are the best approach to set background without using gridview and listview combination.
pintrest like android scrollview
Basically I am looking to have two list views which scroll only together (not separately) when I scroll the screen. (Like if they where in the same scroll view)
Each if the list items of course most remain clickable. Each if the items in each list can have different lengths, so no I can't have a single adapter.
Thanks
The Trick is ListView withing a ListView. You need to have a main listview and then a layout that holds other two listview. The subsequest scroll can be sync between those both using onScrollListener and sync between them. Its quite a project by itself but you could give a try.
Another way is to build a custom view which you want to display as pInterest, might take more than expected time.
there are a lot of libraries for that, here are some of them
https://github.com/vladexologija/PinterestListView
https://github.com/chenyoca/pinterest-like-adapter-view
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
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.
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 :)
I have a homescreen widget (android > 4.0) with a gridview and show some pictures within. And I want to make some additional views (imageview with icons or anything else) visible on scrolling this grid.
So if the user scolls through the grid, little icons within every picture is gonna be visible.
Is that possible?
I searched for something like setOnScrollListener on RemoteViews, but I didn't find anything nor a getParent to access the grid from within the griditem.
Thanks in advance!!!
You do not need an OnScrollListener for this. GridView already knows how to scroll and already knows how to populate additional cells in the grid based upon that scrolling. Simply provide your data to the GridView (in this case, via a RemoteViewsFactory).