| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/display/root_window_transformers.h" | 5 #include "ash/display/root_window_transformers.h" |
| 6 | 6 |
| 7 #include <cmath> | 7 #include <cmath> |
| 8 | 8 |
| 9 #include "ash/display/display_info.h" | 9 #include "ash/display/display_info.h" |
| 10 #include "ash/display/display_manager.h" | 10 #include "ash/display/display_manager.h" |
| 11 #include "ash/magnifier/magnification_controller.h" | 11 #include "ash/magnifier/magnification_controller.h" |
| 12 #include "ash/shell.h" | 12 #include "ash/shell.h" |
| 13 #include "base/basictypes.h" | 13 #include "base/basictypes.h" |
| 14 #include "base/memory/scoped_ptr.h" | 14 #include "base/memory/scoped_ptr.h" |
| 15 #include "third_party/skia/include/utils/SkMatrix44.h" | 15 #include "third_party/skia/include/utils/SkMatrix44.h" |
| 16 #include "ui/aura/root_window_transformer.h" | 16 #include "ui/aura/root_window_transformer.h" |
| 17 #include "ui/aura/window_event_dispatcher.h" | 17 #include "ui/aura/window_event_dispatcher.h" |
| 18 #include "ui/aura/window_property.h" | 18 #include "ui/aura/window_property.h" |
| 19 #include "ui/compositor/dip_util.h" | 19 #include "ui/compositor/dip_util.h" |
| 20 #include "ui/gfx/display.h" | 20 #include "ui/gfx/display.h" |
| 21 #include "ui/gfx/insets.h" | 21 #include "ui/gfx/insets.h" |
| 22 #include "ui/gfx/size_conversions.h" | 22 #include "ui/gfx/size_conversions.h" |
| 23 #include "ui/gfx/transform.h" | 23 #include "ui/gfx/transform.h" |
| 24 #include "ui/gfx/transform.h" | 24 #include "ui/gfx/transform.h" |
| 25 | 25 |
| 26 DECLARE_WINDOW_PROPERTY_TYPE(gfx::Display::Rotation); | 26 DECLARE_WINDOW_PROPERTY_TYPE(gfx::Display::Rotation); |
| 27 | 27 |
| 28 namespace ash { | 28 namespace ash { |
| 29 namespace internal { | |
| 30 namespace { | 29 namespace { |
| 31 | 30 |
| 32 #if defined(OS_WIN) | 31 #if defined(OS_WIN) |
| 33 DEFINE_WINDOW_PROPERTY_KEY(gfx::Display::Rotation, kRotationPropertyKey, | 32 DEFINE_WINDOW_PROPERTY_KEY(gfx::Display::Rotation, kRotationPropertyKey, |
| 34 gfx::Display::ROTATE_0); | 33 gfx::Display::ROTATE_0); |
| 35 #endif | 34 #endif |
| 36 | 35 |
| 37 // Round near zero value to zero. | 36 // Round near zero value to zero. |
| 38 void RoundNearZero(gfx::Transform* transform) { | 37 void RoundNearZero(gfx::Transform* transform) { |
| 39 const float kEpsilon = 0.001f; | 38 const float kEpsilon = 0.001f; |
| (...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 274 return new AshRootWindowTransformer(root, display); | 273 return new AshRootWindowTransformer(root, display); |
| 275 } | 274 } |
| 276 | 275 |
| 277 aura::RootWindowTransformer* CreateRootWindowTransformerForMirroredDisplay( | 276 aura::RootWindowTransformer* CreateRootWindowTransformerForMirroredDisplay( |
| 278 const DisplayInfo& source_display_info, | 277 const DisplayInfo& source_display_info, |
| 279 const DisplayInfo& mirror_display_info) { | 278 const DisplayInfo& mirror_display_info) { |
| 280 return new MirrorRootWindowTransformer(source_display_info, | 279 return new MirrorRootWindowTransformer(source_display_info, |
| 281 mirror_display_info); | 280 mirror_display_info); |
| 282 } | 281 } |
| 283 | 282 |
| 284 } // namespace internal | |
| 285 } // namespace ash | 283 } // namespace ash |
| OLD | NEW |