| Index: content/browser/renderer_host/render_widget_host_impl.h
|
| diff --git a/content/browser/renderer_host/render_widget_host_impl.h b/content/browser/renderer_host/render_widget_host_impl.h
|
| index 71aa04fcf349b863b94ba6b5020a711d76ecc799..41ecb35765e877a2ecd2f7bdd0d1d0ba16955984 100644
|
| --- a/content/browser/renderer_host/render_widget_host_impl.h
|
| +++ b/content/browser/renderer_host/render_widget_host_impl.h
|
| @@ -46,6 +46,7 @@ struct ViewHostMsg_BeginSmoothScroll_Params;
|
| struct ViewHostMsg_SelectionBounds_Params;
|
| struct ViewHostMsg_TextInputState_Params;
|
| struct ViewHostMsg_UpdateRect_Params;
|
| +struct ViewMsg_Resize_Params;
|
|
|
| namespace base {
|
| class TimeTicks;
|
| @@ -435,7 +436,17 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
|
|
| // Indicates whether the renderer drives the RenderWidgetHosts's size or the
|
| // other way around.
|
| - bool should_auto_resize() { return should_auto_resize_; }
|
| + bool auto_resize_enabled() { return auto_resize_enabled_; }
|
| +
|
| + // The minimum size of this renderer when auto-resize is enabled.
|
| + const gfx::Size& min_size_for_auto_resize() const {
|
| + return min_size_for_auto_resize_;
|
| + }
|
| +
|
| + // The maximum size of this renderer when auto-resize is enabled.
|
| + const gfx::Size& max_size_for_auto_resize() const {
|
| + return max_size_for_auto_resize_;
|
| + }
|
|
|
| void FrameSwapped(const ui::LatencyInfo& latency_info);
|
| void DidReceiveRendererFrame();
|
| @@ -543,7 +554,16 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
|
|
| // Indicates if the render widget host should track the render widget's size
|
| // as opposed to visa versa.
|
| - void SetShouldAutoResize(bool enable);
|
| + void SetAutoResize(bool enable,
|
| + const gfx::Size& min_size,
|
| + const gfx::Size& max_size);
|
| +
|
| + // Fills in the |resize_params| struct.
|
| + void GetResizeParams(ViewMsg_Resize_Params* resize_params);
|
| +
|
| + // Sets the |resize_params| that were sent to the renderer bundled with the
|
| + // request to create a new RenderWidget.
|
| + void SetInitialRenderSizeParams(const ViewMsg_Resize_Params& resize_params);
|
|
|
| // Expose increment/decrement of the in-flight event count, so
|
| // RenderViewHostImpl can account for in-flight beforeunload/unload events.
|
| @@ -702,9 +722,6 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
| // most recent call to process_->WidgetRestored() / WidgetHidden().
|
| bool is_hidden_;
|
|
|
| - // Indicates whether a page is fullscreen or not.
|
| - bool is_fullscreen_;
|
| -
|
| // Set if we are waiting for a repaint ack for the view.
|
| bool repaint_ack_pending_;
|
|
|
| @@ -722,31 +739,21 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
| // The current size of the RenderWidget.
|
| gfx::Size current_size_;
|
|
|
| - // The size of the view's backing surface in non-DPI-adjusted pixels.
|
| - gfx::Size physical_backing_size_;
|
| -
|
| - // The amount that the viewport size given to Blink was shrunk by the URL-bar
|
| - // (always 0 on platforms where URL-bar hiding isn't supported).
|
| - float top_controls_layout_height_;
|
| -
|
| - // The size of the visible viewport, which may be smaller than the view if the
|
| - // view is partially occluded (e.g. by a virtual keyboard). The size is in
|
| - // DPI-adjusted pixels.
|
| - gfx::Size visible_viewport_size_;
|
| -
|
| - // The size we last sent as requested size to the renderer. |current_size_|
|
| - // is only updated once the resize message has been ack'd. This on the other
|
| - // hand is updated when the resize message is sent. This is very similar to
|
| - // |resize_ack_pending_|, but the latter is not set if the new size has width
|
| - // or height zero, which is why we need this too.
|
| - gfx::Size last_requested_size_;
|
| + // Resize information that was previously sent to the renderer.
|
| + scoped_ptr<ViewMsg_Resize_Params> old_resize_params_;
|
|
|
| // The next auto resize to send.
|
| gfx::Size new_auto_size_;
|
|
|
| // True if the render widget host should track the render widget's size as
|
| // opposed to visa versa.
|
| - bool should_auto_resize_;
|
| + bool auto_resize_enabled_;
|
| +
|
| + // The minimum size for the render widget if auto-resize is enabled.
|
| + gfx::Size min_size_for_auto_resize_;
|
| +
|
| + // The maximum size for the render widget if auto-resize is enabled.
|
| + gfx::Size max_size_for_auto_resize_;
|
|
|
| bool waiting_for_screen_rects_ack_;
|
| gfx::Rect last_view_screen_rect_;
|
|
|