if (!compositor_)
return false;
+ if (last_on_draw_global_visible_rect_.IsEmpty())
+ return client_->RequestDrawGL(java_canvas, false);
+
if (!hardware_enabled_) {
hardware_enabled_ = compositor_->InitializeHwDraw();
if (hardware_enabled_) {
FROM_HERE,
fallback_tick_fired_.callback(),
base::TimeDelta::FromMilliseconds(kFallbackTickTimeoutInMilliseconds));
+ } else {
+ // Pretend we just composited to unblock further invalidates.
+ DidComposite();
}
}
// This should only be called if OnDraw or DrawGL did not come in time, which
// means block_invalidates_ must still be true.
DCHECK(block_invalidates_);
- if (compositor_needs_continuous_invalidate_ && compositor_)
+ if (compositor_needs_continuous_invalidate_ && compositor_) {
ForceFakeCompositeSW();
+ } else {
+ // Pretend we just composited to unblock further invalidates.
+ DidComposite();
+ }
}
void BrowserViewRenderer::ForceFakeCompositeSW() {