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

Side by Side Diff: components/exo/wm_helper_ash.cc

Issue 2949353003: Implement large cursors in Mushrome. (Closed)
Patch Set: rename everything to CursorSize Created 3 years, 5 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 unified diff | Download patch
« no previous file with comments | « components/exo/wm_helper_ash.h ('k') | components/exo/wm_helper_mus.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "components/exo/wm_helper_ash.h" 5 #include "components/exo/wm_helper_ash.h"
6 6
7 #include "ash/public/cpp/config.h" 7 #include "ash/public/cpp/config.h"
8 #include "ash/shell.h" 8 #include "ash/shell.h"
9 #include "ash/system/tray/system_tray_notifier.h" 9 #include "ash/system/tray/system_tray_notifier.h"
10 #include "ash/wm/maximize_mode/maximize_mode_controller.h" 10 #include "ash/wm/maximize_mode/maximize_mode_controller.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 aura::Window* WMHelperAsh::GetActiveWindow() const { 63 aura::Window* WMHelperAsh::GetActiveWindow() const {
64 return ash::Shell::Get()->activation_client()->GetActiveWindow(); 64 return ash::Shell::Get()->activation_client()->GetActiveWindow();
65 } 65 }
66 66
67 aura::Window* WMHelperAsh::GetFocusedWindow() const { 67 aura::Window* WMHelperAsh::GetFocusedWindow() const {
68 aura::client::FocusClient* focus_client = 68 aura::client::FocusClient* focus_client =
69 aura::client::GetFocusClient(ash::Shell::GetPrimaryRootWindow()); 69 aura::client::GetFocusClient(ash::Shell::GetPrimaryRootWindow());
70 return focus_client->GetFocusedWindow(); 70 return focus_client->GetFocusedWindow();
71 } 71 }
72 72
73 ui::CursorSetType WMHelperAsh::GetCursorSet() const { 73 ui::CursorSize WMHelperAsh::GetCursorSize() const {
74 // TODO(crbug.com/631103): Mushrome doesn't have a cursor manager yet. 74 // TODO(crbug.com/631103): Mushrome doesn't have a cursor manager yet.
75 if (ash::Shell::GetAshConfig() == ash::Config::MUS) 75 if (ash::Shell::GetAshConfig() == ash::Config::MUS)
76 return ui::CURSOR_SET_NORMAL; 76 return ui::CursorSize::kNormal;
77 return ash::Shell::Get()->cursor_manager()->GetCursorSet(); 77 return ash::Shell::Get()->cursor_manager()->GetCursorSize();
78 } 78 }
79 79
80 const display::Display& WMHelperAsh::GetCursorDisplay() const { 80 const display::Display& WMHelperAsh::GetCursorDisplay() const {
81 // TODO(crbug.com/631103): Mushrome doesn't have a cursor manager yet. 81 // TODO(crbug.com/631103): Mushrome doesn't have a cursor manager yet.
82 if (ash::Shell::GetAshConfig() == ash::Config::MUS) { 82 if (ash::Shell::GetAshConfig() == ash::Config::MUS) {
83 static const display::Display display; 83 static const display::Display display;
84 return display; 84 return display;
85 } 85 }
86 return ash::Shell::Get()->cursor_manager()->GetDisplay(); 86 return ash::Shell::Get()->cursor_manager()->GetDisplay();
87 } 87 }
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 121
122 void WMHelperAsh::OnWindowFocused(aura::Window* gained_focus, 122 void WMHelperAsh::OnWindowFocused(aura::Window* gained_focus,
123 aura::Window* lost_focus) { 123 aura::Window* lost_focus) {
124 NotifyWindowFocused(gained_focus, lost_focus); 124 NotifyWindowFocused(gained_focus, lost_focus);
125 } 125 }
126 126
127 void WMHelperAsh::OnCursorVisibilityChanged(bool is_visible) { 127 void WMHelperAsh::OnCursorVisibilityChanged(bool is_visible) {
128 NotifyCursorVisibilityChanged(is_visible); 128 NotifyCursorVisibilityChanged(is_visible);
129 } 129 }
130 130
131 void WMHelperAsh::OnCursorSetChanged(ui::CursorSetType cursor_set) { 131 void WMHelperAsh::OnCursorSizeChanged(ui::CursorSize cursor_size) {
132 NotifyCursorSetChanged(cursor_set); 132 NotifyCursorSizeChanged(cursor_size);
133 } 133 }
134 134
135 void WMHelperAsh::OnCursorDisplayChanged(const display::Display& display) { 135 void WMHelperAsh::OnCursorDisplayChanged(const display::Display& display) {
136 NotifyCursorDisplayChanged(display); 136 NotifyCursorDisplayChanged(display);
137 } 137 }
138 138
139 void WMHelperAsh::OnMaximizeModeStarted() { 139 void WMHelperAsh::OnMaximizeModeStarted() {
140 NotifyMaximizeModeStarted(); 140 NotifyMaximizeModeStarted();
141 } 141 }
142 142
143 void WMHelperAsh::OnMaximizeModeEnding() { 143 void WMHelperAsh::OnMaximizeModeEnding() {
144 NotifyMaximizeModeEnding(); 144 NotifyMaximizeModeEnding();
145 } 145 }
146 146
147 void WMHelperAsh::OnMaximizeModeEnded() { 147 void WMHelperAsh::OnMaximizeModeEnded() {
148 NotifyMaximizeModeEnded(); 148 NotifyMaximizeModeEnded();
149 } 149 }
150 150
151 void WMHelperAsh::OnDisplayConfigurationChanged() { 151 void WMHelperAsh::OnDisplayConfigurationChanged() {
152 NotifyDisplayConfigurationChanged(); 152 NotifyDisplayConfigurationChanged();
153 } 153 }
154 154
155 void WMHelperAsh::OnKeyboardDeviceConfigurationChanged() { 155 void WMHelperAsh::OnKeyboardDeviceConfigurationChanged() {
156 NotifyKeyboardDeviceConfigurationChanged(); 156 NotifyKeyboardDeviceConfigurationChanged();
157 } 157 }
158 158
159 } // namespace exo 159 } // namespace exo
OLDNEW
« no previous file with comments | « components/exo/wm_helper_ash.h ('k') | components/exo/wm_helper_mus.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698