embedded-react 0.19.0 → 0.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -3
- package/aot/compile.mjs +178 -58
- package/aot/compiler/animations.mjs +290 -281
- package/aot/compiler/boot.mjs +70 -33
- package/aot/compiler/branch-merge.mjs +4 -3
- package/aot/compiler/check.mjs +9 -9
- package/aot/compiler/collect.mjs +324 -205
- package/aot/compiler/control-flow.mjs +209 -197
- package/aot/compiler/diagnostics.mjs +22 -25
- package/aot/compiler/elements/activity-indicator.mjs +25 -24
- package/aot/compiler/elements/dial.mjs +91 -77
- package/aot/compiler/elements/flat-list.mjs +24 -22
- package/aot/compiler/elements/image.mjs +51 -50
- package/aot/compiler/elements/modal.mjs +31 -30
- package/aot/compiler/elements/props.mjs +23 -23
- package/aot/compiler/elements/switch.mjs +42 -34
- package/aot/compiler/elements/text-input.mjs +34 -32
- package/aot/compiler/expressions.mjs +372 -333
- package/aot/compiler/handlers.mjs +473 -387
- package/aot/compiler/ir/functions.mjs +11 -1
- package/aot/compiler/ir/nodes.mjs +4 -4
- package/aot/compiler/ir/reads.mjs +19 -19
- package/aot/compiler/ir/types.mjs +14 -14
- package/aot/compiler/ir/vectors.mjs +5 -1
- package/aot/compiler/keyboard.mjs +17 -7
- package/aot/compiler/lower.mjs +77 -80
- package/aot/compiler/nodes.mjs +169 -152
- package/aot/compiler/options.mjs +35 -30
- package/aot/compiler/out.mjs +18 -22
- package/aot/compiler/package/animations.mjs +669 -0
- package/aot/compiler/package/arena.mjs +252 -0
- package/aot/compiler/package/assemble.mjs +177 -0
- package/aot/compiler/package/bytecode.mjs +286 -0
- package/aot/compiler/package/checks.mjs +1022 -0
- package/aot/compiler/package/codegen.mjs +1329 -0
- package/aot/compiler/package/enums.mjs +138 -0
- package/aot/compiler/package/format.mjs +760 -0
- package/aot/compiler/package/layouts.mjs +136 -0
- package/aot/compiler/package/lower.mjs +1606 -0
- package/aot/compiler/package/props.mjs +118 -0
- package/aot/compiler/package/tables.mjs +103 -0
- package/aot/compiler/package/vectors.mjs +502 -0
- package/aot/compiler/package/writer.mjs +664 -0
- package/aot/compiler/pan-responder.mjs +69 -61
- package/aot/compiler/parse.mjs +21 -21
- package/aot/compiler/static-eval.mjs +25 -23
- package/aot/compiler/style-text.mjs +161 -172
- package/aot/compiler/svg.mjs +477 -251
- package/aot/screenshot-smoke.mjs +54 -40
- package/aot/style-map.mjs +102 -90
- package/assets/bake-font.mjs +123 -77
- package/assets/bake-image.mjs +39 -22
- package/assets/bake-svg.mjs +361 -262
- package/assets/build-builtin-font.mjs +11 -7
- package/assets/emit-c.mjs +77 -58
- package/assets/emit-container.mjs +123 -37
- package/assets/emit-pack.mjs +77 -67
- package/assets/font-config.mjs +9 -6
- package/assets/font-sizes.mjs +163 -123
- package/assets/glyph-coverage.mjs +74 -54
- package/assets/index.mjs +31 -9
- package/assets/rasterize.mjs +126 -99
- package/assets/svg-loader.mjs +8 -8
- package/build.mjs +14 -12
- package/cli.mjs +359 -172
- package/compile-bin.mjs +3 -3
- package/flash.mjs +537 -0
- package/hotreload/dev-device.mjs +90 -33
- package/hotreload/pack-app.mjs +55 -43
- package/hotreload/pack-split.mjs +46 -37
- package/hotreload/package-transfer.mjs +175 -0
- package/hotreload/protocol.mjs +50 -37
- package/hotreload/uploader.mjs +38 -27
- package/hotreload/watch-tree.mjs +19 -19
- package/pack-container.mjs +28 -20
- package/package.json +7 -8
- package/persist-transform.mjs +34 -28
- package/qjsc-wasm.mjs +25 -14
- package/sim/embedded-react.cjs +1 -1
- package/sim/embedded-react.js +1 -1
- package/sim/embedded-react.wasm +0 -0
- package/sim/index.html +94 -85
- package/sim-server.mjs +101 -82
- package/src/embedded-react/Animated.js +24 -24
- package/src/embedded-react/Easing.js +1 -1
- package/src/embedded-react/FlatList.js +3 -3
- package/src/embedded-react/LayoutAnimation.js +8 -5
- package/src/embedded-react/PanResponder.js +75 -71
- package/src/embedded-react/Pressable.js +2 -8
- package/src/embedded-react/SectionList.js +6 -6
- package/src/embedded-react/StyleSheet.js +4 -3
- package/src/embedded-react/TouchableOpacity.js +13 -8
- package/src/embedded-react/index.d.ts +5 -5
- package/src/embedded-react/layout-anim-config.js +10 -4
- package/src/embedded-react/list-child.js +5 -5
- package/src/embedded-react/named-colors.js +1 -1
- package/src/embedded-react/split-style.js +11 -11
- package/src/embedded-react/svg-ops.js +760 -593
- package/src/embedded-react/useHostValue.js +3 -3
- package/src/embedded-react/usePersistentState.js +6 -6
- package/src/embedded-react/warn-props.js +1 -1
- package/src/host-config.js +60 -53
- package/src/props.js +49 -41
- package/src/renderer.js +7 -4
- package/aot/compiler/assemble.mjs +0 -944
- package/aot/compiler/c/animations.mjs +0 -436
- package/aot/compiler/c/boot.mjs +0 -127
- package/aot/compiler/c/expressions.mjs +0 -270
- package/aot/compiler/c/functions.mjs +0 -268
- package/aot/compiler/c/keyboard.mjs +0 -96
- package/aot/compiler/c/nodes.mjs +0 -303
- package/aot/compiler/c/pan-responder.mjs +0 -136
- package/aot/compiler/c/statements.mjs +0 -319
- package/aot/compiler/c/text.mjs +0 -83
- package/aot/compiler/c/vectors.mjs +0 -381
- package/aot/compiler/c-syntax.mjs +0 -127
|
@@ -0,0 +1,760 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2026 Cory Lamming
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
/*
|
|
17
|
+
* The Flow B package format, as the compiler writes it: the codes and sizes in runtime/erb_format.h, the
|
|
18
|
+
* engine ABI's prop ids in runtime/erb_props.c, and the er_scene.h enum values constant props name. The
|
|
19
|
+
* npm package doesn't ship the C headers, so they are copied here; package-format.unit.test.js reads the
|
|
20
|
+
* headers and fails when the two drift apart.
|
|
21
|
+
*/
|
|
22
|
+
/*----------------------------------------------------------------------------------------------------------------------
|
|
23
|
+
- Versions and container
|
|
24
|
+
---------------------------------------------------------------------------------------------------------------------*/
|
|
25
|
+
export const FORMAT_MAJOR = 1;
|
|
26
|
+
export const FORMAT_MINOR = 6;
|
|
27
|
+
/** The engine ABI level the package is built against (er_scene.h's ER_ABI). */
|
|
28
|
+
export const ENGINE_ABI = 1;
|
|
29
|
+
export const PACKAGE_TAG = 'erb';
|
|
30
|
+
export const SECTION_PROGRAM = 4;
|
|
31
|
+
export const SECTION_DEBUG = 5;
|
|
32
|
+
export const FLAG_DEBUG = 0x0001;
|
|
33
|
+
/** "None", for any u16 index. */
|
|
34
|
+
export const NONE = 0xffff;
|
|
35
|
+
/** Each table of the debug section starts with its header; then its entries. */
|
|
36
|
+
export const DEBUG_HEADER_SIZE = 20;
|
|
37
|
+
export const DEBUG_ENTRY_SIZE = 16;
|
|
38
|
+
/*----------------------------------------------------------------------------------------------------------------------
|
|
39
|
+
- Program section
|
|
40
|
+
---------------------------------------------------------------------------------------------------------------------*/
|
|
41
|
+
export const HEADER_SIZE = 24;
|
|
42
|
+
export const PANEL_SIZE = 16;
|
|
43
|
+
export const NEED_SIZE = 8;
|
|
44
|
+
export const DIRECTORY_SIZE = 12;
|
|
45
|
+
export const REGION_SIZE = 12;
|
|
46
|
+
export const SLOT_SIZE = 16;
|
|
47
|
+
export const SET_SIZE = 4;
|
|
48
|
+
export const ROW_SIZE = 8;
|
|
49
|
+
export const FIELD_SIZE = 8;
|
|
50
|
+
export const PROP_SIZE = 8;
|
|
51
|
+
export const TEMPLATE_SIZE = 8;
|
|
52
|
+
export const NODE_SIZE = 12;
|
|
53
|
+
export const BINDING_SIZE = 4;
|
|
54
|
+
export const FUNCTION_SIZE = 16;
|
|
55
|
+
export const ANIMATION_SIZE = 40;
|
|
56
|
+
export const INTERPOLATION_SIZE = 72;
|
|
57
|
+
export const TAPE_SIZE = 16;
|
|
58
|
+
export const TAPE_HEADER_SIZE = 16;
|
|
59
|
+
export const PAINT_SIZE = 24;
|
|
60
|
+
export const GRADIENT_SIZE = 24;
|
|
61
|
+
export const STOP_SIZE = 8;
|
|
62
|
+
export const KEYBOARD_HEADER_SIZE = 28;
|
|
63
|
+
export const KEYBOARD_GROUP_SIZE = 4;
|
|
64
|
+
export const KEYBOARD_KEY_SIZE = 8;
|
|
65
|
+
/** Engine resources a package names in its needs, besides nodes. */
|
|
66
|
+
export const Resource = {
|
|
67
|
+
vectorNodes: 1,
|
|
68
|
+
animationValues: 2,
|
|
69
|
+
animations: 3,
|
|
70
|
+
animationGroups: 4,
|
|
71
|
+
images: 5,
|
|
72
|
+
fonts: 6,
|
|
73
|
+
glyphs: 7,
|
|
74
|
+
extraGlyphs: 8,
|
|
75
|
+
};
|
|
76
|
+
/** Table ids. */
|
|
77
|
+
export const Table = {
|
|
78
|
+
strings: 1,
|
|
79
|
+
const32: 2,
|
|
80
|
+
const64: 3,
|
|
81
|
+
arena: 4,
|
|
82
|
+
slots: 5,
|
|
83
|
+
enums: 6,
|
|
84
|
+
rows: 7,
|
|
85
|
+
props: 8,
|
|
86
|
+
templates: 9,
|
|
87
|
+
bindings: 10,
|
|
88
|
+
functions: 11,
|
|
89
|
+
types: 12,
|
|
90
|
+
code: 13,
|
|
91
|
+
animations: 14,
|
|
92
|
+
tapes: 15,
|
|
93
|
+
imports: 16,
|
|
94
|
+
inputs: 17,
|
|
95
|
+
interpolations: 18,
|
|
96
|
+
keyboard: 19,
|
|
97
|
+
checks: 20,
|
|
98
|
+
};
|
|
99
|
+
/** Arena region kinds, written in this order. */
|
|
100
|
+
export const Region = {
|
|
101
|
+
slots: 1,
|
|
102
|
+
dirty: 2,
|
|
103
|
+
strings: 3,
|
|
104
|
+
lists: 4,
|
|
105
|
+
handles: 5,
|
|
106
|
+
timers: 6,
|
|
107
|
+
animations: 7,
|
|
108
|
+
stack: 8,
|
|
109
|
+
tape: 9,
|
|
110
|
+
events: 10,
|
|
111
|
+
};
|
|
112
|
+
/** Cells each VM frame keeps besides its registers. */
|
|
113
|
+
export const FRAME_CELLS = 3;
|
|
114
|
+
/** Bytes a timer takes in the timer table, a running animation in the anims region, and an event in the queue. */
|
|
115
|
+
export const TIMER_SIZE = 16;
|
|
116
|
+
export const ANIMATION_ENTRY_SIZE = 20;
|
|
117
|
+
export const EVENT_SIZE = 32;
|
|
118
|
+
/** Bytes a list pool keeps before its rows: the row count. */
|
|
119
|
+
export const LIST_HEADER_SIZE = 4;
|
|
120
|
+
/** Bytes a stack cell, a tape float and a node handle take. */
|
|
121
|
+
export const CELL_SIZE = 4;
|
|
122
|
+
export const TAPE_FLOAT_SIZE = 4;
|
|
123
|
+
export const HANDLE_SIZE = 8;
|
|
124
|
+
/** Register and slot value types. A 64-bit type, or a node handle, takes two register cells, the first even. */
|
|
125
|
+
export const ValueType = {
|
|
126
|
+
pair: 0,
|
|
127
|
+
int: 1,
|
|
128
|
+
bool: 2,
|
|
129
|
+
float: 3,
|
|
130
|
+
int64: 4,
|
|
131
|
+
double: 5,
|
|
132
|
+
string: 6,
|
|
133
|
+
enum: 7,
|
|
134
|
+
node: 8,
|
|
135
|
+
animation: 9,
|
|
136
|
+
animatedValue: 10,
|
|
137
|
+
list: 11,
|
|
138
|
+
};
|
|
139
|
+
/** Slot flag bits. */
|
|
140
|
+
export const SlotFlag = {
|
|
141
|
+
tracked: 0x01,
|
|
142
|
+
bootOnly: 0x02,
|
|
143
|
+
};
|
|
144
|
+
/** Binding kinds. */
|
|
145
|
+
export const BindingKind = {
|
|
146
|
+
event: 1,
|
|
147
|
+
query: 2,
|
|
148
|
+
animated: 3,
|
|
149
|
+
tape: 4,
|
|
150
|
+
interpolated: 5,
|
|
151
|
+
};
|
|
152
|
+
/** Animation descriptor kinds. */
|
|
153
|
+
export const AnimationKind = {
|
|
154
|
+
timing: 1,
|
|
155
|
+
spring: 2,
|
|
156
|
+
decay: 3,
|
|
157
|
+
sequence: 4,
|
|
158
|
+
parallel: 5,
|
|
159
|
+
stagger: 6,
|
|
160
|
+
loop: 7,
|
|
161
|
+
};
|
|
162
|
+
/** Animation descriptor flag bits. */
|
|
163
|
+
export const AnimationFlag = {
|
|
164
|
+
loop: 0x01,
|
|
165
|
+
loopReverse: 0x02,
|
|
166
|
+
toRegister: 0x04,
|
|
167
|
+
};
|
|
168
|
+
/** The paint fields VPAINT sets. */
|
|
169
|
+
export const PaintField = {
|
|
170
|
+
fill: 0,
|
|
171
|
+
stroke: 1,
|
|
172
|
+
strokeWidth: 2,
|
|
173
|
+
fillGradient: 3,
|
|
174
|
+
strokeGradient: 4,
|
|
175
|
+
};
|
|
176
|
+
/** The gradient fields VGRAD sets: the geometry, then stop k's color at `stops + 2k` and its position after it. */
|
|
177
|
+
export const GradientField = {
|
|
178
|
+
ax: 0,
|
|
179
|
+
ay: 1,
|
|
180
|
+
bx: 2,
|
|
181
|
+
by: 3,
|
|
182
|
+
radius: 4,
|
|
183
|
+
stops: 8,
|
|
184
|
+
};
|
|
185
|
+
/** Interpolation flag bits. */
|
|
186
|
+
export const InterpolationFlag = {
|
|
187
|
+
color: 0x01,
|
|
188
|
+
};
|
|
189
|
+
/** Each ERAnimationProp an animated value drives, as the ERProps field its ABI prop is. */
|
|
190
|
+
export const ANIMATION_PROP_FIELDS = new Map([
|
|
191
|
+
['ER_PROP_BACKGROUND_COLOR', 'background_color'],
|
|
192
|
+
['ER_PROP_OPACITY', 'opacity'],
|
|
193
|
+
['ER_PROP_COLOR', 'color'],
|
|
194
|
+
['ER_PROP_TRANSLATE_X', 'transform_translate_x'],
|
|
195
|
+
['ER_PROP_TRANSLATE_Y', 'transform_translate_y'],
|
|
196
|
+
['ER_PROP_SCALE_X', 'transform_scale_x'],
|
|
197
|
+
['ER_PROP_SCALE_Y', 'transform_scale_y'],
|
|
198
|
+
['ER_PROP_ROTATE_Z', 'transform_rotate_z'],
|
|
199
|
+
['ER_PROP_ROTATE_X', 'transform_rotate_x'],
|
|
200
|
+
['ER_PROP_ROTATE_Y', 'transform_rotate_y'],
|
|
201
|
+
['ER_PROP_SWITCH_THUMB', 'switch_value'],
|
|
202
|
+
['ER_PROP_ARC_VALUE', 'arc_value'],
|
|
203
|
+
['ER_PROP_ARC_VALUE_START', 'arc_value_start'],
|
|
204
|
+
]);
|
|
205
|
+
/** Function kinds. Below `query`, a kind is the EREventType its handler is bound to. */
|
|
206
|
+
export const FunctionKind = {
|
|
207
|
+
query: 0x40,
|
|
208
|
+
timer: 0x80,
|
|
209
|
+
effect: 0x81,
|
|
210
|
+
update: 0x82,
|
|
211
|
+
boot: 0x83,
|
|
212
|
+
helper: 0x84,
|
|
213
|
+
animationDone: 0x85,
|
|
214
|
+
};
|
|
215
|
+
/** Event data fields EVT reads. */
|
|
216
|
+
export const EventField = {
|
|
217
|
+
x: 0,
|
|
218
|
+
y: 1,
|
|
219
|
+
dx: 2,
|
|
220
|
+
dy: 3,
|
|
221
|
+
vx: 4,
|
|
222
|
+
vy: 5,
|
|
223
|
+
scrollX: 6,
|
|
224
|
+
scrollY: 7,
|
|
225
|
+
layoutX: 8,
|
|
226
|
+
layoutY: 9,
|
|
227
|
+
layoutWidth: 10,
|
|
228
|
+
layoutHeight: 11,
|
|
229
|
+
value: 12,
|
|
230
|
+
valueStart: 13,
|
|
231
|
+
finished: 14,
|
|
232
|
+
touches: 15,
|
|
233
|
+
};
|
|
234
|
+
/** FMATH and DMATH functions. */
|
|
235
|
+
export const MathFn = {
|
|
236
|
+
sin: 0,
|
|
237
|
+
cos: 1,
|
|
238
|
+
tan: 2,
|
|
239
|
+
sqrt: 3,
|
|
240
|
+
abs: 4,
|
|
241
|
+
round: 5,
|
|
242
|
+
floor: 6,
|
|
243
|
+
ceil: 7,
|
|
244
|
+
min: 8,
|
|
245
|
+
max: 9,
|
|
246
|
+
atan2: 10,
|
|
247
|
+
pow: 11,
|
|
248
|
+
mod: 12,
|
|
249
|
+
};
|
|
250
|
+
/** Template kinds. */
|
|
251
|
+
export const TemplateKind = {
|
|
252
|
+
root: 1,
|
|
253
|
+
branch: 2,
|
|
254
|
+
row: 3,
|
|
255
|
+
};
|
|
256
|
+
/** Constant prop value kinds. */
|
|
257
|
+
export const PropKind = {
|
|
258
|
+
i16: 1,
|
|
259
|
+
u8: 2,
|
|
260
|
+
u16: 3,
|
|
261
|
+
enum: 4,
|
|
262
|
+
bool: 5,
|
|
263
|
+
color: 6,
|
|
264
|
+
float: 7,
|
|
265
|
+
opacity: 8,
|
|
266
|
+
string: 9,
|
|
267
|
+
image: 10,
|
|
268
|
+
};
|
|
269
|
+
/** A panel whose layout fits every screen names this instead of a check. */
|
|
270
|
+
export const CHECK_ALWAYS = 0xffffffff;
|
|
271
|
+
/** Values a layout check may hold on its stack, and in its locals. */
|
|
272
|
+
export const CHECK_STACK = 16;
|
|
273
|
+
export const CHECK_LOCALS = 48;
|
|
274
|
+
/** Words one load may run across all the panels' checks. */
|
|
275
|
+
export const CHECK_BUDGET = 65536;
|
|
276
|
+
/** The ops of a layout check (erb_format.h's ERB_CHECK_OP_ values). */
|
|
277
|
+
export const CheckOp = {
|
|
278
|
+
end: 1,
|
|
279
|
+
width: 2,
|
|
280
|
+
height: 3,
|
|
281
|
+
pushi: 4,
|
|
282
|
+
pushk: 5,
|
|
283
|
+
load: 6,
|
|
284
|
+
store: 7,
|
|
285
|
+
add: 8,
|
|
286
|
+
sub: 9,
|
|
287
|
+
mul: 10,
|
|
288
|
+
div: 11,
|
|
289
|
+
neg: 12,
|
|
290
|
+
math: 13,
|
|
291
|
+
toint: 14,
|
|
292
|
+
idiv: 15,
|
|
293
|
+
lt: 16,
|
|
294
|
+
gt: 17,
|
|
295
|
+
le: 18,
|
|
296
|
+
ge: 19,
|
|
297
|
+
eq: 20,
|
|
298
|
+
ne: 21,
|
|
299
|
+
not: 22,
|
|
300
|
+
and: 23,
|
|
301
|
+
or: 24,
|
|
302
|
+
select: 25,
|
|
303
|
+
};
|
|
304
|
+
/** The whole-number divisions of a check's idiv op (erb_format.h's ERB_CHECK_OP_IDIV_ values). */
|
|
305
|
+
export const CheckDivide = {
|
|
306
|
+
trunc: 0,
|
|
307
|
+
floor: 1,
|
|
308
|
+
ceil: 2,
|
|
309
|
+
round: 3,
|
|
310
|
+
mod: 4,
|
|
311
|
+
};
|
|
312
|
+
/** ERB_OPCODES, in order: an opcode is its index here plus one (0 is never an instruction). */
|
|
313
|
+
export const OPCODES = [
|
|
314
|
+
['MOVE', 'abc', 1],
|
|
315
|
+
['LOADI', 'abx', 1],
|
|
316
|
+
['LOADK', 'abx', 1],
|
|
317
|
+
['LOADK64', 'abx', 1],
|
|
318
|
+
['LOADS', 'abx', 1],
|
|
319
|
+
['LOADE', 'abx', 2],
|
|
320
|
+
['GET32', 'abx', 1],
|
|
321
|
+
['GET64', 'abx', 1],
|
|
322
|
+
['GETS', 'abx', 1],
|
|
323
|
+
['SET32', 'abx', 1],
|
|
324
|
+
['SET64', 'abx', 1],
|
|
325
|
+
['SETS', 'abx', 1],
|
|
326
|
+
['GETNI', 'abc', 2],
|
|
327
|
+
['LEN', 'abx', 1],
|
|
328
|
+
['ROWGET', 'abc', 2],
|
|
329
|
+
['ROWSET', 'abc', 2],
|
|
330
|
+
['APPEND', 'abx', 1],
|
|
331
|
+
['CLEAR', 'abx', 1],
|
|
332
|
+
['POP', 'abx', 1],
|
|
333
|
+
['KEEP', 'abx', 1],
|
|
334
|
+
['SLICE', 'abc', 2],
|
|
335
|
+
['ADD', 'abc', 1],
|
|
336
|
+
['SUB', 'abc', 1],
|
|
337
|
+
['MUL', 'abc', 1],
|
|
338
|
+
['DIV', 'abc', 1],
|
|
339
|
+
['FLOORDIV', 'abc', 1],
|
|
340
|
+
['CEILDIV', 'abc', 1],
|
|
341
|
+
['ROUNDDIV', 'abc', 1],
|
|
342
|
+
['MOD', 'abc', 1],
|
|
343
|
+
['MIN', 'abc', 1],
|
|
344
|
+
['MAX', 'abc', 1],
|
|
345
|
+
['NEG', 'abc', 1],
|
|
346
|
+
['ABS', 'abc', 1],
|
|
347
|
+
['ADDL', 'abc', 1],
|
|
348
|
+
['SUBL', 'abc', 1],
|
|
349
|
+
['MULL', 'abc', 1],
|
|
350
|
+
['DIVL', 'abc', 1],
|
|
351
|
+
['FLOORDIVL', 'abc', 1],
|
|
352
|
+
['CEILDIVL', 'abc', 1],
|
|
353
|
+
['ROUNDDIVL', 'abc', 1],
|
|
354
|
+
['MODL', 'abc', 1],
|
|
355
|
+
['MINL', 'abc', 1],
|
|
356
|
+
['MAXL', 'abc', 1],
|
|
357
|
+
['NEGL', 'abc', 1],
|
|
358
|
+
['ABSL', 'abc', 1],
|
|
359
|
+
['FADD', 'abc', 1],
|
|
360
|
+
['FSUB', 'abc', 1],
|
|
361
|
+
['FMUL', 'abc', 1],
|
|
362
|
+
['FDIV', 'abc', 1],
|
|
363
|
+
['FNEG', 'abc', 1],
|
|
364
|
+
['FMATH', 'abc', 2],
|
|
365
|
+
['DADD', 'abc', 1],
|
|
366
|
+
['DSUB', 'abc', 1],
|
|
367
|
+
['DMUL', 'abc', 1],
|
|
368
|
+
['DDIV', 'abc', 1],
|
|
369
|
+
['DNEG', 'abc', 1],
|
|
370
|
+
['DMATH', 'abc', 2],
|
|
371
|
+
['ITOF', 'abc', 1],
|
|
372
|
+
['FTOI', 'abc', 1],
|
|
373
|
+
['LTOF', 'abc', 1],
|
|
374
|
+
['ITOL', 'abc', 1],
|
|
375
|
+
['LTOI', 'abc', 1],
|
|
376
|
+
['DTOI', 'abc', 1],
|
|
377
|
+
['FTOD', 'abc', 1],
|
|
378
|
+
['DTOF', 'abc', 1],
|
|
379
|
+
['ITOD', 'abc', 1],
|
|
380
|
+
['LTOD', 'abc', 1],
|
|
381
|
+
['DTOL', 'abc', 1],
|
|
382
|
+
['FTOL', 'abc', 1],
|
|
383
|
+
['EQ', 'abc', 1],
|
|
384
|
+
['LT', 'abc', 1],
|
|
385
|
+
['LE', 'abc', 1],
|
|
386
|
+
['FEQ', 'abc', 1],
|
|
387
|
+
['FLT', 'abc', 1],
|
|
388
|
+
['FLE', 'abc', 1],
|
|
389
|
+
['LEQ', 'abc', 1],
|
|
390
|
+
['LLT', 'abc', 1],
|
|
391
|
+
['LLE', 'abc', 1],
|
|
392
|
+
['DEQ', 'abc', 1],
|
|
393
|
+
['DLT', 'abc', 1],
|
|
394
|
+
['DLE', 'abc', 1],
|
|
395
|
+
['SEQ', 'abc', 1],
|
|
396
|
+
['NOT', 'abc', 1],
|
|
397
|
+
['JMP', 'abx', 1],
|
|
398
|
+
['JT', 'abx', 1],
|
|
399
|
+
['JF', 'abx', 1],
|
|
400
|
+
['JDIRTY', 'abx', 2],
|
|
401
|
+
['LOOPSET', 'abx', 1],
|
|
402
|
+
['LOOP', 'abx', 1],
|
|
403
|
+
['RET', 'abc', 1],
|
|
404
|
+
['CALL', 'abx', 1],
|
|
405
|
+
['CALLN', 'abx', 1],
|
|
406
|
+
['FMTK', 'abx', 1],
|
|
407
|
+
['FMTS', 'abc', 1],
|
|
408
|
+
['FMTI', 'abc', 1],
|
|
409
|
+
['FMTL', 'abc', 1],
|
|
410
|
+
['FMTF', 'abc', 1],
|
|
411
|
+
['FMTB', 'abc', 1],
|
|
412
|
+
['FMTE', 'abx', 1],
|
|
413
|
+
['FMTFX', 'abc', 1],
|
|
414
|
+
['FMTPAD', 'abc', 1],
|
|
415
|
+
['FMTSET', 'abx', 1],
|
|
416
|
+
['FMTTEXT', 'abc', 1],
|
|
417
|
+
['FMTSPAN', 'abc', 1],
|
|
418
|
+
['PROPS', 'abx', 1],
|
|
419
|
+
['PSETI', 'abx', 1],
|
|
420
|
+
['PSETF', 'abx', 1],
|
|
421
|
+
['PSETB', 'abx', 1],
|
|
422
|
+
['PSETS', 'abx', 1],
|
|
423
|
+
['PSETE', 'abx', 2],
|
|
424
|
+
['SPANS', 'abc', 1],
|
|
425
|
+
['COMMIT', 'abc', 1],
|
|
426
|
+
['BUILD', 'abc', 2],
|
|
427
|
+
['DESTROY', 'abc', 1],
|
|
428
|
+
['SCROLL', 'abc', 1],
|
|
429
|
+
['FOCUS', 'abc', 1],
|
|
430
|
+
['BLUR', 'abc', 1],
|
|
431
|
+
['INPUT', 'abx', 1],
|
|
432
|
+
['TSTART', 'abc', 2],
|
|
433
|
+
['TCLEAR', 'abc', 1],
|
|
434
|
+
['ASTART', 'abx', 2],
|
|
435
|
+
['ASTOP', 'abc', 1],
|
|
436
|
+
['AVSET', 'abx', 1],
|
|
437
|
+
['AVGET', 'abx', 1],
|
|
438
|
+
['VTAPE', 'abx', 1],
|
|
439
|
+
['VSET', 'abx', 1],
|
|
440
|
+
['VCOMMIT', 'abx', 1],
|
|
441
|
+
['VDIRTY', 'abc', 1],
|
|
442
|
+
['EVT', 'abc', 1],
|
|
443
|
+
['NOW', 'abc', 1],
|
|
444
|
+
['DATENOW', 'abc', 1],
|
|
445
|
+
['TRAP', 'abx', 1],
|
|
446
|
+
['EFFECT', 'abx', 1],
|
|
447
|
+
['VPAINT', 'abc', 1],
|
|
448
|
+
['VGRAD', 'abc', 1],
|
|
449
|
+
['VCOMMITP', 'abx', 1],
|
|
450
|
+
['SCREEN', 'abx', 1],
|
|
451
|
+
];
|
|
452
|
+
/** The props with ids 1 to 150, in id order, as erb_props.c lists them, with each enum's largest value. */
|
|
453
|
+
const PROPS_IN_ORDER = [
|
|
454
|
+
['left', 'i16'],
|
|
455
|
+
['top', 'i16'],
|
|
456
|
+
['right', 'i16'],
|
|
457
|
+
['bottom', 'i16'],
|
|
458
|
+
['width', 'i16'],
|
|
459
|
+
['height', 'i16'],
|
|
460
|
+
['min_width', 'i16'],
|
|
461
|
+
['max_width', 'i16'],
|
|
462
|
+
['min_height', 'i16'],
|
|
463
|
+
['max_height', 'i16'],
|
|
464
|
+
['padding', 'i16'],
|
|
465
|
+
['padding_left', 'i16'],
|
|
466
|
+
['padding_top', 'i16'],
|
|
467
|
+
['padding_right', 'i16'],
|
|
468
|
+
['padding_bottom', 'i16'],
|
|
469
|
+
['margin', 'i16'],
|
|
470
|
+
['margin_left', 'i16'],
|
|
471
|
+
['margin_top', 'i16'],
|
|
472
|
+
['margin_right', 'i16'],
|
|
473
|
+
['margin_bottom', 'i16'],
|
|
474
|
+
['gap', 'i16'],
|
|
475
|
+
['row_gap', 'i16'],
|
|
476
|
+
['column_gap', 'i16'],
|
|
477
|
+
['flex_grow', 'i16'],
|
|
478
|
+
['flex_shrink', 'i16'],
|
|
479
|
+
['flex_basis', 'i16'],
|
|
480
|
+
['flex_direction', 'enum', 3],
|
|
481
|
+
['flex_wrap', 'enum', 2],
|
|
482
|
+
['align_items', 'enum', 4],
|
|
483
|
+
['align_self', 'enum', 4],
|
|
484
|
+
['align_content', 'enum', 5],
|
|
485
|
+
['justify_content', 'enum', 5],
|
|
486
|
+
['position', 'enum', 1],
|
|
487
|
+
['display', 'enum', 1],
|
|
488
|
+
['aspect_ratio', 'float'],
|
|
489
|
+
['margin_horizontal', 'i16'],
|
|
490
|
+
['margin_vertical', 'i16'],
|
|
491
|
+
['padding_horizontal', 'i16'],
|
|
492
|
+
['padding_vertical', 'i16'],
|
|
493
|
+
['flex_basis_percent', 'float'],
|
|
494
|
+
['width_percent', 'float'],
|
|
495
|
+
['height_percent', 'float'],
|
|
496
|
+
['left_percent', 'float'],
|
|
497
|
+
['top_percent', 'float'],
|
|
498
|
+
['right_percent', 'float'],
|
|
499
|
+
['bottom_percent', 'float'],
|
|
500
|
+
['background_color', 'color'],
|
|
501
|
+
['border_color', 'color'],
|
|
502
|
+
['border_width', 'i16'],
|
|
503
|
+
['border_radius', 'i16'],
|
|
504
|
+
['border_top_left_radius', 'i16'],
|
|
505
|
+
['border_top_right_radius', 'i16'],
|
|
506
|
+
['border_bottom_left_radius', 'i16'],
|
|
507
|
+
['border_bottom_right_radius', 'i16'],
|
|
508
|
+
['border_left_width', 'i16'],
|
|
509
|
+
['border_top_width', 'i16'],
|
|
510
|
+
['border_right_width', 'i16'],
|
|
511
|
+
['border_bottom_width', 'i16'],
|
|
512
|
+
['border_left_color', 'color'],
|
|
513
|
+
['border_top_color', 'color'],
|
|
514
|
+
['border_right_color', 'color'],
|
|
515
|
+
['border_bottom_color', 'color'],
|
|
516
|
+
['border_style', 'enum', 2],
|
|
517
|
+
['z_index', 'i16'],
|
|
518
|
+
['opacity', 'opacity'],
|
|
519
|
+
['overflow', 'enum', 2],
|
|
520
|
+
['pointer_events', 'enum', 3],
|
|
521
|
+
['hit_slop_left', 'i16'],
|
|
522
|
+
['hit_slop_top', 'i16'],
|
|
523
|
+
['hit_slop_right', 'i16'],
|
|
524
|
+
['hit_slop_bottom', 'i16'],
|
|
525
|
+
['long_press_ms', 'u16'],
|
|
526
|
+
['text', 'string'],
|
|
527
|
+
['font_family', 'string'],
|
|
528
|
+
['color', 'color'],
|
|
529
|
+
['font_size', 'u8'],
|
|
530
|
+
['font_weight', 'enum', 1],
|
|
531
|
+
['font_style', 'enum', 1],
|
|
532
|
+
['text_align', 'enum', 2],
|
|
533
|
+
['number_of_lines', 'u8'],
|
|
534
|
+
['ellipsize_mode', 'enum', 3],
|
|
535
|
+
['text_decoration', 'enum', 2],
|
|
536
|
+
['line_height', 'i16'],
|
|
537
|
+
['letter_spacing', 'i16'],
|
|
538
|
+
['image_name', 'image'],
|
|
539
|
+
['resize_mode', 'enum', 4],
|
|
540
|
+
['tint_color', 'color'],
|
|
541
|
+
['transform_translate_x', 'float'],
|
|
542
|
+
['transform_translate_y', 'float'],
|
|
543
|
+
['transform_scale_x', 'float'],
|
|
544
|
+
['transform_scale_y', 'float'],
|
|
545
|
+
['transform_rotate_z', 'float'],
|
|
546
|
+
['transform_origin_x', 'float'],
|
|
547
|
+
['transform_origin_y', 'float'],
|
|
548
|
+
['transform_rotate_x', 'float'],
|
|
549
|
+
['transform_rotate_y', 'float'],
|
|
550
|
+
['transform_perspective', 'float'],
|
|
551
|
+
['shadow_color', 'color'],
|
|
552
|
+
['shadow_offset_x', 'float'],
|
|
553
|
+
['shadow_offset_y', 'float'],
|
|
554
|
+
['shadow_opacity', 'float'],
|
|
555
|
+
['shadow_radius', 'u8'],
|
|
556
|
+
['elevation', 'u8'],
|
|
557
|
+
['indicator_color', 'color'],
|
|
558
|
+
['animating', 'bool'],
|
|
559
|
+
['switch_value', 'bool'],
|
|
560
|
+
['track_color_false', 'color'],
|
|
561
|
+
['track_color_true', 'color'],
|
|
562
|
+
['thumb_color', 'color'],
|
|
563
|
+
['placeholder', 'string'],
|
|
564
|
+
['placeholder_color', 'color'],
|
|
565
|
+
['cursor_color', 'color'],
|
|
566
|
+
['editable', 'bool'],
|
|
567
|
+
['secure_text_entry', 'bool'],
|
|
568
|
+
['modal_visible', 'bool'],
|
|
569
|
+
['backdrop_color', 'color'],
|
|
570
|
+
['arc_value', 'float'],
|
|
571
|
+
['arc_value_start', 'float'],
|
|
572
|
+
['arc_min_span', 'float'],
|
|
573
|
+
['arc_min', 'float'],
|
|
574
|
+
['arc_max', 'float'],
|
|
575
|
+
['arc_start_angle', 'float'],
|
|
576
|
+
['arc_sweep_angle', 'float'],
|
|
577
|
+
['arc_step', 'float'],
|
|
578
|
+
['arc_gap_angle', 'float'],
|
|
579
|
+
['arc_width', 'i16'],
|
|
580
|
+
['arc_band_width', 'i16'],
|
|
581
|
+
['arc_knob_size', 'i16'],
|
|
582
|
+
['arc_knob_border_width', 'i16'],
|
|
583
|
+
['arc_track_color', 'color'],
|
|
584
|
+
['arc_indicator_color', 'color'],
|
|
585
|
+
['arc_band_color', 'color'],
|
|
586
|
+
['arc_knob_color', 'color'],
|
|
587
|
+
['arc_knob_border_color', 'color'],
|
|
588
|
+
['arc_segments', 'u8'],
|
|
589
|
+
['arc_cap', 'enum', 1],
|
|
590
|
+
['arc_knob', 'enum', 3],
|
|
591
|
+
['arc_adjustable', 'bool'],
|
|
592
|
+
['arc_range', 'bool'],
|
|
593
|
+
['gradient_type', 'enum', 3],
|
|
594
|
+
['gradient_angle', 'float'],
|
|
595
|
+
['gradient_stop_count', 'enum', 4],
|
|
596
|
+
['gradient_stops[0].color', 'color'],
|
|
597
|
+
['gradient_stops[1].color', 'color'],
|
|
598
|
+
['gradient_stops[2].color', 'color'],
|
|
599
|
+
['gradient_stops[3].color', 'color'],
|
|
600
|
+
['gradient_stops[0].position', 'float'],
|
|
601
|
+
['gradient_stops[1].position', 'float'],
|
|
602
|
+
['gradient_stops[2].position', 'float'],
|
|
603
|
+
['gradient_stops[3].position', 'float'],
|
|
604
|
+
];
|
|
605
|
+
/** Span props start at this id, SPAN_STRIDE ids per span. */
|
|
606
|
+
export const SPAN_PROP_FIRST = 160;
|
|
607
|
+
export const SPAN_STRIDE = 8;
|
|
608
|
+
export const MAX_SPANS = 4;
|
|
609
|
+
/** A span's fields, in its ids. */
|
|
610
|
+
const SPAN_FIELDS = [
|
|
611
|
+
['color', 'color'],
|
|
612
|
+
['font_size', 'u8'],
|
|
613
|
+
['font_weight', 'u8'],
|
|
614
|
+
['font_style', 'u8'],
|
|
615
|
+
['text_decoration', 'u8'],
|
|
616
|
+
['letter_spacing', 'i16'],
|
|
617
|
+
];
|
|
618
|
+
/** Every ABI prop, by the ERProps field it sets. */
|
|
619
|
+
export const ABI_PROPS = new Map([
|
|
620
|
+
...PROPS_IN_ORDER.map(([field, kind, max], index) => [
|
|
621
|
+
field,
|
|
622
|
+
max === undefined ? { id: index + 1, kind } : { id: index + 1, kind, max },
|
|
623
|
+
]),
|
|
624
|
+
...Array.from({ length: MAX_SPANS }, (_, span) => SPAN_FIELDS.map(([field, kind], fieldIndex) => [
|
|
625
|
+
`spans[${span}].${field}`,
|
|
626
|
+
{ id: SPAN_PROP_FIRST + span * SPAN_STRIDE + fieldIndex, kind },
|
|
627
|
+
])).flat(),
|
|
628
|
+
]);
|
|
629
|
+
/*----------------------------------------------------------------------------------------------------------------------
|
|
630
|
+
- Engine values
|
|
631
|
+
---------------------------------------------------------------------------------------------------------------------*/
|
|
632
|
+
/** er_scene.h's ER_LAYOUT_AUTO (INT16_MIN). */
|
|
633
|
+
export const LAYOUT_AUTO = -32768;
|
|
634
|
+
/** The er_scene.h names constant props and node types use and their values. */
|
|
635
|
+
export const ENGINE_VALUES = new Map([
|
|
636
|
+
['ER_LAYOUT_AUTO', LAYOUT_AUTO],
|
|
637
|
+
['ER_NODE_VIEW', 0],
|
|
638
|
+
['ER_NODE_TEXT', 1],
|
|
639
|
+
['ER_NODE_IMAGE', 2],
|
|
640
|
+
['ER_NODE_SCROLL_VIEW', 3],
|
|
641
|
+
['ER_NODE_FLAT_LIST', 4],
|
|
642
|
+
['ER_NODE_PRESSABLE', 5],
|
|
643
|
+
['ER_NODE_TEXT_INPUT', 6],
|
|
644
|
+
['ER_NODE_ACTIVITY_INDICATOR', 7],
|
|
645
|
+
['ER_NODE_SWITCH', 8],
|
|
646
|
+
['ER_NODE_MODAL', 9],
|
|
647
|
+
['ER_NODE_VECTOR', 10],
|
|
648
|
+
['ER_NODE_ARC', 11],
|
|
649
|
+
['ER_FLEX_COLUMN', 0],
|
|
650
|
+
['ER_FLEX_ROW', 1],
|
|
651
|
+
['ER_FLEX_ROW_REVERSE', 2],
|
|
652
|
+
['ER_FLEX_COLUMN_REVERSE', 3],
|
|
653
|
+
['ER_WRAP_NOWRAP', 0],
|
|
654
|
+
['ER_WRAP_WRAP', 1],
|
|
655
|
+
['ER_WRAP_WRAP_REVERSE', 2],
|
|
656
|
+
['ER_ALIGN_AUTO', 0],
|
|
657
|
+
['ER_ALIGN_STRETCH', 1],
|
|
658
|
+
['ER_ALIGN_FLEX_START', 2],
|
|
659
|
+
['ER_ALIGN_CENTER', 3],
|
|
660
|
+
['ER_ALIGN_FLEX_END', 4],
|
|
661
|
+
['ER_ALIGN_CONTENT_FLEX_START', 0],
|
|
662
|
+
['ER_ALIGN_CONTENT_FLEX_END', 1],
|
|
663
|
+
['ER_ALIGN_CONTENT_CENTER', 2],
|
|
664
|
+
['ER_ALIGN_CONTENT_STRETCH', 3],
|
|
665
|
+
['ER_ALIGN_CONTENT_SPACE_BETWEEN', 4],
|
|
666
|
+
['ER_ALIGN_CONTENT_SPACE_AROUND', 5],
|
|
667
|
+
['ER_JUSTIFY_FLEX_START', 0],
|
|
668
|
+
['ER_JUSTIFY_CENTER', 1],
|
|
669
|
+
['ER_JUSTIFY_FLEX_END', 2],
|
|
670
|
+
['ER_JUSTIFY_SPACE_BETWEEN', 3],
|
|
671
|
+
['ER_JUSTIFY_SPACE_AROUND', 4],
|
|
672
|
+
['ER_JUSTIFY_SPACE_EVENLY', 5],
|
|
673
|
+
['ER_POSITION_RELATIVE', 0],
|
|
674
|
+
['ER_POSITION_ABSOLUTE', 1],
|
|
675
|
+
['ER_DISPLAY_FLEX', 0],
|
|
676
|
+
['ER_DISPLAY_NONE', 1],
|
|
677
|
+
['ER_BORDER_SOLID', 0],
|
|
678
|
+
['ER_BORDER_DASHED', 1],
|
|
679
|
+
['ER_BORDER_DOTTED', 2],
|
|
680
|
+
['ER_OVERFLOW_VISIBLE', 0],
|
|
681
|
+
['ER_OVERFLOW_HIDDEN', 1],
|
|
682
|
+
['ER_OVERFLOW_SCROLL', 2],
|
|
683
|
+
['ER_POINTER_EVENTS_AUTO', 0],
|
|
684
|
+
['ER_POINTER_EVENTS_NONE', 1],
|
|
685
|
+
['ER_POINTER_EVENTS_BOX_ONLY', 2],
|
|
686
|
+
['ER_POINTER_EVENTS_BOX_NONE', 3],
|
|
687
|
+
['ER_FONT_STYLE_NORMAL', 0],
|
|
688
|
+
['ER_FONT_STYLE_ITALIC', 1],
|
|
689
|
+
['ER_TEXT_ALIGN_LEFT', 0],
|
|
690
|
+
['ER_TEXT_ALIGN_CENTER', 1],
|
|
691
|
+
['ER_TEXT_ALIGN_RIGHT', 2],
|
|
692
|
+
['ER_TEXT_ELLIPSIZE_TAIL', 0],
|
|
693
|
+
['ER_TEXT_ELLIPSIZE_HEAD', 1],
|
|
694
|
+
['ER_TEXT_ELLIPSIZE_MIDDLE', 2],
|
|
695
|
+
['ER_TEXT_ELLIPSIZE_CLIP', 3],
|
|
696
|
+
['ER_TEXT_DECORATION_NONE', 0],
|
|
697
|
+
['ER_TEXT_DECORATION_UNDERLINE', 1],
|
|
698
|
+
['ER_TEXT_DECORATION_LINE_THROUGH', 2],
|
|
699
|
+
['ER_RESIZE_COVER', 0],
|
|
700
|
+
['ER_RESIZE_CONTAIN', 1],
|
|
701
|
+
['ER_RESIZE_STRETCH', 2],
|
|
702
|
+
['ER_RESIZE_REPEAT', 3],
|
|
703
|
+
['ER_RESIZE_CENTER', 4],
|
|
704
|
+
['ER_ARC_CAP_BUTT', 0],
|
|
705
|
+
['ER_ARC_CAP_ROUND', 1],
|
|
706
|
+
['ER_ARC_KNOB_NONE', 0],
|
|
707
|
+
['ER_ARC_KNOB_CIRCLE', 1],
|
|
708
|
+
['ER_ARC_KNOB_IMAGE', 2],
|
|
709
|
+
['ER_ARC_KNOB_CHILD', 3],
|
|
710
|
+
['ER_GRADIENT_NONE', 0],
|
|
711
|
+
['ER_GRADIENT_LINEAR', 1],
|
|
712
|
+
['ER_GRADIENT_RADIAL', 2],
|
|
713
|
+
['ER_GRADIENT_CONIC', 3],
|
|
714
|
+
['ER_EVENT_PRESS', 0],
|
|
715
|
+
['ER_EVENT_LONG_PRESS', 1],
|
|
716
|
+
['ER_EVENT_PRESS_IN', 2],
|
|
717
|
+
['ER_EVENT_PRESS_OUT', 3],
|
|
718
|
+
['ER_EVENT_TOUCH_START', 4],
|
|
719
|
+
['ER_EVENT_TOUCH_MOVE', 5],
|
|
720
|
+
['ER_EVENT_TOUCH_END', 6],
|
|
721
|
+
['ER_EVENT_TOUCH_CANCEL', 7],
|
|
722
|
+
['ER_EVENT_SCROLL', 8],
|
|
723
|
+
['ER_EVENT_RESPONDER_GRANT', 9],
|
|
724
|
+
['ER_EVENT_RESPONDER_REJECT', 10],
|
|
725
|
+
['ER_EVENT_RESPONDER_MOVE', 11],
|
|
726
|
+
['ER_EVENT_RESPONDER_RELEASE', 12],
|
|
727
|
+
['ER_EVENT_RESPONDER_TERMINATE', 13],
|
|
728
|
+
['ER_EVENT_LAYOUT', 14],
|
|
729
|
+
['ER_EVENT_CHANGE_TEXT', 15],
|
|
730
|
+
['ER_EVENT_SUBMIT_EDITING', 16],
|
|
731
|
+
['ER_EVENT_FOCUS', 17],
|
|
732
|
+
['ER_EVENT_BLUR', 18],
|
|
733
|
+
['ER_EVENT_VALUE_CHANGE', 19],
|
|
734
|
+
['ER_QUERY_START_SHOULD_SET', 0],
|
|
735
|
+
['ER_QUERY_START_SHOULD_SET_CAPTURE', 1],
|
|
736
|
+
['ER_QUERY_MOVE_SHOULD_SET', 2],
|
|
737
|
+
['ER_QUERY_MOVE_SHOULD_SET_CAPTURE', 3],
|
|
738
|
+
['ER_QUERY_TERMINATION_REQUEST', 4],
|
|
739
|
+
['ER_EASE_LINEAR', 0],
|
|
740
|
+
['ER_EASE_EASE', 1],
|
|
741
|
+
['ER_EASE_EASE_IN', 2],
|
|
742
|
+
['ER_EASE_EASE_OUT', 3],
|
|
743
|
+
['ER_EASE_EASE_IN_OUT', 4],
|
|
744
|
+
['ER_EASE_QUAD_IN', 5],
|
|
745
|
+
['ER_EASE_QUAD_OUT', 6],
|
|
746
|
+
['ER_EASE_QUAD_IN_OUT', 7],
|
|
747
|
+
['ER_EASE_CUBIC_IN', 8],
|
|
748
|
+
['ER_EASE_CUBIC_OUT', 9],
|
|
749
|
+
['ER_EASE_CUBIC_IN_OUT', 10],
|
|
750
|
+
['ER_EASE_BOUNCE_OUT', 11],
|
|
751
|
+
['ER_EASE_ELASTIC_OUT', 12],
|
|
752
|
+
['ER_EASE_BEZIER', 13],
|
|
753
|
+
['ER_EXTRAPOLATE_EXTEND', 0],
|
|
754
|
+
['ER_EXTRAPOLATE_CLAMP', 1],
|
|
755
|
+
['ER_EXTRAPOLATE_IDENTITY', 2],
|
|
756
|
+
['ER_KEYBOARD_KEY_CHAR', 0],
|
|
757
|
+
['ER_KEYBOARD_KEY_BACKSPACE', 1],
|
|
758
|
+
['ER_KEYBOARD_KEY_DONE', 2],
|
|
759
|
+
['ER_KEYBOARD_KEY_LAYER', 3],
|
|
760
|
+
]);
|