ItemScrollController class

Jumps or scrolls a ScrollablePositionedList to an item.

A controller can be attached to one list at a time; when it is briefly attached to two (for example during a route transition), the newest wins.

Constructors

ItemScrollController()

Properties

anchor → ListAnchor?
הפריט הראשון שנראה והמרחק מקצהו לתחילת התצוגה. restoreAnchor משחזר אותו, כולל ריפוד שנראה לפני הפריט הראשון.
no setter
hashCode → int
The hash code for this object.
no setterinherited
isAttached → bool
Whether a list is attached. jumpTo and scrollTo require it.
no setter
listController → ListController?
The ListController of the attached list's SuperSliverList. Its indices are child indices, which differ from item indices in a separated list.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
scrollController → ScrollController?
The scroll controller of the attached list.
no setter

Methods

indexForScrollOffset(double pixels) → int?
מחזיר אינדקס פריט לפי היסט הפיקסלים של הרשימה, או null מחוץ לתוכן. היסט שבתוך מפריד ממופה לפריט שלפניו.
jumpTo({required int index, double alignment = 0, double offset = 0, TargetRectResolver? targetRectResolver}) → void
Places the leading edge of the item at index at alignment of the viewport plus offset pixels, before the next paint.
jumpToAsync({required int index, double alignment = 0, double offset = 0, TargetRectResolver? targetRectResolver}) → Future<void>
כמו jumpTo, ומשלים אחרי הפריסה שמיישמת את הקפיצה או ביטולה.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
restoreAnchor(ListAnchor anchor) → void
משחזר עוגן בלי להוסיף את הריפוד של jumpTo לפריט הראשון.
restoreAnchorAsync(ListAnchor anchor) → Future<void>
כמו restoreAnchor, ומשלים אחרי הפריסה שמיישמת את השחזור או ביטולו.
scrollTo({required int index, double alignment = 0, double offset = 0, required Duration duration, Curve curve = Curves.linear, List<double> opacityAnimationWeights = const [40, 20, 40], TargetRectResolver? targetRectResolver}) → Future<void>
Animates until the item at index is at alignment; see jumpTo.
toString() → String
A string representation of this object.
inherited
updateEstimatedExtents(Map<int, double> extents) → Future<void>
מעדכן הערכות לפי אינדקסי פריטים ומשלים לאחר הפריסה שמיישמת את האצווה. ברשימה מופרדת גובהי המפרידים נשארים ללא שינוי.

Operators

operator ==(Object other) → bool
The equality operator.
inherited