LoopScrollRect icon indicating copy to clipboard operation
LoopScrollRect copied to clipboard

These scripts will make your UGUI ScrollRect reusing cells, to improve performance, loading time and draw calls.

Results 29 LoopScrollRect issues
Sort by recently updated
recently updated
newest added

我遇到的,主要是 Layout 不会即时排版,可能是 Layout 用太多层了(?) 导致计算子物件大小等,都不是非常正确,滚动时出现诡异的抖动 所以在子物件新增/删除之后,会呼叫 LayoutRebuilder.ForceRebuildLayoutImmediate(content)

@qiankanglai 你好,我最近在使用这个插件进行开发,但是遇到了点问题。 我做了一个竖垂直列表,内容由Title、Dock和Bean三种预制体构成,根据内容Bean会加入到Dock中,最多五个,可以正常循环。但是在一开始生成第一批内容的时候,会生成30个预制体,把内容的高度撑的很长,在内容滚动以后,高度会恢复到demo中的那种合适的高度,多余的预制体都会归还到池中,之后高度就一直正常,十分的奇怪。

比如LoopVerticalScrollRect共有10个元素且每行显示4个,整个界面能显示2行多一点点。这时候更新totalCount为5完了再重新设置totalCount为10并调用RefreshCells,这时候只能刷新两行元素并不会将剩余的元素创建出来。 LoopVerticalScrollRect UpdateItems里: `if (viewBounds.min.y < contentBounds.min.y + m_ContentBottomPadding) { float size = NewItemAtEnd(), totalSize = size; while (size > 0 && viewBounds.min.y < contentBounds.min.y + m_ContentBottomPadding - totalSize) {...

请问请求的数据如何动态赋给不同的item

是否可以支持翻页按钮,如果已支持,请问接口是哪个

看代码 是 NewItemAtEnd 方法里面 itemTypeEnd的值 始终大于 totalCount 直接返回-1 无法创建造成的

In the descriptions, you've said "I need to modify some private variants to make dragging smooth." But I think it's possible to do that using reflection. This removes code duplication,...

首先Content使用GridLayerGroup,并且设置TopPadding为负数。 然后在Awake时候调用RefillCells,这时候显示正常, 当我点击Item时候,调用了RefreshCells,这时候在UpdateItems时候,threshold 等于0,导致算下来Content实际尺寸小于ViewBounds.Max,触发了DeleteItemAtStart,然后把所有的Item都清空了。 然后我往上查,发现在NewItemAtEnd方法中获取Item的Size时候(GetSize方法),这个方法的IncludeSpaceing为false,没有计算contentSpacing,导致m_GridLayer == null,所以获取的size为0,给threshold赋值也是0.

开启reverseDirection后,RefillCells(0),会把index修改。不过我其实本意是想要一个从下往上滑的列表,最底部应该是0,目前等于是滑倒了最底部。我目前是在回调里又转了一遍index。。 另外ScrollToCellWithinTime使用index,貌似并没有转换index。 我准备不使用reverseDirection,业务侧把index转换了