scroll_to_index是一个用于在 Flutter 中实现列表滚动到指定索引的库 依赖 scroll_to_index: ^3.0.1 #滑动位置 使用 classScrollToIndexExampleextendsStatefulWidget { @override _ScrollToIndexExampleState createState()=>_ScrollToIndexExampleSt
2.自定义模型对象 注意自定义对象一定要继承ScrollToIndexBaseObject类 classTestObjectextendsScrollToIndexBaseObject{finalStringname;finalintage; TestObject(this.name,this.age); } 3.在页面中使用widget 使用组件ScrollToIndex ScrollToIndex( itemBuilder: (context, index) { TestObject item = objs[index];/...
scroll_to_index: any In your library add the following import: import 'package:scroll_to_index/scroll_to_index.dart'; For help getting started with Flutter, view the online documentation. Usage This is a widget level library, means you can use this mechanism inside any Flutter scrollable widg...
ariejdlchanged the titleProvide method and or config to programmatically scroll to ListView indexSep 29, 2017 Hixieaddedframeworkflutter/packages/flutter repository. See also f: labels.f: scrollingViewports, list views, slivers, etc.c: new featureNothing broken; request for a new capabilitylabelsNov...
Package https://pub.dev/packages/scrollable_positioned_list scrollable_positioned_list 0.1.9 & others The scrollTo a particular index fails to go to the correct position when the List Items are of different heights (random). This does no...
This package provides the scroll to index mechanism for fixed/variable row height for Flutter scrollable widget. Getting Started In the pubspec.yaml of your flutter project, add the following dependency: dependencies: ... scroll_to_index: any In your library add the following import: import 'pac...