| 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/event_transformation_handler.h" | 5 #include "ash/display/event_transformation_handler.h" |
| 6 | 6 |
| 7 #include <cmath> | 7 #include <cmath> |
| 8 | 8 |
| 9 #include "ash/display/display_info.h" | |
| 10 #include "ash/display/display_manager.h" | |
| 11 #include "ash/wm/window_util.h" | |
| 12 #include "ui/aura/window.h" | 9 #include "ui/aura/window.h" |
| 13 #include "ui/aura/window_event_dispatcher.h" | 10 #include "ui/aura/window_event_dispatcher.h" |
| 14 #include "ui/compositor/dip_util.h" | |
| 15 #include "ui/display/display.h" | 11 #include "ui/display/display.h" |
| 16 #include "ui/display/screen.h" | 12 #include "ui/display/screen.h" |
| 17 #include "ui/events/event.h" | 13 #include "ui/events/event.h" |
| 18 #include "ui/wm/core/coordinate_conversion.h" | 14 #include "ui/wm/core/coordinate_conversion.h" |
| 19 | 15 |
| 20 namespace ash { | 16 namespace ash { |
| 21 namespace { | 17 namespace { |
| 22 | 18 |
| 23 // Boost factor for non-integrated displays. | 19 // Boost factor for non-integrated displays. |
| 24 const float kBoostForNonIntegrated = 1.20f; | 20 const float kBoostForNonIntegrated = 1.20f; |
| (...skipping 18 matching lines...) Expand all Loading... |
| 43 ::wm::ConvertPointToScreen(target, &point_in_screen); | 39 ::wm::ConvertPointToScreen(target, &point_in_screen); |
| 44 const display::Display& display = | 40 const display::Display& display = |
| 45 display::Screen::GetScreen()->GetDisplayNearestPoint(point_in_screen); | 41 display::Screen::GetScreen()->GetDisplayNearestPoint(point_in_screen); |
| 46 | 42 |
| 47 // Apply some additional scaling if the display is non-integrated. | 43 // Apply some additional scaling if the display is non-integrated. |
| 48 if (!display.IsInternal()) | 44 if (!display.IsInternal()) |
| 49 event->Scale(kBoostForNonIntegrated); | 45 event->Scale(kBoostForNonIntegrated); |
| 50 } | 46 } |
| 51 | 47 |
| 52 } // namespace ash | 48 } // namespace ash |
| OLD | NEW |