dinghongfa / super-scrollview

Cocos Creator 3.x 虚拟列表

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

SuperScrollView

Optimization for Cocoscreator cc.ScrollView

[Online Demonstration Effect] (https://icipiqkm.github.io/super-scrollView/)

[Cocos forum address] (https://forum.cocos.org/topic/118518)

[Cocoscreator2.x Old Edition here] (https://github.com/icipiqkm/UisuperScrollView)

illustrate


The increase or decrease of the entire list of data is processed by the use layer. The components don’t need to know what your data structure is
No matter what you do to your array (push, pop ....)
Or when you modify the content of a certain element, you just need to tell the component how many data you have,
This is the method of superlayout.total

Interface

  • SuperLayout.total (length: Number) This method is to tell the component how many data you have. Whenever you add deletion or your array length has not changed, but the content of your array has changed. You can call this method to refresh this method.
  • SuperLayout.scrolltoheader rolled to the starting location
  • SuperLayout.scrolltofooter rolled to the end position
  • SuperLayout.scrolltoindex rolled to the specified location
  • If you like it, don't forget to click Star, thank you

Code is not easy to give a reward at hand to this guy!

About

Cocos Creator 3.x 虚拟列表


Languages

Language:TypeScript 100.0%