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

Unified Diff: ash/rotator/screen_rotation_animator.cc

Issue 1924703002: Rename gfx::Display/Screen to display::Display/Screen in ash (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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
« no previous file with comments | « ash/rotator/screen_rotation_animator.h ('k') | ash/screen_util.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/rotator/screen_rotation_animator.cc
diff --git a/ash/rotator/screen_rotation_animator.cc b/ash/rotator/screen_rotation_animator.cc
index 1725dac9886b8da10619138d235ddacfcb9a30d5..9f6f4afed13d849f29c19227b32306583ad5ab16 100644
--- a/ash/rotator/screen_rotation_animator.cc
+++ b/ash/rotator/screen_rotation_animator.cc
@@ -22,8 +22,8 @@
#include "ui/compositor/layer_animator.h"
#include "ui/compositor/layer_owner.h"
#include "ui/compositor/layer_tree_owner.h"
+#include "ui/display/display.h"
#include "ui/gfx/animation/tween.h"
-#include "ui/gfx/display.h"
#include "ui/gfx/geometry/point.h"
#include "ui/gfx/geometry/rect.h"
#include "ui/gfx/geometry/rect_f.h"
@@ -43,7 +43,7 @@ const int kRotationDurationInMs = 250;
// Gets the current display rotation for the display with the specified
// |display_id|.
-gfx::Display::Rotation GetCurrentRotation(int64_t display_id) {
+display::Display::Rotation GetCurrentRotation(int64_t display_id) {
return Shell::GetInstance()
->display_manager()
->GetDisplayInfo(display_id)
@@ -52,8 +52,8 @@ gfx::Display::Rotation GetCurrentRotation(int64_t display_id) {
// Returns true if the rotation between |initial_rotation| and |new_rotation| is
// 180 degrees.
-bool Is180DegreeFlip(gfx::Display::Rotation initial_rotation,
- gfx::Display::Rotation new_rotation) {
+bool Is180DegreeFlip(display::Display::Rotation initial_rotation,
+ display::Display::Rotation new_rotation) {
return (initial_rotation + 2) % 4 == new_rotation;
}
@@ -146,13 +146,13 @@ void LayerCleanupObserver::AbortAnimations(ui::Layer* layer) {
// out, and the new orientation's layer will be rotated in to the
// |new_orientation| through |rotation_degrees| arc.
void RotateScreen(int64_t display_id,
- gfx::Display::Rotation new_rotation,
- gfx::Display::RotationSource source) {
+ display::Display::Rotation new_rotation,
+ display::Display::RotationSource source) {
aura::Window* root_window = Shell::GetInstance()
->window_tree_host_manager()
->GetRootWindowForDisplayId(display_id);
- const gfx::Display::Rotation initial_orientation =
+ const display::Display::Rotation initial_orientation =
GetCurrentRotation(display_id);
const gfx::Rect original_screen_bounds = root_window->GetTargetBounds();
@@ -256,9 +256,9 @@ bool ScreenRotationAnimator::CanAnimate() const {
.is_valid();
}
-void ScreenRotationAnimator::Rotate(gfx::Display::Rotation new_rotation,
- gfx::Display::RotationSource source) {
- const gfx::Display::Rotation current_rotation =
+void ScreenRotationAnimator::Rotate(display::Display::Rotation new_rotation,
+ display::Display::RotationSource source) {
+ const display::Display::Rotation current_rotation =
GetCurrentRotation(display_id_);
if (current_rotation == new_rotation)
« no previous file with comments | « ash/rotator/screen_rotation_animator.h ('k') | ash/screen_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698