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

Unified Diff: Source/web/PageWidgetDelegate.cpp

Issue 1160863004: Make sure the TransformRecorder is finished before replaying the SKPicture. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/PageWidgetDelegate.cpp
diff --git a/Source/web/PageWidgetDelegate.cpp b/Source/web/PageWidgetDelegate.cpp
index f658284918bccb05054001b0005d335c20724703..73b2f7de150ee05e7245ecc6570677edaf83da6d 100644
--- a/Source/web/PageWidgetDelegate.cpp
+++ b/Source/web/PageWidgetDelegate.cpp
@@ -83,20 +83,23 @@ void PageWidgetDelegate::paint(Page& page, PageOverlayList* overlays, WebCanvas*
AffineTransform scale;
scale.scale(scaleFactor);
- TransformRecorder scaleRecorder(*context, root, scale);
-
- IntRect dirtyRect(rect);
- FrameView* view = root.view();
- if (view) {
- ClipRecorder clipRecorder(*context, root, DisplayItem::PageWidgetDelegateClip, LayoutRect(dirtyRect));
-
- view->paint(context, dirtyRect);
- if (overlays)
- overlays->paintWebFrame(*context);
- } else {
- DrawingRecorder drawingRecorder(*context, root, DisplayItem::PageWidgetDelegateBackgroundFallback, dirtyRect);
- if (!drawingRecorder.canUseCachedDrawing())
- context->fillRect(dirtyRect, Color::white);
+
+ {
+ TransformRecorder scaleRecorder(*context, root, scale);
+
+ IntRect dirtyRect(rect);
+ FrameView* view = root.view();
+ if (view) {
+ ClipRecorder clipRecorder(*context, root, DisplayItem::PageWidgetDelegateClip, LayoutRect(dirtyRect));
+
+ view->paint(context, dirtyRect);
+ if (overlays)
+ overlays->paintWebFrame(*context);
+ } else {
+ DrawingRecorder drawingRecorder(*context, root, DisplayItem::PageWidgetDelegateBackgroundFallback, dirtyRect);
+ if (!drawingRecorder.canUseCachedDrawing())
+ context->fillRect(dirtyRect, Color::white);
+ }
}
builder.endRecording()->playback(canvas);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698