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

Side by Side Diff: third_party/WebKit/Source/core/page/scrolling/TopDocumentRootScrollerController.h

Issue 2499853002: Fixed clip resize for document.rootScroller with inertTopControls (Closed)
Patch Set: Fixed typo Created 4 years 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 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 TopDocumentRootScrollerController_h 5 #ifndef TopDocumentRootScrollerController_h
6 #define TopDocumentRootScrollerController_h 6 #define TopDocumentRootScrollerController_h
7 7
8 #include "core/CoreExport.h" 8 #include "core/CoreExport.h"
9 #include "core/page/scrolling/RootScrollerController.h" 9 #include "core/page/scrolling/RootScrollerController.h"
10 #include "platform/heap/Handle.h" 10 #include "platform/heap/Handle.h"
11 11
12 namespace blink { 12 namespace blink {
13 13
14 class Element; 14 class Element;
15 class FrameHost; 15 class FrameHost;
16 class GraphicsLayer; 16 class GraphicsLayer;
17 class PaintLayer;
17 class RootFrameViewport; 18 class RootFrameViewport;
18 class ScrollStateCallback; 19 class ScrollStateCallback;
19 class ViewportScrollCallback; 20 class ViewportScrollCallback;
20 21
21 // This class manages the the page level aspects of the root scroller. That 22 // This class manages the the page level aspects of the root scroller. That
22 // is, given all the iframes on a page and their individual root scrollers, 23 // is, given all the iframes on a page and their individual root scrollers,
23 // this class will determine which ultimate Element should be used as the root 24 // this class will determine which ultimate Element should be used as the root
24 // scroller and ensures that Element is used to scroll browser controls and 25 // scroller and ensures that Element is used to scroll browser controls and
25 // provide overscroll effects. 26 // provide overscroll effects.
26 // TODO(bokan): This class is currently OOPIF unaware. crbug.com/642378. 27 // TODO(bokan): This class is currently OOPIF unaware. crbug.com/642378.
(...skipping 16 matching lines...) Expand all
43 // Returns true if the given ScrollStateCallback is the 44 // Returns true if the given ScrollStateCallback is the
44 // ViewportScrollCallback managed by this class. 45 // ViewportScrollCallback managed by this class.
45 // TODO(bokan): Temporarily needed to allow ScrollCustomization to 46 // TODO(bokan): Temporarily needed to allow ScrollCustomization to
46 // differentiate between real custom callback and the built-in viewport 47 // differentiate between real custom callback and the built-in viewport
47 // apply scroll. crbug.com/623079. 48 // apply scroll. crbug.com/623079.
48 bool isViewportScrollCallback(const ScrollStateCallback*) const; 49 bool isViewportScrollCallback(const ScrollStateCallback*) const;
49 50
50 // Returns the GraphicsLayer for the global root scroller. 51 // Returns the GraphicsLayer for the global root scroller.
51 GraphicsLayer* rootScrollerLayer() const; 52 GraphicsLayer* rootScrollerLayer() const;
52 53
54 PaintLayer* rootScrollerPaintLayer() const;
55
53 // Returns the Element that's the global root scroller. 56 // Returns the Element that's the global root scroller.
54 Element* globalRootScroller() const; 57 Element* globalRootScroller() const;
55 58
56 // Called when the root scroller in any frames on the page has changed. 59 // Called when the root scroller in any frames on the page has changed.
57 void didChangeRootScroller(); 60 void didChangeRootScroller();
58 61
62 void mainFrameViewResized();
63
59 private: 64 private:
60 TopDocumentRootScrollerController(FrameHost&); 65 TopDocumentRootScrollerController(FrameHost&);
61 66
62 // Calculates the Element that should be the globalRootScroller. On a 67 // Calculates the Element that should be the globalRootScroller. On a
63 // simple page, this will simply the root frame's effectiveRootScroller but 68 // simple page, this will simply the root frame's effectiveRootScroller but
64 // if the root scroller is set to an iframe, this will then descend into 69 // if the root scroller is set to an iframe, this will then descend into
65 // the iframe to find its effective root scroller. 70 // the iframe to find its effective root scroller.
66 Element* findGlobalRootScrollerElement(); 71 Element* findGlobalRootScrollerElement();
67 72
68 // Should be called to ensure the correct element is currently set as the 73 // Should be called to ensure the correct element is currently set as the
(...skipping 15 matching lines...) Expand all
84 // m_viewportApplyScroll has been created, it will always be set on this 89 // m_viewportApplyScroll has been created, it will always be set on this
85 // Element. 90 // Element.
86 WeakMember<Element> m_globalRootScroller; 91 WeakMember<Element> m_globalRootScroller;
87 92
88 WeakMember<FrameHost> m_frameHost; 93 WeakMember<FrameHost> m_frameHost;
89 }; 94 };
90 95
91 } // namespace blink 96 } // namespace blink
92 97
93 #endif // RootScrollerController_h 98 #endif // RootScrollerController_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698