Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(277)

Issue 21091004: Fix bottom/right fixed-pos with non-overlay scrollbars. (Closed)

Created:
7 years, 4 months ago by aelias_OOO_until_Jul13
Modified:
7 years, 4 months ago
Reviewers:
enne (OOO)
CC:
chromium-reviews, cc-bugs_chromium.org, trchen, wjmaclean
Visibility:
Public.

Description

Fix bottom/right fixed-pos with non-overlay scrollbars. Since Blink positions fixed-pos elements against the clip-rect, adjusting them against the true viewport size (which includes the non-overlay scrollbars) was incorrect. Moreover, scrollbar layer size isn't correct here because custom scrollbars and non-impl-scrolled scrollbars don't have them attached to the root scroll layer (and this likely is causing bugs in the max scroll offset calculation that haven't been noticed yet). The cleanest way to deal with this is to get additional information from Blink about what it believes the viewport size is including the non-overlay scrollbars (see https://codereview.chromium.org/21084007 ). This is passed in via the bounds of a layer I call the ViewportLayer. CC determines it by looping up the ancestors of RootContainerLayer, in order for the logic to work regardless of additional intermediate layers that Blink might later add (page scale layer, etc). BUG=263172

Patch Set 1 #

Total comments: 7
Unified diffs Side-by-side diffs Delta from patch set Stats (+55 lines, -22 lines) Patch
M cc/trees/layer_tree_impl.h View 1 chunk +2 lines, -0 lines 0 comments Download
M cc/trees/layer_tree_impl.cc View 4 chunks +53 lines, -22 lines 7 comments Download

Messages

Total messages: 12 (0 generated)
aelias_OOO_until_Jul13
Hi Enne, let me know what you think of this approach. If it looks good, ...
7 years, 4 months ago (2013-07-29 21:42:14 UTC) #1
enne (OOO)
+1 to setting bounds of layers in Blink to convey more information to the compositor. ...
7 years, 4 months ago (2013-07-30 02:32:17 UTC) #2
aelias_OOO_until_Jul13
https://codereview.chromium.org/21091004/diff/1/cc/trees/layer_tree_impl.cc File cc/trees/layer_tree_impl.cc (right): https://codereview.chromium.org/21091004/diff/1/cc/trees/layer_tree_impl.cc#newcode252 cc/trees/layer_tree_impl.cc:252: max_scroll.set_x(max_scroll.x() + NonOverlayScrollbarThickness(VERTICAL)); On 2013/07/30 02:32:17, enne wrote: > ...
7 years, 4 months ago (2013-07-30 02:52:00 UTC) #3
enne (OOO)
https://codereview.chromium.org/21091004/diff/1/cc/trees/layer_tree_impl.cc File cc/trees/layer_tree_impl.cc (right): https://codereview.chromium.org/21091004/diff/1/cc/trees/layer_tree_impl.cc#newcode252 cc/trees/layer_tree_impl.cc:252: max_scroll.set_x(max_scroll.x() + NonOverlayScrollbarThickness(VERTICAL)); On 2013/07/30 02:52:00, aelias wrote: > ...
7 years, 4 months ago (2013-07-30 03:44:46 UTC) #4
aelias_OOO_until_Jul13
https://codereview.chromium.org/21091004/diff/1/cc/trees/layer_tree_impl.cc File cc/trees/layer_tree_impl.cc (right): https://codereview.chromium.org/21091004/diff/1/cc/trees/layer_tree_impl.cc#newcode252 cc/trees/layer_tree_impl.cc:252: max_scroll.set_x(max_scroll.x() + NonOverlayScrollbarThickness(VERTICAL)); On 2013/07/30 03:44:47, enne wrote: > ...
7 years, 4 months ago (2013-07-30 04:06:13 UTC) #5
enne (OOO)
On 2013/07/30 04:06:13, aelias wrote: > https://codereview.chromium.org/21091004/diff/1/cc/trees/layer_tree_impl.cc > File cc/trees/layer_tree_impl.cc (right): > > https://codereview.chromium.org/21091004/diff/1/cc/trees/layer_tree_impl.cc#newcode252 > ...
7 years, 4 months ago (2013-07-30 19:14:54 UTC) #6
aelias_OOO_until_Jul13
Good point about the future two-scroll-layer world. But, the other factor you're not considering is ...
7 years, 4 months ago (2013-07-30 20:27:12 UTC) #7
enne (OOO)
On 2013/07/30 20:27:12, aelias wrote: > Good point about the future two-scroll-layer world. > > ...
7 years, 4 months ago (2013-07-30 20:40:21 UTC) #8
aelias_OOO_until_Jul13
On 2013/07/30 20:40:21, enne wrote: > On 2013/07/30 20:27:12, aelias wrote: > > Good point ...
7 years, 4 months ago (2013-07-30 20:51:40 UTC) #9
enne (OOO)
On 2013/07/30 20:51:40, aelias wrote: > Unfortunately, the top controls manager can also increase the ...
7 years, 4 months ago (2013-07-31 00:59:09 UTC) #10
aelias_OOO_until_Jul13
On 2013/07/31 00:59:09, enne wrote: > On 2013/07/30 20:51:40, aelias wrote: > > > Unfortunately, ...
7 years, 4 months ago (2013-07-31 01:33:06 UTC) #11
aelias_OOO_until_Jul13
7 years, 4 months ago (2013-07-31 03:42:12 UTC) #12
Semi-revert up for your consideration at
https://codereview.chromium.org/21323002

Powered by Google App Engine
This is Rietveld 408576698