2 name: "elm/layout/dialer/main";
7 * Represents the dialer main layout with actions and swallows.
10 * SWALLOW: elm.swallow.keypad
11 * SWALLOW: elm.swallow.contacts
12 * SWALLOW: elm.swallow.history
13 * SWALLOW: elm.swallow.activecall
16 * Emit (source is "gui"):
17 * pressed,<ID>: key <ID> was pressed
18 * released,<ID>: key <ID> was released
19 * clicked,<ID>: key <ID> was clicked (press and release in the key)
20 * Listens (source is "gui"):
21 * show,<ID>: have <ID> to be visible (swallow and action)
22 * toggle,on,<ID>: force <ID> to be marked as selected
23 * toggle,off,<ID>: force <ID> to be marked as unselected
25 * Where <ID> is: keypad, contacts, history, activecall.
29 image: "ico_keypad.png" COMP;
30 image: "ico_contacts.png" COMP;
31 image: "ico_history.png" COMP;
46 name: "elm.swallow.activecall";
48 api: "activecall" "where to place the active call, if any";
62 inherit: "default" 0.0;
68 signal: "show,activecall";
70 action: STATE_SET "visible" 0.0;
71 target: "elm.swallow.activecall";
72 api: "activecall_show" "make the activecall swallow visible";
75 signal: "hide,activecall";
77 action: STATE_SET "default" 0.0;
78 target: "elm.swallow.activecall";
79 api: "activecall_hide" "make the activecall swallow hidden";
84 name: "elm.swallow.keypad";
86 api: "keypad" "where to place the keypad";
90 to_y: "elm.swallow.activecall";
94 rel2.offset: -1 (-ACTION_HEIGHT - 1);
98 inherit: "default" 0.0;
103 name: "elm.swallow.contacts";
105 api: "contacts" "where to place the contacts";
107 state: "default" 0.0;
109 to_y: "elm.swallow.activecall";
113 rel2.offset: -1 (-ACTION_HEIGHT - 1);
117 inherit: "default" 0.0;
122 name: "elm.swallow.history";
124 api: "history" "where to place the history";
126 state: "default" 0.0;
128 to_y: "elm.swallow.activecall";
132 rel2.offset: -1 (-ACTION_HEIGHT - 1);
136 inherit: "default" 0.0;
146 state: "default" 0.0;
148 min: WIDTH ACTION_HEIGHT;
149 max: WIDTH 99999; /* keep it tight centered */
153 offset: 0 -ACTION_HEIGHT;
158 #define ACTION_TOGGLE(id, x1, x2) \
160 name: "button."##id; \
163 clip_to: "clipper.toggle."##id; \
165 state: "default" 0.0; \
166 color: 255 255 255 0; \
167 color_class: "action"; \
168 min: ACTION_WIDTH ACTION_HEIGHT; \
169 max: ACTION_WIDTH ACTION_HEIGHT; \
182 state: "pressed" 0.0; \
183 inherit: "default" 0.0; \
184 color: 255 255 255 255; \
188 name: "button.ico."##id; \
191 clip_to: "clipper.toggle."##id; \
193 state: "default" 0.0; \
194 color: 255 255 255 255; \
195 color_class: "action"; \
196 min: ACTION_HEIGHT ACTION_HEIGHT; \
197 max: ACTION_HEIGHT ACTION_HEIGHT; \
199 rel1.to: "button."##id; \
200 rel2.to: "button."##id; \
201 image.normal: "ico_"##id".png"; \
204 state: "pressed" 0.0; \
205 inherit: "default" 0.0; \
210 name: "clipper.toggle."##id; \
214 state: "default" 0.0; \
215 color: 255 255 255 255; \
220 inherit: "default" 0.0; \
221 color: 255 255 255 0; \
226 name: "button.toggle."##id; \
230 state: "default" 0.0; \
231 color: 255 255 255 0; \
232 color_class: "action"; \
233 min: ACTION_WIDTH ACTION_HEIGHT; \
234 max: ACTION_WIDTH ACTION_HEIGHT; \
249 inherit: "default" 0.0; \
250 color: 255 255 255 255; \
255 name: "button.toggle.ico."##id; \
259 state: "default" 0.0; \
260 color: 255 255 255 255; \
261 color_class: "action"; \
262 min: ACTION_HEIGHT ACTION_HEIGHT; \
263 max: ACTION_HEIGHT ACTION_HEIGHT; \
266 rel1.to: "button.toggle."##id; \
267 rel2.to: "button.toggle."##id; \
268 image.normal: "ico_"##id".png"; \
272 inherit: "default" 0.0; \
278 name: "blocker."##id; \
282 state: "default" 0.0; \
287 state: "disabled" 0.0; \
288 inherit: "default" 0.0; \
294 signal: "mouse,up,1"; \
295 source: "button."##id; \
296 action: SIGNAL_EMIT "released,"##id "gui"; \
297 after: "show_up_"##id; \
298 api: id"_released" id" was released"; \
301 name: "show_up_"##id; \
302 action: STATE_SET "default" 0.0; \
303 transition: DECELERATE 0.1; \
304 target: "button."##id; \
305 target: "button.ico."##id; \
308 signal: "mouse,down,1"; \
309 source: "button."##id; \
310 after: "show_down_"##id; \
311 action: SIGNAL_EMIT "pressed,"##id "gui"; \
312 api: id"_pressed" id" was pressed"; \
315 name: "show_down_"##id; \
316 action: STATE_SET "pressed" 0.0; \
317 transition: ACCELERATE 0.1; \
318 target: "button."##id; \
319 target: "button.ico."##id; \
322 signal: "mouse,clicked,1"; \
323 source: "button."##id; \
324 action: SIGNAL_EMIT "clicked,"##id "gui"; \
325 api: id"_clicked" id" was clicked"; \
328 signal: "mouse,clicked,1"; \
329 source: "button.toggle."##id; \
330 action: SIGNAL_EMIT "clicked,"##id "gui"; \
331 api: id"_clicked" id" was clicked"; \
334 signal: "toggle,on,"##id; \
336 action: STATE_SET "on" 0.0; \
337 target: "clipper.toggle."##id; \
338 target: "button.toggle."##id; \
339 target: "button.toggle.ico."##id; \
342 signal: "toggle,off,"##id; \
344 action: STATE_SET "default" 0.0; \
345 target: "clipper.toggle."##id; \
346 target: "button.toggle."##id; \
347 target: "button.toggle.ico."##id; \
351 ACTION_TOGGLE("keypad", 0.000000000, 0.333333333);
352 ACTION_TOGGLE("contacts", 0.333333333, 0.666666666);
353 ACTION_TOGGLE("history", 0.666666666, 1.000000000);
358 name: "show-keypad-swallow-phase1";
359 signal: "show,keypad";
361 action: STATE_SET "hidden" 0.0;
362 target: "elm.swallow.contacts";
363 target: "elm.swallow.history";
364 after: "show-keypad-swallow-phase2";
367 name: "show-keypad-swallow-phase2";
368 action: STATE_SET "default" 0.0;
369 target: "elm.swallow.keypad";
373 signal: "show,keypad";
375 action: SIGNAL_EMIT "toggle,on,keypad" "gui";
378 signal: "show,keypad";
380 action: SIGNAL_EMIT "toggle,off,contacts" "gui";
383 signal: "show,keypad";
385 action: SIGNAL_EMIT "toggle,off,history" "gui";
389 name: "show-contacts-swallow-phase1";
390 signal: "show,contacts";
392 action: STATE_SET "hidden" 0.0;
393 target: "elm.swallow.keypad";
394 target: "elm.swallow.history";
395 after: "show-contacts-swallow-phase2";
398 name: "show-contacts-swallow-phase2";
399 action: STATE_SET "default" 0.0;
400 target: "elm.swallow.contacts";
404 signal: "show,contacts";
406 action: SIGNAL_EMIT "toggle,on,contacts" "gui";
409 signal: "show,contacts";
411 action: SIGNAL_EMIT "toggle,off,keypad" "gui";
414 signal: "show,contacts";
416 action: SIGNAL_EMIT "toggle,off,history" "gui";
420 name: "show-history-swallow-phase1";
421 signal: "show,history";
423 action: STATE_SET "hidden" 0.0;
424 target: "elm.swallow.contacts";
425 target: "elm.swallow.keypad";
426 after: "show-history-swallow-phase2";
429 name: "show-history-swallow-phase2";
430 action: STATE_SET "default" 0.0;
431 target: "elm.swallow.history";
435 signal: "show,history";
437 action: SIGNAL_EMIT "toggle,on,history" "gui";
440 signal: "show,history";
442 action: SIGNAL_EMIT "toggle,off,contacts" "gui";
445 signal: "show,history";
447 action: SIGNAL_EMIT "toggle,off,keypad" "gui";