OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef RootScrollerUtil_h | 5 #ifndef RootScrollerUtil_h |
6 #define RootScrollerUtil_h | 6 #define RootScrollerUtil_h |
7 | 7 |
8 namespace blink { | 8 namespace blink { |
9 | 9 |
10 class Element; | 10 class Element; |
| 11 class PaintLayer; |
11 class ScrollableArea; | 12 class ScrollableArea; |
12 | 13 |
13 namespace RootScrollerUtil { | 14 namespace RootScrollerUtil { |
14 | 15 |
15 ScrollableArea* scrollableAreaFor(const Element&); | 16 // Returns the ScrollableArea that's associated with the root scroller element. |
| 17 // For the <html> element this will be the FrameView or root |
| 18 // PaintLayerScrollableArea. |
| 19 ScrollableArea* scrollableAreaForRootScroller(const Element&); |
| 20 |
| 21 // Returns the PaintLayer that'll be used as the root scrolling layer. For the |
| 22 // <html> element, this returns the LayoutView's PaintLayer rather than |
| 23 // <html>'s since scrolling is handled by LayoutView. |
| 24 PaintLayer* paintLayerForRootScroller(const Element*); |
16 | 25 |
17 } // namespace RootScrollerUtil | 26 } // namespace RootScrollerUtil |
18 | 27 |
19 } // namespace blink | 28 } // namespace blink |
20 | 29 |
21 #endif // RootScrollerUtil_h | 30 #endif // RootScrollerUtil_h |
OLD | NEW |