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

Unified Diff: content/renderer/manifest/manifest_manager.cc

Issue 930223003: Do not reset ManifestManager state for same page navigation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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
« no previous file with comments | « content/browser/manifest/manifest_browsertest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/manifest/manifest_manager.cc
diff --git a/content/renderer/manifest/manifest_manager.cc b/content/renderer/manifest/manifest_manager.cc
index a5ee94cf6b59c4d7829d5373c93b434b7f677dcc..98e976e2c2c1117d44f8f494bc74dd97338f89cf 100644
--- a/content/renderer/manifest/manifest_manager.cc
+++ b/content/renderer/manifest/manifest_manager.cc
@@ -7,6 +7,8 @@
#include "base/bind.h"
#include "base/strings/nullable_string16.h"
#include "content/common/manifest_manager_messages.h"
+#include "content/public/renderer/document_state.h"
+#include "content/public/renderer/navigation_state.h"
#include "content/public/renderer/render_frame.h"
#include "content/renderer/fetchers/manifest_fetcher.h"
#include "content/renderer/manifest/manifest_parser.h"
@@ -102,6 +104,11 @@ void ManifestManager::DidChangeManifest() {
}
void ManifestManager::DidCommitProvisionalLoad(bool is_new_navigation) {
+ NavigationState* navigation_state = DocumentState::FromDataSource(
+ render_frame()->GetWebFrame()->dataSource())->navigation_state();
+ if (navigation_state->was_within_same_page())
+ return;
+
may_have_manifest_ = false;
manifest_dirty_ = true;
}
« no previous file with comments | « content/browser/manifest/manifest_browsertest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698