OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/magnifier/magnification_controller.h" | 5 #include "ash/magnifier/magnification_controller.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "ash/accelerators/accelerator_controller.h" | 9 #include "ash/accelerators/accelerator_controller.h" |
10 #include "ash/accessibility_delegate.h" | 10 #include "ash/accessibility_delegate.h" |
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
365 ui::ScopedLayerAnimationSettings settings( | 365 ui::ScopedLayerAnimationSettings settings( |
366 root_window_->layer()->GetAnimator()); | 366 root_window_->layer()->GetAnimator()); |
367 settings.AddObserver(this); | 367 settings.AddObserver(this); |
368 settings.SetPreemptionStrategy( | 368 settings.SetPreemptionStrategy( |
369 ui::LayerAnimator::IMMEDIATELY_ANIMATE_TO_NEW_TARGET); | 369 ui::LayerAnimator::IMMEDIATELY_ANIMATE_TO_NEW_TARGET); |
370 settings.SetTweenType(tween_type); | 370 settings.SetTweenType(tween_type); |
371 settings.SetTransitionDuration( | 371 settings.SetTransitionDuration( |
372 base::TimeDelta::FromMilliseconds(duration_in_ms)); | 372 base::TimeDelta::FromMilliseconds(duration_in_ms)); |
373 | 373 |
374 gfx::Display display = | 374 gfx::Display display = |
375 Shell::GetScreen()->GetDisplayNearestWindow(root_window_); | 375 gfx::Screen::GetScreen()->GetDisplayNearestWindow(root_window_); |
376 scoped_ptr<RootWindowTransformer> transformer( | 376 scoped_ptr<RootWindowTransformer> transformer( |
377 CreateRootWindowTransformerForDisplay(root_window_, display)); | 377 CreateRootWindowTransformerForDisplay(root_window_, display)); |
378 GetRootWindowController(root_window_) | 378 GetRootWindowController(root_window_) |
379 ->ash_host() | 379 ->ash_host() |
380 ->SetRootWindowTransformer(std::move(transformer)); | 380 ->SetRootWindowTransformer(std::move(transformer)); |
381 | 381 |
382 if (duration_in_ms > 0) | 382 if (duration_in_ms > 0) |
383 is_on_animation_ = true; | 383 is_on_animation_ = true; |
384 | 384 |
385 return true; | 385 return true; |
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
853 | 853 |
854 //////////////////////////////////////////////////////////////////////////////// | 854 //////////////////////////////////////////////////////////////////////////////// |
855 // MagnificationController: | 855 // MagnificationController: |
856 | 856 |
857 // static | 857 // static |
858 MagnificationController* MagnificationController::CreateInstance() { | 858 MagnificationController* MagnificationController::CreateInstance() { |
859 return new MagnificationControllerImpl(); | 859 return new MagnificationControllerImpl(); |
860 } | 860 } |
861 | 861 |
862 } // namespace ash | 862 } // namespace ash |
OLD | NEW |