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

Unified Diff: ui/base/cursor/cursor_loader_ozone.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 | « ui/base/cursor/cursor_loader_ozone.h ('k') | ui/base/cursor/cursor_loader_win.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/cursor/cursor_loader_ozone.cc
diff --git a/ui/base/cursor/cursor_loader_ozone.cc b/ui/base/cursor/cursor_loader_ozone.cc
index 1d74eec7345c738bf3ad0b7a3d36549fe3c2300f..5f1ba8ec57c55a8ead4881f196e8e35747482009 100644
--- a/ui/base/cursor/cursor_loader_ozone.cc
+++ b/ui/base/cursor/cursor_loader_ozone.cc
@@ -16,7 +16,7 @@ CursorLoaderOzone::CursorLoaderOzone() {}
CursorLoaderOzone::~CursorLoaderOzone() {}
-void CursorLoaderOzone::LoadImageCursor(int id,
+void CursorLoaderOzone::LoadImageCursor(CursorType id,
int resource_id,
const gfx::Point& hot) {
SkBitmap bitmap;
@@ -28,7 +28,7 @@ void CursorLoaderOzone::LoadImageCursor(int id,
bitmap, hotspot, scale());
}
-void CursorLoaderOzone::LoadAnimatedCursor(int id,
+void CursorLoaderOzone::LoadAnimatedCursor(CursorType id,
int resource_id,
const gfx::Point& hot,
int frame_delay_ms) {
@@ -51,13 +51,13 @@ void CursorLoaderOzone::UnloadAll() {
}
void CursorLoaderOzone::SetPlatformCursor(gfx::NativeCursor* cursor) {
- int native_type = cursor->native_type();
+ CursorType native_type = cursor->native_type();
PlatformCursor platform;
if (cursors_.count(native_type)) {
// An image cursor is loaded for this type.
platform = cursors_[native_type];
- } else if (native_type == kCursorCustom) {
+ } else if (native_type == CursorType::kCustom) {
// The platform cursor was already set via WebCursor::GetPlatformCursor.
platform = cursor->platform();
} else {
« no previous file with comments | « ui/base/cursor/cursor_loader_ozone.h ('k') | ui/base/cursor/cursor_loader_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698