Refactor ScrollView::updateScrollbars()
This CL splits ScrollView::updateScrollbars() into 3 independent helper functions, namely: computeScrollbarExistence() computes whether scrollbars are needed given the current ScrollView state. adjustScrollbarExistence() creates/removes scrollbars and invoke appropriate callbacks to update layout (if applicable). updateScrollbarGeometry() positions the scrollbars and pushes the scroll extents. Also we no longer do update scrollbar passes in recursion. Instead we do it in a loop and early exits if updateScrollbars() is re-entered. No tests as there should be no behavior difference. Review URL: https://codereview.chromium.org/314583008 git-svn-id: svn://svn.chromium.org/blink/trunk@175852 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Showing
This diff is collapsed.
Please register or sign in to comment