diff options
author | willchan@chromium.org <willchan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-11 21:51:59 +0000 |
---|---|---|
committer | willchan@chromium.org <willchan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-11 21:51:59 +0000 |
commit | b6ca264f3c8d6b010e92774f1ef508dc3c39604e (patch) | |
tree | d2773fdb355529a9b22cc27f792067effad263a6 | |
parent | bad21d6733c440e2143ba2f9afde61471535c86d (diff) | |
download | chromium_src-b6ca264f3c8d6b010e92774f1ef508dc3c39604e.zip chromium_src-b6ca264f3c8d6b010e92774f1ef508dc3c39604e.tar.gz chromium_src-b6ca264f3c8d6b010e92774f1ef508dc3c39604e.tar.bz2 |
Only show the original RWHV or the interstitial page at any time.
In Windows this doesn't matter, since the interstitial page just renders on top of the original RWHV.
In Linux, the two RWHV widgets are in the same content view vbox, so we need to hide one of them so they both don't render on the screen.
BUG=http://www.crbug.com/8486
Review URL: http://codereview.chromium.org/112014
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15792 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/browser/renderer_host/render_widget_host_view_gtk.cc | 4 | ||||
-rw-r--r-- | chrome/browser/tab_contents/interstitial_page.cc | 6 |
2 files changed, 8 insertions, 2 deletions
diff --git a/chrome/browser/renderer_host/render_widget_host_view_gtk.cc b/chrome/browser/renderer_host/render_widget_host_view_gtk.cc index c0e08e7..d2e3a19 100644 --- a/chrome/browser/renderer_host/render_widget_host_view_gtk.cc +++ b/chrome/browser/renderer_host/render_widget_host_view_gtk.cc @@ -242,11 +242,11 @@ bool RenderWidgetHostViewGtk::HasFocus() { } void RenderWidgetHostViewGtk::Show() { - NOTIMPLEMENTED(); + gtk_widget_show(view_.get()); } void RenderWidgetHostViewGtk::Hide() { - NOTIMPLEMENTED(); + gtk_widget_hide(view_.get()); } gfx::Rect RenderWidgetHostViewGtk::GetViewBounds() const { diff --git a/chrome/browser/tab_contents/interstitial_page.cc b/chrome/browser/tab_contents/interstitial_page.cc index 3c3226b..0dbe26a 100644 --- a/chrome/browser/tab_contents/interstitial_page.cc +++ b/chrome/browser/tab_contents/interstitial_page.cc @@ -200,6 +200,9 @@ void InterstitialPage::Show() { } void InterstitialPage::Hide() { + // Show the original RVH since we're going away. + tab_->render_view_host()->view()->Show(); + render_view_host_->Shutdown(); render_view_host_ = NULL; if (tab_->interstitial_page()) @@ -383,6 +386,9 @@ void InterstitialPage::DidNavigate( if (tab_->render_view_host()->view()->HasFocus()) Focus(); + // Hide the original RVH since we're showing the interstitial instead. + tab_->render_view_host()->view()->Hide(); + // Notify the tab we are not loading so the throbber is stopped. It also // causes a NOTIFY_LOAD_STOP notification, that the AutomationProvider (used // by the UI tests) expects to consider a navigation as complete. Without |