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

Unified Diff: content/browser/frame_host/navigation_handle_impl.h

Issue 1294243004: PlzNavigate: Make ServiceWorker work with PlzNavigate. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Missed a spot. Created 5 years, 3 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: content/browser/frame_host/navigation_handle_impl.h
diff --git a/content/browser/frame_host/navigation_handle_impl.h b/content/browser/frame_host/navigation_handle_impl.h
index edd7b5552c95227a2980da067c8b71d17ea760ca..efe3b89b59f66e2a45ab112d99b5792408d591f5 100644
--- a/content/browser/frame_host/navigation_handle_impl.h
+++ b/content/browser/frame_host/navigation_handle_impl.h
@@ -8,6 +8,7 @@
#include "content/public/browser/navigation_handle.h"
#include "base/macros.h"
+#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/scoped_vector.h"
#include "content/browser/frame_host/render_frame_host_impl.h"
@@ -18,6 +19,7 @@
namespace content {
class NavigatorDelegate;
+class ServiceWorkerContextWrapper;
struct NavigationRequestInfo;
// This class keeps track of a single navigation. It is created upon receipt of
@@ -55,9 +57,11 @@ struct NavigationRequestInfo;
// the RenderFrameHost still apply.
class CONTENT_EXPORT NavigationHandleImpl : public NavigationHandle {
public:
- static scoped_ptr<NavigationHandleImpl> Create(const GURL& url,
- bool is_main_frame,
- NavigatorDelegate* delegate);
+ static scoped_ptr<NavigationHandleImpl> Create(
+ const GURL& url,
+ bool is_main_frame,
+ NavigatorDelegate* delegate,
+ int service_worker_provider_id);
clamy 2015/10/02 10:34:44 See the comment in the previous patch set on why w
Fabrice (no longer in Chrome) 2015/10/02 16:37:34 Done.
~NavigationHandleImpl() override;
// NavigationHandle implementation:
@@ -142,8 +146,9 @@ class CONTENT_EXPORT NavigationHandleImpl : public NavigationHandle {
};
NavigationHandleImpl(const GURL& url,
- const bool is_main_frame,
- NavigatorDelegate* delegate);
+ bool is_main_frame,
+ NavigatorDelegate* delegate,
+ int service_worker_provider_id);
// See NavigationHandle for a description of those member variables.
GURL url_;
@@ -171,6 +176,14 @@ class CONTENT_EXPORT NavigationHandleImpl : public NavigationHandle {
// A list of Throttles registered for this navigation.
ScopedVector<NavigationThrottle> throttles_;
+ // PlzNavigate
+ // The ServiceWorkerProviderHost ID used for navigations.
+ // Set to kInvalidServiceWorkerProviderId for sandboxed frames and sync loads.
+ // Set to kInvalidServiceWorkerProviderId for current navigation.
clamy 2015/10/02 10:34:44 I don't understand the last comment.
Fabrice (no longer in Chrome) 2015/10/02 16:37:34 I clarified it is unused. Since it is unused, it d
+ int service_worker_provider_id_;
+
+ scoped_refptr<ServiceWorkerContextWrapper> service_worker_context_;
+
DISALLOW_COPY_AND_ASSIGN(NavigationHandleImpl);
};

Powered by Google App Engine
This is Rietveld 408576698