-
Notifications
You must be signed in to change notification settings - Fork 142
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
使用GalleryLayoutManager之后item显示不出来 #16
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
这是我的代码
List lisr = new ArrayList<>();
for (int i = 0; i <20 ; i++) {
lisr.add("item"+i);
}
adapter = new NoticeBannerAdapter(lisr);
new GalleryLayoutManager(GalleryLayoutManager.HORIZONTAL).attach(recycleBanner);
recycleBanner.setAdapter(adapter);
下面是打印出来的日志
D/GalleryLayoutManager: onLayoutChildren() called with: state = [State{mTargetPosition=-1, mData=null, mItemCount=20, mIsMeasuring=false, mPreviousLayoutItemCount=0, mDeletedInvisibleItemCountSincePreviousLayout=0, mStructureChanged=true, mInPreLayout=false, mRunSimpleAnimations=false, mRunPredictiveAnimations=false}]
reset:
D/GalleryLayoutManager: firstFillCover finish:first: 0,last:0
V/GalleryLayoutManager: onScrolled: dx:0,dy:0
onScrolled: dx:0,dy:0
D/GalleryLayoutManager: onLayoutChildren() called with: state = [State{mTargetPosition=-1, mData=null, mItemCount=20, mIsMeasuring=false, mPreviousLayoutItemCount=20, mDeletedInvisibleItemCountSincePreviousLayout=0, mStructureChanged=false, mInPreLayout=false, mRunSimpleAnimations=false, mRunPredictiveAnimations=false}]
onLayoutChildren: ignore extra layout step
D/OpenGLRenderer: endAllActiveAnimators on 0x7f7c70c000 (RippleDrawable) with handle 0x7f7decc840
请问下我是不是哪里写的有点问题,我把这些代码复制到一个新开的项目,能显示,然后在自己项目中引用就显示不出来,我看打印出来的日志mItemCount是有20条的。
The text was updated successfully, but these errors were encountered: