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

Unified Diff: remoting/host/chromeos/mouse_cursor_monitor_aura.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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « mash/simple_wm/move_event_handler.cc ('k') | services/ui/public/interfaces/cursor/cursor.mojom » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/chromeos/mouse_cursor_monitor_aura.cc
diff --git a/remoting/host/chromeos/mouse_cursor_monitor_aura.cc b/remoting/host/chromeos/mouse_cursor_monitor_aura.cc
index 9749ac7b40529f77181ad54cf6c5139c72a4d750..d828b3332f0041f86cf23c990e5f946414c066ce 100644
--- a/remoting/host/chromeos/mouse_cursor_monitor_aura.cc
+++ b/remoting/host/chromeos/mouse_cursor_monitor_aura.cc
@@ -69,14 +69,14 @@ void MouseCursorMonitorAura::NotifyCursorChanged(const ui::Cursor& cursor) {
std::unique_ptr<SkBitmap> cursor_bitmap(new SkBitmap());
gfx::Point cursor_hotspot;
- if (cursor.native_type() == ui::kCursorNone) {
+ if (cursor.native_type() == ui::CursorType::kNone) {
callback_->OnMouseCursor(CreateEmptyMouseCursor());
return;
}
if (!ui::GetCursorBitmap(cursor, cursor_bitmap.get(), &cursor_hotspot)) {
LOG(ERROR) << "Failed to load bitmap for cursor type:"
- << cursor.native_type();
+ << static_cast<int>(cursor.native_type());
callback_->OnMouseCursor(CreateEmptyMouseCursor());
return;
}
@@ -92,7 +92,8 @@ void MouseCursorMonitorAura::NotifyCursorChanged(const ui::Cursor& cursor) {
if (cursor_hotspot.x() >= cursor_bitmap->width() ||
cursor_hotspot.y() >= cursor_bitmap->height()) {
LOG(WARNING) << "Cursor hotspot is out of bounds for type: "
- << cursor.native_type() << ". Setting to (0,0) instead";
+ << static_cast<int>(cursor.native_type())
+ << ". Setting to (0,0) instead";
cursor_hotspot.SetPoint(0, 0);
}
« no previous file with comments | « mash/simple_wm/move_event_handler.cc ('k') | services/ui/public/interfaces/cursor/cursor.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698