ScrollHost class abstract
Provides access to a scrollbar, its size and their change events.
Interacting with the scroll container, or reading values from it may cause reflows, and should be done only in batched read and write cycles (e.g. Angular's domRead, or DomService's layout check and update callbacks.
- Implemented types
- Implementers
Constructors
Properties
- anchorElement → Element?
-
Returns anchor element for hosting virtual horizontal scrollbar.
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
-
onScroll
→ Stream<
ScrollHostEvent> ? -
The stream of scroll events.
no setter
- panController → PanController?
-
Gets the pan controller for the given scroll host.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scrollLength → int
-
The total scrollable length.
no setter
- scrollPosition → int
-
The current position (>=0, < scrollLength)
no setter
- stickyController → StickyController?
-
Gets the sticky controller for the given scroll host.
no setter
Methods
-
calcViewportRect(
) → Rectangle< num> - Returns absolute positions of the visible frame.
-
dispose(
) → void -
Disposes this disposable and any resources it has open.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
onIntersection(
Element? element) → Stream< IntersectionObserverEntry?> -
A stream which fires when
element
intersects with the scroll viewport. -
scrollToPosition(
int newPosition) → void - Scrolls the scrollbar into the new position.
-
scrollWithDelta(
int delta) → void - Scrolls the scrollbar with the given delta.
-
startNativeScrollListener(
) → void - Start intercepting events that would cause scrolling.
-
stopEvent(
WheelEvent event) → void - Stop an event.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited