diff options
author | levin@chromium.org <levin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-02 16:13:34 +0000 |
---|---|---|
committer | levin@chromium.org <levin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-02 16:13:34 +0000 |
commit | 61e2b3cc316ac7c6fa1300dacbac2512b4c2148c (patch) | |
tree | 9a1bedc0a30c8726d97adaf0b558c94451766cd2 /content/browser/renderer_host/render_widget_host.cc | |
parent | dcec8e7b214c4e5ea10bfb2c8a2791099c44ba2f (diff) | |
download | chromium_src-61e2b3cc316ac7c6fa1300dacbac2512b4c2148c.zip chromium_src-61e2b3cc316ac7c6fa1300dacbac2512b4c2148c.tar.gz chromium_src-61e2b3cc316ac7c6fa1300dacbac2512b4c2148c.tar.bz2 |
Change panels to be able to turn off autoresize.
BUG=109343
TEST=PanelBrowserTest.ResizePanel
Review URL: http://codereview.chromium.org/9517010
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@124664 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/browser/renderer_host/render_widget_host.cc')
-rw-r--r-- | content/browser/renderer_host/render_widget_host.cc | 22 |
1 files changed, 5 insertions, 17 deletions
diff --git a/content/browser/renderer_host/render_widget_host.cc b/content/browser/renderer_host/render_widget_host.cc index d08f150..ea2013e 100644 --- a/content/browser/renderer_host/render_widget_host.cc +++ b/content/browser/renderer_host/render_widget_host.cc @@ -941,17 +941,7 @@ bool RenderWidgetHostImpl::IsFullscreen() const { } void RenderWidgetHostImpl::SetShouldAutoResize(bool enable) { - // Note if this switches from true to false then one has to verify that the - // mechanics about all the messaging works. For example, what happens to a - // update message rect that was in progress from the render widget. Perhaps, - // on a transition to false, this should do a WasResized, but what if that - // will not trigger a resize message...etc. Due to these complications it is - // fitting that this method doesn't look like a simple set method. - DCHECK(enable); - - // TODO: Change this to enable instead of true when this supports turning - // off auto-resize. - should_auto_resize_ = true; + should_auto_resize_ = enable; } void RenderWidgetHostImpl::Destroy() { @@ -1077,12 +1067,10 @@ void RenderWidgetHostImpl::OnMsgUpdateRect( // resize_ack_pending_ needs to be cleared before we call DidPaintRect, since // that will end up reaching GetBackingStore. - if (is_resize_ack || should_auto_resize_) { - if (is_resize_ack) { - DCHECK(resize_ack_pending_); - resize_ack_pending_ = false; - in_flight_size_.SetSize(0, 0); - } + if (is_resize_ack) { + DCHECK(resize_ack_pending_); + resize_ack_pending_ = false; + in_flight_size_.SetSize(0, 0); } bool is_repaint_ack = |