| Index: third_party/WebKit/Source/platform/graphics/paint/DrawingRecorder.cpp
|
| diff --git a/third_party/WebKit/Source/platform/graphics/paint/DrawingRecorder.cpp b/third_party/WebKit/Source/platform/graphics/paint/DrawingRecorder.cpp
|
| index cfefdacefc0950070abc3fb773d5ca288e2dd016..a2bac310469265a3c8d0617fc4ddee06ddc1bb6d 100644
|
| --- a/third_party/WebKit/Source/platform/graphics/paint/DrawingRecorder.cpp
|
| +++ b/third_party/WebKit/Source/platform/graphics/paint/DrawingRecorder.cpp
|
| @@ -51,8 +51,8 @@ DrawingRecorder::DrawingRecorder(GraphicsContext& context,
|
| // bounds of the object during painting. Potentially expanding the cull rect
|
| // by a pixel or two also does not affect correctness, and is very unlikely to
|
| // matter for performance.
|
| - IntRect cull_rect = EnclosingIntRect(float_cull_rect);
|
| - context.BeginRecording(cull_rect);
|
| + recording_bounds_ = EnclosingIntRect(float_cull_rect);
|
| + context.BeginRecording(recording_bounds_);
|
|
|
| #if DCHECK_IS_ON()
|
| if (RuntimeEnabledFeatures::slimmingPaintStrictCullRectClippingEnabled()) {
|
| @@ -66,8 +66,9 @@ DrawingRecorder::DrawingRecorder(GraphicsContext& context,
|
| // TODO(schenney) This is not the best place to do this. Ideally, we would
|
| // expand by one pixel in device (pixel) space, but to do that we would need
|
| // to add the verification mode to Skia.
|
| - cull_rect.Inflate(1);
|
| - context.ClipRect(cull_rect, kNotAntiAliased, SkClipOp::kIntersect);
|
| + IntRect clip_rect = recording_bounds_;
|
| + clip_rect.Inflate(1);
|
| + context.ClipRect(clip_rect, kNotAntiAliased, SkClipOp::kIntersect);
|
| }
|
| #endif
|
| }
|
| @@ -99,7 +100,8 @@ DrawingRecorder::~DrawingRecorder() {
|
| #endif
|
|
|
| context_.GetPaintController().CreateAndAppend<DrawingDisplayItem>(
|
| - display_item_client_, display_item_type_, picture, known_to_be_opaque_);
|
| + display_item_client_, display_item_type_, picture, recording_bounds_,
|
| + known_to_be_opaque_);
|
| }
|
|
|
| } // namespace blink
|
|
|