summaryrefslogtreecommitdiffstats
path: root/content/browser/frame_host
diff options
context:
space:
mode:
authorfdegans <fdegans@chromium.org>2015-03-19 05:52:22 -0700
committerCommit bot <commit-bot@chromium.org>2015-03-19 12:52:59 +0000
commit6ce28f57d686337e99099a7a97354f45d22ca2f6 (patch)
treeb55f7d3dc90dd3cd25c4de1181e714b4a6de37f1 /content/browser/frame_host
parentb0a90f4b6c81fc65dd0c57ebc00b0ba6fe784b22 (diff)
downloadchromium_src-6ce28f57d686337e99099a7a97354f45d22ca2f6.zip
chromium_src-6ce28f57d686337e99099a7a97354f45d22ca2f6.tar.gz
chromium_src-6ce28f57d686337e99099a7a97354f45d22ca2f6.tar.bz2
Remove RenderViewHost parameter from WebContentsObserver::Did{Start|Stop}Loading.
This parameter is unused in almost every class derived from WebContentsObserver. This will make refactoring the OnDid{Start|Stop}Loading IPCs from WebContentsImpl to RenderFrameHostImpl simpler. BUG=429399,450799 Review URL: https://codereview.chromium.org/1008913002 Cr-Commit-Position: refs/heads/master@{#321341}
Diffstat (limited to 'content/browser/frame_host')
-rw-r--r--content/browser/frame_host/interstitial_page_impl.cc6
-rw-r--r--content/browser/frame_host/navigation_controller_delegate.h3
-rw-r--r--content/browser/frame_host/navigation_controller_impl_browsertest.cc6
-rw-r--r--content/browser/frame_host/navigation_controller_impl_unittest.cc2
4 files changed, 6 insertions, 11 deletions
diff --git a/content/browser/frame_host/interstitial_page_impl.cc b/content/browser/frame_host/interstitial_page_impl.cc
index 197d9d4..f7ee287 100644
--- a/content/browser/frame_host/interstitial_page_impl.cc
+++ b/content/browser/frame_host/interstitial_page_impl.cc
@@ -483,8 +483,7 @@ void InterstitialPageImpl::DidNavigate(
// as complete. Without this, navigating in a UI test to a URL that triggers
// an interstitial would hang.
web_contents_was_loading_ = controller_->delegate()->IsLoading();
- controller_->delegate()->SetIsLoading(
- controller_->delegate()->GetRenderViewHost(), false, true, NULL);
+ controller_->delegate()->SetIsLoading(false, true, NULL);
}
RendererPreferences InterstitialPageImpl::GetRendererPrefs(
@@ -591,8 +590,7 @@ void InterstitialPageImpl::Proceed() {
// Resumes the throbber, if applicable.
if (web_contents_was_loading_)
- controller_->delegate()->SetIsLoading(
- controller_->delegate()->GetRenderViewHost(), true, true, NULL);
+ controller_->delegate()->SetIsLoading(true, true, NULL);
// If this is a new navigation, the old page is going away, so we cancel any
// blocked requests for it. If it is not a new navigation, then it means the
diff --git a/content/browser/frame_host/navigation_controller_delegate.h b/content/browser/frame_host/navigation_controller_delegate.h
index 90fd4d3..e578a84 100644
--- a/content/browser/frame_host/navigation_controller_delegate.h
+++ b/content/browser/frame_host/navigation_controller_delegate.h
@@ -71,8 +71,7 @@ class NavigationControllerDelegate {
virtual void AttachInterstitialPage(
InterstitialPageImpl* interstitial_page) = 0;
virtual void DetachInterstitialPage() = 0;
- virtual void SetIsLoading(RenderViewHost* render_view_host,
- bool is_loading,
+ virtual void SetIsLoading(bool is_loading,
bool to_different_document,
LoadNotificationDetails* details) = 0;
};
diff --git a/content/browser/frame_host/navigation_controller_impl_browsertest.cc b/content/browser/frame_host/navigation_controller_impl_browsertest.cc
index 66646f7..6f54e00 100644
--- a/content/browser/frame_host/navigation_controller_impl_browsertest.cc
+++ b/content/browser/frame_host/navigation_controller_impl_browsertest.cc
@@ -289,7 +289,7 @@ class FrameNavigateParamsCapturer : public WebContentsObserver {
message_loop_runner_->Quit();
}
- void DidStopLoading(RenderViewHost* render_view_host) override {
+ void DidStopLoading() override {
if (!navigations_remaining_)
message_loop_runner_->Quit();
}
@@ -359,9 +359,7 @@ class LoadCommittedCapturer : public WebContentsObserver {
message_loop_runner_->Quit();
}
- void DidStopLoading(RenderViewHost* render_view_host) override {
- message_loop_runner_->Quit();
- }
+ void DidStopLoading() override { message_loop_runner_->Quit(); }
// The id of the FrameTreeNode whose navigations to observe.
int frame_tree_node_id_;
diff --git a/content/browser/frame_host/navigation_controller_impl_unittest.cc b/content/browser/frame_host/navigation_controller_impl_unittest.cc
index 3b56740..c18ca9b 100644
--- a/content/browser/frame_host/navigation_controller_impl_unittest.cc
+++ b/content/browser/frame_host/navigation_controller_impl_unittest.cc
@@ -3078,7 +3078,7 @@ TEST_F(NavigationControllerTest, ShowBrowserURLAfterFailUntilModified) {
params.showing_repost_interstitial = false;
main_test_rfh()->OnMessageReceived(
FrameHostMsg_DidFailProvisionalLoadWithError(0, params));
- contents()->SetIsLoading(test_rvh(), false, true, NULL);
+ contents()->SetIsLoading(false, true, NULL);
EXPECT_EQ(url, controller.GetVisibleEntry()->GetURL());
// If something else later modifies the contents of the about:blank page, then