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

Unified Diff: content/public/test/test_navigation_observer.cc

Issue 248963004: "Go back" on the block interstitial closes the tab if there is no previous URL. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Typo fix. (Also rebase) Created 6 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
« no previous file with comments | « content/public/test/test_navigation_observer.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/test/test_navigation_observer.cc
diff --git a/content/public/test/test_navigation_observer.cc b/content/public/test/test_navigation_observer.cc
index e2c69b74369fabd0f3de5c48c48634464cd39067..cad43a8cb6348ba6ff10cac34cfbff4c3f10d6c0 100644
--- a/content/public/test/test_navigation_observer.cc
+++ b/content/public/test/test_navigation_observer.cc
@@ -30,6 +30,10 @@ class TestNavigationObserver::TestWebContentsObserver
parent_->OnNavigationEntryCommitted(this, web_contents(), load_details);
}
+ virtual void DidAttachInterstitialPage() OVERRIDE {
+ parent_->OnDidAttachInterstitialPage(web_contents());
+ }
+
virtual void WebContentsDestroyed(WebContents* web_contents) OVERRIDE {
parent_->OnWebContentsDestroyed(this, web_contents);
}
@@ -118,6 +122,13 @@ void TestNavigationObserver::OnNavigationEntryCommitted(
navigation_started_ = true;
}
+void TestNavigationObserver::OnDidAttachInterstitialPage(
+ WebContents* web_contents) {
+ // Going to an interstitial page does not trigger NavigationEntryCommitted,
+ // but has the same meaning for us here.
+ navigation_started_ = true;
+}
+
void TestNavigationObserver::OnDidStartLoading(WebContents* web_contents) {
navigation_started_ = true;
}
« no previous file with comments | « content/public/test/test_navigation_observer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698