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

Side by Side Diff: third_party/WebKit/Source/core/frame/RootFrameViewport.h

Issue 2128553002: Make rootScroller the layout viewport. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@viewportScrollCallbackInterface
Patch Set: Rebase + comment fix in test Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 13 matching lines...) Expand all
24 class CORE_EXPORT RootFrameViewport final : public GarbageCollectedFinalized<Roo tFrameViewport>, public ScrollableArea { 24 class CORE_EXPORT RootFrameViewport final : public GarbageCollectedFinalized<Roo tFrameViewport>, public ScrollableArea {
25 USING_GARBAGE_COLLECTED_MIXIN(RootFrameViewport); 25 USING_GARBAGE_COLLECTED_MIXIN(RootFrameViewport);
26 public: 26 public:
27 static RootFrameViewport* create(ScrollableArea& visualViewport, ScrollableA rea& layoutViewport) 27 static RootFrameViewport* create(ScrollableArea& visualViewport, ScrollableA rea& layoutViewport)
28 { 28 {
29 return new RootFrameViewport(visualViewport, layoutViewport); 29 return new RootFrameViewport(visualViewport, layoutViewport);
30 } 30 }
31 31
32 DECLARE_VIRTUAL_TRACE(); 32 DECLARE_VIRTUAL_TRACE();
33 33
34 void setLayoutViewport(ScrollableArea&);
35
34 // ScrollableArea Implementation 36 // ScrollableArea Implementation
35 void setScrollPosition(const DoublePoint&, ScrollType, ScrollBehavior = Scro llBehaviorInstant) override; 37 void setScrollPosition(const DoublePoint&, ScrollType, ScrollBehavior = Scro llBehaviorInstant) override;
36 LayoutRect scrollIntoView( 38 LayoutRect scrollIntoView(
37 const LayoutRect& rectInContent, 39 const LayoutRect& rectInContent,
38 const ScrollAlignment& alignX, 40 const ScrollAlignment& alignX,
39 const ScrollAlignment& alignY, 41 const ScrollAlignment& alignY,
40 ScrollType = ProgrammaticScroll) override; 42 ScrollType = ProgrammaticScroll) override;
41 DoubleRect visibleContentRectDouble(IncludeScrollbarsInRect = ExcludeScrollb ars) const override; 43 DoubleRect visibleContentRectDouble(IncludeScrollbarsInRect = ExcludeScrollb ars) const override;
42 IntRect visibleContentRect(IncludeScrollbarsInRect = ExcludeScrollbars) cons t override; 44 IntRect visibleContentRect(IncludeScrollbarsInRect = ExcludeScrollbars) cons t override;
43 bool shouldUseIntegerScrollOffset() const override; 45 bool shouldUseIntegerScrollOffset() const override;
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 ScrollableArea& visualViewport() const { ASSERT(m_visualViewport); return *m _visualViewport; } 89 ScrollableArea& visualViewport() const { ASSERT(m_visualViewport); return *m _visualViewport; }
88 ScrollableArea& layoutViewport() const { ASSERT(m_layoutViewport); return *m _layoutViewport; } 90 ScrollableArea& layoutViewport() const { ASSERT(m_layoutViewport); return *m _layoutViewport; }
89 91
90 Member<ScrollableArea> m_visualViewport; 92 Member<ScrollableArea> m_visualViewport;
91 Member<ScrollableArea> m_layoutViewport; 93 Member<ScrollableArea> m_layoutViewport;
92 }; 94 };
93 95
94 } // namespace blink 96 } // namespace blink
95 97
96 #endif // RootFrameViewport_h 98 #endif // RootFrameViewport_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/frame/FrameView.cpp ('k') | third_party/WebKit/Source/core/frame/RootFrameViewport.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698