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

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

Issue 2727093002: Account for perspective and preserve-3d in mapToVisualRectInAncestorSpace (Closed)
Patch Set: none Created 3 years, 9 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
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 874 matching lines...) Expand 10 before | Expand all | Expand 10 after
885 EBreakBetween previousBreakAfterValue) const; 885 EBreakBetween previousBreakAfterValue) const;
886 886
887 // Return true if we should insert a break in front of this box. The box needs 887 // Return true if we should insert a break in front of this box. The box needs
888 // to start at a valid class A break point in order to allow a forced break. 888 // to start at a valid class A break point in order to allow a forced break.
889 // To determine whether or not to break, we also need to know the break-after 889 // To determine whether or not to break, we also need to know the break-after
890 // value of the previous in-flow sibling. 890 // value of the previous in-flow sibling.
891 bool needsForcedBreakBefore(EBreakBetween previousBreakAfterValue) const; 891 bool needsForcedBreakBefore(EBreakBetween previousBreakAfterValue) const;
892 892
893 bool paintedOutputOfObjectHasNoEffectRegardlessOfSize() const override; 893 bool paintedOutputOfObjectHasNoEffectRegardlessOfSize() const override;
894 LayoutRect localVisualRect() const override; 894 LayoutRect localVisualRect() const override;
895 bool mapToVisualRectInAncestorSpace( 895 bool mapToVisualRectInAncestorSpaceInternal(
896 const LayoutBoxModelObject* ancestor, 896 const LayoutBoxModelObject* ancestor,
897 LayoutRect&, 897 TransformState&,
898 VisualRectFlags = DefaultVisualRectFlags) const override; 898 VisualRectFlags = DefaultVisualRectFlags) const override;
899 899
900 LayoutUnit containingBlockLogicalHeightForGetComputedStyle() const; 900 LayoutUnit containingBlockLogicalHeightForGetComputedStyle() const;
901 901
902 LayoutUnit containingBlockLogicalWidthForContent() const override; 902 LayoutUnit containingBlockLogicalWidthForContent() const override;
903 LayoutUnit containingBlockLogicalHeightForContent( 903 LayoutUnit containingBlockLogicalHeightForContent(
904 AvailableLogicalHeightType) const; 904 AvailableLogicalHeightType) const;
905 905
906 LayoutUnit containingBlockAvailableLineWidth() const; 906 LayoutUnit containingBlockAvailableLineWidth() const;
907 LayoutUnit perpendicularContainingBlockLogicalHeight() const; 907 LayoutUnit perpendicularContainingBlockLogicalHeight() const;
(...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after
1228 bool hasVisualOverflow() const { 1228 bool hasVisualOverflow() const {
1229 return m_overflow && !borderBoxRect().contains(visualOverflowRect()); 1229 return m_overflow && !borderBoxRect().contains(visualOverflowRect());
1230 } 1230 }
1231 1231
1232 virtual bool needsPreferredWidthsRecalculation() const; 1232 virtual bool needsPreferredWidthsRecalculation() const;
1233 1233
1234 // See README.md for an explanation of scroll origin. 1234 // See README.md for an explanation of scroll origin.
1235 virtual IntSize originAdjustmentForScrollbars() const; 1235 virtual IntSize originAdjustmentForScrollbars() const;
1236 IntSize scrolledContentOffset() const; 1236 IntSize scrolledContentOffset() const;
1237 1237
1238 // Maps a rect in scrolling contents space to box space and apply overflow 1238 // Maps from scrolling contents space to box space and apply overflow
1239 // clip if needed. Returns true if no clipping applied or the rect actually 1239 // clip if needed. Returns true if no clipping applied or the flattened quad
1240 // intersects the clipping region. If edgeInclusive is true, then this method 1240 // bounds actually intersects the clipping region. If edgeInclusive is true,
1241 // may return true even if the resulting rect has zero area. 1241 // then this method may return true even if the resulting rect has zero area.
1242 //
1243 // When applying offsets and not clips, the TransformAccumulation is
1244 // respected. If there is a clip, the TransformState is flattened first.
1242 bool mapScrollingContentsRectToBoxSpace( 1245 bool mapScrollingContentsRectToBoxSpace(
1243 LayoutRect&, 1246 TransformState&,
1247 TransformState::TransformAccumulation,
1244 VisualRectFlags = DefaultVisualRectFlags) const; 1248 VisualRectFlags = DefaultVisualRectFlags) const;
1245 1249
1246 virtual bool hasRelativeLogicalWidth() const; 1250 virtual bool hasRelativeLogicalWidth() const;
1247 virtual bool hasRelativeLogicalHeight() const; 1251 virtual bool hasRelativeLogicalHeight() const;
1248 1252
1249 bool hasHorizontalLayoutOverflow() const { 1253 bool hasHorizontalLayoutOverflow() const {
1250 if (!m_overflow) 1254 if (!m_overflow)
1251 return false; 1255 return false;
1252 1256
1253 LayoutRect layoutOverflowRect = m_overflow->layoutOverflowRect(); 1257 LayoutRect layoutOverflowRect = m_overflow->layoutOverflowRect();
(...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after
1561 1565
1562 void locationChanged(); 1566 void locationChanged();
1563 void sizeChanged(); 1567 void sizeChanged();
1564 1568
1565 virtual bool isInSelfHitTestingPhase(HitTestAction hitTestAction) const { 1569 virtual bool isInSelfHitTestingPhase(HitTestAction hitTestAction) const {
1566 return hitTestAction == HitTestForeground; 1570 return hitTestAction == HitTestForeground;
1567 } 1571 }
1568 1572
1569 void updateBackgroundAttachmentFixedStatusAfterStyleChange(); 1573 void updateBackgroundAttachmentFixedStatusAfterStyleChange();
1570 1574
1571 void inflateVisualRectForFilter(LayoutRect&) const; 1575 void inflateVisualRectForFilter(TransformState&) const;
1572 void inflateVisualRectForFilterUnderContainer( 1576 void inflateVisualRectForFilterUnderContainer(
1573 LayoutRect&, 1577 TransformState&,
1574 const LayoutObject& container, 1578 const LayoutObject& container,
1575 const LayoutBoxModelObject* ancestorToStopAt) const; 1579 const LayoutBoxModelObject* ancestorToStopAt) const;
1576 1580
1577 LayoutRectOutsets m_marginBoxOutsets; 1581 LayoutRectOutsets m_marginBoxOutsets;
1578 1582
1579 void addSnapArea(const LayoutBox&); 1583 void addSnapArea(const LayoutBox&);
1580 void removeSnapArea(const LayoutBox&); 1584 void removeSnapArea(const LayoutBox&);
1581 1585
1582 LayoutRect debugRect() const override; 1586 LayoutRect debugRect() const override;
1583 1587
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
1698 breakValue == EBreakBetween::kLeft || 1702 breakValue == EBreakBetween::kLeft ||
1699 breakValue == EBreakBetween::kPage || 1703 breakValue == EBreakBetween::kPage ||
1700 breakValue == EBreakBetween::kRecto || 1704 breakValue == EBreakBetween::kRecto ||
1701 breakValue == EBreakBetween::kRight || 1705 breakValue == EBreakBetween::kRight ||
1702 breakValue == EBreakBetween::kVerso; 1706 breakValue == EBreakBetween::kVerso;
1703 } 1707 }
1704 1708
1705 } // namespace blink 1709 } // namespace blink
1706 1710
1707 #endif // LayoutBox_h 1711 #endif // LayoutBox_h
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/TestExpectations ('k') | third_party/WebKit/Source/core/layout/LayoutBox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698