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

Side by Side Diff: Source/core/rendering/RenderBox.h

Issue 792513004: Implement CSSOM smooth scroll for Elements (Closed) Base URL: svn://svn.chromium.org/blink/trunk
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 | Annotate | Revision Log
« no previous file with comments | « Source/core/page/PageAnimator.cpp ('k') | Source/core/rendering/RenderBox.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 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved. 4 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
11 * This library is distributed in the hope that it will be useful, 11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Library General Public License for more details. 14 * Library General Public License for more details.
15 * 15 *
16 * You should have received a copy of the GNU Library General Public License 16 * You should have received a copy of the GNU Library General Public License
17 * along with this library; see the file COPYING.LIB. If not, write to 17 * along with this library; see the file COPYING.LIB. If not, write to
18 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 18 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
19 * Boston, MA 02110-1301, USA. 19 * Boston, MA 02110-1301, USA.
20 * 20 *
21 */ 21 */
22 22
23 #ifndef RenderBox_h 23 #ifndef RenderBox_h
24 #define RenderBox_h 24 #define RenderBox_h
25 25
26 #include "core/rendering/RenderBoxModelObject.h" 26 #include "core/rendering/RenderBoxModelObject.h"
27 #include "core/rendering/RenderOverflow.h" 27 #include "core/rendering/RenderOverflow.h"
28 #include "core/rendering/shapes/ShapeOutsideInfo.h" 28 #include "core/rendering/shapes/ShapeOutsideInfo.h"
29 #include "platform/scroll/ScrollTypes.h" 29 #include "platform/scroll/ScrollTypes.h"
30 #include "platform/scroll/ScrollableArea.h"
30 31
31 namespace blink { 32 namespace blink {
32 33
33 struct PaintInfo; 34 struct PaintInfo;
34 35
35 enum SizeType { MainOrPreferredSize, MinSize, MaxSize }; 36 enum SizeType { MainOrPreferredSize, MinSize, MaxSize };
36 enum AvailableLogicalHeightType { ExcludeMarginBorderPadding, IncludeMarginBorde rPadding }; 37 enum AvailableLogicalHeightType { ExcludeMarginBorderPadding, IncludeMarginBorde rPadding };
37 enum OverlayScrollbarSizeRelevancy { IgnoreOverlayScrollbarSize, IncludeOverlayS crollbarSize }; 38 enum OverlayScrollbarSizeRelevancy { IgnoreOverlayScrollbarSize, IncludeOverlayS crollbarSize };
38 enum MarginDirection { BlockDirection, InlineDirection }; 39 enum MarginDirection { BlockDirection, InlineDirection };
39 40
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 // scrolling). 258 // scrolling).
258 virtual LayoutUnit scrollLeft() const; 259 virtual LayoutUnit scrollLeft() const;
259 virtual LayoutUnit scrollTop() const; 260 virtual LayoutUnit scrollTop() const;
260 virtual LayoutUnit scrollWidth() const; 261 virtual LayoutUnit scrollWidth() const;
261 virtual LayoutUnit scrollHeight() const; 262 virtual LayoutUnit scrollHeight() const;
262 int pixelSnappedScrollWidth() const; 263 int pixelSnappedScrollWidth() const;
263 int pixelSnappedScrollHeight() const; 264 int pixelSnappedScrollHeight() const;
264 virtual void setScrollLeft(LayoutUnit); 265 virtual void setScrollLeft(LayoutUnit);
265 virtual void setScrollTop(LayoutUnit); 266 virtual void setScrollTop(LayoutUnit);
266 267
267 void scrollToOffset(const DoubleSize&); 268 void scrollToOffset(const DoubleSize&, ScrollBehavior = ScrollBehaviorInstan t);
268 void scrollByRecursively(const DoubleSize& delta, ScrollOffsetClamping = Scr ollOffsetUnclamped); 269 void scrollByRecursively(const DoubleSize& delta, ScrollOffsetClamping = Scr ollOffsetUnclamped);
269 void scrollRectToVisible(const LayoutRect&, const ScrollAlignment& alignX, c onst ScrollAlignment& alignY); 270 void scrollRectToVisible(const LayoutRect&, const ScrollAlignment& alignX, c onst ScrollAlignment& alignY);
270 271
271 virtual LayoutBoxExtent marginBox() const override { return m_marginBox; } 272 virtual LayoutBoxExtent marginBox() const override { return m_marginBox; }
272 virtual LayoutUnit marginTop() const override { return m_marginBox.top(); } 273 virtual LayoutUnit marginTop() const override { return m_marginBox.top(); }
273 virtual LayoutUnit marginBottom() const override { return m_marginBox.bottom (); } 274 virtual LayoutUnit marginBottom() const override { return m_marginBox.bottom (); }
274 virtual LayoutUnit marginLeft() const override { return m_marginBox.left(); } 275 virtual LayoutUnit marginLeft() const override { return m_marginBox.left(); }
275 virtual LayoutUnit marginRight() const override { return m_marginBox.right() ; } 276 virtual LayoutUnit marginRight() const override { return m_marginBox.right() ; }
276 void setMarginTop(LayoutUnit margin) { m_marginBox.setTop(margin); } 277 void setMarginTop(LayoutUnit margin) { m_marginBox.setTop(margin); }
277 void setMarginBottom(LayoutUnit margin) { m_marginBox.setBottom(margin); } 278 void setMarginBottom(LayoutUnit margin) { m_marginBox.setBottom(margin); }
(...skipping 560 matching lines...) Expand 10 before | Expand all | Expand 10 after
838 if (UNLIKELY(inlineBoxWrapper() != 0)) 839 if (UNLIKELY(inlineBoxWrapper() != 0))
839 deleteLineBoxWrapper(); 840 deleteLineBoxWrapper();
840 } 841 }
841 842
842 ensureRareData().m_inlineBoxWrapper = boxWrapper; 843 ensureRareData().m_inlineBoxWrapper = boxWrapper;
843 } 844 }
844 845
845 } // namespace blink 846 } // namespace blink
846 847
847 #endif // RenderBox_h 848 #endif // RenderBox_h
OLDNEW
« no previous file with comments | « Source/core/page/PageAnimator.cpp ('k') | Source/core/rendering/RenderBox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698