| 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 ScrollManager_h | 5 #ifndef ScrollManager_h |
| 6 #define ScrollManager_h | 6 #define ScrollManager_h |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include "core/CoreExport.h" | 9 #include "core/CoreExport.h" |
| 10 #include "core/page/EventWithHitTestResults.h" | 10 #include "core/page/EventWithHitTestResults.h" |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 94 | 94 |
| 95 private: | 95 private: |
| 96 WebInputEventResult HandleGestureScrollUpdate(const WebGestureEvent&); | 96 WebInputEventResult HandleGestureScrollUpdate(const WebGestureEvent&); |
| 97 WebInputEventResult HandleGestureScrollBegin(const WebGestureEvent&); | 97 WebInputEventResult HandleGestureScrollBegin(const WebGestureEvent&); |
| 98 | 98 |
| 99 WebInputEventResult PassScrollGestureEvent(const WebGestureEvent&, | 99 WebInputEventResult PassScrollGestureEvent(const WebGestureEvent&, |
| 100 LayoutObject*); | 100 LayoutObject*); |
| 101 | 101 |
| 102 void ClearGestureScrollState(); | 102 void ClearGestureScrollState(); |
| 103 | 103 |
| 104 void CustomizedScroll(const Node& start_node, ScrollState&); | 104 void CustomizedScroll(ScrollState&); |
| 105 | 105 |
| 106 Page* GetPage() const; | 106 Page* GetPage() const; |
| 107 | 107 |
| 108 bool IsViewportScrollingElement(const Element&) const; | 108 bool IsViewportScrollingElement(const Element&) const; |
| 109 | 109 |
| 110 bool HandleScrollGestureOnResizer(Node*, const WebGestureEvent&); | 110 bool HandleScrollGestureOnResizer(Node*, const WebGestureEvent&); |
| 111 | 111 |
| 112 void RecomputeScrollChain(const Node& start_node, | 112 void RecomputeScrollChain(const Node& start_node, |
| 113 const ScrollState&, |
| 113 std::deque<int>& scroll_chain); | 114 std::deque<int>& scroll_chain); |
| 115 bool CanScroll(const ScrollState&, const Element& current_element); |
| 114 | 116 |
| 115 // scroller_size is set only when scrolling non root scroller. | 117 // scroller_size is set only when scrolling non root scroller. |
| 116 void ComputeScrollRelatedMetrics( | 118 void ComputeScrollRelatedMetrics( |
| 117 uint32_t* non_composited_main_thread_scrolling_reasons, | 119 uint32_t* non_composited_main_thread_scrolling_reasons, |
| 118 int* scroller_size, | 120 int* scroller_size, |
| 119 bool* scroller_size_updated); | 121 bool* scroller_size_updated); |
| 120 void RecordScrollRelatedMetrics(const WebGestureDevice); | 122 void RecordScrollRelatedMetrics(const WebGestureDevice); |
| 121 | 123 |
| 122 // NOTE: If adding a new field to this class please ensure that it is | 124 // NOTE: If adding a new field to this class please ensure that it is |
| 123 // cleared in |ScrollManager::clear()|. | 125 // cleared in |ScrollManager::clear()|. |
| (...skipping 24 matching lines...) Expand all Loading... |
| 148 | 150 |
| 149 Member<PaintLayerScrollableArea> resize_scrollable_area_; | 151 Member<PaintLayerScrollableArea> resize_scrollable_area_; |
| 150 | 152 |
| 151 LayoutSize | 153 LayoutSize |
| 152 offset_from_resize_corner_; // In the coords of m_resizeScrollableArea. | 154 offset_from_resize_corner_; // In the coords of m_resizeScrollableArea. |
| 153 }; | 155 }; |
| 154 | 156 |
| 155 } // namespace blink | 157 } // namespace blink |
| 156 | 158 |
| 157 #endif // ScrollManager_h | 159 #endif // ScrollManager_h |
| OLD | NEW |