summaryrefslogtreecommitdiffstats
path: root/native/src/mouse
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón <hector0193@gmail.com>2020-05-05 00:05:47 +0200
committerLibravatar GitHub <noreply@github.com>2020-05-05 00:05:47 +0200
commit7dc02a5e16a3143b7c3ba9270207e3ebda71d567 (patch)
treedd727f138641fbda008af8e7827369cc99420749 /native/src/mouse
parent27aad74a32fd8ac2b12f9d32df8a3b61a3175457 (diff)
parent93c6be5eef577f0778b5787dac37351c035ed471 (diff)
downloadiced-7dc02a5e16a3143b7c3ba9270207e3ebda71d567.tar.gz
iced-7dc02a5e16a3143b7c3ba9270207e3ebda71d567.tar.bz2
iced-7dc02a5e16a3143b7c3ba9270207e3ebda71d567.zip
Merge pull request #325 from hecrj/feature/canvas-interaction
Canvas interactivity and Game of Life example
Diffstat (limited to '')
-rw-r--r--native/src/mouse.rs6
-rw-r--r--native/src/mouse/click.rs (renamed from native/src/input/mouse/click.rs)0
-rw-r--r--native/src/mouse_cursor.rs36
3 files changed, 6 insertions, 36 deletions
diff --git a/native/src/mouse.rs b/native/src/mouse.rs
new file mode 100644
index 00000000..9ee406cf
--- /dev/null
+++ b/native/src/mouse.rs
@@ -0,0 +1,6 @@
+//! Track mouse events.
+
+pub mod click;
+
+pub use click::Click;
+pub use iced_core::mouse::*;
diff --git a/native/src/input/mouse/click.rs b/native/src/mouse/click.rs
index d27bc67e..d27bc67e 100644
--- a/native/src/input/mouse/click.rs
+++ b/native/src/mouse/click.rs
diff --git a/native/src/mouse_cursor.rs b/native/src/mouse_cursor.rs
deleted file mode 100644
index 0dad3edc..00000000
--- a/native/src/mouse_cursor.rs
+++ /dev/null
@@ -1,36 +0,0 @@
-/// The state of the mouse cursor.
-#[derive(Debug, Eq, PartialEq, Clone, Copy, PartialOrd, Ord)]
-pub enum MouseCursor {
- /// The cursor is out of the bounds of the user interface.
- OutOfBounds,
-
- /// The cursor is over a non-interactive widget.
- Idle,
-
- /// The cursor is over a clickable widget.
- Pointer,
-
- /// The cursor is over a busy widget.
- Working,
-
- /// The cursor is over a grabbable widget.
- Grab,
-
- /// The cursor is grabbing a widget.
- Grabbing,
-
- /// The cursor is over a text widget.
- Text,
-
- /// The cursor is resizing a widget horizontally.
- ResizingHorizontally,
-
- /// The cursor is resizing a widget vertically.
- ResizingVertically,
-}
-
-impl Default for MouseCursor {
- fn default() -> MouseCursor {
- MouseCursor::OutOfBounds
- }
-}