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

Side by Side Diff: services/ui/ws/display.cc

Issue 2833163002: Change ui cursor identifiers to an enum class. (Closed)
Patch Set: OK, it can't be explicit for mac. Created 3 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 unified diff | Download patch
« no previous file with comments | « services/ui/ws/cursor_unittest.cc ('k') | services/ui/ws/drag_controller.cc » ('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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "services/ui/ws/display.h" 5 #include "services/ui/ws/display.h"
6 6
7 #include <set> 7 #include <set>
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 19 matching lines...) Expand all
30 #include "ui/display/screen.h" 30 #include "ui/display/screen.h"
31 31
32 #if defined(USE_OZONE) 32 #if defined(USE_OZONE)
33 #include "ui/ozone/public/ozone_platform.h" 33 #include "ui/ozone/public/ozone_platform.h"
34 #endif 34 #endif
35 35
36 namespace ui { 36 namespace ui {
37 namespace ws { 37 namespace ws {
38 38
39 Display::Display(WindowServer* window_server) 39 Display::Display(WindowServer* window_server)
40 : window_server_(window_server), 40 : window_server_(window_server), last_cursor_(mojom::CursorType::kNull) {
41 last_cursor_(mojom::CursorType::CURSOR_NULL) {
42 window_server_->window_manager_window_tree_factory_set()->AddObserver(this); 41 window_server_->window_manager_window_tree_factory_set()->AddObserver(this);
43 window_server_->user_id_tracker()->AddObserver(this); 42 window_server_->user_id_tracker()->AddObserver(this);
44 } 43 }
45 44
46 Display::~Display() { 45 Display::~Display() {
47 window_server_->user_id_tracker()->RemoveObserver(this); 46 window_server_->user_id_tracker()->RemoveObserver(this);
48 47
49 window_server_->window_manager_window_tree_factory_set()->RemoveObserver( 48 window_server_->window_manager_window_tree_factory_set()->RemoveObserver(
50 this); 49 this);
51 50
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
412 411
413 UserActivityMonitor* activity_monitor = 412 UserActivityMonitor* activity_monitor =
414 window_server_->GetUserActivityMonitorForUser( 413 window_server_->GetUserActivityMonitorForUser(
415 window_server_->user_id_tracker()->active_id()); 414 window_server_->user_id_tracker()->active_id());
416 activity_monitor->OnUserActivity(); 415 activity_monitor->OnUserActivity();
417 return EventDispatchDetails(); 416 return EventDispatchDetails();
418 } 417 }
419 418
420 } // namespace ws 419 } // namespace ws
421 } // namespace ui 420 } // namespace ui
OLDNEW
« no previous file with comments | « services/ui/ws/cursor_unittest.cc ('k') | services/ui/ws/drag_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698