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

Unified Diff: content/renderer/render_frame_impl.cc

Issue 2501343003: PlzNavigate: AppCache support. (Closed)
Patch Set: Add DCHECKs for PlzNavigate and fix a double Release problem which caused one unit_test to fail wit… Created 4 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: content/renderer/render_frame_impl.cc
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
index ec0a91c116c55a1080521c8eab573259a2a45480..b06a87d2d98fa1876fc8af3f76dfdc70713327d0 100644
--- a/content/renderer/render_frame_impl.cc
+++ b/content/renderer/render_frame_impl.cc
@@ -66,6 +66,7 @@
#include "content/common/site_isolation_policy.h"
#include "content/common/swapped_out_messages.h"
#include "content/common/view_messages.h"
+#include "content/public/common/appcache_info.h"
#include "content/public/common/associated_interface_provider.h"
#include "content/public/common/bindings_policy.h"
#include "content/public/common/browser_side_navigation_policy.h"
@@ -1122,6 +1123,7 @@ RenderFrameImpl::RenderFrameImpl(const CreateParams& params)
frame_binding_(this),
host_zoom_binding_(this),
has_accessed_initial_document_(false),
+ appcache_host_id_(kAppCacheNoHostId),
weak_factory_(this) {
// We don't have a service_manager::Connection at this point, so use empty
// identity/specs.
@@ -2868,7 +2870,8 @@ blink::WebApplicationCacheHost* RenderFrameImpl::createApplicationCacheHost(
return NULL;
return new RendererWebApplicationCacheHostImpl(
RenderViewImpl::FromWebView(frame_->view()), client,
- RenderThreadImpl::current()->appcache_dispatcher()->backend_proxy());
+ RenderThreadImpl::current()->appcache_dispatcher()->backend_proxy(),
+ appcache_host_id_);
}
blink::WebWorkerContentSettingsClientProxy*
@@ -5008,8 +5011,13 @@ void RenderFrameImpl::OnCommitNavigation(
request_params.has_user_gesture ? new blink::WebScopedUserGesture(frame_)
: nullptr);
+ appcache_host_id_ = request_params.appcache_host_id;
+
NavigateInternal(common_params, StartNavigationParams(), request_params,
std::move(stream_override));
+
+ appcache_host_id_ = kAppCacheNoHostId;
+
browser_side_navigation_pending_ = false;
}

Powered by Google App Engine
This is Rietveld 408576698