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

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

Issue 1147283002: Add ScrollDirectionPhysical enum in Scroll types. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fixed a conflict on EventHandler Created 5 years, 7 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
« no previous file with comments | « Source/core/frame/FrameView.cpp ('k') | Source/core/frame/RootFrameViewport.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 bool scrollbarsCanBeActive() const override; 52 bool scrollbarsCanBeActive() const override;
53 IntRect scrollableAreaBoundingBox() const override; 53 IntRect scrollableAreaBoundingBox() const override;
54 bool userInputScrollable(ScrollbarOrientation) const override; 54 bool userInputScrollable(ScrollbarOrientation) const override;
55 bool shouldPlaceVerticalScrollbarOnLeft() const override; 55 bool shouldPlaceVerticalScrollbarOnLeft() const override;
56 void invalidateScrollbarRect(Scrollbar*, const IntRect&) override; 56 void invalidateScrollbarRect(Scrollbar*, const IntRect&) override;
57 void invalidateScrollCornerRect(const IntRect&) override; 57 void invalidateScrollCornerRect(const IntRect&) override;
58 GraphicsLayer* layerForContainer() const override; 58 GraphicsLayer* layerForContainer() const override;
59 GraphicsLayer* layerForScrolling() const override; 59 GraphicsLayer* layerForScrolling() const override;
60 GraphicsLayer* layerForHorizontalScrollbar() const override; 60 GraphicsLayer* layerForHorizontalScrollbar() const override;
61 GraphicsLayer* layerForVerticalScrollbar() const override; 61 GraphicsLayer* layerForVerticalScrollbar() const override;
62 bool scroll(ScrollDirection, ScrollGranularity, float delta = 1) override; 62 bool scroll(ScrollDirectionPhysical, ScrollGranularity, float delta = 1) ove rride;
63 // TODO(bokan): This method should be removed. It should be replaced by 63 // TODO(bokan): This method should be removed. It should be replaced by
64 // making EventHandler::handleWheelEvent unpack the WheelEvent and make a 64 // making EventHandler::handleWheelEvent unpack the WheelEvent and make a
65 // call to this class' scroll method. 65 // call to this class' scroll method.
66 ScrollResult handleWheel(const PlatformWheelEvent&) override; 66 ScrollResult handleWheel(const PlatformWheelEvent&) override;
67 67
68 private: 68 private:
69 RootFrameViewport(ScrollableArea& visualViewport, ScrollableArea& layoutView port); 69 RootFrameViewport(ScrollableArea& visualViewport, ScrollableArea& layoutView port);
70 70
71 DoublePoint scrollOffsetFromScrollAnimators() const; 71 DoublePoint scrollOffsetFromScrollAnimators() const;
72 72
73 // If either of the layout or visual viewports are scrolled explicitly (i.e. not 73 // If either of the layout or visual viewports are scrolled explicitly (i.e. not
74 // through this class), their updated offset will not be reflected in this c lass' 74 // through this class), their updated offset will not be reflected in this c lass'
75 // animator so use this method to pull updated values when necessary. 75 // animator so use this method to pull updated values when necessary.
76 void updateScrollAnimator(); 76 void updateScrollAnimator();
77 77
78 ScrollableArea& visualViewport() const { return m_visualViewport; } 78 ScrollableArea& visualViewport() const { return m_visualViewport; }
79 ScrollableArea& layoutViewport() const { return m_layoutViewport; } 79 ScrollableArea& layoutViewport() const { return m_layoutViewport; }
80 80
81 ScrollableArea& m_visualViewport; 81 ScrollableArea& m_visualViewport;
82 ScrollableArea& m_layoutViewport; 82 ScrollableArea& m_layoutViewport;
83 }; 83 };
84 84
85 } // namespace blink 85 } // namespace blink
86 86
87 #endif // RootFrameViewport_h 87 #endif // RootFrameViewport_h
OLDNEW
« no previous file with comments | « Source/core/frame/FrameView.cpp ('k') | Source/core/frame/RootFrameViewport.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698