-
Notifications
You must be signed in to change notification settings - Fork 27
Description
Given
- A
scrollable
withscrollPosition
ofScrollPos_Bottom
- During the event frame of the display region changing
When
A scroll position is that is requested for the scrollable
via scrollTo
(and probably also scrollBy
) that is
- within view given the "current"
scrollPosition
(ScrollPos_Bottom
) andscrollHeight
- outside of the view given the updated
height
Result
The scrollable
maintains the scrollPosition
of ScrollPos_Bottom
, effectively ignoring the requested scrollPosition
.
Expected
My expectation is that the scrollable
would update to the requested scrollPosition
, given that position would be outside of the view from the ScollPos_Bottom
position, using the "totalLines
" and "scrollHight
" of the new event frame.
Context
I am building a way to select a line from a list, by having the list displayed in a scrollable
and having it scroll when the user moves the selection past the ends of the scrollable
.
But, to maintain that the currently selected item stays displayed, I need to scroll the scrollable
to a appropriate position when the height of the scrollable
changes, as the selected item can get cut from view when the scrollable
shrinks. So, therefor I am pushed to move the scrollable
in the same event frame as the height changing.