efl/src/lib/evas/canvas/efl_pointer_event.eo

127 lines
3.3 KiB
Plaintext
Raw Normal View History

import efl_orientation;
import efl_event_types;
class Efl.Pointer.Event (Eo.Base, Efl.Event, Efl.Input.State)
{
[[Event data carried over with any pointer event (mouse, touch, ...)
@since 1.18
]]
methods {
@property action {
[[The action represented by this event.]]
values {
act: Efl.Pointer.Action;
}
}
@property button {
[[The mouse button that triggered the event.]]
values {
but: int; [[1 to 32, 0 if not a button event.]]
}
}
@property button_pressed {
[[Whether a mouse button is pressed at the moment of the event.]]
keys {
button: int;
}
values {
pressed: bool;
}
}
/* FIXME: output vs. canvas position??? */
@property position {
[[Position where the event happened, relative to the window.]]
values {
x: int;
y: int;
xsub: double;
ysub: double;
}
}
@property previous_position {
[[Position of the previous event, valid for move events.
Relative to the window. May be equal to @.position.
]]
values {
x: int;
y: int;
}
}
@property device {
[[Pointing device that originated this event.]]
values {
dev: Efl.Input.Device;
}
}
@property finger {
[[Finger ID in case of a multi touch event.]]
values {
id: int;
}
}
@property touch {
[[Touch information about a specific finger or pointer.]]
values {
radius: double;
rad_x: double;
rad_y: double;
pressure: double;
angle: double;
}
}
@property source {
[[The object where this event first originated, in case of
propagation or repetition of the event.
]]
values {
src: Eo.Base; [[Source object: $Efl.Gfx]]
}
}
/* FIXME: why not double_click() and triple_click() */
@property button_flags {
[[Double or triple click information.]]
values {
flags: Efl.Pointer.Button_Flags;
}
}
@property event_flags {
[[Extra flags for this event, may be changed by the user.]]
values {
flags: Efl.Pointer.Event_Flags;
}
}
@property wheel_direction {
values {
dir: Efl.Orient; [[Horizontal or Vertical only.]]
}
}
@property wheel_distance {
values {
dist: int;
}
}
instance_get @class {
[[Creates an instance of this events or returns a fresh one from
a memory pool.
]]
params {
@in owner: Eo.Base; [[The parent object.]]
@out priv: void*; [[Pointer to the internal data of the object.]]
}
return: own(Efl.Pointer.Event);
}
}
implements {
Eo.Base.constructor;
class.destructor;
Efl.Event.reset;
Efl.Event.dup;
Efl.Event.timestamp.set;
Efl.Event.timestamp.get;
Efl.Input.State.modifier_enabled.get;
Efl.Input.State.lock_enabled.get;
}
}