NestedScrollView

(SESL Modified) NestedScrollView is just like ScrollView, but it supports acting as both a nested scrolling parent and child on both new and old versions of Android. Nested scrolling is enabled by default.

Constructors

Link copied to clipboard
constructor(@NonNull context: @NonNull Context)
constructor(@NonNull context: @NonNull Context, @Nullable attrs: @Nullable AttributeSet)
constructor(@NonNull context: @NonNull Context, @Nullable attrs: @Nullable AttributeSet, defStyleAttr: Int)

Types

Link copied to clipboard
Interface definition for a callback to be invoked when the scroll X or Y positions of a view change.

Properties

Link copied to clipboard
Link copied to clipboard
open var mEdgeGlowBottom: @NonNull EdgeEffect
Link copied to clipboard
open var mEdgeGlowTop: @NonNull EdgeEffect
Link copied to clipboard

Functions

Link copied to clipboard
open fun addView(@NonNull child: @NonNull View)
open fun addView(child: View, params: ViewGroup.LayoutParams)
open fun addView(child: View, index: Int)
open fun addView(child: View, index: Int, params: ViewGroup.LayoutParams)
Link copied to clipboard
open fun arrowScroll(direction: Int): Boolean
Handle scrolling in response to an up or down arrow click.
Link copied to clipboard
open fun computeScroll()
Link copied to clipboard
The scroll range of a scroll view is the overall height of all of its children.
Link copied to clipboard
open fun dispatchDraw(@NonNull canvas: @NonNull Canvas)
Link copied to clipboard
Link copied to clipboard
open fun dispatchNestedFling(velocityX: Float, velocityY: Float, consumed: Boolean): Boolean
Link copied to clipboard
open fun dispatchNestedPreFling(velocityX: Float, velocityY: Float): Boolean
Link copied to clipboard
open fun dispatchNestedPreScroll(dx: Int, dy: Int, consumed: @Nullable Array<Int>, offsetInWindow: @Nullable Array<Int>): Boolean

open fun dispatchNestedPreScroll(dx: Int, dy: Int, consumed: @Nullable Array<Int>, offsetInWindow: @Nullable Array<Int>, type: Int): Boolean
Dispatch one step of a nested scroll in progress before this view consumes any portion of it.
Link copied to clipboard
open fun dispatchNestedScroll(dxConsumed: Int, dyConsumed: Int, dxUnconsumed: Int, dyUnconsumed: Int, offsetInWindow: @Nullable Array<Int>): Boolean

open fun dispatchNestedScroll(dxConsumed: Int, dyConsumed: Int, dxUnconsumed: Int, dyUnconsumed: Int, offsetInWindow: @Nullable Array<Int>, type: Int): Boolean
open fun dispatchNestedScroll(dxConsumed: Int, dyConsumed: Int, dxUnconsumed: Int, dyUnconsumed: Int, offsetInWindow: @Nullable Array<Int>, type: Int, consumed: @NonNull Array<Int>)
Dispatch one step of a nested scroll in progress.
Link copied to clipboard
Link copied to clipboard
open fun draw(@NonNull canvas: @NonNull Canvas)
Link copied to clipboard
open fun executeKeyEvent(@NonNull event: @NonNull KeyEvent): Boolean
You can call this function yourself to have the scroll view perform scrolling from a key event, just as if the event had been dispatched to it by the view hierarchy.
Link copied to clipboard
open fun fling(velocityY: Int)
Fling the scroll view
Link copied to clipboard
open fun flingWithoutAcc(velocityY: Int)
Link copied to clipboard
open fun fullScroll(direction: Int): Boolean
Handles scrolling in response to a "home/end" shortcut press.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Returns true if this view has a nested scrolling parent for the given input type.
Link copied to clipboard
Indicates whether this ScrollView's content is stretched to fill the viewport.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun onGenericMotionEvent(@NonNull motionEvent: @NonNull MotionEvent): Boolean
Link copied to clipboard
open fun onInterceptTouchEvent(@NonNull ev: @NonNull MotionEvent): Boolean
Link copied to clipboard
open fun onNestedFling(@NonNull target: @NonNull View, velocityX: Float, velocityY: Float, consumed: Boolean): Boolean
Link copied to clipboard
open fun onNestedPreFling(@NonNull target: @NonNull View, velocityX: Float, velocityY: Float): Boolean
Link copied to clipboard
open fun onNestedPreScroll(@NonNull target: @NonNull View, dx: Int, dy: Int, consumed: @NonNull Array<Int>)

open fun onNestedPreScroll(@NonNull target: @NonNull View, dx: Int, dy: Int, consumed: @NonNull Array<Int>, type: Int)
React to a nested scroll in progress before the target view consumes a portion of the scroll.
Link copied to clipboard
open fun onNestedScroll(@NonNull target: @NonNull View, dxConsumed: Int, dyConsumed: Int, dxUnconsumed: Int, dyUnconsumed: Int)

open fun onNestedScroll(@NonNull target: @NonNull View, dxConsumed: Int, dyConsumed: Int, dxUnconsumed: Int, dyUnconsumed: Int, type: Int)
open fun onNestedScroll(@NonNull target: @NonNull View, dxConsumed: Int, dyConsumed: Int, dxUnconsumed: Int, dyUnconsumed: Int, type: Int, consumed: @NonNull Array<Int>)
React to a nested scroll in progress.
Link copied to clipboard
open fun onNestedScrollAccepted(@NonNull child: @NonNull View, @NonNull target: @NonNull View, axes: Int)

open fun onNestedScrollAccepted(@NonNull child: @NonNull View, @NonNull target: @NonNull View, axes: Int, type: Int)
React to the successful claiming of a nested scroll operation.
Link copied to clipboard
open fun onStartNestedScroll(@NonNull child: @NonNull View, @NonNull target: @NonNull View, axes: Int): Boolean

open fun onStartNestedScroll(@NonNull child: @NonNull View, @NonNull target: @NonNull View, axes: Int, type: Int): Boolean
React to a descendant view initiating a nestable scroll operation, claiming the nested scroll operation if appropriate.
Link copied to clipboard
open fun onStopNestedScroll(@NonNull target: @NonNull View)

open fun onStopNestedScroll(@NonNull target: @NonNull View, type: Int)
React to a nested scroll operation ending.
Link copied to clipboard
open fun onTouchEvent(@NonNull motionEvent: @NonNull MotionEvent): Boolean
Link copied to clipboard
open fun pageScroll(direction: Int): Boolean
Handles scrolling in response to a "page up/down" shortcut press.
Link copied to clipboard
open fun requestChildFocus(child: View, focused: View)
Link copied to clipboard
open fun requestChildRectangleOnScreen(@NonNull child: @NonNull View, rectangle: Rect, immediate: Boolean): Boolean
Link copied to clipboard
open fun requestDisallowInterceptTouchEvent(disallowIntercept: Boolean)
Link copied to clipboard
open fun requestLayout()
Link copied to clipboard
open fun scrollTo(x: Int, y: Int)
This version also clamps the scrolling to the bounds of our child.
Link copied to clipboard
Link copied to clipboard
open fun seslSetGoToTopEnabled(enabled: Boolean)
open fun seslSetGoToTopEnabled(enabled: Boolean, buttonStyle: Int)
Link copied to clipboard
Link copied to clipboard
open fun seslSetScrollbarVerticalPadding(topPadding: Int, bottomPadding: Int)
Link copied to clipboard
open fun setFillViewport(fillViewport: Boolean)
Set whether this ScrollView should stretch its content height to fill the viewport or not.
Link copied to clipboard
Link copied to clipboard
Register a callback to be invoked when the scroll X or Y positions of this view change.
Link copied to clipboard
open fun setSmoothScrollingEnabled(smoothScrollingEnabled: Boolean)
Set whether arrow scrolling will animate its transition.
Link copied to clipboard
fun smoothScrollBy(dx: Int, dy: Int)
fun smoothScrollBy(dx: Int, dy: Int, scrollDurationMs: Int)
Like scrollBy, but scroll smoothly instead of immediately.
Link copied to clipboard
fun smoothScrollTo(x: Int, y: Int)
fun smoothScrollTo(x: Int, y: Int, scrollDurationMs: Int)
Like scrollTo, but scroll smoothly instead of immediately.
Link copied to clipboard
open fun startNestedScroll(axes: Int): Boolean

open fun startNestedScroll(axes: Int, type: Int): Boolean
Begin a nestable scroll operation along the given axes, for the given input type.
Link copied to clipboard
open fun stopNestedScroll()

open fun stopNestedScroll(type: Int)
Stop a nested scroll in progress for the given input type.