百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
S

ScrollableItemList

> 编程语言
开源

一个包含可滚动以显示更多内容的 Android RecyclerView 列表

365 stars0 点赞0 次浏览
访问官网GitHub

工具介绍

一个包含可滚动以显示更多内容的 Android RecyclerView 列表

ScrollableItemList

Description

An Android RecyclerView List with items that can scroll to reveal more content on the side. This view has been inspired by the one found in the Reddit News App.

Demo

[]

Notes on using this

The view has been created using standard views now available with Android Lollipop and its compatibility libraries. The list is a RecyclerView with a LinearLayoutManager. Each item in the list is essentially a ViewPager with two views; a CardView and FrameLayout with three buttons.

Everything else can be used normally except the RecyclerViewAdapter.java where most of the work is required.

The challenges were as follows:

1) The ViewPager does not inflate properly inside the RecyclerView.

In order to solve this, the width of the ViewPager was manually set to the current width of the screen when it inflates inside the adapter. The height should be specified manaully and wrap_content attribute cannot be used.

2) The ViewPagers do not retain state as the list items are scrolled away from current view and back.

In order to solve this problem, the RecyclerViewAdapter holds a list of states for each of the ViewPager and sets them back when a previously modified item comes back in view.

License

…

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

Java

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月17日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言