SliverOverlapAbsorberHandle class

Handle to provide to a SliverOverlapAbsorber, a SliverOverlapInjector, and an NestedScrollViewViewport, to shift overlap in a NestedScrollView.

A particular SliverOverlapAbsorberHandle can only be assigned to a single SliverOverlapAbsorber at a time. It can also be (and normally is) assigned to one or more SliverOverlapInjectors, which must be later descendants of the same NestedScrollViewViewport as the SliverOverlapAbsorber. The SliverOverlapAbsorber must be a direct descendant of the NestedScrollViewViewport, taking part in the same sliver layout. (The SliverOverlapInjector can be a descendant that takes part in a nested scroll view's sliver layout.)

Whenever the NestedScrollViewViewport is marked dirty for layout, it will cause its assigned SliverOverlapAbsorberHandle to fire notifications. It is the responsibility of the SliverOverlapInjectors (and any other clients) to mark themselves dirty when this happens, in case the geometry subsequently changes during layout.

See also:

Inheritance

Constructors

SliverOverlapAbsorberHandle()
Creates a SliverOverlapAbsorberHandle.

Properties

hashCode int
The hash code for this object.
no setterinherited
hasListeners bool
Whether any listeners are currently registered.
no setterinherited
layoutExtent double?
The current amount of overlap being absorbed by the SliverOverlapAbsorber.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scrollExtent double?
The total scroll extent of the gap being absorbed by the SliverOverlapAbsorber.
no setter

Methods

addListener(VoidCallback listener) → void
Register a closure to be called when the object changes.
inherited
dispose() → void
Discards any resources used by the object. After this is called, the object is not in a usable state and should be discarded (calls to addListener will throw after the object is disposed).
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyListeners() → void
Call all the registered listeners.
inherited
removeListener(VoidCallback listener) → void
Remove a previously registered closure from the list of closures that are notified when the object changes.
inherited
toString() String
A string representation of this object.
override

Operators

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