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

Unified Diff: third_party/WebKit/Source/core/exported/SharedWorkerRepositoryClientImpl.cpp

Issue 2881073003: Support DataSaver for SharedWorker (Closed)
Patch Set: fix #include "public/web/WebDataSaverFlag.h" Created 3 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
Index: third_party/WebKit/Source/core/exported/SharedWorkerRepositoryClientImpl.cpp
diff --git a/third_party/WebKit/Source/core/exported/SharedWorkerRepositoryClientImpl.cpp b/third_party/WebKit/Source/core/exported/SharedWorkerRepositoryClientImpl.cpp
index 08fbfb0eed1184b66d46ff884ac5818b0fe88954..f46b8c8675fbdab8231bee9a75e8fbf7225e5cff 100644
--- a/third_party/WebKit/Source/core/exported/SharedWorkerRepositoryClientImpl.cpp
+++ b/third_party/WebKit/Source/core/exported/SharedWorkerRepositoryClientImpl.cpp
@@ -34,6 +34,7 @@
#include <utility>
#include "core/dom/ExecutionContext.h"
#include "core/events/Event.h"
+#include "core/frame/Settings.h"
#include "core/frame/UseCounter.h"
#include "core/frame/csp/ContentSecurityPolicy.h"
#include "core/probe/CoreProbes.h"
@@ -144,7 +145,8 @@ void SharedWorkerRepositoryClientImpl::Connect(
worker->GetExecutionContext()->GetSecurityContext().AddressSpace(),
is_secure_context ? kWebSharedWorkerCreationContextTypeSecure
: kWebSharedWorkerCreationContextTypeNonsecure,
- std::move(port), std::move(listener));
+ document->GetFrame()->GetSettings()->GetDataSaverFlag(), std::move(port),
+ std::move(listener));
}
void SharedWorkerRepositoryClientImpl::DocumentDetached(Document* document) {

Powered by Google App Engine
This is Rietveld 408576698