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

Side by Side Diff: Source/core/layout/compositing/CompositingInputsUpdater.cpp

Issue 1303413004: Convert some call sites to use explicit LayoutRect->FloatRect conversion. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/layout/LayoutPart.cpp ('k') | Source/core/layout/line/AbstractInlineTextBox.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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "config.h" 5 #include "config.h"
6 #include "core/layout/compositing/CompositingInputsUpdater.h" 6 #include "core/layout/compositing/CompositingInputsUpdater.h"
7 7
8 #include "core/layout/LayoutBlock.h" 8 #include "core/layout/LayoutBlock.h"
9 #include "core/layout/compositing/CompositedDeprecatedPaintLayerMapping.h" 9 #include "core/layout/compositing/CompositedDeprecatedPaintLayerMapping.h"
10 #include "core/layout/compositing/DeprecatedPaintLayerCompositor.h" 10 #include "core/layout/compositing/DeprecatedPaintLayerCompositor.h"
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 if (layer->needsCompositingInputsUpdate()) { 106 if (layer->needsCompositingInputsUpdate()) {
107 if (info.enclosingCompositedLayer) 107 if (info.enclosingCompositedLayer)
108 info.enclosingCompositedLayer->compositedDeprecatedPaintLayerMapping ()->setNeedsGraphicsLayerUpdate(GraphicsLayerUpdateSubtree); 108 info.enclosingCompositedLayer->compositedDeprecatedPaintLayerMapping ()->setNeedsGraphicsLayerUpdate(GraphicsLayerUpdateSubtree);
109 updateType = ForceUpdate; 109 updateType = ForceUpdate;
110 } 110 }
111 111
112 if (updateType == ForceUpdate) { 112 if (updateType == ForceUpdate) {
113 DeprecatedPaintLayer::AncestorDependentCompositingInputs properties; 113 DeprecatedPaintLayer::AncestorDependentCompositingInputs properties;
114 114
115 if (!layer->isRootLayer()) { 115 if (!layer->isRootLayer()) {
116 properties.clippedAbsoluteBoundingBox = enclosingIntRect(m_geometryM ap.absoluteRect(layer->boundingBoxForCompositingOverlapTest())); 116 properties.clippedAbsoluteBoundingBox = enclosingIntRect(m_geometryM ap.absoluteRect(FloatRect(layer->boundingBoxForCompositingOverlapTest())));
117 // FIXME: Setting the absBounds to 1x1 instead of 0x0 makes very lit tle sense, 117 // FIXME: Setting the absBounds to 1x1 instead of 0x0 makes very lit tle sense,
118 // but removing this code will make JSGameBench sad. 118 // but removing this code will make JSGameBench sad.
119 // See https://codereview.chromium.org/13912020/ 119 // See https://codereview.chromium.org/13912020/
120 if (properties.clippedAbsoluteBoundingBox.isEmpty()) 120 if (properties.clippedAbsoluteBoundingBox.isEmpty())
121 properties.clippedAbsoluteBoundingBox.setSize(IntSize(1, 1)); 121 properties.clippedAbsoluteBoundingBox.setSize(IntSize(1, 1));
122 122
123 IntRect clipRect = pixelSnappedIntRect(layer->clipper().backgroundCl ipRect(ClipRectsContext(m_rootLayer, AbsoluteClipRects)).rect()); 123 IntRect clipRect = pixelSnappedIntRect(layer->clipper().backgroundCl ipRect(ClipRectsContext(m_rootLayer, AbsoluteClipRects)).rect());
124 properties.clippedAbsoluteBoundingBox.intersect(clipRect); 124 properties.clippedAbsoluteBoundingBox.intersect(clipRect);
125 125
126 const DeprecatedPaintLayer* parent = layer->parent(); 126 const DeprecatedPaintLayer* parent = layer->parent();
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 ASSERT(!layer->childNeedsCompositingInputsUpdate()); 194 ASSERT(!layer->childNeedsCompositingInputsUpdate());
195 ASSERT(!layer->needsCompositingInputsUpdate()); 195 ASSERT(!layer->needsCompositingInputsUpdate());
196 196
197 for (DeprecatedPaintLayer* child = layer->firstChild(); child; child = child ->nextSibling()) 197 for (DeprecatedPaintLayer* child = layer->firstChild(); child; child = child ->nextSibling())
198 assertNeedsCompositingInputsUpdateBitsCleared(child); 198 assertNeedsCompositingInputsUpdateBitsCleared(child);
199 } 199 }
200 200
201 #endif 201 #endif
202 202
203 } // namespace blink 203 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/layout/LayoutPart.cpp ('k') | Source/core/layout/line/AbstractInlineTextBox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698