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

Unified Diff: third_party/WebKit/Source/web/LinkHighlightImpl.cpp

Issue 1452353002: Turn off computation of the interest rect in cc in synchronized paint mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month 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
Index: third_party/WebKit/Source/web/LinkHighlightImpl.cpp
diff --git a/third_party/WebKit/Source/web/LinkHighlightImpl.cpp b/third_party/WebKit/Source/web/LinkHighlightImpl.cpp
index ce39f38634e0b32f3f239b45f5852dadee362d0e..b69d3c21298f597cb93d8d0da7366cafc9636419 100644
--- a/third_party/WebKit/Source/web/LinkHighlightImpl.cpp
+++ b/third_party/WebKit/Source/web/LinkHighlightImpl.cpp
@@ -53,6 +53,7 @@
#include "third_party/skia/include/core/SkCanvas.h"
#include "third_party/skia/include/core/SkPictureRecorder.h"
#include "third_party/skia/include/utils/SkMatrix44.h"
+#include "ui/gfx/geometry/rect.h"
#include "web/WebLocalFrameImpl.h"
#include "web/WebSettingsImpl.h"
#include "web/WebViewImpl.h"
@@ -260,14 +261,14 @@ bool LinkHighlightImpl::computeHighlightLayerPathAndPosition(const LayoutBoxMode
return pathHasChanged;
}
-void LinkHighlightImpl::paintContents(WebDisplayItemList* webDisplayItemList, const WebRect& webClipRect, WebContentLayerClient::PaintingControlSetting paintingControl)
+void LinkHighlightImpl::paintContents(WebDisplayItemList* webDisplayItemList, gfx::Rect* recordingViewport, WebContentLayerClient::PaintingControlSetting paintingControl)
{
if (!m_node || !m_node->layoutObject())
return;
SkPictureRecorder recorder;
- SkCanvas* canvas = recorder.beginRecording(webClipRect.width, webClipRect.height);
- canvas->translate(-webClipRect.x, -webClipRect.y);
+ SkCanvas* canvas = recorder.beginRecording(recordingViewport->width(), recordingViewport->height());
+ canvas->translate(-recordingViewport->x(), -recordingViewport->y());
SkPaint paint;
paint.setStyle(SkPaint::kFill_Style);

Powered by Google App Engine
This is Rietveld 408576698