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

Unified Diff: third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp

Issue 1928043002: Add drawImage() originClean() getSecurityOrigin() to OffscreenCanvas (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Put back CallWith=ScriptState Created 4 years, 8 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
Index: third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp
diff --git a/third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp b/third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp
index b29be4df2562f67099e7aa9968280a82a549d3fe..dd61fee9ba35032bb512b23a57b789b840b6f6f6 100644
--- a/third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp
+++ b/third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp
@@ -14,6 +14,7 @@ namespace blink {
OffscreenCanvas::OffscreenCanvas(const IntSize& size)
: m_size(size)
+ , m_originClean(true)
{
}
@@ -102,6 +103,18 @@ void OffscreenCanvas::registerRenderingContextFactory(PassOwnPtr<CanvasRendering
renderingContextFactories()[type] = std::move(renderingContextFactory);
}
+bool OffscreenCanvas::originClean() const
+{
+ // TODO(crbug.com/607575): Make Settings accessable in worker and use
+ // disableReadingFromCanvas to determine originClean value.
+ return m_originClean;
+}
+
+SecurityOrigin* OffscreenCanvas::getSecurityOrigin(ScriptState* scriptState) const
Justin Novosad 2016/04/29 04:08:54 This method is not needed
xlai (Olivia) 2016/04/29 18:57:01 Removed.
+{
+ return scriptState->getExecutionContext()->getSecurityOrigin();
+}
+
DEFINE_TRACE(OffscreenCanvas)
{
visitor->trace(m_context);

Powered by Google App Engine
This is Rietveld 408576698