From bfb2792d3cd8ebc9abf8586dd683211bced7eabe Mon Sep 17 00:00:00 2001 From: Raphael Date: Thu, 28 Jul 2022 17:14:50 +0800 Subject: [PATCH] feat: add current cursor and currentsystem cursor --- src/appkit/cursor.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/appkit/cursor.rs b/src/appkit/cursor.rs index 99f5688..935880a 100644 --- a/src/appkit/cursor.rs +++ b/src/appkit/cursor.rs @@ -9,6 +9,12 @@ pub enum CursorType { /// A standard arrow. Arrow, + /// Current Cusrosr + Current, + + /// Current System cursor + CurrentSystem, + /// A crosshair. Crosshair, @@ -96,6 +102,8 @@ impl Cursor { unsafe { let cursor: id = match cursor_type { CursorType::Arrow => msg_send![class!(NSCursor), arrowCursor], + CursorType::Current => msg_send![class!(NSCursor), currentCursor], + CursorType::CurrentSystem => msg_send![class!(NSCursor), currentSystemCursor], CursorType::Crosshair => msg_send![class!(NSCursor), crosshairCursor], CursorType::ClosedHand => msg_send![class!(NSCursor), closedHandCursor], CursorType::OpenHand => msg_send![class!(NSCursor), openHandCursor],