| Index: ui/gfx/compositor/compositor.cc
|
| diff --git a/ui/gfx/compositor/compositor.cc b/ui/gfx/compositor/compositor.cc
|
| index 388d7d9196ba5b9df39f125fb85bcb6329757adf..724f7a18105f810859d5b288128663e85a626940 100644
|
| --- a/ui/gfx/compositor/compositor.cc
|
| +++ b/ui/gfx/compositor/compositor.cc
|
| @@ -26,6 +26,8 @@ Compositor::Compositor(CompositorDelegate* delegate, const gfx::Size& size)
|
| }
|
|
|
| Compositor::~Compositor() {
|
| + if (root_layer_)
|
| + root_layer_->SetCompositor(NULL);
|
| }
|
|
|
| void Compositor::ScheduleDraw() {
|
| @@ -33,6 +35,8 @@ void Compositor::ScheduleDraw() {
|
| }
|
|
|
| void Compositor::SetRootLayer(Layer* root_layer) {
|
| + if (root_layer_)
|
| + root_layer_->SetCompositor(NULL);
|
| root_layer_ = root_layer;
|
| if (!root_layer_->GetCompositor())
|
| root_layer_->SetCompositor(this);
|
|
|