| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "ash/wm/overview/window_grid.h" | 5 #include "ash/wm/overview/window_grid.h" |
| 6 | 6 |
| 7 #include "ash/ash_switches.h" | 7 #include "ash/ash_switches.h" |
| 8 #include "ash/screen_util.h" | 8 #include "ash/screen_util.h" |
| 9 #include "ash/shell.h" | 9 #include "ash/shell.h" |
| 10 #include "ash/shell_window_ids.h" | 10 #include "ash/shell_window_ids.h" |
| (...skipping 23 matching lines...) Expand all Loading... |
| 34 // An observer which holds onto the passed widget until the animation is | 34 // An observer which holds onto the passed widget until the animation is |
| 35 // complete. | 35 // complete. |
| 36 class CleanupWidgetAfterAnimationObserver | 36 class CleanupWidgetAfterAnimationObserver |
| 37 : public ui::ImplicitAnimationObserver { | 37 : public ui::ImplicitAnimationObserver { |
| 38 public: | 38 public: |
| 39 explicit CleanupWidgetAfterAnimationObserver( | 39 explicit CleanupWidgetAfterAnimationObserver( |
| 40 scoped_ptr<views::Widget> widget); | 40 scoped_ptr<views::Widget> widget); |
| 41 virtual ~CleanupWidgetAfterAnimationObserver(); | 41 virtual ~CleanupWidgetAfterAnimationObserver(); |
| 42 | 42 |
| 43 // ui::ImplicitAnimationObserver: | 43 // ui::ImplicitAnimationObserver: |
| 44 virtual void OnImplicitAnimationsCompleted() OVERRIDE; | 44 virtual void OnImplicitAnimationsCompleted() override; |
| 45 | 45 |
| 46 private: | 46 private: |
| 47 scoped_ptr<views::Widget> widget_; | 47 scoped_ptr<views::Widget> widget_; |
| 48 | 48 |
| 49 DISALLOW_COPY_AND_ASSIGN(CleanupWidgetAfterAnimationObserver); | 49 DISALLOW_COPY_AND_ASSIGN(CleanupWidgetAfterAnimationObserver); |
| 50 }; | 50 }; |
| 51 | 51 |
| 52 CleanupWidgetAfterAnimationObserver::CleanupWidgetAfterAnimationObserver( | 52 CleanupWidgetAfterAnimationObserver::CleanupWidgetAfterAnimationObserver( |
| 53 scoped_ptr<views::Widget> widget) | 53 scoped_ptr<views::Widget> widget) |
| 54 : widget_(widget.Pass()) { | 54 : widget_(widget.Pass()) { |
| (...skipping 416 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 471 ui::LayerAnimator::IMMEDIATELY_ANIMATE_TO_NEW_TARGET); | 471 ui::LayerAnimator::IMMEDIATELY_ANIMATE_TO_NEW_TARGET); |
| 472 selection_widget_->SetBounds(SelectedWindow()->target_bounds()); | 472 selection_widget_->SetBounds(SelectedWindow()->target_bounds()); |
| 473 selection_widget_->SetOpacity(kWindowOverviewSelectorOpacity); | 473 selection_widget_->SetOpacity(kWindowOverviewSelectorOpacity); |
| 474 return; | 474 return; |
| 475 } | 475 } |
| 476 selection_widget_->SetBounds(SelectedWindow()->target_bounds()); | 476 selection_widget_->SetBounds(SelectedWindow()->target_bounds()); |
| 477 selection_widget_->SetOpacity(kWindowOverviewSelectorOpacity); | 477 selection_widget_->SetOpacity(kWindowOverviewSelectorOpacity); |
| 478 } | 478 } |
| 479 | 479 |
| 480 } // namespace ash | 480 } // namespace ash |
| OLD | NEW |