| Index: athena/wm/window_overview_mode.cc
|
| diff --git a/athena/wm/window_overview_mode.cc b/athena/wm/window_overview_mode.cc
|
| index b9a58fe6b74e21c3a508ab528a69b936b8934377..37b8492d49ce8ee5e59962c889bb65b8f59a0c01 100644
|
| --- a/athena/wm/window_overview_mode.cc
|
| +++ b/athena/wm/window_overview_mode.cc
|
| @@ -28,6 +28,7 @@
|
| #include "ui/gfx/frame_time.h"
|
| #include "ui/gfx/transform.h"
|
| #include "ui/wm/core/shadow_types.h"
|
| +#include "ui/wm/core/window_animations.h"
|
| #include "ui/wm/core/window_util.h"
|
|
|
| namespace {
|
| @@ -479,12 +480,9 @@ class WindowOverviewModeImpl : public WindowOverviewMode,
|
| void CloseDragWindow(const ui::GestureEvent& gesture) {
|
| // Animate |dragged_window_| offscreen first, then destroy it.
|
| {
|
| - ui::ScopedLayerAnimationSettings settings(
|
| - dragged_window_->layer()->GetAnimator());
|
| - settings.SetPreemptionStrategy(
|
| + wm::ScopedHidingAnimationSettings settings(dragged_window_);
|
| + settings.layer_animation_settings()->SetPreemptionStrategy(
|
| ui::LayerAnimator::IMMEDIATELY_ANIMATE_TO_NEW_TARGET);
|
| - settings.AddObserver(new ui::ClosureAnimationObserver(
|
| - base::Bind(&base::DeletePointer<aura::Window>, dragged_window_)));
|
|
|
| WindowOverviewState* dragged_state =
|
| dragged_window_->GetProperty(kWindowOverviewState);
|
| @@ -546,6 +544,7 @@ class WindowOverviewModeImpl : public WindowOverviewMode,
|
| }
|
| }
|
|
|
| + delete dragged_window_;
|
| dragged_window_ = NULL;
|
| }
|
|
|
|
|