1use crate::{geometry::vector::Vector2F, keymap::Keystroke};
2
3#[derive(Copy, Clone, Debug)]
4pub enum NavigationDirection {
5 Back,
6 Forward,
7}
8
9#[derive(Clone, Debug)]
10pub enum Event {
11 KeyDown {
12 keystroke: Keystroke,
13 input: Option<String>,
14 is_held: bool,
15 },
16 ScrollWheel {
17 position: Vector2F,
18 delta: Vector2F,
19 precise: bool,
20 },
21 LeftMouseDown {
22 position: Vector2F,
23 ctrl: bool,
24 alt: bool,
25 shift: bool,
26 cmd: bool,
27 click_count: usize,
28 },
29 LeftMouseUp {
30 position: Vector2F,
31 },
32 LeftMouseDragged {
33 position: Vector2F,
34 },
35 RightMouseDown {
36 position: Vector2F,
37 ctrl: bool,
38 alt: bool,
39 shift: bool,
40 cmd: bool,
41 click_count: usize,
42 },
43 RightMouseUp {
44 position: Vector2F,
45 },
46 NavigateMouseDown {
47 position: Vector2F,
48 direction: NavigationDirection,
49 ctrl: bool,
50 alt: bool,
51 shift: bool,
52 cmd: bool,
53 click_count: usize,
54 },
55 NavigateMouseUp {
56 position: Vector2F,
57 direction: NavigationDirection,
58 },
59 MouseMoved {
60 position: Vector2F,
61 left_mouse_down: bool,
62 },
63}