aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib.rs')
-rw-r--r--src/lib.rs17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/lib.rs b/src/lib.rs
index bdf7975..3fdf4f3 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -198,6 +198,23 @@ pub enum MouseCursor {
RowResize,
}
+/// Describes how glutin handles the cursor.
+#[derive(Debug, Copy)]
+pub enum CursorState {
+ /// Normal cursor behavior.
+ Normal,
+
+ /// The cursor will be invisible when over the window.
+ Hide,
+
+ /// Grabs the mouse cursor. The cursor's motion will be confined to this
+ /// window and the window has exclusive access to further events regarding
+ /// the cursor.
+ ///
+ /// This is useful for first-person cameras for example.
+ Grab,
+}
+
/// Describes a possible format. Unused.
#[allow(missing_docs)]
#[derive(Debug, Clone)]