OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 RootFrameViewport_h | 5 #ifndef RootFrameViewport_h |
6 #define RootFrameViewport_h | 6 #define RootFrameViewport_h |
7 | 7 |
8 #include "core/CoreExport.h" | 8 #include "core/CoreExport.h" |
9 #include "platform/scroll/ScrollableArea.h" | 9 #include "platform/scroll/ScrollableArea.h" |
10 | 10 |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 void didUpdateVisualViewport(); | 53 void didUpdateVisualViewport(); |
54 | 54 |
55 // ScrollableArea Implementation | 55 // ScrollableArea Implementation |
56 bool isRootFrameViewport() const override { return true; } | 56 bool isRootFrameViewport() const override { return true; } |
57 void setScrollOffset(const ScrollOffset&, | 57 void setScrollOffset(const ScrollOffset&, |
58 ScrollType, | 58 ScrollType, |
59 ScrollBehavior = ScrollBehaviorInstant) override; | 59 ScrollBehavior = ScrollBehaviorInstant) override; |
60 LayoutRect scrollIntoView(const LayoutRect& rectInContent, | 60 LayoutRect scrollIntoView(const LayoutRect& rectInContent, |
61 const ScrollAlignment& alignX, | 61 const ScrollAlignment& alignX, |
62 const ScrollAlignment& alignY, | 62 const ScrollAlignment& alignY, |
63 ScrollType = ProgrammaticScroll) override; | 63 ScrollType = ProgrammaticScroll, |
| 64 ScrollBehavior = ScrollBehaviorAuto) override; |
64 IntRect visibleContentRect( | 65 IntRect visibleContentRect( |
65 IncludeScrollbarsInRect = ExcludeScrollbars) const override; | 66 IncludeScrollbarsInRect = ExcludeScrollbars) const override; |
66 bool shouldUseIntegerScrollOffset() const override; | 67 bool shouldUseIntegerScrollOffset() const override; |
67 LayoutRect visualRectForScrollbarParts() const override { | 68 LayoutRect visualRectForScrollbarParts() const override { |
68 ASSERT_NOT_REACHED(); | 69 ASSERT_NOT_REACHED(); |
69 return LayoutRect(); | 70 return LayoutRect(); |
70 } | 71 } |
71 bool isActive() const override; | 72 bool isActive() const override; |
72 int scrollSize(ScrollbarOrientation) const override; | 73 int scrollSize(ScrollbarOrientation) const override; |
73 bool isScrollCornerVisible() const override; | 74 bool isScrollCornerVisible() const override; |
(...skipping 15 matching lines...) Expand all Loading... |
89 GraphicsLayer* layerForHorizontalScrollbar() const override; | 90 GraphicsLayer* layerForHorizontalScrollbar() const override; |
90 GraphicsLayer* layerForVerticalScrollbar() const override; | 91 GraphicsLayer* layerForVerticalScrollbar() const override; |
91 GraphicsLayer* layerForScrollCorner() const override; | 92 GraphicsLayer* layerForScrollCorner() const override; |
92 int horizontalScrollbarHeight( | 93 int horizontalScrollbarHeight( |
93 OverlayScrollbarClipBehavior = IgnoreOverlayScrollbarSize) const override; | 94 OverlayScrollbarClipBehavior = IgnoreOverlayScrollbarSize) const override; |
94 int verticalScrollbarWidth( | 95 int verticalScrollbarWidth( |
95 OverlayScrollbarClipBehavior = IgnoreOverlayScrollbarSize) const override; | 96 OverlayScrollbarClipBehavior = IgnoreOverlayScrollbarSize) const override; |
96 ScrollResult userScroll(ScrollGranularity, const FloatSize&) override; | 97 ScrollResult userScroll(ScrollGranularity, const FloatSize&) override; |
97 bool scrollAnimatorEnabled() const override; | 98 bool scrollAnimatorEnabled() const override; |
98 HostWindow* getHostWindow() const override; | 99 HostWindow* getHostWindow() const override; |
| 100 ProgrammaticScrollCoordinator* getProgrammaticScrollCoordinator() |
| 101 const override; |
99 void serviceScrollAnimations(double) override; | 102 void serviceScrollAnimations(double) override; |
100 void updateCompositorScrollAnimations() override; | 103 void updateCompositorScrollAnimations() override; |
101 void cancelProgrammaticScrollAnimation() override; | 104 void cancelProgrammaticScrollAnimation() override; |
102 ScrollBehavior scrollBehaviorStyle() const override; | 105 ScrollBehavior scrollBehaviorStyle() const override; |
103 Widget* getWidget() override; | 106 Widget* getWidget() override; |
104 void clearScrollableArea() override; | 107 void clearScrollableArea() override; |
105 LayoutBox* layoutBox() const override; | 108 LayoutBox* layoutBox() const override; |
106 FloatQuad localToVisibleContentQuad(const FloatQuad&, | 109 FloatQuad localToVisibleContentQuad(const FloatQuad&, |
107 const LayoutObject*, | 110 const LayoutObject*, |
108 unsigned = 0) const final; | 111 unsigned = 0) const final; |
(...skipping 28 matching lines...) Expand all Loading... |
137 | 140 |
138 DEFINE_TYPE_CASTS(RootFrameViewport, | 141 DEFINE_TYPE_CASTS(RootFrameViewport, |
139 ScrollableArea, | 142 ScrollableArea, |
140 scrollableArea, | 143 scrollableArea, |
141 scrollableArea->isRootFrameViewport(), | 144 scrollableArea->isRootFrameViewport(), |
142 scrollableArea.isRootFrameViewport()); | 145 scrollableArea.isRootFrameViewport()); |
143 | 146 |
144 } // namespace blink | 147 } // namespace blink |
145 | 148 |
146 #endif // RootFrameViewport_h | 149 #endif // RootFrameViewport_h |
OLD | NEW |