1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
//! Contains methods for interacting with the pointer
//! and keyboard of wlc.

pub mod pointer {
//! Methods for interacting with the mouse
    use super::super::types::{Point};

    /// Gets the current position of the mouse.
    pub fn get_position() -> Point {
        let point = Point { x: 0, y: 0 };
        return point;
    }

    pub fn get_position_v2() -> (f64, f64) {
        (0.0,0.0)
    }

    /// Sets the current mouse position. Required on mouse move callback.
    pub fn set_position(point: Point) {
    }

    pub fn set_position_v2(_: f64, _: f64) {}
}

pub mod keyboard {
//! Methods for interacting with the keyboard
    use super::super::types::{KeyboardModifiers};
    use super::super::xkb::Keysym;

    /// Get currently held keys.
    /// # Panics
    /// All the time, this function hasn't been implemented yet
    pub fn get_current_keys<'a>() -> &'a[u32] {
        unimplemented!();
    }

    /// Gets a keysym given a key and modifiers.
    pub fn get_keysym_for_key(key: u32, modifiers: KeyboardModifiers) -> Keysym {
        unimplemented!()
    }

    /// Gets a UTF32 value for a given key and modifiers.
    pub fn get_utf32_for_key(key: u32, modifiers: KeyboardModifiers) -> u32 {
        unimplemented!()
    }
}