Index: ui/gfx/compositor/compositor_gl.cc |
diff --git a/ui/gfx/compositor/compositor_gl.cc b/ui/gfx/compositor/compositor_gl.cc |
index ee1a38d994c861e7ece04cd0a7bc28e0fa1efff0..962703f31822a0a1973bb04f9ab4d9a514851a8d 100644 |
--- a/ui/gfx/compositor/compositor_gl.cc |
+++ b/ui/gfx/compositor/compositor_gl.cc |
@@ -441,11 +441,12 @@ void TextureGL::DrawInternal(const ui::TextureProgramGL& program, |
glDrawArrays(GL_TRIANGLE_FAN, 0, 4); |
} |
-CompositorGL::CompositorGL(gfx::AcceleratedWidget widget, |
+CompositorGL::CompositorGL(CompositorOwner* owner, |
const gfx::Size& size) |
- : Compositor(size), |
+ : Compositor(owner, size), |
started_(false) { |
- gl_surface_ = gfx::GLSurface::CreateViewGLSurface(false, widget); |
+ gl_surface_ = gfx::GLSurface::CreateViewGLSurface(false, |
+ owner->GetAcceleratedWidget()); |
gl_context_ = SharedResources::GetInstance()-> |
CreateContext(gl_surface_.get()); |
gl_context_->MakeCurrent(gl_surface_.get()); |
@@ -494,17 +495,16 @@ void CompositorGL::Blur(const gfx::Rect& bounds) { |
} |
void CompositorGL::SchedulePaint() { |
- // TODO: X doesn't provide coalescing of regions, its left to the toolkit. |
- NOTIMPLEMENTED(); |
+ owner()->PaintNow(); |
sadrul
2011/09/06 17:27:05
This will actually be a PostTask
|
} |
// static |
-Compositor* Compositor::Create(gfx::AcceleratedWidget widget, |
+Compositor* Compositor::Create(CompositorOwner* owner, |
const gfx::Size& size) { |
if (SharedResources::GetInstance() == NULL) |
return NULL; |
else |
- return new CompositorGL(widget, size); |
+ return new CompositorGL(owner, size); |
} |
} // namespace ui |