| Index: content/browser/frame_host/render_widget_host_view_guest.cc
|
| diff --git a/content/browser/frame_host/render_widget_host_view_guest.cc b/content/browser/frame_host/render_widget_host_view_guest.cc
|
| index 6d4a1811c5bc9eae2ed516d37e990a25d42bc905..9cfa1da40c79598635b30373a61b38eb7e9d0fe0 100644
|
| --- a/content/browser/frame_host/render_widget_host_view_guest.cc
|
| +++ b/content/browser/frame_host/render_widget_host_view_guest.cc
|
| @@ -23,10 +23,10 @@
|
| #include "content/common/browser_plugin/browser_plugin_messages.h"
|
| #include "content/common/frame_messages.h"
|
| #include "content/common/gpu/gpu_messages.h"
|
| -#include "content/common/input/web_touch_event_traits.h"
|
| #include "content/common/view_messages.h"
|
| #include "content/common/webplugin_geometry.h"
|
| #include "content/public/common/content_switches.h"
|
| +#include "content/public/common/input/web_touch_event_traits.h"
|
| #include "skia/ext/platform_canvas.h"
|
| #include "third_party/WebKit/public/platform/WebScreenInfo.h"
|
|
|
| @@ -134,7 +134,7 @@ void RenderWidgetHostViewGuest::Focus() {
|
| // InterstitialPages are not WebContents, and so BrowserPluginGuest does not
|
| // have direct access to the interstitial page's RenderWidgetHost.
|
| if (guest_)
|
| - guest_->SetFocus(host_, true, blink::WebFocusTypeNone);
|
| + guest_->SetFocusForRenderWidgetHost(host_, true, blink::WebFocusTypeNone);
|
| }
|
|
|
| bool RenderWidgetHostViewGuest::HasFocus() const {
|
| @@ -218,7 +218,11 @@ void RenderWidgetHostViewGuest::Destroy() {
|
| }
|
|
|
| gfx::Size RenderWidgetHostViewGuest::GetPhysicalBackingSize() const {
|
| - return RenderWidgetHostViewBase::GetPhysicalBackingSize();
|
| + blink::WebScreenInfo screen_info;
|
| + RenderWidgetHostViewBase* embedder_view = GetOwnerRenderWidgetHostView();
|
| + if (embedder_view)
|
| + embedder_view->GetScreenInfo(&screen_info);
|
| + return gfx::ScaleToCeiledSize(size_, screen_info.deviceScaleFactor);
|
| }
|
|
|
| base::string16 RenderWidgetHostViewGuest::GetSelectedText() const {
|
| @@ -254,7 +258,6 @@ void RenderWidgetHostViewGuest::OnSwapCompositorFrame(
|
|
|
| gfx::Size frame_size = root_pass->output_rect.size();
|
| float scale_factor = frame->metadata.device_scale_factor;
|
| -
|
| // Check whether we need to recreate the cc::Surface, which means the child
|
| // frame renderer has changed its output surface, or size, or scale factor.
|
| if (output_surface_id != last_output_surface_id_ && surface_factory_) {
|
|
|