InputDevice
Object Hierarchy:
Description:
Generic representation of an input device.
The actual contents of this structure depend on the backend used.
Namespace: Clutter
Package: clutter-1.0
Content:
Properties:
- public Backend backend { owned get; construct; }
The Backend that created the device.
- public DeviceManager device_manager { owned get; construct; }
The DeviceManager instance which owns the device
- public InputMode device_mode { get; construct; }
- public InputDeviceType device_type { get; construct; }
The type of the device
- public bool enabled { get; set; }
Whether the device is enabled.
- public bool has_cursor { get; construct; }
Whether the device has an on screen cursor following its movement.
- public int id { get; construct; }
The unique identifier of the device
- public uint n_axes { get; }
The number of axes of the device.
- public string name { owned get; construct; }
The name of the device
- public string product_id { get; construct; }
Product ID of this device.
- public string vendor_id { get; construct; }
Vendor ID of this device.
Static methods:
- public static unowned InputDevice get_for_id (int id_)
Retrieves the InputDevice from its
id_
.
Creation methods:
- protected InputDevice ()
Methods:
- public unowned InputDevice get_associated_device ()
Retrieves a pointer to the InputDevice that has been associated to this.
- public InputAxis get_axis (uint index_)
Retrieves the type of axis on this at the given index.
- public bool get_axis_value (double[] axes, InputAxis axis, out double value)
Extracts the value of the given
axis
of a InputDevice from an array of axis values. - public bool get_coords (EventSequence? sequence, out Point point)
Retrieves the latest coordinates of a pointer or touch point of this.
- public void get_device_coords (out int x, out int y)
Retrieves the latest coordinates of the pointer of this
- public int get_device_id ()
Retrieves the unique identifier of this
- public InputMode get_device_mode ()
Retrieves the InputMode of this.
- public unowned string get_device_name ()
Retrieves the name of the this
- public InputDeviceType get_device_type ()
Retrieves the type of this
- public bool get_enabled ()
Retrieves whether this is enabled.
- public unowned Actor get_grabbed_actor ()
Retrieves a pointer to the Actor currently grabbing all the events coming from this.
- public bool get_has_cursor ()
Retrieves whether this has a pointer that follows the device motion.
- public bool get_key (uint index_, out uint keyval, out ModifierType modifiers)
Retrieves the key set using set_key
- public ModifierType get_modifier_state ()
Retrieves the current modifiers state of the device, as seen by the last event Clutter processed.
- public uint get_n_axes ()
Retrieves the number of axes available on this .
- public uint get_n_keys ()
Retrieves the number of keys registered for this .
- public unowned Actor get_pointer_actor ()
Retrieves the Actor underneath the pointer of this
- public unowned Stage get_pointer_stage ()
Retrieves the Stage underneath the pointer of this
- public unowned string get_product_id ()
Gets the product ID of this device.
- public List<unowned InputDevice> get_slave_devices ()
Retrieves the slave devices attached to this .
- public unowned string get_vendor_id ()
Gets the vendor ID of this device.
- public void grab (Actor actor)
Acquires a grab on
actor
for the given this. - public bool keycode_to_evdev (uint hardware_keycode, uint evdev_keycode)
Translates a hardware keycode from a KeyEvent to the equivalent evdev keycode.
- public unowned Actor sequence_get_grabbed_actor (EventSequence sequence)
Retrieves a pointer to the Actor currently grabbing the touch events coming from this given the
sequence
. - public void sequence_grab (EventSequence sequence, Actor actor)
Acquires a grab on
actor
for the given this and the given touchsequence
. - public void sequence_ungrab (EventSequence sequence)
Releases the grab on the this for the given
sequence
, if one is in place. - public void set_enabled (bool enabled)
Enables or disables a InputDevice.
- public void set_key (uint index_, uint keyval, ModifierType modifiers)
Sets the keyval and modifiers at the given
index_
for this. - public void ungrab ()
Releases the grab on the this, if one is in place.
- public void update_from_event (Event event, bool update_stage)
Forcibly updates the state of the this using a Event
Inherited Members:
All known members inherited from class GLib.Object