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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutFlowThread.cpp

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) 2011 Adobe Systems Incorporated. All rights reserved. 2 * Copyright (C) 2011 Adobe Systems Incorporated. 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 * 7 *
8 * 1. Redistributions of source code must retain the above 8 * 1. Redistributions of source code must retain the above
9 * copyright notice, this list of conditions and the following 9 * copyright notice, this list of conditions and the following
10 * disclaimer. 10 * disclaimer.
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 m_multiColumnSetIntervalTree.clear(); 78 m_multiColumnSetIntervalTree.clear();
79 } 79 }
80 80
81 void LayoutFlowThread::validateColumnSets() { 81 void LayoutFlowThread::validateColumnSets() {
82 m_columnSetsInvalidated = false; 82 m_columnSetsInvalidated = false;
83 // Called to get the maximum logical width for the columnSet. 83 // Called to get the maximum logical width for the columnSet.
84 updateLogicalWidth(); 84 updateLogicalWidth();
85 generateColumnSetIntervalTree(); 85 generateColumnSetIntervalTree();
86 } 86 }
87 87
88 bool LayoutFlowThread::mapToVisualRectInAncestorSpace( 88 bool LayoutFlowThread::mapToVisualRectInAncestorSpaceInternal(
89 const LayoutBoxModelObject* ancestor, 89 const LayoutBoxModelObject* ancestor,
90 LayoutRect& rect, 90 TransformState& transformState,
91 VisualRectFlags visualRectFlags) const { 91 VisualRectFlags visualRectFlags) const {
92 // A flow thread should never be an invalidation container. 92 // A flow thread should never be an invalidation container.
93 DCHECK(ancestor != this); 93 DCHECK(ancestor != this);
94 transformState.flatten();
95 LayoutRect rect(transformState.lastPlanarQuad().boundingBox());
94 rect = fragmentsBoundingBox(rect); 96 rect = fragmentsBoundingBox(rect);
95 return LayoutBlockFlow::mapToVisualRectInAncestorSpace(ancestor, rect, 97 transformState.setQuad(FloatQuad(FloatRect(rect)));
96 visualRectFlags); 98 return LayoutBlockFlow::mapToVisualRectInAncestorSpaceInternal(
99 ancestor, transformState, visualRectFlags);
97 } 100 }
98 101
99 void LayoutFlowThread::layout() { 102 void LayoutFlowThread::layout() {
100 m_pageLogicalSizeChanged = m_columnSetsInvalidated && everHadLayout(); 103 m_pageLogicalSizeChanged = m_columnSetsInvalidated && everHadLayout();
101 LayoutBlockFlow::layout(); 104 LayoutBlockFlow::layout();
102 m_pageLogicalSizeChanged = false; 105 m_pageLogicalSizeChanged = false;
103 } 106 }
104 107
105 void LayoutFlowThread::computeLogicalHeight( 108 void LayoutFlowThread::computeLogicalHeight(
106 LayoutUnit, 109 LayoutUnit,
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
229 232
230 void LayoutFlowThread::MultiColumnSetSearchAdapter::collectIfNeeded( 233 void LayoutFlowThread::MultiColumnSetSearchAdapter::collectIfNeeded(
231 const MultiColumnSetInterval& interval) { 234 const MultiColumnSetInterval& interval) {
232 if (m_result) 235 if (m_result)
233 return; 236 return;
234 if (interval.low() <= m_offset && interval.high() > m_offset) 237 if (interval.low() <= m_offset && interval.high() > m_offset)
235 m_result = interval.data(); 238 m_result = interval.data();
236 } 239 }
237 240
238 } // namespace blink 241 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutFlowThread.h ('k') | third_party/WebKit/Source/core/layout/LayoutInline.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698