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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutBox.h

Issue 2569013006: Changed EOverflow to an enum class and renamed its members (Closed)
Patch Set: Rebase 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 /* 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 *
(...skipping 984 matching lines...) Expand 10 before | Expand all | Expand 10 after
995 virtual ScrollResult scroll(ScrollGranularity, const FloatSize&); 995 virtual ScrollResult scroll(ScrollGranularity, const FloatSize&);
996 bool canBeScrolledAndHasScrollableArea() const; 996 bool canBeScrolledAndHasScrollableArea() const;
997 virtual bool canBeProgramaticallyScrolled() const; 997 virtual bool canBeProgramaticallyScrolled() const;
998 virtual void autoscroll(const IntPoint&); 998 virtual void autoscroll(const IntPoint&);
999 bool canAutoscroll() const; 999 bool canAutoscroll() const;
1000 IntSize calculateAutoscrollDirection(const IntPoint& pointInRootFrame) const; 1000 IntSize calculateAutoscrollDirection(const IntPoint& pointInRootFrame) const;
1001 static LayoutBox* findAutoscrollable(LayoutObject*); 1001 static LayoutBox* findAutoscrollable(LayoutObject*);
1002 virtual void stopAutoscroll() {} 1002 virtual void stopAutoscroll() {}
1003 1003
1004 DISABLE_CFI_PERF bool hasAutoVerticalScrollbar() const { 1004 DISABLE_CFI_PERF bool hasAutoVerticalScrollbar() const {
1005 return hasOverflowClip() && (style()->overflowY() == OverflowAuto || 1005 return hasOverflowClip() && (style()->overflowY() == EOverflow::Auto ||
1006 style()->overflowY() == OverflowPagedY || 1006 style()->overflowY() == EOverflow::PagedY ||
1007 style()->overflowY() == OverflowOverlay); 1007 style()->overflowY() == EOverflow::Overlay);
1008 } 1008 }
1009 DISABLE_CFI_PERF bool hasAutoHorizontalScrollbar() const { 1009 DISABLE_CFI_PERF bool hasAutoHorizontalScrollbar() const {
1010 return hasOverflowClip() && (style()->overflowX() == OverflowAuto || 1010 return hasOverflowClip() && (style()->overflowX() == EOverflow::Auto ||
1011 style()->overflowX() == OverflowOverlay); 1011 style()->overflowX() == EOverflow::Overlay);
1012 } 1012 }
1013 DISABLE_CFI_PERF bool scrollsOverflow() const { 1013 DISABLE_CFI_PERF bool scrollsOverflow() const {
1014 return scrollsOverflowX() || scrollsOverflowY(); 1014 return scrollsOverflowX() || scrollsOverflowY();
1015 } 1015 }
1016 virtual bool shouldPlaceBlockDirectionScrollbarOnLogicalLeft() const { 1016 virtual bool shouldPlaceBlockDirectionScrollbarOnLogicalLeft() const {
1017 return style()->shouldPlaceBlockDirectionScrollbarOnLogicalLeft(); 1017 return style()->shouldPlaceBlockDirectionScrollbarOnLogicalLeft();
1018 } 1018 }
1019 1019
1020 bool hasScrollableOverflowX() const { 1020 bool hasScrollableOverflowX() const {
1021 return scrollsOverflowX() && 1021 return scrollsOverflowX() &&
1022 pixelSnappedScrollWidth() != pixelSnappedClientWidth(); 1022 pixelSnappedScrollWidth() != pixelSnappedClientWidth();
1023 } 1023 }
1024 bool hasScrollableOverflowY() const { 1024 bool hasScrollableOverflowY() const {
1025 return scrollsOverflowY() && 1025 return scrollsOverflowY() &&
1026 pixelSnappedScrollHeight() != pixelSnappedClientHeight(); 1026 pixelSnappedScrollHeight() != pixelSnappedClientHeight();
1027 } 1027 }
1028 virtual bool scrollsOverflowX() const { 1028 virtual bool scrollsOverflowX() const {
1029 return hasOverflowClip() && (style()->overflowX() == OverflowScroll || 1029 return hasOverflowClip() && (style()->overflowX() == EOverflow::Scroll ||
1030 hasAutoHorizontalScrollbar()); 1030 hasAutoHorizontalScrollbar());
1031 } 1031 }
1032 virtual bool scrollsOverflowY() const { 1032 virtual bool scrollsOverflowY() const {
1033 return hasOverflowClip() && (style()->overflowY() == OverflowScroll || 1033 return hasOverflowClip() && (style()->overflowY() == EOverflow::Scroll ||
1034 hasAutoVerticalScrollbar()); 1034 hasAutoVerticalScrollbar());
1035 } 1035 }
1036 1036
1037 // Elements such as the <input> field override this to specify that they are 1037 // Elements such as the <input> field override this to specify that they are
1038 // scrollable outside the context of the CSS overflow style 1038 // scrollable outside the context of the CSS overflow style
1039 virtual bool isIntrinsicallyScrollable( 1039 virtual bool isIntrinsicallyScrollable(
1040 ScrollbarOrientation orientation) const { 1040 ScrollbarOrientation orientation) const {
1041 return false; 1041 return false;
1042 } 1042 }
1043 1043
(...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after
1623 1623
1624 inline bool LayoutBox::isForcedFragmentainerBreakValue(EBreak breakValue) { 1624 inline bool LayoutBox::isForcedFragmentainerBreakValue(EBreak breakValue) {
1625 return breakValue == BreakColumn || breakValue == BreakLeft || 1625 return breakValue == BreakColumn || breakValue == BreakLeft ||
1626 breakValue == BreakPage || breakValue == BreakRecto || 1626 breakValue == BreakPage || breakValue == BreakRecto ||
1627 breakValue == BreakRight || breakValue == BreakVerso; 1627 breakValue == BreakRight || breakValue == BreakVerso;
1628 } 1628 }
1629 1629
1630 } // namespace blink 1630 } // namespace blink
1631 1631
1632 #endif // LayoutBox_h 1632 #endif // LayoutBox_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/frame/FrameView.cpp ('k') | third_party/WebKit/Source/core/layout/LayoutBox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698