| Index: ui/compositor/compositor.cc
|
| ===================================================================
|
| --- ui/compositor/compositor.cc (revision 192187)
|
| +++ ui/compositor/compositor.cc (working copy)
|
| @@ -12,6 +12,7 @@
|
| #include "base/memory/singleton.h"
|
| #include "base/message_loop.h"
|
| #include "base/string_util.h"
|
| +#include "base/synchronization/waitable_event.h"
|
| #include "base/threading/thread.h"
|
| #include "base/threading/thread_restrictions.h"
|
| #include "cc/base/switches.h"
|
| @@ -411,6 +412,7 @@
|
| last_started_frame_(0),
|
| last_ended_frame_(0),
|
| disable_schedule_composite_(false),
|
| + is_resizing_ (false),
|
| compositor_lock_(NULL) {
|
| root_web_layer_ = cc::Layer::Create();
|
| root_web_layer_->SetAnchorPoint(gfx::PointF(0.f, 0.f));
|
| @@ -527,6 +529,18 @@
|
| // compositeImmediately() directly.
|
| Layout();
|
| host_->Composite(base::TimeTicks::Now());
|
| +
|
| +#if defined(OS_WIN)
|
| + // While we resize, we are usually a few frames behind. By blocking
|
| + // the UI thread here we minize the area that is mis-painted, specially
|
| + // in the non-client area. See RenderWidgetHostViewAura::SetBounds for
|
| + // more details and bug 177115.
|
| + if (is_resizing_ && (last_ended_frame_ > 1)) {
|
| + is_resizing_ = false;
|
| + host_->FinishAllRendering();
|
| + }
|
| +#endif
|
| +
|
| }
|
| if (!pending_swap.posted())
|
| NotifyEnd();
|
| @@ -557,6 +571,8 @@
|
| size_ = size_in_pixel;
|
| host_->SetViewportSize(size_in_pixel, size_in_pixel);
|
| root_web_layer_->SetBounds(size_in_pixel);
|
| +
|
| + is_resizing_ = true;
|
| }
|
| if (device_scale_factor_ != scale) {
|
| device_scale_factor_ = scale;
|
|
|