pub struct SystemMouseCursor { /* private fields */ }Expand description
A mouse cursor that is natively supported on the platform that the application is running on.
System cursors can be used without external resources, and their appearances match the experience of native apps. Examples of system cursors are a pointing arrow, a pointing hand, a double arrow for resizing, or a text I-beam, etc.
An instance of SystemMouseCursor refers to one cursor from each platform
that represents the same concept, such as being text, being clickable, or
being a forbidden operation. Since the set of system cursors supported by each
platform varies, multiple instances can correspond to the same system cursor.
Each cursor is noted with its corresponding native cursors on each platform:
- Android: API name in Java
- Web: CSS cursor
- Windows: Win32 API
- Linux: GDK,
gdk_cursor_new_from_name - macOS: API name in ObjectiveC
If the platform that the application is running on is not listed for a
cursor, using this cursor falls back to SystemMouseCursors::BASIC.
SystemMouseCursors enumerates the complete set of system cursors supported
by Flutter, which are hard-coded in the engine. Therefore, manually
instantiating this class is not supported.
Implementations§
Source§impl SystemMouseCursor
impl SystemMouseCursor
Sourcepub fn kind(&self) -> SystemMouseCursorKind
pub fn kind(&self) -> SystemMouseCursorKind
The kind of the cursor.
The interpretation of kind is platform-dependent.
Trait Implementations§
Source§impl Clone for SystemMouseCursor
impl Clone for SystemMouseCursor
impl Copy for SystemMouseCursor
Source§impl Debug for SystemMouseCursor
impl Debug for SystemMouseCursor
impl Eq for SystemMouseCursor
Source§impl From<SystemMouseCursor> for MouseCursorRef
impl From<SystemMouseCursor> for MouseCursorRef
Source§fn from(cursor: SystemMouseCursor) -> MouseCursorRef
fn from(cursor: SystemMouseCursor) -> MouseCursorRef
Source§impl Hash for SystemMouseCursor
impl Hash for SystemMouseCursor
Source§impl MouseCursor for SystemMouseCursor
impl MouseCursor for SystemMouseCursor
Source§fn create_session(&self, device: i64) -> Box<dyn MouseCursorSession>
fn create_session(&self, device: i64) -> Box<dyn MouseCursorSession>
Source§fn debug_description(&self) -> String
fn debug_description(&self) -> String
Source§fn eq_cursor(&self, other: &dyn MouseCursor) -> bool
fn eq_cursor(&self, other: &dyn MouseCursor) -> bool
==. Identity unless a class overrides it, as SystemMouseCursor does.Source§impl PartialEq for SystemMouseCursor
impl PartialEq for SystemMouseCursor
impl StructuralPartialEq for SystemMouseCursor
Auto Trait Implementations§
impl Freeze for SystemMouseCursor
impl RefUnwindSafe for SystemMouseCursor
impl Send for SystemMouseCursor
impl Sync for SystemMouseCursor
impl Unpin for SystemMouseCursor
impl UnsafeUnpin for SystemMouseCursor
impl UnwindSafe for SystemMouseCursor
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.