Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3357)

Unified Diff: ash/accelerators/accelerator_controller_delegate_aura.cc

Issue 2720913003: Calls display_configuration_controller to rotate screen in accelerator_controller_delegate_aura (Closed)
Patch Set: Calls display_configuration_controller to rotate screen in accelerator_controller_delegate_aura Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ash/accelerators/accelerator_controller_delegate_aura.cc
diff --git a/ash/accelerators/accelerator_controller_delegate_aura.cc b/ash/accelerators/accelerator_controller_delegate_aura.cc
index 16313bd039f056315c2d3d55a13655e0ca14c757..9e9a8bd81bb4e88fde273f364a8da54e22a88ed4 100644
--- a/ash/accelerators/accelerator_controller_delegate_aura.cc
+++ b/ash/accelerators/accelerator_controller_delegate_aura.cc
@@ -28,7 +28,6 @@
#include "ash/magnifier/magnification_controller.h"
#include "ash/public/cpp/shell_window_ids.h"
#include "ash/root_window_controller.h"
-#include "ash/rotator/screen_rotation_animator.h"
#include "ash/rotator/window_rotation.h"
#include "ash/screenshot_delegate.h"
#include "ash/shell.h"
@@ -160,15 +159,15 @@ void HandleRotateScreen() {
if (Shell::GetInstance()->display_manager()->IsInUnifiedMode())
return;
- base::RecordAction(UserMetricsAction("Accel_Rotate_Window"));
+ base::RecordAction(UserMetricsAction("Accel_Rotate_Screen"));
bruthig 2017/02/28 22:49:22 Good eye!
gfx::Point point = display::Screen::GetScreen()->GetCursorScreenPoint();
display::Display display =
display::Screen::GetScreen()->GetDisplayNearestPoint(point);
const display::ManagedDisplayInfo& display_info =
Shell::GetInstance()->display_manager()->GetDisplayInfo(display.id());
- ScreenRotationAnimator(display.id())
- .Rotate(GetNextRotation(display_info.GetActiveRotation()),
- display::Display::ROTATION_SOURCE_USER);
+ Shell::GetInstance()->display_configuration_controller()->SetDisplayRotation(
+ display.id(), GetNextRotation(display_info.GetActiveRotation()),
+ display::Display::ROTATION_SOURCE_USER);
}
// Rotate the active window.

Powered by Google App Engine
This is Rietveld 408576698