summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/lib/evas/canvas/efl_event_hold.c17
-rw-r--r--src/lib/evas/canvas/efl_event_hold.eo12
-rw-r--r--src/lib/evas/canvas/efl_event_input.c38
-rw-r--r--src/lib/evas/canvas/efl_event_input.eo7
-rw-r--r--src/lib/evas/canvas/efl_event_key.c30
-rw-r--r--src/lib/evas/canvas/efl_event_key.eo4
-rw-r--r--src/lib/evas/canvas/efl_event_pointer.c30
-rw-r--r--src/lib/evas/canvas/efl_event_pointer.eo4
8 files changed, 61 insertions, 81 deletions
diff --git a/src/lib/evas/canvas/efl_event_hold.c b/src/lib/evas/canvas/efl_event_hold.c
index 4f169da..700d486 100644
--- a/src/lib/evas/canvas/efl_event_hold.c
+++ b/src/lib/evas/canvas/efl_event_hold.c
@@ -24,13 +24,13 @@ _efl_event_hold_hold_get(Eo *obj EINA_UNUSED, Efl_Event_Hold_Data *pd)
24} 24}
25 25
26EOLIAN static void 26EOLIAN static void
27_efl_event_hold_device_set(Eo *obj EINA_UNUSED, Efl_Event_Hold_Data *pd, Efl_Input_Device *dev) 27_efl_event_hold_efl_event_input_device_set(Eo *obj EINA_UNUSED, Efl_Event_Hold_Data *pd, Efl_Input_Device *dev)
28{ 28{
29 pd->device = dev; 29 pd->device = dev;
30} 30}
31 31
32EOLIAN static Efl_Input_Device * 32EOLIAN static Efl_Input_Device *
33_efl_event_hold_device_get(Eo *obj EINA_UNUSED, Efl_Event_Hold_Data *pd) 33_efl_event_hold_efl_event_input_device_get(Eo *obj EINA_UNUSED, Efl_Event_Hold_Data *pd)
34{ 34{
35 return pd->device; 35 return pd->device;
36} 36}
@@ -47,6 +47,19 @@ _efl_event_hold_efl_event_timestamp_set(Eo *obj EINA_UNUSED, Efl_Event_Hold_Data
47 pd->timestamp = ms; 47 pd->timestamp = ms;
48} 48}
49 49
50EOLIAN static void
51_efl_event_hold_efl_event_input_event_flags_set(Eo *obj EINA_UNUSED, Efl_Event_Hold_Data *pd EINA_UNUSED, Efl_Event_Flags flags EINA_UNUSED)
52{
53 // ignore
54}
55
56EOLIAN static Efl_Event_Flags
57_efl_event_hold_efl_event_input_event_flags_get(Eo *obj EINA_UNUSED, Efl_Event_Hold_Data *pd EINA_UNUSED)
58{
59 // ignore
60 return 0;
61}
62
50EOLIAN static Eo * 63EOLIAN static Eo *
51_efl_event_hold_eo_base_constructor(Eo *obj, Efl_Event_Hold_Data *pd) 64_efl_event_hold_eo_base_constructor(Eo *obj, Efl_Event_Hold_Data *pd)
52{ 65{
diff --git a/src/lib/evas/canvas/efl_event_hold.eo b/src/lib/evas/canvas/efl_event_hold.eo
index 4380c9f..07e8fcf 100644
--- a/src/lib/evas/canvas/efl_event_hold.eo
+++ b/src/lib/evas/canvas/efl_event_hold.eo
@@ -8,13 +8,6 @@ class Efl.Event.Hold (Eo.Base, Efl.Event.Input)
8 val: bool; 8 val: bool;
9 } 9 }
10 } 10 }
11 @property device {
12 [[Input device that is now on hold or resumed.]]
13 values {
14 dev: Efl.Input.Device;
15 }
16 }
17 /* FIXME: does not expose event_flags - is it necessary? */
18 } 11 }
19 implements { 12 implements {
20 Eo.Base.constructor; 13 Eo.Base.constructor;
@@ -23,5 +16,10 @@ class Efl.Event.Hold (Eo.Base, Efl.Event.Input)
23 Efl.Event.dup; 16 Efl.Event.dup;
24 Efl.Event.timestamp.get; 17 Efl.Event.timestamp.get;
25 Efl.Event.timestamp.set; 18 Efl.Event.timestamp.set;
19 //Efl.Event.Input.fake.get;
20 Efl.Event.Input.event_flags.set;
21 Efl.Event.Input.event_flags.get;
22 Efl.Event.Input.device.set;
23 Efl.Event.Input.device.get;
26 } 24 }
27} 25}
diff --git a/src/lib/evas/canvas/efl_event_input.c b/src/lib/evas/canvas/efl_event_input.c
index cc004f7..a4c313d 100644
--- a/src/lib/evas/canvas/efl_event_input.c
+++ b/src/lib/evas/canvas/efl_event_input.c
@@ -7,6 +7,42 @@
7#define EFL_INTERNAL_UNSTABLE 7#define EFL_INTERNAL_UNSTABLE
8#include "interfaces/efl_common_internal.h" 8#include "interfaces/efl_common_internal.h"
9 9
10#define MY_CLASS EFL_EVENT_INPUT_CLASS 10#define MY_CLASS EFL_EVENT_INPUT_MIXIN
11
12EOLIAN static void
13_efl_event_input_processed_set(Eo *obj, void *pd EINA_UNUSED, Eina_Bool val)
14{
15 if (val)
16 efl_event_flags_set(obj, efl_event_flags_get(obj) | EFL_EVENT_FLAGS_PROCESSED);
17 else
18 efl_event_flags_set(obj, efl_event_flags_get(obj) & ~EFL_EVENT_FLAGS_PROCESSED);
19}
20
21EOLIAN static Eina_Bool
22_efl_event_input_processed_get(Eo *obj EINA_UNUSED, void *pd EINA_UNUSED)
23{
24 return !!(efl_event_flags_get(obj) & EFL_EVENT_FLAGS_PROCESSED);
25}
26
27EOLIAN static void
28_efl_event_input_scrolling_set(Eo *obj EINA_UNUSED, void *pd EINA_UNUSED, Eina_Bool val)
29{
30 if (val)
31 efl_event_flags_set(obj, efl_event_flags_get(obj) | EFL_EVENT_FLAGS_SCROLLING);
32 else
33 efl_event_flags_set(obj, efl_event_flags_get(obj) & ~EFL_EVENT_FLAGS_SCROLLING);
34}
35
36EOLIAN static Eina_Bool
37_efl_event_input_scrolling_get(Eo *obj EINA_UNUSED, void *pd EINA_UNUSED)
38{
39 return !!(efl_event_flags_get(obj) & EFL_EVENT_FLAGS_SCROLLING);
40}
41
42EOLIAN static Eina_Bool
43_efl_event_input_fake_get(Eo *obj EINA_UNUSED, void *pd EINA_UNUSED)
44{
45 return EINA_FALSE;
46}
11 47
12#include "efl_event_input.eo.c" 48#include "efl_event_input.eo.c"
diff --git a/src/lib/evas/canvas/efl_event_input.eo b/src/lib/evas/canvas/efl_event_input.eo
index 6e2e6cc..b23fdfa 100644
--- a/src/lib/evas/canvas/efl_event_input.eo
+++ b/src/lib/evas/canvas/efl_event_input.eo
@@ -1,16 +1,17 @@
1import efl_event_types; 1import efl_event_types;
2 2
3interface Efl.Event.Input (Efl.Event) 3mixin Efl.Event.Input (Efl.Event)
4{ 4{
5 eo_prefix: efl_event; 5 eo_prefix: efl_event;
6 data: null;
6 methods { 7 methods {
7 @property device { 8 @property device @virtual_pure {
8 [[Input device that originated this event.]] 9 [[Input device that originated this event.]]
9 values { 10 values {
10 dev: Efl.Input.Device; 11 dev: Efl.Input.Device;
11 } 12 }
12 } 13 }
13 @property event_flags { 14 @property event_flags @virtual_pure {
14 [[Extra flags for this event, may be changed by the user.]] 15 [[Extra flags for this event, may be changed by the user.]]
15 values { 16 values {
16 flags: Efl.Event.Flags; 17 flags: Efl.Event.Flags;
diff --git a/src/lib/evas/canvas/efl_event_key.c b/src/lib/evas/canvas/efl_event_key.c
index 421e557..bce7c7c 100644
--- a/src/lib/evas/canvas/efl_event_key.c
+++ b/src/lib/evas/canvas/efl_event_key.c
@@ -208,36 +208,6 @@ _efl_event_key_efl_event_input_event_flags_get(Eo *obj EINA_UNUSED, Efl_Event_Ke
208} 208}
209 209
210EOLIAN static void 210EOLIAN static void
211_efl_event_key_efl_event_input_processed_set(Eo *obj EINA_UNUSED, Efl_Event_Key_Data *pd, Eina_Bool val)
212{
213 if (val)
214 pd->event_flags |= EFL_EVENT_FLAGS_PROCESSED;
215 else
216 pd->event_flags &= ~EFL_EVENT_FLAGS_PROCESSED;
217}
218
219EOLIAN static Eina_Bool
220_efl_event_key_efl_event_input_processed_get(Eo *obj EINA_UNUSED, Efl_Event_Key_Data *pd)
221{
222 return !!(pd->event_flags & EFL_EVENT_FLAGS_PROCESSED);
223}
224
225EOLIAN static void
226_efl_event_key_efl_event_input_scrolling_set(Eo *obj EINA_UNUSED, Efl_Event_Key_Data *pd, Eina_Bool val)
227{
228 if (val)
229 pd->event_flags |= EFL_EVENT_FLAGS_SCROLLING;
230 else
231 pd->event_flags &= ~EFL_EVENT_FLAGS_SCROLLING;
232}
233
234EOLIAN static Eina_Bool
235_efl_event_key_efl_event_input_scrolling_get(Eo *obj EINA_UNUSED, Efl_Event_Key_Data *pd)
236{
237 return !!(pd->event_flags & EFL_EVENT_FLAGS_SCROLLING);
238}
239
240EOLIAN static void
241_efl_event_key_efl_event_input_device_set(Eo *obj EINA_UNUSED, Efl_Event_Key_Data *pd, Efl_Input_Device *dev) 211_efl_event_key_efl_event_input_device_set(Eo *obj EINA_UNUSED, Efl_Event_Key_Data *pd, Efl_Input_Device *dev)
242{ 212{
243 pd->device = dev; 213 pd->device = dev;
diff --git a/src/lib/evas/canvas/efl_event_key.eo b/src/lib/evas/canvas/efl_event_key.eo
index 9ca7515..897dd46 100644
--- a/src/lib/evas/canvas/efl_event_key.eo
+++ b/src/lib/evas/canvas/efl_event_key.eo
@@ -62,10 +62,6 @@ class Efl.Event.Key (Eo.Base, Efl.Event, Efl.Input.State, Efl.Event.Input)
62 Efl.Event.Input.fake.get; 62 Efl.Event.Input.fake.get;
63 Efl.Event.Input.event_flags.set; 63 Efl.Event.Input.event_flags.set;
64 Efl.Event.Input.event_flags.get; 64 Efl.Event.Input.event_flags.get;
65 Efl.Event.Input.processed.set;
66 Efl.Event.Input.processed.get;
67 Efl.Event.Input.scrolling.set;
68 Efl.Event.Input.scrolling.get;
69 Efl.Event.Input.device.set; 65 Efl.Event.Input.device.set;
70 Efl.Event.Input.device.get; 66 Efl.Event.Input.device.get;
71 Efl.Input.State.modifier_enabled.get; 67 Efl.Input.State.modifier_enabled.get;
diff --git a/src/lib/evas/canvas/efl_event_pointer.c b/src/lib/evas/canvas/efl_event_pointer.c
index db1d662..637f19f 100644
--- a/src/lib/evas/canvas/efl_event_pointer.c
+++ b/src/lib/evas/canvas/efl_event_pointer.c
@@ -377,36 +377,6 @@ _efl_event_pointer_triple_click_get(Eo *obj EINA_UNUSED, Efl_Event_Pointer_Data
377 return !!(pd->button_flags & EFL_POINTER_FLAGS_TRIPLE_CLICK); 377 return !!(pd->button_flags & EFL_POINTER_FLAGS_TRIPLE_CLICK);
378} 378}
379 379
380EOLIAN static void
381_efl_event_pointer_efl_event_input_processed_set(Eo *obj EINA_UNUSED, Efl_Event_Pointer_Data *pd, Eina_Bool val)
382{
383 if (val)
384 pd->event_flags |= EFL_EVENT_FLAGS_PROCESSED;
385 else
386 pd->event_flags &= ~EFL_EVENT_FLAGS_PROCESSED;
387}
388
389EOLIAN static Eina_Bool
390_efl_event_pointer_efl_event_input_processed_get(Eo *obj EINA_UNUSED, Efl_Event_Pointer_Data *pd)
391{
392 return !!(pd->event_flags & EFL_EVENT_FLAGS_PROCESSED);
393}
394
395EOLIAN static void
396_efl_event_pointer_efl_event_input_scrolling_set(Eo *obj EINA_UNUSED, Efl_Event_Pointer_Data *pd, Eina_Bool val)
397{
398 if (val)
399 pd->event_flags |= EFL_EVENT_FLAGS_SCROLLING;
400 else
401 pd->event_flags &= ~EFL_EVENT_FLAGS_SCROLLING;
402}
403
404EOLIAN static Eina_Bool
405_efl_event_pointer_efl_event_input_scrolling_get(Eo *obj EINA_UNUSED, Efl_Event_Pointer_Data *pd)
406{
407 return !!(pd->event_flags & EFL_EVENT_FLAGS_SCROLLING);
408}
409
410EOLIAN static Eina_Bool 380EOLIAN static Eina_Bool
411_efl_event_pointer_efl_event_input_fake_get(Eo *obj EINA_UNUSED, Efl_Event_Pointer_Data *pd) 381_efl_event_pointer_efl_event_input_fake_get(Eo *obj EINA_UNUSED, Efl_Event_Pointer_Data *pd)
412{ 382{
diff --git a/src/lib/evas/canvas/efl_event_pointer.eo b/src/lib/evas/canvas/efl_event_pointer.eo
index 2a9e7c8..1fbac08 100644
--- a/src/lib/evas/canvas/efl_event_pointer.eo
+++ b/src/lib/evas/canvas/efl_event_pointer.eo
@@ -137,10 +137,6 @@ class Efl.Event.Pointer (Eo.Base, Efl.Event, Efl.Input.State, Efl.Event.Input)
137 Efl.Event.Input.fake.get; 137 Efl.Event.Input.fake.get;
138 Efl.Event.Input.event_flags.set; 138 Efl.Event.Input.event_flags.set;
139 Efl.Event.Input.event_flags.get; 139 Efl.Event.Input.event_flags.get;
140 Efl.Event.Input.processed.set;
141 Efl.Event.Input.processed.get;
142 Efl.Event.Input.scrolling.set;
143 Efl.Event.Input.scrolling.get;
144 Efl.Event.Input.device.set; 140 Efl.Event.Input.device.set;
145 Efl.Event.Input.device.get; 141 Efl.Event.Input.device.get;
146 Efl.Input.State.modifier_enabled.get; 142 Efl.Input.State.modifier_enabled.get;