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

Unified Diff: third_party/WebKit/Source/core/paint/FilterPainter.cpp

Issue 1512803004: Use refs for GraphicsContext (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ScrollbarTheme
Patch Set: Created 5 years 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/core/paint/FilterPainter.cpp
diff --git a/third_party/WebKit/Source/core/paint/FilterPainter.cpp b/third_party/WebKit/Source/core/paint/FilterPainter.cpp
index cc14063934468c50812b25e92c576382a6271f38..1fd278d113a33a8c65c24f1976585af08964f752 100644
--- a/third_party/WebKit/Source/core/paint/FilterPainter.cpp
+++ b/third_party/WebKit/Source/core/paint/FilterPainter.cpp
@@ -21,7 +21,7 @@
namespace blink {
-FilterPainter::FilterPainter(PaintLayer& layer, GraphicsContext* context, const LayoutPoint& offsetFromRoot, const ClipRect& clipRect, PaintLayerPaintingInfo& paintingInfo, PaintLayerFlags paintFlags,
+FilterPainter::FilterPainter(PaintLayer& layer, GraphicsContext& context, const LayoutPoint& offsetFromRoot, const ClipRect& clipRect, PaintLayerPaintingInfo& paintingInfo, PaintLayerFlags paintFlags,
LayoutRect& rootRelativeBounds, bool& rootRelativeBoundsComputed)
: m_filterInProgress(false)
, m_context(context)
@@ -56,11 +56,11 @@ FilterPainter::FilterPainter(PaintLayer& layer, GraphicsContext* context, const
paintingInfo.clipToDirtyRect = false;
if (clipRect.rect() != paintingInfo.paintDirtyRect || clipRect.hasRadius()) {
- m_clipRecorder = adoptPtr(new LayerClipRecorder(*context, *layer.layoutObject(), DisplayItem::ClipLayerFilter, clipRect, &paintingInfo, LayoutPoint(), paintFlags));
+ m_clipRecorder = adoptPtr(new LayerClipRecorder(context, *layer.layoutObject(), DisplayItem::ClipLayerFilter, clipRect, &paintingInfo, LayoutPoint(), paintFlags));
}
ASSERT(m_layoutObject);
- if (!context->paintController().displayItemConstructionIsDisabled()) {
+ if (!context.paintController().displayItemConstructionIsDisabled()) {
FilterOperations filterOperations(layer.computeFilterOperations(m_layoutObject->styleRef()));
OwnPtr<WebFilterOperations> webFilterOperations = adoptPtr(Platform::current()->compositorSupport()->createFilterOperations());
builder.buildFilterOperations(filterOperations, webFilterOperations.get());
@@ -70,7 +70,7 @@ FilterPainter::FilterPainter(PaintLayer& layer, GraphicsContext* context, const
// the layer's filter. See crbug.com/502026.
if (webFilterOperations->isEmpty())
return;
- context->paintController().createAndAppend<BeginFilterDisplayItem>(*m_layoutObject, imageFilter, FloatRect(rootRelativeBounds), webFilterOperations.release());
+ context.paintController().createAndAppend<BeginFilterDisplayItem>(*m_layoutObject, imageFilter, FloatRect(rootRelativeBounds), webFilterOperations.release());
}
m_filterInProgress = true;
@@ -81,7 +81,7 @@ FilterPainter::~FilterPainter()
if (!m_filterInProgress)
return;
- m_context->paintController().endItem<EndFilterDisplayItem>(*m_layoutObject);
+ m_context.paintController().endItem<EndFilterDisplayItem>(*m_layoutObject);
}
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/core/paint/FilterPainter.h ('k') | third_party/WebKit/Source/core/paint/FramePainter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698