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

Side by Side Diff: sky/engine/platform/scroll/ScrollableArea.h

Issue 770223002: Remove lots of code from the WebWidget/WebView/WebFrame layer. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 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 /* 1 /*
2 * Copyright (C) 2008, 2011 Apple Inc. All Rights Reserved. 2 * Copyright (C) 2008, 2011 Apple Inc. All Rights Reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 // Functions for controlling if you can scroll past the end of the document. 76 // Functions for controlling if you can scroll past the end of the document.
77 bool constrainsScrollingToContentEdge() const { return m_constrainsScrolling ToContentEdge; } 77 bool constrainsScrollingToContentEdge() const { return m_constrainsScrolling ToContentEdge; }
78 void setConstrainsScrollingToContentEdge(bool constrainsScrollingToContentEd ge) { m_constrainsScrollingToContentEdge = constrainsScrollingToContentEdge; } 78 void setConstrainsScrollingToContentEdge(bool constrainsScrollingToContentEd ge) { m_constrainsScrollingToContentEdge = constrainsScrollingToContentEdge; }
79 79
80 void setVerticalScrollElasticity(ScrollElasticity scrollElasticity) { m_vert icalScrollElasticity = scrollElasticity; } 80 void setVerticalScrollElasticity(ScrollElasticity scrollElasticity) { m_vert icalScrollElasticity = scrollElasticity; }
81 ScrollElasticity verticalScrollElasticity() const { return static_cast<Scrol lElasticity>(m_verticalScrollElasticity); } 81 ScrollElasticity verticalScrollElasticity() const { return static_cast<Scrol lElasticity>(m_verticalScrollElasticity); }
82 82
83 void setHorizontalScrollElasticity(ScrollElasticity scrollElasticity) { m_ho rizontalScrollElasticity = scrollElasticity; } 83 void setHorizontalScrollElasticity(ScrollElasticity scrollElasticity) { m_ho rizontalScrollElasticity = scrollElasticity; }
84 ScrollElasticity horizontalScrollElasticity() const { return static_cast<Scr ollElasticity>(m_horizontalScrollElasticity); } 84 ScrollElasticity horizontalScrollElasticity() const { return static_cast<Scr ollElasticity>(m_horizontalScrollElasticity); }
85 85
86 bool inLiveResize() const { return m_inLiveResize; }
eseidel 2014/12/02 08:25:05 I guess we don't resize on mobile? :) I suspect w
87 void willStartLiveResize();
88 void willEndLiveResize();
89
90 void mouseEnteredContentArea() const; 86 void mouseEnteredContentArea() const;
91 void mouseExitedContentArea() const; 87 void mouseExitedContentArea() const;
92 void mouseMovedInContentArea() const; 88 void mouseMovedInContentArea() const;
93 void mouseEnteredScrollbar(Scrollbar*) const; 89 void mouseEnteredScrollbar(Scrollbar*) const;
94 void mouseExitedScrollbar(Scrollbar*) const; 90 void mouseExitedScrollbar(Scrollbar*) const;
95 void contentAreaDidShow() const; 91 void contentAreaDidShow() const;
96 void contentAreaDidHide() const; 92 void contentAreaDidHide() const;
97 93
98 void finishCurrentScrollAnimations() const; 94 void finishCurrentScrollAnimations() const;
99 95
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
210 IntRect m_horizontalBarDamage; 206 IntRect m_horizontalBarDamage;
211 IntRect m_verticalBarDamage; 207 IntRect m_verticalBarDamage;
212 208
213 struct ScrollableAreaAnimators { 209 struct ScrollableAreaAnimators {
214 OwnPtr<ScrollAnimator> scrollAnimator; 210 OwnPtr<ScrollAnimator> scrollAnimator;
215 }; 211 };
216 212
217 mutable OwnPtr<ScrollableAreaAnimators> m_animators; 213 mutable OwnPtr<ScrollableAreaAnimators> m_animators;
218 unsigned m_constrainsScrollingToContentEdge : 1; 214 unsigned m_constrainsScrollingToContentEdge : 1;
219 215
220 unsigned m_inLiveResize : 1;
221
222 unsigned m_verticalScrollElasticity : 2; // ScrollElasticity 216 unsigned m_verticalScrollElasticity : 2; // ScrollElasticity
223 unsigned m_horizontalScrollElasticity : 2; // ScrollElasticity 217 unsigned m_horizontalScrollElasticity : 2; // ScrollElasticity
224 218
225 unsigned m_scrollbarOverlayStyle : 2; // ScrollbarOverlayStyle 219 unsigned m_scrollbarOverlayStyle : 2; // ScrollbarOverlayStyle
226 220
227 unsigned m_scrollOriginChanged : 1; 221 unsigned m_scrollOriginChanged : 1;
228 222
229 // There are 8 possible combinations of writing mode and direction. Scroll o rigin will be non-zero in the x or y axis 223 // There are 8 possible combinations of writing mode and direction. Scroll o rigin will be non-zero in the x or y axis
230 // if there is any reversed direction or writing-mode. The combinations are: 224 // if there is any reversed direction or writing-mode. The combinations are:
231 // writing-mode / direction scrollOrigin.x() set scrollOrigin.y() set 225 // writing-mode / direction scrollOrigin.x() set scrollOrigin.y() set
232 // horizontal-tb / ltr NO NO 226 // horizontal-tb / ltr NO NO
233 // horizontal-tb / rtl YES NO 227 // horizontal-tb / rtl YES NO
234 // horizontal-bt / ltr NO YES 228 // horizontal-bt / ltr NO YES
235 // horizontal-bt / rtl YES YES 229 // horizontal-bt / rtl YES YES
236 // vertical-lr / ltr NO NO 230 // vertical-lr / ltr NO NO
237 // vertical-lr / rtl NO YES 231 // vertical-lr / rtl NO YES
238 // vertical-rl / ltr YES NO 232 // vertical-rl / ltr YES NO
239 // vertical-rl / rtl YES YES 233 // vertical-rl / rtl YES YES
240 IntPoint m_scrollOrigin; 234 IntPoint m_scrollOrigin;
241 }; 235 };
242 236
243 } // namespace blink 237 } // namespace blink
244 238
245 #endif // SKY_ENGINE_PLATFORM_SCROLL_SCROLLABLEAREA_H_ 239 #endif // SKY_ENGINE_PLATFORM_SCROLL_SCROLLABLEAREA_H_
OLDNEW
« no previous file with comments | « sky/engine/platform/scroll/ScrollAnimator.h ('k') | sky/engine/platform/scroll/ScrollableArea.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698