leochuan / viewpagerlayoutmanager Goto Github PK
View Code? Open in Web Editor NEWViewPager like LayoutManager which supports some awesome animations and infinite scroll.
License: Apache License 2.0
ViewPager like LayoutManager which supports some awesome animations and infinite scroll.
License: Apache License 2.0
CircleLayoutManager,是以底部为圆心,可以以左边为圆心么,滑动路径是这个形状的“ )”
一个横向的RecyclerView,然后一行的item个数是不限(不像这里3个),然后滑动,每次滑到的过程第一个可见位置的item要放大图片,有没有什么思路呢
比如我只想显示3个,滑动过后出现后续的卡片,但是每次只能看到3个卡片
点击item如何将item移到中间文字
When I set my list to infinite scroll mode using mLayoutManager.setInfinite(true);
, the library seems to auto duplicate items to fill the screen if there are only a few items (like two or three) in the list. How can I prevent this from happening. What should I do if I want to see only the items I have set in the list even if there is only 1 or 2 items, while still being able to scroll them infinitely?
I noticed that when the system language is set to the Persian (RTL) locale, navigating the items with D-Pad (on remote controller) is wrong. For example you press right on the remote and the list jumps to a random item (not the next). It seems this is only true for android TV (remote controller D-Pad). Testing with keyboard on an emulator device with the Persian locale does not seem to have the problem. Can you please the issue? Is the library dependent on LTR locales to work?
I just upgraded to 2.0.1 and now in all CarouselLayoutManager constructors I get the following error when trying to run the app:
protected CarouselLayoutManager createLayoutManager() {
return new CarouselLayoutManager(Util.Dp2px(this, 100));
}
Error:(80, 52) error: incompatible types: int cannot be converted to Builder
Has the constructor signature changed in the new version?
Hi
I am using CarouselLayoutManager to create a carousel list of items. In a small list with a few items, when set to infinite scroll, after the first round, one of the items gets hidden! What does cause this?
你好,我非常喜欢你的项目,有一个小问题,请问能显示Scrollbars吗,特别是在scrollZoomLayoutManager,我该如何操作?
demo中应该是第一张和第二张会出现重叠
我看你已经弄了 自动滚动的,为什么没把 start stop 方法暴露出来
而且自动轮播的东西 bug 最多了,现在你加的这个,滚动到最后一条数据,下一个数据的滚动就会出现 bug
ScaleLayout图片为3个时,循环轮播会产生一个空白页,
用ScaleLayoutManager作为RecyvlerView的LayoutManager,再用CenterSnapHelper().attachToRecyclerView(mRecyvlerView)后,RecyvlerView的item点击事件就会失效,无法,及时修复!
In devices like Android TV and Android set-top boxes, there is often a remote-controller pointer that is used to navigate activities and lists. In a model I am using (MXQ-4K), the items of list created using ViewPagerLayoutManager cannot be selected or navigated. Other items like buttons and floating action buttons are selectable. Is there a method available in the library to support such navigation?
You can check out the app in action here:
https://youtu.be/glppT8PTmYE
If you scroll default recyclerView, then it scrolling with gradual deceleration of speed.
But if I scroll recyclerView with this settings:
mRecyclerView.setLayoutManager(new ScaleLayoutManager(getActivity(),0));
(new LinearSnapHelper()).attachToRecyclerView(mRecyclerView);
then it scrolling with constant speed till to last item. How to prevent it?
I am navigating the items via Keyboard (on emulator) or Android TV via D-Pad, and the navigation seems to work after several rounds for infinite lists. How can I fix that?
在DialogFragment里 RecyclerView item宽度设置match_parent 但是在显示时并没有占满父View 望修复
java.lang.NullPointerException: Attempt to invoke virtual method 'int android.support.v7.widget.OrientationHelper.getMode()' on a null object reference
at android.support.v7.widget.LinearLayoutManager.resolveIsInfinite(LinearLayoutManager.java:1197)
at android.support.v7.widget.LinearLayoutManager.updateLayoutState(LinearLayoutManager.java:1162)
at android.support.v7.widget.LinearLayoutManager.collectAdjacentPrefetchPositions(LinearLayoutManager.java:1311)
at android.support.v7.widget.GapWorker$LayoutPrefetchRegistryImpl.collectPrefetchPositionsFromView(GapWorker.java:94)
at android.support.v7.widget.GapWorker.buildTaskList(GapWorker.java:219)
at android.support.v7.widget.GapWorker.prefetch(GapWorker.java:364)
at android.support.v7.widget.GapWorker.run(GapWorker.java:396)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
Why the error may happen?
大神,请问实现无限循环有什么思路吗,我们这边有这个需求~ ~
设置了wrap_content不显示,急急急!!!
自动轮播不能在Activity OnPause的时候取消轮播,在onResume的时候恢复轮播。。 这样子的话,界面隐藏了,还会一直发现轮播,对内存消耗有影响。
看了源码,好像在AutoPlaySnapHelper有写,但是AutoPlayRecyclerView里面私有了,木有提供出来。
我想实现的画廊效果跟你的有点差别,能不能帮我看看怎么改?方便给下QQ或者WX吗?
Hi
The list navigation works perfect with D-Pad on Android TV (MXQ-4K), however, it seems that scrolling the list now requires two swipes and selecting an item needs two taps! I confirm this for a real phone and an emulated device. Can this be an issue with VPLM?
Can VPLM automatically arrange the lists items on screen so that they look asymmetrical and not biased. To put it simply, for example, I have three items, then VPLM should scroll to item 1 (second item) and not item 0 (1st item). If I have only one item, then the item should be centered by default, and so on.
! [Desired ]
(https://ibb.co/n5AqsG)
! [Bad]
(https://ibb.co/hXVemb)
这边有个需求,着急,请指导一下
Currently ScaleLayoutManager hasn't alpfa. Add, please, alpfa to ScaleLayoutManager, like it is in GalleryLayoutManager
有木有获取选中的监听啊
是否有点击左右两边的图片时,图片自动滑动到中间的方法?如果没有可否添加
hi, im using ElevateScaleLayoutManager, and it works perfectly fine on android 5+, but on below that i have a problem with elevation (i think), and by that i mean the views on right are always drawn over the views on their left. is there any fix for it?
centerSnapHelper关联recyclerview,用carouselLayoutManager.setMoveSpeed((float) 0.25)设置recyclerview的滑动速度后,自动归位会卡顿一下,并且有时item的点击无作用,使用默认的滑动速度不会有上述问题。请帮忙看下!非常感谢!!
缺少onSaveInstanceState等实现,在重启应用程序的时候,会100%出现 java.lang.ClassNotFoundException android.support.v7.widget.RecyclerView$SavedState
用 ScaleLayoutManager 的话,item 不能设置 match_parent,必须要设置固定的宽度
这样会带来适配的问题
能不能改成 margin 或者 padding,就不用设置固定的宽度
我现在的需求是滑动到最后继续右滑时弹出一个dialog,试了好几种办法都不能很好的监听,请问怎么弄额?
java.lang.NullPointerException: Attempt to invoke virtual method 'int android.support.v7.widget.OrientationHelper.getMode()' on a null object reference
还未分析原因,仅反馈
想做成viewpager一样,一次只能滑动一张,快速滑动功能取消掉
当滑动结束拿到currentPosition 刷新适配器会出现索引错乱的问题
Hey
I was trying to apply custom animations to the items of the list using ConstraintLayout animations (an example here). It had no effect. I also tried another library (Bungee). Again didn't work. It seems that VPLM disables all animations. What's your comment on this? Is it impossible to add custom animations to my activity and views when using VPLM?
快速滑动必现这个闪退
java.lang.IndexOutOfBoundsException: Invalid item position -2(-2). Item count:20
at android.support.v7.widget.RecyclerView$Recycler.tryGetViewHolderForPositionByDeadline(RecyclerView.java:5466)
at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:5440)
at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:5436)
at rouchuan.customlayoutmanager.ViewPagerLayoutManager.layoutItems(ViewPagerLayoutManager.java:299)
at rouchuan.customlayoutmanager.ViewPagerLayoutManager.scrollHorizontallyBy(ViewPagerLayoutManager.java:262)
at android.support.v7.widget.RecyclerView$ViewFlinger.run(RecyclerView.java:4722)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:898)
at android.view.Choreographer.doCallbacks(Choreographer.java:700)
at android.view.Choreographer.doFrame(Choreographer.java:632)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:884)
at android.os.Handler.handleCallback(Handler.java:815)
at android.os.Handler.dispatchMessage(Handler.java:104)
at android.os.Looper.loop(Looper.java:238)
at android.app.ActivityThread.main(ActivityThread.java:6016)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:937)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:798)
Hi Leochuan
Can we stop scrolling when last item visible in the screen is the real last item of the list ?
ScrollZoomLayoutManager 现在是中间的布局被放大了,两边没变,不应该是中间不变,两边缩小吗
你好,这里我用了两种类型来显示,但是总是什么都显示不出来。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.