summaryrefslogtreecommitdiff
path: root/src/lib/elm_gesture_layer.eo
blob: 56520cccbbcd7571f04315fca16ceec653d2ed99 (plain)
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
class Elm_Gesture_Layer (Elm.Widget)
{
   eo_prefix: elm_obj_gesture_layer;
   properties {
      zoom_step {
         set {
            /*@
            This function sets step-value for zoom action.
            Set step to any positive value.
            Cancel step setting by setting to 0

            @see elm_gesture_layer_zoom_step_get()
            @ingroup Elm_Gesture_Layer
             */
         }
         get {
            /*@
            This function returns step-value for zoom action.

            @return zoom step value.

            @see elm_gesture_layer_zoom_step_set()
            @ingroup Elm_Gesture_Layer
             */
         }
         values {
            double step; /*@ new zoom step value. */
         }
      }
      tap_finger_size {
         set {
            /*@
            This function sets the gesture layer finger-size for taps
            If not set, this size taken from elm_config.
            Set to ZERO if you want GLayer to use system finger size value (default)

            @since 1.8
            @ingroup Elm_Gesture_Layer
             */
         }
         get {
            /*@
            This function returns the gesture layer finger-size for taps

            @return Finger size that is currently used by Gesture Layer for taps.

            @since 1.8
            @ingroup Elm_Gesture_Layer
             */
         }
         values {
            Evas_Coord sz; /*@ Finger size */
         }
      }
      hold_events {
         set {
            /*@
            This function is to make gesture-layer repeat events.
            Set this if you like to get the raw events only if gestures were not
            detected.
            Clear this if you like gesture layer to forward events as testing gestures.
            @ingroup Elm_Gesture_Layer
             */
         }
         get {
            /*@
            Call this function to get repeat-events settings.

            @return repeat events settings.
            @see elm_gesture_layer_hold_events_set()
            @ingroup Elm_Gesture_Layer
             */
         }
         values {
            bool hold_events; /*@ hold events or not. */
         }
      }
      rotate_step {
         set {
            /*@
            This function sets step-value for rotate action.
            Set step to any positive value.
            Cancel step setting by setting to 0
            @ingroup Elm_Gesture_Layer
             */
         }
         get {
            /*@
            This function returns step-value for rotate action.

            @return rotate step value.
            @ingroup Elm_Gesture_Layer
             */
         }
         values {
            double step; /*@ new rotate step value. */
         }
      }
      cb {
         set {
            /*@
            Use function to set callbacks to be notified about
            change of state of gesture.
            When a user registers a callback with this function
            this means this gesture has to be tested.

            When ALL callbacks for a gesture are set to NULL
            it means user isn't interested in gesture-state
            and it will not be tested.
            @ingroup Elm_Gesture_Layer
             */
         }
         values {
            Elm_Gesture_Type idx; /*@ The gesture you would like to track its state. */
            Elm_Gesture_State cb_type; /*@ what event this callback tracks: START, MOVE, END, ABORT. */
            Elm_Gesture_Event_Cb cb; /*@ callback function pointer. */
            void *data; /*@ user info to be sent to callback (usually, Smart Data) */
         }
      }
   }
   methods {
      attach {
         /*@
         Attach a given gesture layer widget to an Evas object, thus setting
         the widget's @b target.

         A gesture layer target may be whichever Evas object one
         chooses. This will be object @a obj will listen all mouse and key
         events from, to report the gestures made upon it back.

         @return @c EINA_TRUE, on success, @c EINA_FALSE otherwise.
         @ingroup Elm_Gesture_Layer
          */

         return: bool;
         params {
            @in Evas_Object *target; /*@ Object to attach to @a obj (target) */
         }
      }
      cb_del {
         /*@
         Use this function to remove a callback that has been added
         to be notified about change of state of gesture.
         @ingroup Elm_Gesture_Layer
          */

         params {
            @in Elm_Gesture_Type idx; /*@ The gesture you would like to track its state. */
            @in Elm_Gesture_State cb_type; /*@ what event this callback tracks: START, MOVE, END, ABORT. */
            @in Elm_Gesture_Event_Cb cb; /*@ callback function pointer. */
            @in void *data; /*@ user info for the callback (usually, Smart Data) */
         }
      }
      cb_add {
         /*@
         Use function to add callbacks to be notified about
         change of state of gesture.
         When a user registers a callback with this function
         this means this gesture has to be tested.

         When ALL callbacks for a gesture are set to NULL
         it means user isn't interested in gesture-state
         and it will not be tested.

         If a function was already set for this gesture/type/state, it will be
         replaced by the new one. For ABI compat, callbacks added by
         elm_gesture_layer_cb_add will be removed. It is recommended to
         use only one of these functions for a gesture object.
         @ingroup Elm_Gesture_Layer
          */

         params {
            @in Elm_Gesture_Type idx; /*@ The gesture you would like to track its state. */
            @in Elm_Gesture_State cb_type; /*@ what event this callback tracks: START, MOVE, END, ABORT. */
            @in Elm_Gesture_Event_Cb cb; /*@ callback function pointer. */
            @in void *data; /*@ user info to be sent to callback (usually, Smart Data) */
         }
      }
   }
   implements {
      class.constructor;
      Eo.Base.constructor;
      Evas.Object_Smart.add;
      Evas.Object_Smart.del;
      Elm.Widget.disable;
   }

}