ScrollDirection enum

The direction of a scroll, relative to the positive scroll offset axis given by an AxisDirection and a GrowthDirection.

This contrasts to GrowthDirection in that it has a third value, idle, for the case where no scroll is occurring.

This is used by RenderSliverFloatingPersistentHeader to only expand when the user is scrolling in the same direction as the detected scroll offset change.

Constants

forward → const ScrollDirection

Scrolling is happening in the positive scroll offset direction.

For example, for the GrowthDirection.forward part of a vertical AxisDirection.down list, this means the content is moving up, exposing lower content.

const ScrollDirection(1)
idle → const ScrollDirection

No scrolling is underway.

const ScrollDirection(0)
reverse → const ScrollDirection

Scrolling is happening in the negative scroll offset direction.

For example, for the GrowthDirection.forward part of a vertical AxisDirection.down list, this means the content is moving down, exposing earlier content.

const ScrollDirection(2)
values → const List<ScrollDirection>

A constant List of the values in this enum, in order of their declaration.

const List<ScrollDirection>

Properties

index → int

The integer index of this enum.

final
hashCode → int
The hash code for this object. [...]
read-only, inherited
runtimeType → Type
A representation of the runtime type of the object.
read-only, inherited

Methods

toString() → String
Returns a string representation of this object.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited

Operators

operator ==(dynamic other) → bool
The equality operator. [...]
inherited