| 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/display/window_tree_host_manager.h" | 5 #include "ash/display/window_tree_host_manager.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <cmath> | 8 #include <cmath> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 810 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 821 for (auto& observer : observers_) | 821 for (auto& observer : observers_) |
| 822 observer.OnDisplayConfigurationChanged(); | 822 observer.OnDisplayConfigurationChanged(); |
| 823 UpdateMouseLocationAfterDisplayChange(); | 823 UpdateMouseLocationAfterDisplayChange(); |
| 824 | 824 |
| 825 #if defined(USE_X11) | 825 #if defined(USE_X11) |
| 826 if (must_clear_window) | 826 if (must_clear_window) |
| 827 ui::ClearX11DefaultRootWindow(); | 827 ui::ClearX11DefaultRootWindow(); |
| 828 #endif | 828 #endif |
| 829 } | 829 } |
| 830 | 830 |
| 831 ui::DisplayConfigurator* WindowTreeHostManager::display_configurator() { | 831 display::DisplayConfigurator* WindowTreeHostManager::display_configurator() { |
| 832 return Shell::GetInstance()->display_configurator(); | 832 return Shell::GetInstance()->display_configurator(); |
| 833 } | 833 } |
| 834 | 834 |
| 835 ui::EventDispatchDetails WindowTreeHostManager::DispatchKeyEventPostIME( | 835 ui::EventDispatchDetails WindowTreeHostManager::DispatchKeyEventPostIME( |
| 836 ui::KeyEvent* event) { | 836 ui::KeyEvent* event) { |
| 837 // Getting the active root window to dispatch the event. This isn't | 837 // Getting the active root window to dispatch the event. This isn't |
| 838 // significant as the event will be sent to the window resolved by | 838 // significant as the event will be sent to the window resolved by |
| 839 // aura::client::FocusClient which is FocusController in ash. | 839 // aura::client::FocusClient which is FocusController in ash. |
| 840 aura::Window* active_window = wm::GetActiveWindow(); | 840 aura::Window* active_window = wm::GetActiveWindow(); |
| 841 aura::Window* root_window = active_window ? active_window->GetRootWindow() | 841 aura::Window* root_window = active_window ? active_window->GetRootWindow() |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 881 | 881 |
| 882 window_tree_hosts_[display.id()] = ash_host; | 882 window_tree_hosts_[display.id()] = ash_host; |
| 883 SetDisplayPropertiesOnHost(ash_host, display); | 883 SetDisplayPropertiesOnHost(ash_host, display); |
| 884 | 884 |
| 885 if (switches::ConstrainPointerToRoot()) | 885 if (switches::ConstrainPointerToRoot()) |
| 886 ash_host->ConfineCursorToRootWindow(); | 886 ash_host->ConfineCursorToRootWindow(); |
| 887 return ash_host; | 887 return ash_host; |
| 888 } | 888 } |
| 889 | 889 |
| 890 } // namespace ash | 890 } // namespace ash |
| OLD | NEW |