summaryrefslogtreecommitdiffstats
path: root/chromecast
diff options
context:
space:
mode:
authornasko <nasko@chromium.org>2015-04-30 08:53:52 -0700
committerCommit bot <commit-bot@chromium.org>2015-04-30 15:55:06 +0000
commitc0fceff6214f05360be23a5fc2ee578e9d7707aa (patch)
tree663368b71f010e549033f160959100383a636324 /chromecast
parentae400e2a1ff4ae81deef1f42d0f92cdf073d7364 (diff)
downloadchromium_src-c0fceff6214f05360be23a5fc2ee578e9d7707aa.zip
chromium_src-c0fceff6214f05360be23a5fc2ee578e9d7707aa.tar.gz
chromium_src-c0fceff6214f05360be23a5fc2ee578e9d7707aa.tar.bz2
Move ClosePage() from RenderViewHost to WebContents.
ClosePage is a page-level concept and because of the deprecation of RenderViewHost, it has to move. WebContents is the object representing page, so I'm moving this public API to it. BUG=304341, 478281 Review URL: https://codereview.chromium.org/1094153002 Cr-Commit-Position: refs/heads/master@{#327719}
Diffstat (limited to 'chromecast')
-rw-r--r--chromecast/browser/android/cast_window_android.cc2
-rw-r--r--chromecast/browser/service/cast_service_simple.cc2
2 files changed, 2 insertions, 2 deletions
diff --git a/chromecast/browser/android/cast_window_android.cc b/chromecast/browser/android/cast_window_android.cc
index 1fe64a8..7c2e354 100644
--- a/chromecast/browser/android/cast_window_android.cc
+++ b/chromecast/browser/android/cast_window_android.cc
@@ -86,7 +86,7 @@ void CastWindowAndroid::Close() {
// Close page first, which fires the window.unload event. The WebContents
// itself will be destroyed after browser-process has received renderer
// notification that the page is closed.
- web_contents_->GetRenderViewHost()->ClosePage();
+ web_contents_->ClosePage();
}
void CastWindowAndroid::Destroy() {
diff --git a/chromecast/browser/service/cast_service_simple.cc b/chromecast/browser/service/cast_service_simple.cc
index d5c1389..2a40b3e 100644
--- a/chromecast/browser/service/cast_service_simple.cc
+++ b/chromecast/browser/service/cast_service_simple.cc
@@ -75,7 +75,7 @@ void CastServiceSimple::StartInternal() {
}
void CastServiceSimple::StopInternal() {
- web_contents_->GetRenderViewHost()->ClosePage();
+ web_contents_->ClosePage();
web_contents_.reset();
window_.reset();
}