summaryrefslogtreecommitdiffstats
path: root/extensions/browser/guest_view
diff options
context:
space:
mode:
authoravi <avi@chromium.org>2015-10-15 07:05:44 -0700
committerCommit bot <commit-bot@chromium.org>2015-10-15 14:06:42 +0000
commitf9ab5d94ceb86be61fc37b282412b181fd115b50 (patch)
treee889365b7183b6e3a7e9305d4b5e7c68c5d6bbcf /extensions/browser/guest_view
parent3c7d234ede220c9d154e760f55ce52645205b88a (diff)
downloadchromium_src-f9ab5d94ceb86be61fc37b282412b181fd115b50.zip
chromium_src-f9ab5d94ceb86be61fc37b282412b181fd115b50.tar.gz
chromium_src-f9ab5d94ceb86be61fc37b282412b181fd115b50.tar.bz2
Separate RenderViewHost from RenderWidgetHost, part 1: public interface.
This is the first part of the separation of RenderViewHost and RenderWidgetHost. The separation of the Impls is yet to come. BUG=478281 TEST=all green Review URL: https://codereview.chromium.org/1392323003 Cr-Commit-Position: refs/heads/master@{#354258}
Diffstat (limited to 'extensions/browser/guest_view')
-rw-r--r--extensions/browser/guest_view/web_view/web_view_guest.cc21
1 files changed, 15 insertions, 6 deletions
diff --git a/extensions/browser/guest_view/web_view/web_view_guest.cc b/extensions/browser/guest_view/web_view/web_view_guest.cc
index f4d1cc4..6cf3d9f 100644
--- a/extensions/browser/guest_view/web_view/web_view_guest.cc
+++ b/extensions/browser/guest_view/web_view/web_view_guest.cc
@@ -23,6 +23,7 @@
#include "content/public/browser/notification_types.h"
#include "content/public/browser/render_process_host.h"
#include "content/public/browser/render_view_host.h"
+#include "content/public/browser/render_widget_host.h"
#include "content/public/browser/render_widget_host_view.h"
#include "content/public/browser/resource_request_details.h"
#include "content/public/browser/site_instance.h"
@@ -453,11 +454,15 @@ void WebViewGuest::GuestReady() {
// interstitial page if one is showing at this time. We only want opacity
// to apply to web pages.
if (allow_transparency_) {
- web_contents()->GetRenderViewHost()->GetView()->SetBackgroundColor(
- SK_ColorTRANSPARENT);
+ web_contents()
+ ->GetRenderViewHost()
+ ->GetWidget()
+ ->GetView()
+ ->SetBackgroundColor(SK_ColorTRANSPARENT);
} else {
web_contents()
->GetRenderViewHost()
+ ->GetWidget()
->GetView()
->SetBackgroundColorToDefault();
}
@@ -1157,15 +1162,19 @@ void WebViewGuest::SetAllowTransparency(bool allow) {
return;
allow_transparency_ = allow;
- if (!web_contents()->GetRenderViewHost()->GetView())
+ if (!web_contents()->GetRenderViewHost()->GetWidget()->GetView())
return;
if (allow_transparency_) {
- web_contents()->GetRenderViewHost()->GetView()->SetBackgroundColor(
- SK_ColorTRANSPARENT);
+ web_contents()
+ ->GetRenderViewHost()
+ ->GetWidget()
+ ->GetView()
+ ->SetBackgroundColor(SK_ColorTRANSPARENT);
} else {
web_contents()
->GetRenderViewHost()
+ ->GetWidget()
->GetView()
->SetBackgroundColorToDefault();
}
@@ -1487,7 +1496,7 @@ void WebViewGuest::SetFullscreenState(bool is_fullscreen) {
}
// Since we changed fullscreen state, sending a Resize message ensures that
// renderer/ sees the change.
- web_contents()->GetRenderViewHost()->WasResized();
+ web_contents()->GetRenderViewHost()->GetWidget()->WasResized();
}
} // namespace extensions