reflexion 0.1.21 → 0.1.22
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.doc/ext/reflex/contact_event.cpp +6 -6
- data/.doc/ext/reflex/focus_event.cpp +6 -6
- data/.doc/ext/reflex/key_event.cpp +210 -12
- data/.doc/ext/reflex/pointer_event.cpp +21 -21
- data/VERSION +1 -1
- data/ext/reflex/contact_event.cpp +6 -6
- data/ext/reflex/focus_event.cpp +6 -6
- data/ext/reflex/key_event.cpp +211 -12
- data/ext/reflex/pointer_event.cpp +21 -21
- data/include/reflex/defs.h +143 -91
- data/lib/reflex/application.rb +3 -3
- data/lib/reflex/autoinit.rb +1 -1
- data/lib/reflex/button.rb +7 -7
- data/lib/reflex/capture_event.rb +7 -7
- data/lib/reflex/contact_event.rb +4 -4
- data/lib/reflex/draw_event.rb +2 -2
- data/lib/reflex/ellipse_shape.rb +2 -2
- data/lib/reflex/focus_event.rb +4 -4
- data/lib/reflex/frame_event.rb +5 -5
- data/lib/reflex/helper.rb +20 -20
- data/lib/reflex/image_view.rb +2 -2
- data/lib/reflex/key_event.rb +5 -5
- data/lib/reflex/model.rb +22 -22
- data/lib/reflex/model_owner.rb +7 -7
- data/lib/reflex/model_view.rb +1 -1
- data/lib/reflex/module.rb +5 -5
- data/lib/reflex/pointer_event.rb +12 -12
- data/lib/reflex/polygon_shape.rb +2 -2
- data/lib/reflex/reflex.rb +3 -3
- data/lib/reflex/scroll_event.rb +1 -1
- data/lib/reflex/selector.rb +4 -4
- data/lib/reflex/shape.rb +13 -13
- data/lib/reflex/style.rb +11 -11
- data/lib/reflex/style_length.rb +1 -1
- data/lib/reflex/text_view.rb +2 -2
- data/lib/reflex/timer.rb +2 -2
- data/lib/reflex/timer_event.rb +1 -1
- data/lib/reflex/update_event.rb +1 -1
- data/lib/reflex/view.rb +32 -32
- data/lib/reflex/wheel_event.rb +3 -3
- data/lib/reflex/window.rb +5 -5
- data/lib/reflexion.rb +17 -17
- data/reflex.gemspec +4 -4
- data/samples/reflexion/noise.rb +1 -1
- data/samples/tree.rb +1 -1
- data/src/ios/window.mm +1 -1
- data/src/osx/event.h +8 -0
- data/src/osx/event.mm +173 -1
- data/src/osx/native_window.mm +5 -1
- data/src/view.cpp +38 -10
- data/src/window.cpp +1 -1
- data/test/helper.rb +3 -3
- data/test/test_application.rb +1 -1
- data/test/test_capture_event.rb +6 -6
- data/test/test_event.rb +2 -2
- data/test/test_has_frame.rb +11 -11
- data/test/test_pointer_event.rb +13 -13
- data/test/test_reflex.rb +1 -1
- data/test/test_selector.rb +8 -8
- data/test/test_shape.rb +8 -8
- data/test/test_style.rb +13 -13
- data/test/test_style_length.rb +5 -5
- data/test/test_view.rb +30 -30
- data/test/test_window.rb +10 -10
- metadata +10 -10
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.22
|
@@ -42,7 +42,7 @@ RUCY_DEF1(initialize_copy, obj)
|
|
42
42
|
RUCY_END
|
43
43
|
|
44
44
|
static
|
45
|
-
RUCY_DEF0(
|
45
|
+
RUCY_DEF0(get_type)
|
46
46
|
{
|
47
47
|
CHECK;
|
48
48
|
return value(THIS->type);
|
@@ -50,7 +50,7 @@ RUCY_DEF0(type)
|
|
50
50
|
RUCY_END
|
51
51
|
|
52
52
|
static
|
53
|
-
RUCY_DEF0(
|
53
|
+
RUCY_DEF0(get_shape)
|
54
54
|
{
|
55
55
|
CHECK;
|
56
56
|
return value(THIS->shape);
|
@@ -58,7 +58,7 @@ RUCY_DEF0(shape)
|
|
58
58
|
RUCY_END
|
59
59
|
|
60
60
|
static
|
61
|
-
RUCY_DEF0(
|
61
|
+
RUCY_DEF0(get_view)
|
62
62
|
{
|
63
63
|
CHECK;
|
64
64
|
return value(THIS->view);
|
@@ -77,9 +77,9 @@ Init_contact_event ()
|
|
77
77
|
cContactEvent.define_alloc_func(alloc);
|
78
78
|
cContactEvent.define_private_method("initialize", initialize);
|
79
79
|
cContactEvent.define_private_method("initialize_copy", initialize_copy);
|
80
|
-
cContactEvent.define_method("type",
|
81
|
-
cContactEvent.define_method("shape",
|
82
|
-
cContactEvent.define_method("view",
|
80
|
+
cContactEvent.define_method("type", get_type);
|
81
|
+
cContactEvent.define_method("shape", get_shape);
|
82
|
+
cContactEvent.define_method("view", get_view);
|
83
83
|
cContactEvent.define_const("TYPE_NONE", Reflex::ContactEvent::NONE);
|
84
84
|
cContactEvent.define_const("TYPE_BEGIN", Reflex::ContactEvent::BEGIN);
|
85
85
|
cContactEvent.define_const("TYPE_END", Reflex::ContactEvent::END);
|
data/ext/reflex/focus_event.cpp
CHANGED
@@ -42,7 +42,7 @@ RUCY_DEF1(initialize_copy, obj)
|
|
42
42
|
RUCY_END
|
43
43
|
|
44
44
|
static
|
45
|
-
RUCY_DEF0(
|
45
|
+
RUCY_DEF0(get_type)
|
46
46
|
{
|
47
47
|
CHECK;
|
48
48
|
return value(THIS->type);
|
@@ -50,7 +50,7 @@ RUCY_DEF0(type)
|
|
50
50
|
RUCY_END
|
51
51
|
|
52
52
|
static
|
53
|
-
RUCY_DEF0(
|
53
|
+
RUCY_DEF0(get_current)
|
54
54
|
{
|
55
55
|
CHECK;
|
56
56
|
return THIS->current ? value(THIS->current) : nil();
|
@@ -58,7 +58,7 @@ RUCY_DEF0(current)
|
|
58
58
|
RUCY_END
|
59
59
|
|
60
60
|
static
|
61
|
-
RUCY_DEF0(
|
61
|
+
RUCY_DEF0(get_last)
|
62
62
|
{
|
63
63
|
CHECK;
|
64
64
|
return THIS->last ? value(THIS->last) : nil();
|
@@ -77,9 +77,9 @@ Init_focus_event ()
|
|
77
77
|
cFocusEvent.define_alloc_func(alloc);
|
78
78
|
cFocusEvent.define_private_method("initialize", initialize);
|
79
79
|
cFocusEvent.define_private_method("initialize_copy", initialize_copy);
|
80
|
-
cFocusEvent.define_method("type",
|
81
|
-
cFocusEvent.define_method("current",
|
82
|
-
cFocusEvent.define_method("last",
|
80
|
+
cFocusEvent.define_method("type", get_type);
|
81
|
+
cFocusEvent.define_method("current", get_current);
|
82
|
+
cFocusEvent.define_method("last", get_last);
|
83
83
|
cFocusEvent.define_const("TYPE_NONE", Reflex::FocusEvent::NONE);
|
84
84
|
cFocusEvent.define_const("TYPE_FOCUS", Reflex::FocusEvent::FOCUS);
|
85
85
|
cFocusEvent.define_const("TYPE_BLUR", Reflex::FocusEvent::BLUR);
|
data/ext/reflex/key_event.cpp
CHANGED
@@ -43,7 +43,7 @@ RUCY_DEF1(initialize_copy, obj)
|
|
43
43
|
RUCY_END
|
44
44
|
|
45
45
|
static
|
46
|
-
RUCY_DEF0(
|
46
|
+
RUCY_DEF0(get_type)
|
47
47
|
{
|
48
48
|
CHECK;
|
49
49
|
return value(THIS->type);
|
@@ -51,7 +51,205 @@ RUCY_DEF0(type)
|
|
51
51
|
RUCY_END
|
52
52
|
|
53
53
|
static
|
54
|
-
RUCY_DEF0(
|
54
|
+
RUCY_DEF0(get_key)
|
55
|
+
{
|
56
|
+
CHECK;
|
57
|
+
switch (THIS->code)
|
58
|
+
{
|
59
|
+
#define CASE(key) case Reflex::KEY_##key
|
60
|
+
#define SYMBOL1(name) SYMBOL2(_##name, #name)
|
61
|
+
#define SYMBOL2(var, sym) {RUCY_SYMBOL(var, sym); return var.value();}
|
62
|
+
|
63
|
+
CASE(A): SYMBOL1(a);
|
64
|
+
CASE(B): SYMBOL1(b);
|
65
|
+
CASE(C): SYMBOL1(c);
|
66
|
+
CASE(D): SYMBOL1(d);
|
67
|
+
CASE(E): SYMBOL1(e);
|
68
|
+
CASE(F): SYMBOL1(f);
|
69
|
+
CASE(G): SYMBOL1(g);
|
70
|
+
CASE(H): SYMBOL1(h);
|
71
|
+
CASE(I): SYMBOL1(i);
|
72
|
+
CASE(J): SYMBOL1(j);
|
73
|
+
CASE(K): SYMBOL1(k);
|
74
|
+
CASE(L): SYMBOL1(l);
|
75
|
+
CASE(M): SYMBOL1(m);
|
76
|
+
CASE(N): SYMBOL1(n);
|
77
|
+
CASE(O): SYMBOL1(o);
|
78
|
+
CASE(P): SYMBOL1(p);
|
79
|
+
CASE(Q): SYMBOL1(q);
|
80
|
+
CASE(R): SYMBOL1(r);
|
81
|
+
CASE(S): SYMBOL1(s);
|
82
|
+
CASE(T): SYMBOL1(t);
|
83
|
+
CASE(U): SYMBOL1(u);
|
84
|
+
CASE(V): SYMBOL1(v);
|
85
|
+
CASE(W): SYMBOL1(w);
|
86
|
+
CASE(X): SYMBOL1(x);
|
87
|
+
CASE(Y): SYMBOL1(y);
|
88
|
+
CASE(Z): SYMBOL1(z);
|
89
|
+
|
90
|
+
CASE(0):
|
91
|
+
CASE(NUM_0): SYMBOL1(0);
|
92
|
+
CASE(1):
|
93
|
+
CASE(NUM_1): SYMBOL1(1);
|
94
|
+
CASE(2):
|
95
|
+
CASE(NUM_2): SYMBOL1(2);
|
96
|
+
CASE(3):
|
97
|
+
CASE(NUM_3): SYMBOL1(3);
|
98
|
+
CASE(4):
|
99
|
+
CASE(NUM_4): SYMBOL1(4);
|
100
|
+
CASE(5):
|
101
|
+
CASE(NUM_5): SYMBOL1(5);
|
102
|
+
CASE(6):
|
103
|
+
CASE(NUM_6): SYMBOL1(6);
|
104
|
+
CASE(7):
|
105
|
+
CASE(NUM_7): SYMBOL1(7);
|
106
|
+
CASE(8):
|
107
|
+
CASE(NUM_8): SYMBOL1(8);
|
108
|
+
CASE(9):
|
109
|
+
CASE(NUM_9): SYMBOL1(9);
|
110
|
+
|
111
|
+
CASE(MINUS): SYMBOL1(minus);
|
112
|
+
CASE(EQUAL): SYMBOL1(equal);
|
113
|
+
CASE(COMMA): SYMBOL1(comma);
|
114
|
+
CASE(PERIOD): SYMBOL1(period);
|
115
|
+
CASE(SEMICOLON): SYMBOL1(semicolon);
|
116
|
+
CASE(QUOTE): SYMBOL1(quote);
|
117
|
+
CASE(SLASH): SYMBOL1(slash);
|
118
|
+
CASE(BACKSLASH): SYMBOL1(backslash);
|
119
|
+
CASE(UNDERSCORE): SYMBOL1(underscore);
|
120
|
+
CASE(GRAVE): SYMBOL1(grave);
|
121
|
+
CASE(YEN): SYMBOL1(yen);
|
122
|
+
CASE(LBRACKET): SYMBOL1(lbracket);
|
123
|
+
CASE(RBRACKET): SYMBOL1(rbracket);
|
124
|
+
|
125
|
+
CASE(ENTER):
|
126
|
+
CASE(RETURN): SYMBOL1(enter);
|
127
|
+
CASE(SPACE): SYMBOL1(space);
|
128
|
+
CASE(TAB): SYMBOL1(tab);
|
129
|
+
CASE(DELETE): SYMBOL2(_delete, "delete");
|
130
|
+
CASE(BACKSPACE): SYMBOL1(backspace);
|
131
|
+
//CASE(INSERT): SYMBOL1(insert);
|
132
|
+
CASE(ESCAPE): SYMBOL1(escape);
|
133
|
+
|
134
|
+
CASE(LEFT): SYMBOL1(left);
|
135
|
+
CASE(RIGHT): SYMBOL1(right);
|
136
|
+
CASE(UP): SYMBOL1(up);
|
137
|
+
CASE(DOWN): SYMBOL1(down);
|
138
|
+
CASE(HOME): SYMBOL1(home);
|
139
|
+
CASE(END): SYMBOL1(end);
|
140
|
+
CASE(PAGEUP): SYMBOL1(pageup);
|
141
|
+
CASE(PAGEDOWN): SYMBOL1(pagedown);
|
142
|
+
|
143
|
+
CASE(LSHIFT):
|
144
|
+
CASE(RSHIFT): SYMBOL1(shift);
|
145
|
+
CASE(LCONTROL):
|
146
|
+
CASE(RCONTROL): SYMBOL1(control);
|
147
|
+
//CASE(LALT):
|
148
|
+
//CASE(RALT): SYMBOL1(alt);
|
149
|
+
//CASE(LWIN):
|
150
|
+
//CASE(RWIN): SYMBOL1(win);
|
151
|
+
CASE(LCOMMAND):
|
152
|
+
CASE(RCOMMAND): SYMBOL1(command);
|
153
|
+
CASE(LOPTION):
|
154
|
+
CASE(ROPTION): SYMBOL1(option);
|
155
|
+
CASE(FUNCTION): SYMBOL1(function);
|
156
|
+
|
157
|
+
CASE(F1): SYMBOL1(f1);
|
158
|
+
CASE(F2): SYMBOL1(f2);
|
159
|
+
CASE(F3): SYMBOL1(f3);
|
160
|
+
CASE(F4): SYMBOL1(f4);
|
161
|
+
CASE(F5): SYMBOL1(f5);
|
162
|
+
CASE(F6): SYMBOL1(f6);
|
163
|
+
CASE(F7): SYMBOL1(f7);
|
164
|
+
CASE(F8): SYMBOL1(f8);
|
165
|
+
CASE(F9): SYMBOL1(f9);
|
166
|
+
CASE(F10): SYMBOL1(f10);
|
167
|
+
CASE(F11): SYMBOL1(f11);
|
168
|
+
CASE(F12): SYMBOL1(f12);
|
169
|
+
CASE(F13): SYMBOL1(f13);
|
170
|
+
CASE(F14): SYMBOL1(f14);
|
171
|
+
CASE(F15): SYMBOL1(f15);
|
172
|
+
CASE(F16): SYMBOL1(f16);
|
173
|
+
CASE(F17): SYMBOL1(f17);
|
174
|
+
CASE(F18): SYMBOL1(f18);
|
175
|
+
CASE(F19): SYMBOL1(f19);
|
176
|
+
CASE(F20): SYMBOL1(f20);
|
177
|
+
//CASE(F21): SYMBOL1(f21);
|
178
|
+
//CASE(F22): SYMBOL1(f22);
|
179
|
+
//CASE(F23): SYMBOL1(f23);
|
180
|
+
//CASE(F24): SYMBOL1(f24);
|
181
|
+
|
182
|
+
CASE(NUM_PLUS): SYMBOL1(plus);
|
183
|
+
CASE(NUM_MINUS): SYMBOL1(minus);
|
184
|
+
CASE(NUM_MULTIPLY): SYMBOL1(multiply);
|
185
|
+
CASE(NUM_DIVIDE): SYMBOL1(divide);
|
186
|
+
CASE(NUM_EQUAL): SYMBOL1(equal);
|
187
|
+
CASE(NUM_COMMA): SYMBOL1(comma);
|
188
|
+
CASE(NUM_DECIMAL): SYMBOL1(decimal);
|
189
|
+
CASE(NUM_CLEAR): SYMBOL1(clear);
|
190
|
+
|
191
|
+
CASE(CAPSLOCK): SYMBOL1(capslock);
|
192
|
+
//CASE(NUMLOCK): SYMBOL1(numlock);
|
193
|
+
//CASE(SCROLLLOCK): SYMBOL1(scrolllock);
|
194
|
+
|
195
|
+
//CASE(PRINTSCREEN): SYMBOL1(printscreen);
|
196
|
+
//CASE(PAUSE): SYMBOL1(pause);
|
197
|
+
//CASE(BREAK): SYMBOL2(_break, "break");
|
198
|
+
CASE(SECTION): SYMBOL1(section);
|
199
|
+
CASE(HELP): SYMBOL1(help);
|
200
|
+
|
201
|
+
CASE(IME_EISU): SYMBOL1(eisu);
|
202
|
+
CASE(IME_KANA): SYMBOL1(kana);
|
203
|
+
//CASE(IME_KANJI): SYMBOL1(kanji);
|
204
|
+
//CASE(IME_JUNJA): SYMBOL1(junja);
|
205
|
+
//CASE(IME_PROCESS): SYMBOL1(process);
|
206
|
+
//CASE(IME_ACCEPT): SYMBOL1(accept);
|
207
|
+
//CASE(IME_FINAL): SYMBOL2(_final, "final");
|
208
|
+
//CASE(IME_CONVERT): SYMBOL1(convert);
|
209
|
+
//CASE(IME_NONCONVERT): SYMBOL1(nonconvert);
|
210
|
+
//CASE(IME_MODECHANGE): SYMBOL1(mode_change);
|
211
|
+
|
212
|
+
CASE(VOLUME_UP): SYMBOL1(volume_up);
|
213
|
+
CASE(VOLUME_DOWN): SYMBOL1(volume_down);
|
214
|
+
CASE(MUTE): SYMBOL1(mute);
|
215
|
+
|
216
|
+
//CASE(SLEEP): SYMBOL1(sleep);
|
217
|
+
//CASE(EXEC): SYMBOL1(exec);
|
218
|
+
//CASE(PRINT): SYMBOL1(print);
|
219
|
+
//CASE(APPS): SYMBOL1(apps);
|
220
|
+
//CASE(SELECT): SYMBOL1(select);
|
221
|
+
//CASE(CLEAR): SYMBOL1(clear);
|
222
|
+
//CASE(PLAY): SYMBOL1(play);
|
223
|
+
//CASE(ZOOM): SYMBOL1(zoom);
|
224
|
+
|
225
|
+
//CASE(BROWSER_BACK): SYMBOL1(browser_back);
|
226
|
+
//CASE(BROWSER_FORWARD): SYMBOL1(browser_forward);
|
227
|
+
//CASE(BROWSER_REFRESH): SYMBOL1(browser_refresh);
|
228
|
+
//CASE(BROWSER_STOP): SYMBOL1(browser_stop);
|
229
|
+
//CASE(BROWSER_SEARCH): SYMBOL1(browser_search);
|
230
|
+
//CASE(BROWSER_FAVORITES): SYMBOL1(browser_favorites);
|
231
|
+
//CASE(BROWSER_HOME): SYMBOL1(browser_home);
|
232
|
+
|
233
|
+
//CASE(MEDIA_NEXT_TRACK): SYMBOL1(media_next);
|
234
|
+
//CASE(MEDIA_PREV_TRACK): SYMBOL1(media_prev);
|
235
|
+
//CASE(MEDIA_STOP): SYMBOL1(media_stop);
|
236
|
+
//CASE(MEDIA_PLAY_PAUSE): SYMBOL1(media_play_stop);
|
237
|
+
|
238
|
+
//CASE(LAUNCH_MAIL): SYMBOL1(launch_mail);
|
239
|
+
//CASE(LAUNCH_MEDIA_SELECT): SYMBOL1(launch_media_select);
|
240
|
+
//CASE(LAUNCH_APP1): SYMBOL1(launch_app1);
|
241
|
+
//CASE(LAUNCH_APP2): SYMBOL1(launch_app2);
|
242
|
+
|
243
|
+
#undef CASE
|
244
|
+
#undef SYMBOL1
|
245
|
+
#undef SYMBOL2
|
246
|
+
}
|
247
|
+
return nil();
|
248
|
+
}
|
249
|
+
RUCY_END
|
250
|
+
|
251
|
+
static
|
252
|
+
RUCY_DEF0(get_chars)
|
55
253
|
{
|
56
254
|
CHECK;
|
57
255
|
return value(THIS->chars.c_str());
|
@@ -59,7 +257,7 @@ RUCY_DEF0(chars)
|
|
59
257
|
RUCY_END
|
60
258
|
|
61
259
|
static
|
62
|
-
RUCY_DEF0(
|
260
|
+
RUCY_DEF0(get_code)
|
63
261
|
{
|
64
262
|
CHECK;
|
65
263
|
return value(THIS->code);
|
@@ -67,7 +265,7 @@ RUCY_DEF0(code)
|
|
67
265
|
RUCY_END
|
68
266
|
|
69
267
|
static
|
70
|
-
RUCY_DEF0(
|
268
|
+
RUCY_DEF0(get_modifiers)
|
71
269
|
{
|
72
270
|
CHECK;
|
73
271
|
return value(THIS->modifiers);
|
@@ -75,7 +273,7 @@ RUCY_DEF0(modifiers)
|
|
75
273
|
RUCY_END
|
76
274
|
|
77
275
|
static
|
78
|
-
RUCY_DEF0(
|
276
|
+
RUCY_DEF0(get_repeat)
|
79
277
|
{
|
80
278
|
CHECK;
|
81
279
|
return value(THIS->repeat);
|
@@ -83,7 +281,7 @@ RUCY_DEF0(repeat)
|
|
83
281
|
RUCY_END
|
84
282
|
|
85
283
|
static
|
86
|
-
RUCY_DEF0(
|
284
|
+
RUCY_DEF0(is_capture)
|
87
285
|
{
|
88
286
|
CHECK;
|
89
287
|
return value(THIS->capture);
|
@@ -102,12 +300,13 @@ Init_key_event ()
|
|
102
300
|
cKeyEvent.define_alloc_func(alloc);
|
103
301
|
cKeyEvent.define_private_method("initialize", initialize);
|
104
302
|
cKeyEvent.define_private_method("initialize_copy", initialize_copy);
|
105
|
-
cKeyEvent.define_method("type",
|
106
|
-
cKeyEvent.define_method("
|
107
|
-
cKeyEvent.define_method("
|
108
|
-
cKeyEvent.define_method("
|
109
|
-
cKeyEvent.define_method("
|
110
|
-
cKeyEvent.define_method("
|
303
|
+
cKeyEvent.define_method("type", get_type);
|
304
|
+
cKeyEvent.define_method("key", get_key);
|
305
|
+
cKeyEvent.define_method("chars", get_chars);
|
306
|
+
cKeyEvent.define_method("code", get_code);
|
307
|
+
cKeyEvent.define_method("modifiers", get_modifiers);
|
308
|
+
cKeyEvent.define_method("repeat", get_repeat);
|
309
|
+
cKeyEvent.define_method("capture?", is_capture);
|
111
310
|
cKeyEvent.define_const("TYPE_NONE", Reflex::KeyEvent::NONE);
|
112
311
|
cKeyEvent.define_const("TYPE_DOWN", Reflex::KeyEvent::DOWN);
|
113
312
|
cKeyEvent.define_const("TYPE_UP", Reflex::KeyEvent::UP);
|
@@ -52,7 +52,7 @@ RUCY_DEF1(initialize_copy, obj)
|
|
52
52
|
RUCY_END
|
53
53
|
|
54
54
|
static
|
55
|
-
RUCY_DEF0(
|
55
|
+
RUCY_DEF0(get_type)
|
56
56
|
{
|
57
57
|
CHECK;
|
58
58
|
return value(THIS->type);
|
@@ -60,7 +60,7 @@ RUCY_DEF0(type)
|
|
60
60
|
RUCY_END
|
61
61
|
|
62
62
|
static
|
63
|
-
RUCY_DEF0(
|
63
|
+
RUCY_DEF0(get_pointer_type)
|
64
64
|
{
|
65
65
|
CHECK;
|
66
66
|
return value(THIS->pointer_type);
|
@@ -68,7 +68,7 @@ RUCY_DEF0(pointer_type)
|
|
68
68
|
RUCY_END
|
69
69
|
|
70
70
|
static
|
71
|
-
RUCY_DEF0(
|
71
|
+
RUCY_DEF0(get_size)
|
72
72
|
{
|
73
73
|
CHECK;
|
74
74
|
return value(THIS->size);
|
@@ -76,7 +76,7 @@ RUCY_DEF0(size)
|
|
76
76
|
RUCY_END
|
77
77
|
|
78
78
|
static
|
79
|
-
RUCY_DEF0(
|
79
|
+
RUCY_DEF0(get_modifiers)
|
80
80
|
{
|
81
81
|
CHECK;
|
82
82
|
return value(THIS->modifiers);
|
@@ -84,7 +84,7 @@ RUCY_DEF0(modifiers)
|
|
84
84
|
RUCY_END
|
85
85
|
|
86
86
|
static
|
87
|
-
RUCY_DEF0(
|
87
|
+
RUCY_DEF0(get_count)
|
88
88
|
{
|
89
89
|
CHECK;
|
90
90
|
return value(THIS->count);
|
@@ -92,7 +92,7 @@ RUCY_DEF0(count)
|
|
92
92
|
RUCY_END
|
93
93
|
|
94
94
|
static
|
95
|
-
RUCY_DEF0(
|
95
|
+
RUCY_DEF0(is_drag)
|
96
96
|
{
|
97
97
|
CHECK;
|
98
98
|
return value(THIS->drag);
|
@@ -100,7 +100,7 @@ RUCY_DEF0(drag)
|
|
100
100
|
RUCY_END
|
101
101
|
|
102
102
|
static
|
103
|
-
RUCY_DEF0(
|
103
|
+
RUCY_DEF0(is_capture)
|
104
104
|
{
|
105
105
|
CHECK;
|
106
106
|
return value(THIS->capture);
|
@@ -108,7 +108,7 @@ RUCY_DEF0(capture)
|
|
108
108
|
RUCY_END
|
109
109
|
|
110
110
|
static
|
111
|
-
RUCY_DEF0(
|
111
|
+
RUCY_DEF0(get_x)
|
112
112
|
{
|
113
113
|
CHECK;
|
114
114
|
return value(THIS->x);
|
@@ -116,7 +116,7 @@ RUCY_DEF0(x)
|
|
116
116
|
RUCY_END
|
117
117
|
|
118
118
|
static
|
119
|
-
RUCY_DEF0(
|
119
|
+
RUCY_DEF0(get_y)
|
120
120
|
{
|
121
121
|
CHECK;
|
122
122
|
return value(THIS->y);
|
@@ -124,7 +124,7 @@ RUCY_DEF0(y)
|
|
124
124
|
RUCY_END
|
125
125
|
|
126
126
|
static
|
127
|
-
RUCY_DEFN(
|
127
|
+
RUCY_DEFN(get_position)
|
128
128
|
{
|
129
129
|
CHECK;
|
130
130
|
check_arg_count(__FILE__, __LINE__, "PointerEvent#position", argc, 0, 1);
|
@@ -159,17 +159,17 @@ Init_pointer_event ()
|
|
159
159
|
cPointerEvent.define_alloc_func(alloc);
|
160
160
|
cPointerEvent.define_private_method("initialize", initialize);
|
161
161
|
cPointerEvent.define_private_method("initialize_copy", initialize_copy);
|
162
|
-
cPointerEvent.define_method("type",
|
163
|
-
cPointerEvent.define_method("pointer_type",
|
164
|
-
cPointerEvent.define_method("size",
|
165
|
-
cPointerEvent.define_method("modifiers",
|
166
|
-
cPointerEvent.define_method("count",
|
167
|
-
cPointerEvent.define_method("drag?",
|
168
|
-
cPointerEvent.define_method("capture?",
|
169
|
-
cPointerEvent.define_method("x",
|
170
|
-
cPointerEvent.define_method("y",
|
171
|
-
cPointerEvent.define_method("position",
|
172
|
-
cPointerEvent.define_method("[]",
|
162
|
+
cPointerEvent.define_method("type", get_type);
|
163
|
+
cPointerEvent.define_method("pointer_type", get_pointer_type);
|
164
|
+
cPointerEvent.define_method("size", get_size);
|
165
|
+
cPointerEvent.define_method("modifiers", get_modifiers);
|
166
|
+
cPointerEvent.define_method("count", get_count);
|
167
|
+
cPointerEvent.define_method("drag?", is_drag);
|
168
|
+
cPointerEvent.define_method("capture?", is_capture);
|
169
|
+
cPointerEvent.define_method("x", get_x);
|
170
|
+
cPointerEvent.define_method("y", get_y);
|
171
|
+
cPointerEvent.define_method("position", get_position);
|
172
|
+
cPointerEvent.define_method("[]", get_at);
|
173
173
|
cPointerEvent.define_const("TYPE_NONE", Reflex::PointerEvent::NONE);
|
174
174
|
cPointerEvent.define_const("TYPE_DOWN", Reflex::PointerEvent::DOWN);
|
175
175
|
cPointerEvent.define_const("TYPE_UP", Reflex::PointerEvent::UP);
|