[Button] searchbar cancel button is modified
[framework/uifw/efl-theme-tizen.git] / themes / widgets / button.edc
1 /*
2  * Copyright (c) 2010 Samsung Electronics Co., Ltd All Rights Reserved 
3  *
4  * PROPRIETARY/CONFIDENTIAL
5  *
6  * This software is the confidential and proprietary information of SAMSUNG
7  * ELECTRONICS ("Confidential Information"). You agree and acknowledge that this
8  * software is owned by Samsung and you shall not disclose such Confidential
9  * Information and shall use it only in accordance with the terms of the license
10  * agreement you entered into with SAMSUNG ELECTRONICS. SAMSUNG make no
11  * representations or warranties about the suitability of the software, either
12  * express or implied, including but not limited to the implied warranties of
13  * merchantability, fitness for a particular purpose, or non-infringement.
14  * SAMSUNG shall not be liable for any damages suffered by licensee arising out
15  * of or releated to this software.
16  *
17  */
18
19 #define BUTTON_STATE_ENABLED 0
20 #define BUTTON_STATE_DISABLED 1
21
22    sounds {
23       sample {
24          name: "touch_sound" AS_IS;
25          source: "S_Touch_30ms.wav";
26       }
27    }
28
29 ///////////////////////////////////////////////////////////////////////////////////////
30    group { name: "elm/button/base/style1";
31       alias: "elm/button/base/text_only/style1";
32       alias: "elm/button/base/center";
33       alias: "elm/button/base/icon_and_text/center";
34       alias: "elm/button/base/nocontents/search_button";
35       images {
36          image: "00_button_01_normal.png" COMP;
37          image: "00_button_01_normal_press.png" COMP;
38          image: "00_button_01_normal_dim.png" COMP;
39          image: "00_button_01_normal_Focus.png" COMP;
40       }
41       script {
42          public button_state = BUTTON_STATE_ENABLED;
43       }
44       parts {
45          part { name: "button_image";
46             scale: 1;
47             description { state: "default" 0.0;
48                image {
49                   normal: "00_button_01_normal.png";
50                   border: BUTTON_TEXT_STYLE1_BG_BORDER_INC;
51                   border_scale: 1;
52                }
53             }
54             description { state: "clicked" 0.0;
55                inherit: "default" 0.0;
56                image.normal: "00_button_01_normal_press.png";
57             }
58             description { state: "disabled" 0.0;
59                inherit: "default" 0.0;
60                image.normal: "00_button_01_normal_dim.png";
61             }
62             description { state: "focused" 0.0;
63                inherit: "default" 0.0;
64                image.normal: "00_button_01_normal_Focus.png";
65             }
66          }
67          part { name: "padding_left_top";
68             type: RECT;
69             scale: 1;
70             mouse_events: 0;
71             description { state: "default" 0.0;
72                align: 0.0 0.0;
73                rel2.relative: 0.0 0.0;
74                min: BUTTON_TEXT_STYLE1_PADDING_MIN_INC;
75                fixed: 1 1;
76                visible: 0;
77             }
78          }
79          part { name: "bg";
80             type: RECT;
81             scale: 1;
82             mouse_events: 0;
83             description { state: "default" 0.0;
84                min: BUTTON_TEXT_STYLE1_BG_MIN_INC;
85                visible: 0;
86             }
87             description { state: "visible" 0.0;
88                inherit: "default" 0.0;
89                min: BUTTON_TEXT_STYLE1_VISIBLE_BG_MIN_INC;
90             }
91             description { state: "icononly" 0.0;
92                inherit: "default" 0.0;
93                min: BUTTON_TEXT_STYLE1_ICONONLY_BG_MIN_INC;
94             }
95          }
96          part { name: "padding_right_bottom";
97             type: RECT;
98             scale: 1;
99             mouse_events: 0;
100             description { state: "default" 0.0;
101                align: 1.0 1.0;
102                rel1.relative: 1.0 1.0;
103                min: BUTTON_TEXT_STYLE1_PADDING_MIN_INC;
104                fixed: 1 1;
105                visible: 0;
106             }
107          }
108          part { name: "icon_rect";
109             type: RECT;
110             scale: 1;
111             mouse_events: 0;
112             description { state: "default" 0.0;
113                visible: 0;
114                min: 0 0;
115                fixed: 1 0;
116                rel1 {
117                   relative: 1.0 1.0;
118                   to: "padding_left_top";
119                }
120                rel2 {
121                   relative: 1.0 0.0;
122                   to_x: "padding_left_top";
123                   to_y: "padding_right_bottom";
124                }
125                align: 0.0 0.5;
126             }
127             description { state: "visible" 0.0;
128                visible: 0;
129                min: BUTTON_TEXT_STYLE1_VISIBLE_ICON_RECT_MIN_MAX_INC;
130                max: BUTTON_TEXT_STYLE1_VISIBLE_ICON_RECT_MIN_MAX_INC;
131                fixed: 1 0;
132                rel1 {
133                   relative: 1.0 1.0;
134                   to: "padding_left_top";
135                }
136                rel2 {
137                   relative: 1.0 0.0;
138                   to_x: "padding_left_top";
139                   to_y: "padding_right_bottom";
140                }
141                align: 0.0 0.5;
142             }
143             description { state: "icononly" 0.0;
144                inherit: "default" 0.0;
145             }
146          }
147          part { name: "padding_after_icon";
148             type: RECT;
149             scale: 1;
150             mouse_events: 0;
151             description { state: "default" 0.0; //when only icon or no icon is there
152                align: 0.0 0.0;
153                rel1 {
154                   relative: 1.0 0.0;
155                   to: "icon_rect";
156                }
157                rel2.to: "icon_rect";
158                fixed: 1 0;
159                min: 0 0;
160                visible: 0;
161             }
162             description { state: "visible" 0.0;
163                visible: 0;
164                align: 0.0 0.0;
165                rel1 {
166                   relative: 1.0 0.0;
167                   to: "icon_rect";
168                }
169                rel2.to: "icon_rect";
170                fixed: 1 0;
171                min: BUTTON_TEXT_STYLE1_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
172             }
173             description { state: "icononly" 0.0;
174                inherit: "default" 0.0;
175             }
176          }
177          part { name: "padding_before_text";
178             type: RECT;
179             scale: 1;
180             mouse_events: 0;
181             description { state: "default" 0.0; //when only icon or no icon is there
182                align: 1.0 0.5;
183                rel1 {
184                   relative: 0.0 1.0;
185                   to_x: "elm.text";
186                   to_y: "padding_left_top";
187                }
188                rel2 {
189                   relative: 0.0 0.0;
190                   to_x: "elm.text";
191                   to_y: "padding_right_bottom";
192                }
193                fixed: 1 0;
194                min: BUTTON_TEXT_STYLE1_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
195                visible: 0;
196             }
197          }
198          part { name: "elm.swallow.content";
199             type: SWALLOW;
200             scale: 1;
201             clip_to: "clipper";
202             description { state: "default" 0.0;
203                visible: 0;
204                align: 0.0 0.5;
205                rel1 {
206                   relative: 1.0 1.0;
207                   to: "padding_left_top";
208                }
209                rel2 {
210                   relative: 1.0 0.0;
211                   to_x: "padding_left_top";
212                   to_y: "padding_right_bottom";
213                }
214                fixed: 1 0;
215             }
216             description { state: "visible" 0.0;
217                fixed: 1 0;
218                min: BUTTON_TEXT_STYLE1_VISIBLE_ICON_MIN_MAX_INC;
219                max: BUTTON_TEXT_STYLE1_VISIBLE_ICON_MIN_MAX_INC;
220                align: 1.0 0.5;
221                rel1 {
222                   relative: 0.0 1.0;
223                   to_x: "padding_before_text";
224                   to_y: "padding_left_top";
225                }
226                rel2 {
227                   relative: 0.0 0.0;
228                   to_x: "padding_before_text";
229                   to_y: "padding_right_bottom";
230                }
231             }
232             description { state: "icononly" 0.0;
233                min: BUTTON_TEXT_STYLE1_ICONONLY_ICON_MIN_MAX_INC;
234                max: BUTTON_TEXT_STYLE1_ICONONLY_ICON_MIN_MAX_INC;
235             }
236          }
237          part { name: "elm.text";
238             type: TEXT;
239             mouse_events: 0;
240             scale: 1;
241             clip_to: "clipper";
242             description { state: "default" 0.0;
243                visible: 0;
244                rel1 {
245                   relative: 1.0 1.0;
246                   to_x: "padding_after_icon";
247                   to_y: "padding_left_top";
248                }
249                rel2 {
250                   relative: 0.0 0.0;
251                   to: "padding_right_bottom";
252                }
253                color: BUTTON_TEXT_STYLE1_NORMAL_COLOR_INC;
254                text {
255                   font: "SLP:style=Medium";
256                   size: BUTTON_TEXT_STYLE1_FONT_SIZE_INC;
257                   min: 0 0;
258                   max: 1 0;
259                   text_class: "slp_medium";
260                }
261             }
262             description { state: "visible" 0.0;
263                inherit: "default" 0.0;
264                visible: 1;
265             }
266             description { state: "clicked" 0.0;
267                inherit: "default" 0.0;
268                visible: 1;
269                color: BUTTON_TEXT_STYLE1_PRESSED_COLOR_INC;
270             }
271             description { state: "disabled" 0.0;
272                inherit: "default" 0.0;
273                color: 0 0 0 128;
274             }
275             description { state: "disabled_visible" 0.0;
276                inherit: "default" 0.0;
277                color: BUTTON_TEXT_STYLE1_DISABLED_COLOR_INC;
278                visible: 1;
279             }
280             description { state: "focused" 0.0;
281                inherit: "default" 0.0;
282                visible: 1;
283                color: BUTTON_TEXT_STYLE1_FOCUSED_COLOR_INC;
284             }
285          }
286          part { name: "over2";
287             type: RECT;
288             repeat_events: 1;
289             ignore_flags: ON_HOLD;
290             description { state: "default" 0.0;
291                color: 0 0 0 0;
292             }
293          }
294          part { name: "over3";
295             type: RECT;
296             repeat_events: 1;
297             description { state: "default" 0.0;
298                color: 0 0 0 0;
299             }
300          }
301          part { name: "clipper";
302             type: RECT;
303             description { state: "default" 0.0;
304                color: 255 255 255 255;
305             }
306          }
307          part { name: "disabler";
308             type: RECT;
309             description { state: "default" 0.0;
310                color: 0 0 0 0;
311                visible: 0;
312             }
313             description { state: "disabled" 0.0;
314                inherit: "default" 0.0;
315                visible: 1;
316             }
317          }
318       }
319       programs {
320          program { name: "button_click";
321             signal: "mouse,down,1";
322             source: "over2";
323             action: SIGNAL_EMIT "elm,action,press" "";
324             after: "button_click_anim";
325          }
326          program { name: "button_click_anim";
327             action: STATE_SET "clicked" 0.0;
328             target: "button_image";
329             after: "text_clicked";
330          }
331          program { name: "text_clicked";
332             script {
333                new st[31];
334                new Float:vl;
335                get_state(PART:"elm.text", st, 30, vl);
336                if (!strcmp(st, "visible"))
337                  set_state(PART:"elm.text", "clicked", 0.0);
338             }
339          }
340          program { name: "button_unpress";
341             action: SIGNAL_EMIT "elm,action,unpress" "";
342          }
343          program { name: "button_mouseout_clicked";
344             signal: "mouse,up,1";
345             source: "over3";
346             script {
347                new st[31];
348                new Float:vl;
349                get_state(PART:"elm.swallow.content", st, 30, vl);
350                if (strcmp(st, "icononly"))
351                  {
352                     emit("elm,action,default,text,set", "");
353                     set_state(PART:"elm.text", "visible", 0.0);
354                  }
355                if (get_int(button_state) != BUTTON_STATE_DISABLED)
356                  set_state(PART:"button_image", "default", 0.0);
357             }
358             after: button_unpress;
359          }
360          program { name: "touch_snd";
361             signal: "mouse,clicked,1";
362             source: "over2";
363             action: PLAY_SAMPLE "touch_sound" 1.0;
364             after: button_unclick3;
365          }
366          program { name: "button_unclick3";
367             action: SIGNAL_EMIT "elm,action,click" "";
368          }
369          program { name: "text_show";
370             signal: "elm,state,text,visible";
371             source: "elm";
372             script {
373                new st[31];
374                new Float:vl;
375                get_state(PART:"elm.swallow.content", st, 30, vl);
376                if (!strcmp(st, "icononly"))
377                  {
378                     set_state(PART:"elm.swallow.content", "visible", 0.0);
379                     set_state(PART:"icon_rect", "visible", 0.0);
380                     set_state(PART:"padding_after_icon", "visible", 0.0);
381                     set_state(PART:"bg", "visible", 0.0);
382                  }
383                if (get_int(button_state) != BUTTON_STATE_DISABLED)
384                  set_state(PART:"elm.text", "visible", 0.0);
385                else
386                  set_state(PART:"elm.text", "disabled_visible", 0.0);
387             }
388          }
389          program { name: "text_hide";
390             signal: "elm,state,text,hidden";
391             source: "elm";
392             script {
393                new st[31];
394                new Float:vl;
395                get_state(PART:"elm.swallow.content", st, 30, vl);
396                if (!strcmp(st, "visible"))
397                  {
398                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
399                     set_state(PART:"icon_rect", "icononly", 0.0);
400                     set_state(PART:"padding_after_icon", "icononly", 0.0);
401                     set_state(PART:"bg", "icononly", 0.0);
402                  }
403                set_state(PART:"elm.text", "default", 0.0);
404             }
405          }
406          program { name: "icon_show";
407             signal: "elm,state,icon,visible";
408             source: "elm";
409             script {
410                new st[31];
411                new Float:vl;
412                get_state(PART:"elm.text", st, 30, vl);
413                if (!strcmp(st, "visible"))
414                  {
415                     set_state(PART:"elm.swallow.content", "visible", 0.0);
416                     set_state(PART:"icon_rect", "visible", 0.0);
417                     set_state(PART:"padding_after_icon", "visible", 0.0);
418                     set_state(PART:"bg", "visible", 0.0);
419                  }
420                else
421                  {
422                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
423                     set_state(PART:"icon_rect", "icononly", 0.0);
424                     set_state(PART:"padding_after_icon", "icononly", 0.0);
425                     set_state(PART:"bg", "icononly", 0.0);
426                  }
427             }
428          }
429          program { name: "icon_hide";
430             signal: "elm,state,icon,hidden";
431             source: "elm";
432             action: STATE_SET "default" 0.0;
433             target: "elm.swallow.content";
434             target: "padding_after_icon";
435             target: "icon_rect";
436             target: "bg";
437          }
438          program { name: "disable";
439             signal: "elm,state,disabled";
440             source: "elm";
441             action: STATE_SET "disabled" 0.0;
442             target: "button_image";
443             target: "disabler";
444             after: "disable_text";
445          }
446          program { name: "disable_text";
447             script {
448                new st[31];
449                new Float:vl;
450                get_state(PART:"elm.text", st, 30, vl);
451                if (!strcmp(st, "visible"))
452                  set_state(PART:"elm.text", "disabled_visible", 0.0);
453                else
454                  set_state(PART:"elm.text", "disabled", 0.0);
455                set_int(button_state, BUTTON_STATE_DISABLED);
456             }
457          }
458          program { name: "enable";
459             signal: "elm,state,enabled";
460             source: "elm";
461             action: STATE_SET "default" 0.0;
462             target: "button_image";
463             target: "disabler";
464             after: "enable_text";
465          }
466          program { name: "enable_text";
467             script {
468                new st[31];
469                new Float:vl;
470                get_state(PART:"elm.text", st, 30, vl);
471                if (!strcmp(st, "disabled_visible"))
472                  set_state(PART:"elm.text", "visible", 0.0);
473                else
474                  set_state(PART:"elm.text", "default", 0.0);
475                set_int(button_state, BUTTON_STATE_ENABLED);
476             }
477          }
478          program { name: "focused";
479             //signal: "elm,action,focus";
480             //source: "elm";
481             action: STATE_SET "focused" 0.0;
482             target: "button_image";
483             target: "elm.text";
484          }
485          program { name: "unfocused";
486             //signal: "elm,action,unfocus";
487             //source: "elm";
488             action: STATE_SET "default" 0.0;
489             target: "button_image";
490             after: "unfocus_text";
491          }
492          program { name: "unfocus_text";
493             action: STATE_SET "visible" 0.0;
494             target: "elm.text";
495          }
496       }
497    }
498
499 //////////////////////////////////////////////////////////////
500    group { name: "elm/button/base/style1/auto_expand";
501       alias: "elm/button/base/datetime_ampm/default";
502       images {
503          image: "00_button_01_normal.png" COMP;
504          image: "00_button_01_normal_press.png" COMP;
505          image: "00_button_01_normal_dim.png" COMP;
506          image: "00_button_01_normal_Focus.png" COMP;
507       }
508       script {
509          public button_state = BUTTON_STATE_ENABLED;
510       }
511       parts {
512          part { name: "button_image";
513             scale: 1;
514             description { state: "default" 0.0;
515                image {
516                   normal: "00_button_01_normal.png";
517                   border: BUTTON_TEXT_STYLE1_BG_BORDER_INC;
518                   border_scale: 1;
519                }
520             }
521             description { state: "clicked" 0.0;
522                inherit: "default" 0.0;
523                image.normal: "00_button_01_normal_press.png";
524             }
525             description { state: "disabled" 0.0;
526                inherit: "default" 0.0;
527                image.normal: "00_button_01_normal_dim.png";
528             }
529             description { state: "focused" 0.0;
530                inherit: "default" 0.0;
531                image.normal: "00_button_01_normal_Focus.png";
532             }
533          }
534          part { name: "padding_left_top";
535             type: RECT;
536             scale: 1;
537             mouse_events: 0;
538             description { state: "default" 0.0;
539                align: 0.0 0.0;
540                rel2.relative: 0.0 0.0;
541                min: BUTTON_TEXT_STYLE1_PADDING_MIN_INC;
542                fixed: 1 1;
543                visible: 0;
544             }
545          }
546          part { name: "bg";
547             type: RECT;
548             scale: 1;
549             mouse_events: 0;
550             description { state: "default" 0.0;
551                min: BUTTON_TEXT_STYLE1_BG_MIN_INC;
552                visible: 0;
553             }
554             description { state: "visible" 0.0;
555                inherit: "default" 0.0;
556                min: BUTTON_TEXT_STYLE1_VISIBLE_BG_MIN_INC;
557             }
558             description { state: "icononly" 0.0;
559                inherit: "default" 0.0;
560                min: BUTTON_TEXT_STYLE1_ICONONLY_BG_MIN_INC;
561             }
562          }
563          part { name: "padding_right_bottom";
564             type: RECT;
565             scale: 1;
566             mouse_events: 0;
567             description { state: "default" 0.0;
568                align: 1.0 1.0;
569                rel1.relative: 1.0 1.0;
570                min: BUTTON_TEXT_STYLE1_PADDING_MIN_INC;
571                fixed: 1 1;
572                visible: 0;
573             }
574          }
575          part { name: "icon_rect";
576             type: RECT;
577             scale: 1;
578             mouse_events: 0;
579             description { state: "default" 0.0;
580                visible: 0;
581                min: 0 0;
582                fixed: 1 0;
583                rel1 {
584                   relative: 1.0 1.0;
585                   to: "padding_left_top";
586                }
587                rel2 {
588                   relative: 1.0 0.0;
589                   to_x: "padding_left_top";
590                   to_y: "padding_right_bottom";
591                }
592                align: 0.0 0.5;
593             }
594             description { state: "visible" 0.0;
595                visible: 0;
596                min: BUTTON_TEXT_STYLE1_VISIBLE_ICON_RECT_MIN_MAX_INC;
597                max: BUTTON_TEXT_STYLE1_VISIBLE_ICON_RECT_MIN_MAX_INC;
598                fixed: 1 0;
599                rel1 {
600                   relative: 1.0 1.0;
601                   to: "padding_left_top";
602                }
603                rel2 {
604                   relative: 1.0 0.0;
605                   to_x: "padding_left_top";
606                   to_y: "padding_right_bottom";
607                }
608                align: 0.0 0.5;
609             }
610             description { state: "icononly" 0.0;
611                inherit: "default" 0.0;
612             }
613          }
614          part { name: "padding_after_icon";
615             type: RECT;
616             scale: 1;
617             mouse_events: 0;
618             description { state: "default" 0.0; //when only icon or no icon is there
619                align: 0.0 0.0;
620                rel1 {
621                   relative: 1.0 0.0;
622                   to: "icon_rect";
623                }
624                rel2.to: "icon_rect";
625                fixed: 1 0;
626                min: 0 0;
627                visible: 0;
628             }
629             description { state: "visible" 0.0;
630                visible: 0;
631                align: 0.0 0.0;
632                rel1 {
633                   relative: 1.0 0.0;
634                   to: "icon_rect";
635                }
636                rel2.to: "icon_rect";
637                fixed: 1 0;
638                min: BUTTON_TEXT_STYLE1_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
639             }
640             description { state: "icononly" 0.0;
641                inherit: "default" 0.0;
642             }
643          }
644          part { name: "padding_before_text";
645             type: RECT;
646             scale: 1;
647             mouse_events: 0;
648             description { state: "default" 0.0; //when only icon or no icon is there
649                align: 1.0 0.5;
650                rel1 {
651                   relative: 0.0 1.0;
652                   to_x: "elm.text";
653                   to_y: "padding_left_top";
654                }
655                rel2 {
656                   relative: 0.0 0.0;
657                   to_x: "elm.text";
658                   to_y: "padding_right_bottom";
659                }
660                fixed: 1 0;
661                min: BUTTON_TEXT_STYLE1_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
662                visible: 0;
663             }
664          }
665          part { name: "elm.swallow.content";
666             type: SWALLOW;
667             scale: 1;
668             clip_to: "clipper";
669             description { state: "default" 0.0;
670                visible: 0;
671                align: 0.0 0.5;
672                rel1 {
673                   relative: 1.0 1.0;
674                   to: "padding_left_top";
675                }
676                rel2 {
677                   relative: 1.0 0.0;
678                   to_x: "padding_left_top";
679                   to_y: "padding_right_bottom";
680                }
681                fixed: 1 0;
682             }
683             description { state: "visible" 0.0;
684                fixed: 1 0;
685                min: BUTTON_TEXT_STYLE1_VISIBLE_ICON_MIN_MAX_INC;
686                max: BUTTON_TEXT_STYLE1_VISIBLE_ICON_MIN_MAX_INC;
687                align: 1.0 0.5;
688                rel1 {
689                   relative: 0.0 1.0;
690                   to_x: "padding_before_text";
691                   to_y: "padding_left_top";
692                }
693                rel2 {
694                   relative: 0.0 0.0;
695                   to_x: "padding_before_text";
696                   to_y: "padding_right_bottom";
697                }
698             }
699             description { state: "icononly" 0.0;
700                min: BUTTON_TEXT_STYLE1_ICONONLY_ICON_MIN_MAX_INC;
701                max: BUTTON_TEXT_STYLE1_ICONONLY_ICON_MIN_MAX_INC;
702             }
703          }
704          part { name: "elm.text";
705             type: TEXT;
706             mouse_events: 0;
707             scale: 1;
708             clip_to: "clipper";
709             description { state: "default" 0.0;
710                visible: 0;
711                rel1 {
712                   relative: 1.0 1.0;
713                   to_x: "padding_after_icon";
714                   to_y: "padding_left_top";
715                }
716                rel2 {
717                   relative: 0.0 0.0;
718                   to: "padding_right_bottom";
719                }
720                color: BUTTON_TEXT_STYLE1_NORMAL_COLOR_INC;
721                text {
722                   font: "SLP:style=Medium";
723                   size: BUTTON_TEXT_STYLE1_FONT_SIZE_INC;
724                   min: 1 0;
725                   max: 1 0;
726                   text_class: "slp_medium";
727                }
728             }
729             description { state: "visible" 0.0;
730                inherit: "default" 0.0;
731                visible: 1;
732             }
733             description { state: "clicked" 0.0;
734                inherit: "default" 0.0;
735                visible: 1;
736                color: BUTTON_TEXT_STYLE1_PRESSED_COLOR_INC;
737             }
738             description { state: "disabled" 0.0;
739                inherit: "default" 0.0;
740                color: 0 0 0 128;
741             }
742             description { state: "disabled_visible" 0.0;
743                inherit: "default" 0.0;
744                color: BUTTON_TEXT_STYLE1_DISABLED_COLOR_INC;
745                visible: 1;
746             }
747             description { state: "focused" 0.0;
748                inherit: "default" 0.0;
749                visible: 1;
750                color: BUTTON_TEXT_STYLE1_FOCUSED_COLOR_INC;
751             }
752          }
753          part { name: "over2";
754             type: RECT;
755             repeat_events: 1;
756             ignore_flags: ON_HOLD;
757             description { state: "default" 0.0;
758                color: 0 0 0 0;
759             }
760          }
761          part { name: "over3";
762             type: RECT;
763             repeat_events: 1;
764             description { state: "default" 0.0;
765                color: 0 0 0 0;
766             }
767          }
768          part { name: "clipper";
769             type: RECT;
770             description { state: "default" 0.0;
771                color: 255 255 255 255;
772             }
773          }
774          part { name: "disabler";
775             type: RECT;
776             description { state: "default" 0.0;
777                color: 0 0 0 0;
778                visible: 0;
779             }
780             description { state: "disabled" 0.0;
781                inherit: "default" 0.0;
782                visible: 1;
783             }
784          }
785       }
786       programs {
787          program { name: "button_click";
788             signal: "mouse,down,1";
789             source: "over2";
790             action: SIGNAL_EMIT "elm,action,press" "";
791             after: "button_click_anim";
792          }
793          program { name: "button_click_anim";
794             action: STATE_SET "clicked" 0.0;
795             target: "button_image";
796             after: "text_clicked";
797          }
798          program { name: "text_clicked";
799             script {
800                new st[31];
801                new Float:vl;
802                get_state(PART:"elm.text", st, 30, vl);
803                if (!strcmp(st, "visible"))
804                  set_state(PART:"elm.text", "clicked", 0.0);
805             }
806          }
807          program { name: "button_unpress";
808             action: SIGNAL_EMIT "elm,action,unpress" "";
809          }
810          program { name: "button_mouseout_clicked";
811             signal: "mouse,up,1";
812             source: "over3";
813             script {
814                new st[31];
815                new Float:vl;
816                get_state(PART:"elm.swallow.content", st, 30, vl);
817                if (strcmp(st, "icononly"))
818                  {
819                     emit("elm,action,default,text,set", "");
820                     set_state(PART:"elm.text", "visible", 0.0);
821                  }
822                if (get_int(button_state) != BUTTON_STATE_DISABLED)
823                  set_state(PART:"button_image", "default", 0.0);
824             }
825             after: button_unpress;
826          }
827          program { name: "touch_snd";
828             signal: "mouse,clicked,1";
829             source: "over2";
830             action: PLAY_SAMPLE "touch_sound" 1.0;
831             after: button_unclick3;
832          }
833          program { name: "button_unclick3";
834             action: SIGNAL_EMIT "elm,action,click" "";
835          }
836          program { name: "text_show";
837             signal: "elm,state,text,visible";
838             source: "elm";
839             script {
840                new st[31];
841                new Float:vl;
842                get_state(PART:"elm.swallow.content", st, 30, vl);
843                if (!strcmp(st, "icononly"))
844                  {
845                     set_state(PART:"elm.swallow.content", "visible", 0.0);
846                     set_state(PART:"icon_rect", "visible", 0.0);
847                     set_state(PART:"padding_after_icon", "visible", 0.0);
848                     set_state(PART:"bg", "visible", 0.0);
849                  }
850                if (get_int(button_state) != BUTTON_STATE_DISABLED)
851                  set_state(PART:"elm.text", "visible", 0.0);
852                else
853                  set_state(PART:"elm.text", "disabled_visible", 0.0);
854             }
855          }
856          program { name: "text_hide";
857             signal: "elm,state,text,hidden";
858             source: "elm";
859             script {
860                new st[31];
861                new Float:vl;
862                get_state(PART:"elm.swallow.content", st, 30, vl);
863                if (!strcmp(st, "visible"))
864                  {
865                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
866                     set_state(PART:"icon_rect", "icononly", 0.0);
867                     set_state(PART:"padding_after_icon", "icononly", 0.0);
868                     set_state(PART:"bg", "icononly", 0.0);
869                  }
870                set_state(PART:"elm.text", "default", 0.0);
871             }
872          }
873          program { name: "icon_show";
874             signal: "elm,state,icon,visible";
875             source: "elm";
876             script {
877                new st[31];
878                new Float:vl;
879                get_state(PART:"elm.text", st, 30, vl);
880                if (!strcmp(st, "visible"))
881                  {
882                     set_state(PART:"elm.swallow.content", "visible", 0.0);
883                     set_state(PART:"icon_rect", "visible", 0.0);
884                     set_state(PART:"padding_after_icon", "visible", 0.0);
885                     set_state(PART:"bg", "visible", 0.0);
886                  }
887                else
888                  {
889                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
890                     set_state(PART:"icon_rect", "icononly", 0.0);
891                     set_state(PART:"padding_after_icon", "icononly", 0.0);
892                     set_state(PART:"bg", "icononly", 0.0);
893                  }
894             }
895          }
896          program { name: "icon_hide";
897             signal: "elm,state,icon,hidden";
898             source: "elm";
899             action: STATE_SET "default" 0.0;
900             target: "elm.swallow.content";
901             target: "padding_after_icon";
902             target: "icon_rect";
903             target: "bg";
904          }
905          program { name: "disable";
906             signal: "elm,state,disabled";
907             source: "elm";
908             action: STATE_SET "disabled" 0.0;
909             target: "button_image";
910             target: "disabler";
911             after: "disable_text";
912          }
913          program { name: "disable_text";
914             script {
915                new st[31];
916                new Float:vl;
917                get_state(PART:"elm.text", st, 30, vl);
918                if (!strcmp(st, "visible"))
919                  set_state(PART:"elm.text", "disabled_visible", 0.0);
920                else
921                  set_state(PART:"elm.text", "disabled", 0.0);
922                set_int(button_state, BUTTON_STATE_DISABLED);
923             }
924          }
925          program { name: "enable";
926             signal: "elm,state,enabled";
927             source: "elm";
928             action: STATE_SET "default" 0.0;
929             target: "button_image";
930             target: "disabler";
931             after: "enable_text";
932          }
933          program { name: "enable_text";
934             script {
935                new st[31];
936                new Float:vl;
937                get_state(PART:"elm.text", st, 30, vl);
938                if (!strcmp(st, "disabled_visible"))
939                  set_state(PART:"elm.text", "visible", 0.0);
940                else
941                  set_state(PART:"elm.text", "default", 0.0);
942                set_int(button_state, BUTTON_STATE_ENABLED);
943             }
944          }
945          program { name: "focused";
946             //signal: "elm,action,focus";
947             //source: "elm";
948             action: STATE_SET "focused" 0.0;
949             target: "button_image";
950             target: "elm.text";
951          }
952          program { name: "unfocused";
953             //signal: "elm,action,unfocus";
954             //source: "elm";
955             action: STATE_SET "default" 0.0;
956             target: "button_image";
957             after: "unfocus_text";
958          }
959          program { name: "unfocus_text";
960             action: STATE_SET "visible" 0.0;
961             target: "elm.text";
962          }
963       }
964    }
965
966 //////////////////////////////////////////////////////////////////////////////////////
967    group { name: "elm/button/base/style1/multiline";
968       images {
969          image: "00_button_01_normal.png" COMP;
970          image: "00_button_01_normal_press.png" COMP;
971          image: "00_button_01_normal_dim.png" COMP;
972          image: "00_button_01_normal_Focus.png" COMP;
973       }
974       styles{
975          style { name: "btn_style1_multiline";
976             base: "font=SLP:style=Roman font_size="BUTTON_TEXT_STYLE1_MULTILINE_FONT_SIZE_INC" align=center color=#ffffff wrap=mixed ellipise=1.0 text_class=slp_roman";
977             tag: "br" "\n";
978             tag: "ps" "ps";
979             tag: "tab" "\t";
980          }
981       }
982       script {
983          public button_state = BUTTON_STATE_ENABLED;
984       }
985       parts {
986          part { name: "button_image";
987             scale: 1;
988             description { state: "default" 0.0;
989                image {
990                   normal: "00_button_01_normal.png";
991                   border: BUTTON_TEXT_STYLE1_BG_BORDER_INC;
992                   border_scale: 1;
993                }
994             }
995             description { state: "clicked" 0.0;
996                inherit: "default" 0.0;
997                image.normal: "00_button_01_normal_press.png";
998             }
999             description { state: "disabled" 0.0;
1000                inherit: "default" 0.0;
1001                image.normal: "00_button_01_normal_dim.png";
1002             }
1003             description { state: "focused" 0.0;
1004                inherit: "default" 0.0;
1005                image.normal: "00_button_01_normal_Focus.png";
1006             }
1007          }
1008          part { name: "padding_left_top";
1009             type: RECT;
1010             scale: 1;
1011             mouse_events: 0;
1012             description { state: "default" 0.0;
1013                align: 0.0 0.0;
1014                rel2.relative: 0.0 0.0;
1015                min: BUTTON_TEXT_STYLE1_PADDING_MIN_INC;
1016                fixed: 1 1;
1017                visible: 0;
1018             }
1019          }
1020          part { name: "bg";
1021             type: RECT;
1022             scale: 1;
1023             mouse_events: 0;
1024             description { state: "default" 0.0;
1025                min: BUTTON_TEXT_STYLE1_BG_MIN_INC;
1026                visible: 0;
1027             }
1028             description { state: "visible" 0.0;
1029                inherit: "default" 0.0;
1030                min: BUTTON_TEXT_STYLE1_VISIBLE_BG_MIN_INC;
1031             }
1032             description { state: "icononly" 0.0;
1033                inherit: "default" 0.0;
1034                min: BUTTON_TEXT_STYLE1_ICONONLY_BG_MIN_INC;
1035             }
1036          }
1037          part { name: "padding_right_bottom";
1038             type: RECT;
1039             scale: 1;
1040             mouse_events: 0;
1041             description { state: "default" 0.0;
1042                align: 1.0 1.0;
1043                rel1.relative: 1.0 1.0;
1044                min: BUTTON_TEXT_STYLE1_PADDING_MIN_INC;
1045                fixed: 1 1;
1046                visible: 0;
1047             }
1048          }
1049          part { name: "icon_rect";
1050             type: RECT;
1051             scale: 1;
1052             mouse_events: 0;
1053             description { state: "default" 0.0;
1054                visible: 0;
1055                min: 0 0;
1056                fixed: 1 0;
1057                rel1 {
1058                   relative: 1.0 1.0;
1059                   to: "padding_left_top";
1060                }
1061                rel2 {
1062                   relative: 1.0 0.0;
1063                   to_x: "padding_left_top";
1064                   to_y: "padding_right_bottom";
1065                }
1066                align: 0.0 0.5;
1067             }
1068             description { state: "visible" 0.0;
1069                visible: 0;
1070                min: BUTTON_TEXT_STYLE1_VISIBLE_ICON_RECT_MIN_MAX_INC;
1071                max: BUTTON_TEXT_STYLE1_VISIBLE_ICON_RECT_MIN_MAX_INC;
1072                fixed: 1 0;
1073                rel1 {
1074                   relative: 1.0 1.0;
1075                   to: "padding_left_top";
1076                }
1077                rel2 {
1078                   relative: 1.0 0.0;
1079                   to_x: "padding_left_top";
1080                   to_y: "padding_right_bottom";
1081                }
1082                align: 0.0 0.5;
1083             }
1084             description { state: "icononly" 0.0;
1085                inherit: "default" 0.0;
1086             }
1087          }
1088          part { name: "padding_after_icon";
1089             type: RECT;
1090             scale: 1;
1091             mouse_events: 0;
1092             description { state: "default" 0.0; //when only icon or no icon is there
1093                align: 0.0 0.0;
1094                rel1 {
1095                   relative: 1.0 0.0;
1096                   to: "icon_rect";
1097                }
1098                rel2.to: "icon_rect";
1099                fixed: 1 0;
1100                min: 5 0;
1101                visible: 0;
1102             }
1103             description { state: "visible" 0.0;
1104                visible: 0;
1105                align: 0.0 0.0;
1106                rel1 {
1107                   relative: 1.0 0.0;
1108                   to: "icon_rect";
1109                }
1110                rel2.to: "icon_rect";
1111                fixed: 1 0;
1112                min: BUTTON_TEXT_STYLE1_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
1113             }
1114             description { state: "icononly" 0.0;
1115                inherit: "default" 0.0;
1116             }
1117          }
1118          part { name: "padding_before_text";
1119             type: RECT;
1120             scale: 1;
1121             mouse_events: 0;
1122             description { state: "default" 0.0; //when only icon or no icon is there
1123                align: 1.0 0.5;
1124                rel1 {
1125                   relative: 0.0 1.0;
1126                   to_x: "elm.text";
1127                   to_y: "padding_left_top";
1128                }
1129                rel2 {
1130                   relative: 0.0 0.0;
1131                   to_x: "elm.text";
1132                   to_y: "padding_right_bottom";
1133                }
1134                fixed: 1 0;
1135                min: BUTTON_TEXT_STYLE1_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
1136                visible: 0;
1137             }
1138          }
1139          part { name: "elm.swallow.content";
1140             type: SWALLOW;
1141             scale: 1;
1142             clip_to: "clipper";
1143             description { state: "default" 0.0;
1144                visible: 0;
1145                align: 0.0 0.5;
1146                rel1 {
1147                   relative: 1.0 1.0;
1148                   to: "padding_left_top";
1149                }
1150                rel2 {
1151                   relative: 1.0 0.0;
1152                   to_x: "padding_left_top";
1153                   to_y: "padding_right_bottom";
1154                }
1155                fixed: 1 0;
1156             }
1157             description { state: "visible" 0.0;
1158                fixed: 1 0;
1159                min: BUTTON_TEXT_STYLE1_VISIBLE_ICON_MIN_MAX_INC;
1160                max: BUTTON_TEXT_STYLE1_VISIBLE_ICON_MIN_MAX_INC;
1161                align: 1.0 0.5;
1162                rel1 {
1163                   relative: 0.0 1.0;
1164                   to_x: "padding_before_text";
1165                   to_y: "padding_left_top";
1166                }
1167                rel2 {
1168                   relative: 0.0 0.0;
1169                   to_x: "padding_before_text";
1170                   to_y: "padding_right_bottom";
1171                }
1172             }
1173             description { state: "icononly" 0.0;
1174                min: BUTTON_TEXT_STYLE1_ICONONLY_ICON_MIN_MAX_INC;
1175                max: BUTTON_TEXT_STYLE1_ICONONLY_ICON_MIN_MAX_INC;
1176             }
1177          }
1178          part { name: "elm.text";
1179             type: TEXTBLOCK;
1180             mouse_events: 0;
1181             scale: 1;
1182             clip_to: "clipper";
1183             description { state: "default" 0.0;
1184                visible: 0;
1185                rel1 {
1186                   relative: 1.0 1.0;
1187                   to_x: "padding_after_icon";
1188                   to_y: "padding_left_top";
1189                }
1190                rel2 {
1191                   relative: 0.0 0.0;
1192                   to: "padding_right_bottom";
1193                }
1194                color: BUTTON_TEXT_STYLE1_NORMAL_COLOR_INC;
1195                text {
1196                    style: "btn_style1_multiline";
1197                    min: 0 0;
1198                    max: 0 1;
1199                }
1200             }
1201             description { state: "visible" 0.0;
1202                inherit: "default" 0.0;
1203                visible: 1;
1204             }
1205             description { state: "clicked" 0.0;
1206                inherit: "default" 0.0;
1207                visible: 1;
1208                color: BUTTON_TEXT_STYLE1_PRESSED_COLOR_INC;
1209             }
1210             description { state: "disabled" 0.0;
1211                inherit: "default" 0.0;
1212                color: 0 0 0 128;
1213             }
1214             description { state: "disabled_visible" 0.0;
1215                inherit: "default" 0.0;
1216                color: BUTTON_TEXT_STYLE1_DISABLED_COLOR_INC;
1217                visible: 1;
1218             }
1219             description { state: "focused" 0.0;
1220                inherit: "default" 0.0;
1221                visible: 1;
1222                color: BUTTON_TEXT_STYLE1_FOCUSED_COLOR_INC;
1223             }
1224          }
1225          part { name: "over2";
1226             type: RECT;
1227             repeat_events: 1;
1228             ignore_flags: ON_HOLD;
1229             description { state: "default" 0.0;
1230                color: 0 0 0 0;
1231             }
1232          }
1233          part { name: "over3";
1234             type: RECT;
1235             repeat_events: 1;
1236             description { state: "default" 0.0;
1237                color: 0 0 0 0;
1238             }
1239          }
1240          part { name: "clipper";
1241             type: RECT;
1242             description { state: "default" 0.0;
1243                color: 255 255 255 255;
1244             }
1245          }
1246          part { name: "disabler";
1247             type: RECT;
1248             description { state: "default" 0.0;
1249                color: 0 0 0 0;
1250                visible: 0;
1251             }
1252             description { state: "disabled" 0.0;
1253                inherit: "default" 0.0;
1254                visible: 1;
1255             }
1256          }
1257       }
1258       programs {
1259          program { name: "button_click";
1260             signal: "mouse,down,1";
1261             source: "over2";
1262             action: SIGNAL_EMIT "elm,action,press" "";
1263             after: "button_click_anim";
1264          }
1265          program { name: "button_click_anim";
1266             action: STATE_SET "clicked" 0.0;
1267             target: "button_image";
1268             after: "text_clicked";
1269          }
1270          program { name: "text_clicked";
1271             script {
1272                new st[31];
1273                new Float:vl;
1274                get_state(PART:"elm.text", st, 30, vl);
1275                if (!strcmp(st, "visible"))
1276                  set_state(PART:"elm.text", "clicked", 0.0);
1277             }
1278          }
1279          program { name: "button_unpress";
1280             action: SIGNAL_EMIT "elm,action,unpress" "";
1281          }
1282          program { name: "button_mouseout_clicked";
1283             signal: "mouse,up,1";
1284             source: "over3";
1285             script {
1286                new st[31];
1287                new Float:vl;
1288                get_state(PART:"elm.swallow.content", st, 30, vl);
1289                if (strcmp(st, "icononly"))
1290                  {
1291                     emit("elm,action,default,text,set", "");
1292                     set_state(PART:"elm.text", "visible", 0.0);
1293                  }
1294                if (get_int(button_state) != BUTTON_STATE_DISABLED)
1295                  set_state(PART:"button_image", "default", 0.0);
1296             }
1297             after: button_unpress;
1298          }
1299          program { name: "touch_snd";
1300             signal: "mouse,clicked,1";
1301             source: "over2";
1302             action: PLAY_SAMPLE "touch_sound" 1.0;
1303             after: button_unclick3;
1304          }
1305          program { name: "button_unclick3";
1306             action: SIGNAL_EMIT "elm,action,click" "";
1307          }
1308          program { name: "text_show";
1309             signal: "elm,state,text,visible";
1310             source: "elm";
1311             script {
1312                new st[31];
1313                new Float:vl;
1314                get_state(PART:"elm.swallow.content", st, 30, vl);
1315                if (!strcmp(st, "icononly"))
1316                  {
1317                     set_state(PART:"elm.swallow.content", "visible", 0.0);
1318                     set_state(PART:"icon_rect", "visible", 0.0);
1319                     set_state(PART:"padding_after_icon", "visible", 0.0);
1320                     set_state(PART:"bg", "visible", 0.0);
1321                  }
1322                if (get_int(button_state) != BUTTON_STATE_DISABLED)
1323                  set_state(PART:"elm.text", "visible", 0.0);
1324                else
1325                  set_state(PART:"elm.text", "disabled_visible", 0.0);
1326             }
1327          }
1328          program { name: "text_hide";
1329             signal: "elm,state,text,hidden";
1330             source: "elm";
1331             script {
1332                new st[31];
1333                new Float:vl;
1334                get_state(PART:"elm.swallow.content", st, 30, vl);
1335                if (!strcmp(st, "visible"))
1336                  {
1337                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
1338                     set_state(PART:"icon_rect", "icononly", 0.0);
1339                     set_state(PART:"padding_after_icon", "icononly", 0.0);
1340                     set_state(PART:"bg", "icononly", 0.0);
1341                  }
1342                set_state(PART:"elm.text", "default", 0.0);
1343             }
1344          }
1345          program { name: "icon_show";
1346             signal: "elm,state,icon,visible";
1347             source: "elm";
1348             script {
1349                new st[31];
1350                new Float:vl;
1351                get_state(PART:"elm.text", st, 30, vl);
1352                if (!strcmp(st, "visible"))
1353                  {
1354                     set_state(PART:"elm.swallow.content", "visible", 0.0);
1355                     set_state(PART:"icon_rect", "visible", 0.0);
1356                     set_state(PART:"padding_after_icon", "visible", 0.0);
1357                     set_state(PART:"bg", "visible", 0.0);
1358                  }
1359                else
1360                  {
1361                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
1362                     set_state(PART:"icon_rect", "icononly", 0.0);
1363                     set_state(PART:"padding_after_icon", "icononly", 0.0);
1364                     set_state(PART:"bg", "icononly", 0.0);
1365                  }
1366             }
1367          }
1368          program { name: "icon_hide";
1369             signal: "elm,state,icon,hidden";
1370             source: "elm";
1371             action: STATE_SET "default" 0.0;
1372             target: "elm.swallow.content";
1373             target: "padding_after_icon";
1374             target: "icon_rect";
1375             target: "bg";
1376          }
1377          program { name: "disable";
1378             signal: "elm,state,disabled";
1379             source: "elm";
1380             action: STATE_SET "disabled" 0.0;
1381             target: "button_image";
1382             target: "disabler";
1383             after: "disable_text";
1384          }
1385          program { name: "disable_text";
1386             script {
1387                new st[31];
1388                new Float:vl;
1389                get_state(PART:"elm.text", st, 30, vl);
1390                if (!strcmp(st, "visible"))
1391                  set_state(PART:"elm.text", "disabled_visible", 0.0);
1392                else
1393                  set_state(PART:"elm.text", "disabled", 0.0);
1394                set_int(button_state, BUTTON_STATE_DISABLED);
1395             }
1396          }
1397          program { name: "enable";
1398             signal: "elm,state,enabled";
1399             source: "elm";
1400             action: STATE_SET "default" 0.0;
1401             target: "button_image";
1402             target: "disabler";
1403             after: "enable_text";
1404          }
1405          program { name: "enable_text";
1406             script {
1407                new st[31];
1408                new Float:vl;
1409                get_state(PART:"elm.text", st, 30, vl);
1410                if (!strcmp(st, "disabled_visible"))
1411                  set_state(PART:"elm.text", "visible", 0.0);
1412                else
1413                  set_state(PART:"elm.text", "default", 0.0);
1414                set_int(button_state, BUTTON_STATE_ENABLED);
1415             }
1416          }
1417          program { name: "focused";
1418             //signal: "elm,action,focus";
1419             //source: "elm";
1420             action: STATE_SET "focused" 0.0;
1421             target: "button_image";
1422             target: "elm.text";
1423          }
1424          program { name: "unfocused";
1425             //signal: "elm,action,unfocus";
1426             //source: "elm";
1427             action: STATE_SET "default" 0.0;
1428             target: "button_image";
1429             after: "unfocus_text";
1430          }
1431          program { name: "unfocus_text";
1432             action: STATE_SET "visible" 0.0;
1433             target: "elm.text";
1434          }
1435       }
1436    }
1437
1438 ///////////////////////////////////////////////////////////////////////////////////////
1439    group { name: "elm/button/base/style2";
1440       alias: "elm/button/base/text_only/style2";
1441       images {
1442          image: "00_button_04_normal.png" COMP;
1443          image: "00_button_04_press.png" COMP;
1444          image: "00_button_04_dim.png" COMP;
1445          image: "00_button_04_normal_focus.png" COMP;
1446       }
1447       script {
1448          public button_state = BUTTON_STATE_ENABLED;
1449       }
1450       parts {
1451          part { name: "button_image";
1452             scale: 1;
1453             description { state: "default" 0.0;
1454                image {
1455                   normal: "00_button_04_normal.png";
1456                   border: BUTTON_TEXT_STYLE2_BG_BORDER_INC;
1457                   border_scale: 1;
1458                }
1459             }
1460             description { state: "clicked" 0.0;
1461                inherit: "default" 0.0;
1462                image.normal: "00_button_04_press.png";
1463             }
1464             description { state: "disabled" 0.0;
1465                inherit: "default" 0.0;
1466                image.normal: "00_button_04_dim.png";
1467             }
1468             description { state: "focused" 0.0;
1469                inherit: "default" 0.0;
1470                image.normal: "00_button_04_normal_focus.png";
1471             }
1472          }
1473          part { name: "padding_left_top";
1474             type: RECT;
1475             scale: 1;
1476             mouse_events: 0;
1477             description { state: "default" 0.0;
1478                align: 0.0 0.0;
1479                rel2.relative: 0.0 0.0;
1480                min: BUTTON_TEXT_STYLE2_PADDING_MIN_INC;
1481                fixed: 1 1;
1482                visible: 0;
1483             }
1484          }
1485          part { name: "bg";
1486             type: RECT;
1487             scale: 1;
1488             mouse_events: 0;
1489             description { state: "default" 0.0;
1490                min: BUTTON_TEXT_STYLE2_BG_MIN_INC;
1491                visible: 0;
1492             }
1493             description { state: "visible" 0.0;
1494                inherit: "default" 0.0;
1495                min: BUTTON_TEXT_STYLE2_VISIBLE_BG_MIN_INC;
1496             }
1497             description { state: "icononly" 0.0;
1498                inherit: "default" 0.0;
1499                min: BUTTON_TEXT_STYLE2_ICONONLY_BG_MIN_INC;
1500             }
1501          }
1502          part { name: "padding_right_bottom";
1503             type: RECT;
1504             scale: 1;
1505             mouse_events: 0;
1506             description { state: "default" 0.0;
1507                align: 1.0 1.0;
1508                rel1.relative: 1.0 1.0;
1509                min: BUTTON_TEXT_STYLE2_PADDING_MIN_INC;
1510                fixed: 1 1;
1511                visible: 0;
1512             }
1513          }
1514          part { name: "icon_rect";
1515             type: RECT;
1516             scale: 1;
1517             mouse_events: 0;
1518             description { state: "default" 0.0;
1519                visible: 0;
1520                min: 0 0;
1521                fixed: 1 0;
1522                rel1 {
1523                   relative: 1.0 1.0;
1524                   to: "padding_left_top";
1525                }
1526                rel2 {
1527                   relative: 1.0 0.0;
1528                   to_x: "padding_left_top";
1529                   to_y: "padding_right_bottom";
1530                }
1531                align: 0.0 0.5;
1532             }
1533             description { state: "visible" 0.0;
1534                visible: 0;
1535                min: BUTTON_TEXT_STYLE2_VISIBLE_ICON_RECT_MIN_MAX_INC;
1536                max: BUTTON_TEXT_STYLE2_VISIBLE_ICON_RECT_MIN_MAX_INC;
1537                fixed: 1 0;
1538                rel1 {
1539                   relative: 1.0 1.0;
1540                   to: "padding_left_top";
1541                }
1542                rel2 {
1543                   relative: 1.0 0.0;
1544                   to_x: "padding_left_top";
1545                   to_y: "padding_right_bottom";
1546                }
1547                align: 0.0 0.5;
1548             }
1549             description { state: "icononly" 0.0;
1550                inherit: "default" 0.0;
1551             }
1552          }
1553          part { name: "padding_after_icon";
1554             type: RECT;
1555             scale: 1;
1556             mouse_events: 0;
1557             description { state: "default" 0.0; //when only icon or no icon is there
1558                align: 0.0 0.0;
1559                rel1 {
1560                   relative: 1.0 0.0;
1561                   to: "icon_rect";
1562                }
1563                rel2.to: "icon_rect";
1564                fixed: 1 0;
1565                min: 0 0;
1566                visible: 0;
1567             }
1568             description { state: "visible" 0.0;
1569                visible: 0;
1570                align: 0.0 0.0;
1571                rel1 {
1572                   relative: 1.0 0.0;
1573                   to: "icon_rect";
1574                }
1575                rel2.to: "icon_rect";
1576                fixed: 1 0;
1577                min: BUTTON_TEXT_STYLE2_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
1578             }
1579             description { state: "icononly" 0.0;
1580                inherit: "default" 0.0;
1581             }
1582          }
1583          part { name: "padding_before_text";
1584             type: RECT;
1585             scale: 1;
1586             mouse_events: 0;
1587             description { state: "default" 0.0; //when only icon or no icon is there
1588                align: 1.0 0.5;
1589                rel1 {
1590                   relative: 0.0 1.0;
1591                   to_x: "elm.text";
1592                   to_y: "padding_left_top";
1593                }
1594                rel2 {
1595                   relative: 0.0 0.0;
1596                   to_x: "elm.text";
1597                   to_y: "padding_right_bottom";
1598                }
1599                fixed: 1 0;
1600                min: BUTTON_TEXT_STYLE2_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
1601                visible: 0;
1602             }
1603          }
1604          part { name: "elm.swallow.content";
1605             type: SWALLOW;
1606             scale: 1;
1607             clip_to: "clipper";
1608             description { state: "default" 0.0;
1609                visible: 0;
1610                align: 0.0 0.5;
1611                rel1 {
1612                   relative: 1.0 1.0;
1613                   to: "padding_left_top";
1614                }
1615                rel2 {
1616                   relative: 1.0 0.0;
1617                   to_x: "padding_left_top";
1618                   to_y: "padding_right_bottom";
1619                }
1620                fixed: 1 0;
1621             }
1622             description { state: "visible" 0.0;
1623                fixed: 1 0;
1624                min: BUTTON_TEXT_STYLE2_VISIBLE_ICON_MIN_MAX_INC;
1625                max: BUTTON_TEXT_STYLE2_VISIBLE_ICON_MIN_MAX_INC;
1626                align: 1.0 0.5;
1627                rel1 {
1628                   relative: 0.0 1.0;
1629                   to_x: "padding_before_text";
1630                   to_y: "padding_left_top";
1631                }
1632                rel2 {
1633                   relative: 0.0 0.0;
1634                   to_x: "padding_before_text";
1635                   to_y: "padding_right_bottom";
1636                }
1637             }
1638             description { state: "icononly" 0.0;
1639                min: BUTTON_TEXT_STYLE2_ICONONLY_ICON_MIN_MAX_INC;
1640                max: BUTTON_TEXT_STYLE2_ICONONLY_ICON_MIN_MAX_INC;
1641             }
1642          }
1643          part { name: "elm.text";
1644             type: TEXT;
1645             mouse_events: 0;
1646             scale: 1;
1647             clip_to: "clipper";
1648             description { state: "default" 0.0;
1649                visible: 0;
1650                rel1 {
1651                   relative: 1.0 1.0;
1652                   to_x: "padding_after_icon";
1653                   to_y: "padding_left_top";
1654                }
1655                rel2 {
1656                   relative: 0.0 0.0;
1657                   to: "padding_right_bottom";
1658                }
1659                color: BUTTON_TEXT_STYLE1_NORMAL_COLOR_INC;
1660                text {
1661                   font: "SLP:style=Medium";
1662                   size: BUTTON_TEXT_STYLE2_FONT_SIZE_INC;
1663                   min: 0 0;
1664                   max: 1 0;
1665                   text_class: "slp_medium";
1666                }
1667             }
1668             description { state: "visible" 0.0;
1669                inherit: "default" 0.0;
1670                visible: 1;
1671             }
1672             description { state: "clicked" 0.0;
1673                inherit: "default" 0.0;
1674                visible: 1;
1675                color: BUTTON_TEXT_STYLE1_PRESSED_COLOR_INC;
1676             }
1677             description { state: "disabled" 0.0;
1678                inherit: "default" 0.0;
1679                color: 0 0 0 128;
1680             }
1681             description { state: "disabled_visible" 0.0;
1682                inherit: "default" 0.0;
1683                color: BUTTON_TEXT_STYLE1_DISABLED_COLOR_INC;
1684                visible: 1;
1685             }
1686             description { state: "focused" 0.0;
1687                inherit: "default" 0.0;
1688                visible: 1;
1689                color: BUTTON_TEXT_STYLE1_FOCUSED_COLOR_INC;
1690             }
1691          }
1692          part { name: "over2";
1693             type: RECT;
1694             repeat_events: 1;
1695             ignore_flags: ON_HOLD;
1696             description { state: "default" 0.0;
1697                color: 0 0 0 0;
1698             }
1699          }
1700          part { name: "over3";
1701             type: RECT;
1702             repeat_events: 1;
1703             description { state: "default" 0.0;
1704                color: 0 0 0 0;
1705             }
1706          }
1707          part { name: "clipper";
1708             type: RECT;
1709             description { state: "default" 0.0;
1710                color: 255 255 255 255;
1711             }
1712          }
1713          part { name: "disabler";
1714             type: RECT;
1715             description { state: "default" 0.0;
1716                color: 0 0 0 0;
1717                visible: 0;
1718             }
1719             description { state: "disabled" 0.0;
1720                inherit: "default" 0.0;
1721                visible: 1;
1722             }
1723          }
1724       }
1725       programs {
1726          program { name: "button_click";
1727             signal: "mouse,down,1";
1728             source: "over2";
1729             action: SIGNAL_EMIT "elm,action,press" "";
1730             after: "button_click_anim";
1731          }
1732          program { name: "button_click_anim";
1733             action: STATE_SET "clicked" 0.0;
1734             target: "button_image";
1735             after: "text_clicked";
1736          }
1737          program { name: "text_clicked";
1738             script {
1739                new st[31];
1740                new Float:vl;
1741                get_state(PART:"elm.text", st, 30, vl);
1742                if (!strcmp(st, "visible"))
1743                  set_state(PART:"elm.text", "clicked", 0.0);
1744             }
1745          }
1746          program { name: "button_unpress";
1747             action: SIGNAL_EMIT "elm,action,unpress" "";
1748          }
1749          program { name: "button_mouseout_clicked";
1750             signal: "mouse,up,1";
1751             source: "over3";
1752             script {
1753                new st[31];
1754                new Float:vl;
1755                get_state(PART:"elm.swallow.content", st, 30, vl);
1756                if (strcmp(st, "icononly"))
1757                  {
1758                     emit("elm,action,default,text,set", "");
1759                     set_state(PART:"elm.text", "visible", 0.0);
1760                  }
1761                if (get_int(button_state) != BUTTON_STATE_DISABLED)
1762                  set_state(PART:"button_image", "default", 0.0);
1763             }
1764             after: button_unpress;
1765          }
1766          program { name: "touch_snd";
1767             signal: "mouse,clicked,1";
1768             source: "over2";
1769             action: PLAY_SAMPLE "touch_sound" 1.0;
1770             after: button_unclick3;
1771          }
1772          program { name: "button_unclick3";
1773             action: SIGNAL_EMIT "elm,action,click" "";
1774          }
1775          program { name: "text_show";
1776             signal: "elm,state,text,visible";
1777             source: "elm";
1778             script {
1779                new st[31];
1780                new Float:vl;
1781                get_state(PART:"elm.swallow.content", st, 30, vl);
1782                if (!strcmp(st, "icononly"))
1783                  {
1784                     set_state(PART:"elm.swallow.content", "visible", 0.0);
1785                     set_state(PART:"icon_rect", "visible", 0.0);
1786                     set_state(PART:"padding_after_icon", "visible", 0.0);
1787                     set_state(PART:"bg", "visible", 0.0);
1788                  }
1789                if (get_int(button_state) != BUTTON_STATE_DISABLED)
1790                  set_state(PART:"elm.text", "visible", 0.0);
1791                else
1792                  set_state(PART:"elm.text", "disabled_visible", 0.0);
1793             }
1794          }
1795          program { name: "text_hide";
1796             signal: "elm,state,text,hidden";
1797             source: "elm";
1798             script {
1799                new st[31];
1800                new Float:vl;
1801                get_state(PART:"elm.swallow.content", st, 30, vl);
1802                if (!strcmp(st, "visible"))
1803                  {
1804                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
1805                     set_state(PART:"icon_rect", "icononly", 0.0);
1806                     set_state(PART:"padding_after_icon", "icononly", 0.0);
1807                     set_state(PART:"bg", "icononly", 0.0);
1808                  }
1809                set_state(PART:"elm.text", "default", 0.0);
1810             }
1811          }
1812          program { name: "icon_show";
1813             signal: "elm,state,icon,visible";
1814             source: "elm";
1815             script {
1816                new st[31];
1817                new Float:vl;
1818                get_state(PART:"elm.text", st, 30, vl);
1819                if (!strcmp(st, "visible"))
1820                  {
1821                     set_state(PART:"elm.swallow.content", "visible", 0.0);
1822                     set_state(PART:"icon_rect", "visible", 0.0);
1823                     set_state(PART:"padding_after_icon", "visible", 0.0);
1824                     set_state(PART:"bg", "visible", 0.0);
1825                  }
1826                else
1827                  {
1828                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
1829                     set_state(PART:"icon_rect", "icononly", 0.0);
1830                     set_state(PART:"padding_after_icon", "icononly", 0.0);
1831                     set_state(PART:"bg", "icononly", 0.0);
1832                  }
1833             }
1834          }
1835          program { name: "icon_hide";
1836             signal: "elm,state,icon,hidden";
1837             source: "elm";
1838             action: STATE_SET "default" 0.0;
1839             target: "elm.swallow.content";
1840             target: "padding_after_icon";
1841             target: "icon_rect";
1842             target: "bg";
1843          }
1844          program { name: "disable";
1845             signal: "elm,state,disabled";
1846             source: "elm";
1847             action: STATE_SET "disabled" 0.0;
1848             target: "button_image";
1849             target: "disabler";
1850             after: "disable_text";
1851          }
1852          program { name: "disable_text";
1853             script {
1854                new st[31];
1855                new Float:vl;
1856                get_state(PART:"elm.text", st, 30, vl);
1857                if (!strcmp(st, "visible"))
1858                  set_state(PART:"elm.text", "disabled_visible", 0.0);
1859                else
1860                  set_state(PART:"elm.text", "disabled", 0.0);
1861                set_int(button_state, BUTTON_STATE_DISABLED);
1862             }
1863          }
1864          program { name: "enable";
1865             signal: "elm,state,enabled";
1866             source: "elm";
1867             action: STATE_SET "default" 0.0;
1868             target: "button_image";
1869             target: "disabler";
1870             after: "enable_text";
1871          }
1872          program { name: "enable_text";
1873             script {
1874                new st[31];
1875                new Float:vl;
1876                get_state(PART:"elm.text", st, 30, vl);
1877                if (!strcmp(st, "disabled_visible"))
1878                  set_state(PART:"elm.text", "visible", 0.0);
1879                else
1880                  set_state(PART:"elm.text", "default", 0.0);
1881                set_int(button_state, BUTTON_STATE_ENABLED);
1882             }
1883          }
1884          program { name: "focused";
1885             //signal: "elm,action,focus";
1886             //source: "elm";
1887             action: STATE_SET "focused" 0.0;
1888             target: "button_image";
1889             target: "elm.text";
1890          }
1891          program { name: "unfocused";
1892             //signal: "elm,action,unfocus";
1893             //source: "elm";
1894             action: STATE_SET "default" 0.0;
1895             target: "button_image";
1896             after: "unfocus_text";
1897          }
1898          program { name: "unfocus_text";
1899             action: STATE_SET "visible" 0.0;
1900             target: "elm.text";
1901          }
1902       }
1903    }
1904
1905 ///////////////////////////////////////////////////////////////////////////////////////
1906    group { name: "elm/button/base/style2/multiline";
1907       images {
1908          image: "00_button_04_normal.png" COMP;
1909          image: "00_button_04_press.png" COMP;
1910          image: "00_button_04_dim.png" COMP;
1911          image: "00_button_04_normal_focus.png" COMP;
1912       }
1913       styles{
1914          style { name: "btn_style2_multiline";
1915             base: "font=SLP:style=Roman font_size="BUTTON_TEXT_STYLE2_MULTILINE_FONT_SIZE_INC" align=center color=#ffffff wrap=mixed ellipise=1.0 text_class=slp_roman";
1916             tag: "br" "\n";
1917             tag: "ps" "ps";
1918             tag: "tab" "\t";
1919          }
1920       }
1921       script {
1922          public button_state = BUTTON_STATE_ENABLED;
1923       }
1924       parts {
1925          part { name: "button_image";
1926             scale: 1;
1927             description { state: "default" 0.0;
1928                image {
1929                   normal: "00_button_04_normal.png";
1930                   border: BUTTON_TEXT_STYLE2_BG_BORDER_INC;
1931                   border_scale: 1;
1932                }
1933             }
1934             description { state: "clicked" 0.0;
1935                inherit: "default" 0.0;
1936                image.normal: "00_button_04_press.png";
1937             }
1938             description { state: "disabled" 0.0;
1939                inherit: "default" 0.0;
1940                image.normal: "00_button_04_dim.png";
1941             }
1942             description { state: "focused" 0.0;
1943                inherit: "default" 0.0;
1944                image.normal: "00_button_04_normal_focus.png";
1945             }
1946          }
1947          part { name: "padding_left_top";
1948             type: RECT;
1949             scale: 1;
1950             mouse_events: 0;
1951             description { state: "default" 0.0;
1952                align: 0.0 0.0;
1953                rel2.relative: 0.0 0.0;
1954                min: BUTTON_TEXT_STYLE2_PADDING_MIN_INC;
1955                fixed: 1 1;
1956                visible: 0;
1957             }
1958          }
1959          part { name: "bg";
1960             type: RECT;
1961             scale: 1;
1962             mouse_events: 0;
1963             description { state: "default" 0.0;
1964                min: BUTTON_TEXT_STYLE2_BG_MIN_INC;
1965                visible: 0;
1966             }
1967             description { state: "visible" 0.0;
1968                inherit: "default" 0.0;
1969                min: BUTTON_TEXT_STYLE2_VISIBLE_BG_MIN_INC;
1970             }
1971             description { state: "icononly" 0.0;
1972                inherit: "default" 0.0;
1973                min: BUTTON_TEXT_STYLE2_ICONONLY_BG_MIN_INC;
1974             }
1975          }
1976          part { name: "padding_right_bottom";
1977             type: RECT;
1978             scale: 1;
1979             mouse_events: 0;
1980             description { state: "default" 0.0;
1981                align: 1.0 1.0;
1982                rel1.relative: 1.0 1.0;
1983                min: BUTTON_TEXT_STYLE2_PADDING_MIN_INC;
1984                fixed: 1 1;
1985                visible: 0;
1986             }
1987          }
1988          part { name: "icon_rect";
1989             type: RECT;
1990             scale: 1;
1991             mouse_events: 0;
1992             description { state: "default" 0.0;
1993                visible: 0;
1994                min: 0 0;
1995                fixed: 1 0;
1996                rel1 {
1997                   relative: 1.0 1.0;
1998                   to: "padding_left_top";
1999                }
2000                rel2 {
2001                   relative: 1.0 0.0;
2002                   to_x: "padding_left_top";
2003                   to_y: "padding_right_bottom";
2004                }
2005                align: 0.0 0.5;
2006             }
2007             description { state: "visible" 0.0;
2008                visible: 0;
2009                min: BUTTON_TEXT_STYLE2_VISIBLE_ICON_RECT_MIN_MAX_INC;
2010                max: BUTTON_TEXT_STYLE2_VISIBLE_ICON_RECT_MIN_MAX_INC;
2011                fixed: 1 0;
2012                rel1 {
2013                   relative: 1.0 1.0;
2014                   to: "padding_left_top";
2015                }
2016                rel2 {
2017                   relative: 1.0 0.0;
2018                   to_x: "padding_left_top";
2019                   to_y: "padding_right_bottom";
2020                }
2021                align: 0.0 0.5;
2022             }
2023             description { state: "icononly" 0.0;
2024                inherit: "default" 0.0;
2025             }
2026          }
2027          part { name: "padding_after_icon";
2028             type: RECT;
2029             scale: 1;
2030             mouse_events: 0;
2031             description { state: "default" 0.0; //when only icon or no icon is there
2032                align: 0.0 0.0;
2033                rel1 {
2034                   relative: 1.0 0.0;
2035                   to: "icon_rect";
2036                }
2037                rel2.to: "icon_rect";
2038                fixed: 1 0;
2039                min: 0 0;
2040                visible: 0;
2041             }
2042             description { state: "visible" 0.0;
2043                visible: 0;
2044                align: 0.0 0.0;
2045                rel1 {
2046                   relative: 1.0 0.0;
2047                   to: "icon_rect";
2048                }
2049                rel2.to: "icon_rect";
2050                fixed: 1 0;
2051                min: BUTTON_TEXT_STYLE2_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
2052             }
2053             description { state: "icononly" 0.0;
2054                inherit: "default" 0.0;
2055             }
2056          }
2057          part { name: "padding_before_text";
2058             type: RECT;
2059             scale: 1;
2060             mouse_events: 0;
2061             description { state: "default" 0.0; //when only icon or no icon is there
2062                align: 1.0 0.5;
2063                rel1 {
2064                   relative: 0.0 1.0;
2065                   to_x: "elm.text";
2066                   to_y: "padding_left_top";
2067                }
2068                rel2 {
2069                   relative: 0.0 0.0;
2070                   to_x: "elm.text";
2071                   to_y: "padding_right_bottom";
2072                }
2073                fixed: 1 0;
2074                min: BUTTON_TEXT_STYLE2_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
2075                visible: 0;
2076             }
2077          }
2078          part { name: "elm.swallow.content";
2079             type: SWALLOW;
2080             scale: 1;
2081             clip_to: "clipper";
2082             description { state: "default" 0.0;
2083                visible: 0;
2084                align: 0.0 0.5;
2085                rel1 {
2086                   relative: 1.0 1.0;
2087                   to: "padding_left_top";
2088                }
2089                rel2 {
2090                   relative: 1.0 0.0;
2091                   to_x: "padding_left_top";
2092                   to_y: "padding_right_bottom";
2093                }
2094                fixed: 1 0;
2095             }
2096             description { state: "visible" 0.0;
2097                fixed: 1 0;
2098                min: BUTTON_TEXT_STYLE2_VISIBLE_ICON_MIN_MAX_INC;
2099                max: BUTTON_TEXT_STYLE2_VISIBLE_ICON_MIN_MAX_INC;
2100                align: 1.0 0.5;
2101                rel1 {
2102                   relative: 0.0 1.0;
2103                   to_x: "padding_before_text";
2104                   to_y: "padding_left_top";
2105                }
2106                rel2 {
2107                   relative: 0.0 0.0;
2108                   to_x: "padding_before_text";
2109                   to_y: "padding_right_bottom";
2110                }
2111             }
2112             description { state: "icononly" 0.0;
2113                min: BUTTON_TEXT_STYLE2_ICONONLY_ICON_MIN_MAX_INC;
2114                max: BUTTON_TEXT_STYLE2_ICONONLY_ICON_MIN_MAX_INC;
2115             }
2116          }
2117          part { name: "elm.text";
2118             type: TEXTBLOCK;
2119             mouse_events: 0;
2120             scale: 1;
2121             clip_to: "clipper";
2122             description { state: "default" 0.0;
2123                visible: 0;
2124                rel1 {
2125                   relative: 1.0 1.0;
2126                   to_x: "padding_after_icon";
2127                   to_y: "padding_left_top";
2128                }
2129                rel2 {
2130                   relative: 0.0 0.0;
2131                   to: "padding_right_bottom";
2132                }
2133                color: BUTTON_TEXT_STYLE1_NORMAL_COLOR_INC;
2134                text {
2135                   style: "btn_style2_multiline";
2136                   min: 0 0;
2137                   max: 1 0;
2138                }
2139             }
2140             description { state: "visible" 0.0;
2141                inherit: "default" 0.0;
2142                visible: 1;
2143             }
2144             description { state: "clicked" 0.0;
2145                inherit: "default" 0.0;
2146                visible: 1;
2147                color: BUTTON_TEXT_STYLE1_PRESSED_COLOR_INC;
2148             }
2149             description { state: "disabled" 0.0;
2150                inherit: "default" 0.0;
2151                color: 0 0 0 128;
2152             }
2153             description { state: "disabled_visible" 0.0;
2154                inherit: "default" 0.0;
2155                color: BUTTON_TEXT_STYLE1_DISABLED_COLOR_INC;
2156                visible: 1;
2157             }
2158             description { state: "focused" 0.0;
2159                inherit: "default" 0.0;
2160                visible: 1;
2161                color: BUTTON_TEXT_STYLE1_FOCUSED_COLOR_INC;
2162             }
2163          }
2164          part { name: "over2";
2165             type: RECT;
2166             repeat_events: 1;
2167             ignore_flags: ON_HOLD;
2168             description { state: "default" 0.0;
2169                color: 0 0 0 0;
2170             }
2171          }
2172          part { name: "over3";
2173             type: RECT;
2174             repeat_events: 1;
2175             description { state: "default" 0.0;
2176                color: 0 0 0 0;
2177             }
2178          }
2179          part { name: "clipper";
2180             type: RECT;
2181             description { state: "default" 0.0;
2182                color: 255 255 255 255;
2183             }
2184          }
2185          part { name: "disabler";
2186             type: RECT;
2187             description { state: "default" 0.0;
2188                color: 0 0 0 0;
2189                visible: 0;
2190             }
2191             description { state: "disabled" 0.0;
2192                inherit: "default" 0.0;
2193                visible: 1;
2194             }
2195          }
2196       }
2197       programs {
2198          program { name: "button_click";
2199             signal: "mouse,down,1";
2200             source: "over2";
2201             action: SIGNAL_EMIT "elm,action,press" "";
2202             after: "button_click_anim";
2203          }
2204          program { name: "button_click_anim";
2205             action: STATE_SET "clicked" 0.0;
2206             target: "button_image";
2207             after: "text_clicked";
2208          }
2209          program { name: "text_clicked";
2210             script {
2211                new st[31];
2212                new Float:vl;
2213                get_state(PART:"elm.text", st, 30, vl);
2214                if (!strcmp(st, "visible"))
2215                  set_state(PART:"elm.text", "clicked", 0.0);
2216             }
2217          }
2218          program { name: "button_unpress";
2219             action: SIGNAL_EMIT "elm,action,unpress" "";
2220          }
2221          program { name: "button_mouseout_clicked";
2222             signal: "mouse,up,1";
2223             source: "over3";
2224             script {
2225                new st[31];
2226                new Float:vl;
2227                get_state(PART:"elm.swallow.content", st, 30, vl);
2228                if (strcmp(st, "icononly"))
2229                  {
2230                     emit("elm,action,default,text,set", "");
2231                     set_state(PART:"elm.text", "visible", 0.0);
2232                  }
2233                if (get_int(button_state) != BUTTON_STATE_DISABLED)
2234                  set_state(PART:"button_image", "default", 0.0);
2235             }
2236             after: button_unpress;
2237          }
2238          program { name: "touch_snd";
2239             signal: "mouse,clicked,1";
2240             source: "over2";
2241             action: PLAY_SAMPLE "touch_sound" 1.0;
2242             after: button_unclick3;
2243          }
2244          program { name: "button_unclick3";
2245             action: SIGNAL_EMIT "elm,action,click" "";
2246          }
2247          program { name: "text_show";
2248             signal: "elm,state,text,visible";
2249             source: "elm";
2250             script {
2251                new st[31];
2252                new Float:vl;
2253                get_state(PART:"elm.swallow.content", st, 30, vl);
2254                if (!strcmp(st, "icononly"))
2255                  {
2256                     set_state(PART:"elm.swallow.content", "visible", 0.0);
2257                     set_state(PART:"icon_rect", "visible", 0.0);
2258                     set_state(PART:"padding_after_icon", "visible", 0.0);
2259                     set_state(PART:"bg", "visible", 0.0);
2260                  }
2261                if (get_int(button_state) != BUTTON_STATE_DISABLED)
2262                  set_state(PART:"elm.text", "visible", 0.0);
2263                else
2264                  set_state(PART:"elm.text", "disabled_visible", 0.0);
2265             }
2266          }
2267          program { name: "text_hide";
2268             signal: "elm,state,text,hidden";
2269             source: "elm";
2270             script {
2271                new st[31];
2272                new Float:vl;
2273                get_state(PART:"elm.swallow.content", st, 30, vl);
2274                if (!strcmp(st, "visible"))
2275                  {
2276                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
2277                     set_state(PART:"icon_rect", "icononly", 0.0);
2278                     set_state(PART:"padding_after_icon", "icononly", 0.0);
2279                     set_state(PART:"bg", "icononly", 0.0);
2280                  }
2281                set_state(PART:"elm.text", "default", 0.0);
2282             }
2283          }
2284          program { name: "icon_show";
2285             signal: "elm,state,icon,visible";
2286             source: "elm";
2287             script {
2288                new st[31];
2289                new Float:vl;
2290                get_state(PART:"elm.text", st, 30, vl);
2291                if (!strcmp(st, "visible"))
2292                  {
2293                     set_state(PART:"elm.swallow.content", "visible", 0.0);
2294                     set_state(PART:"icon_rect", "visible", 0.0);
2295                     set_state(PART:"padding_after_icon", "visible", 0.0);
2296                     set_state(PART:"bg", "visible", 0.0);
2297                  }
2298                else
2299                  {
2300                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
2301                     set_state(PART:"icon_rect", "icononly", 0.0);
2302                     set_state(PART:"padding_after_icon", "icononly", 0.0);
2303                     set_state(PART:"bg", "icononly", 0.0);
2304                  }
2305             }
2306          }
2307          program { name: "icon_hide";
2308             signal: "elm,state,icon,hidden";
2309             source: "elm";
2310             action: STATE_SET "default" 0.0;
2311             target: "elm.swallow.content";
2312             target: "padding_after_icon";
2313             target: "icon_rect";
2314             target: "bg";
2315          }
2316          program { name: "disable";
2317             signal: "elm,state,disabled";
2318             source: "elm";
2319             action: STATE_SET "disabled" 0.0;
2320             target: "button_image";
2321             target: "disabler";
2322             after: "disable_text";
2323          }
2324          program { name: "disable_text";
2325             script {
2326                new st[31];
2327                new Float:vl;
2328                get_state(PART:"elm.text", st, 30, vl);
2329                if (!strcmp(st, "visible"))
2330                  set_state(PART:"elm.text", "disabled_visible", 0.0);
2331                else
2332                  set_state(PART:"elm.text", "disabled", 0.0);
2333                set_int(button_state, BUTTON_STATE_DISABLED);
2334             }
2335          }
2336          program { name: "enable";
2337             signal: "elm,state,enabled";
2338             source: "elm";
2339             action: STATE_SET "default" 0.0;
2340             target: "button_image";
2341             target: "disabler";
2342             after: "enable_text";
2343          }
2344          program { name: "enable_text";
2345             script {
2346                new st[31];
2347                new Float:vl;
2348                get_state(PART:"elm.text", st, 30, vl);
2349                if (!strcmp(st, "disabled_visible"))
2350                  set_state(PART:"elm.text", "visible", 0.0);
2351                else
2352                  set_state(PART:"elm.text", "default", 0.0);
2353                set_int(button_state, BUTTON_STATE_ENABLED);
2354             }
2355          }
2356          program { name: "focused";
2357             //signal: "elm,action,focus";
2358             //source: "elm";
2359             action: STATE_SET "focused" 0.0;
2360             target: "button_image";
2361             target: "elm.text";
2362          }
2363          program { name: "unfocused";
2364             //signal: "elm,action,unfocus";
2365             //source: "elm";
2366             action: STATE_SET "default" 0.0;
2367             target: "button_image";
2368             after: "unfocus_text";
2369          }
2370          program { name: "unfocus_text";
2371             action: STATE_SET "visible" 0.0;
2372             target: "elm.text";
2373          }
2374       }
2375    }
2376
2377 ///////////////////////////////////////////////////////////////////////////////////////
2378    group { name: "elm/button/base/sweep";
2379       alias: "elm/button/base/text_only/sweep";
2380       images {
2381          image: "00_button_sweep.png" COMP;
2382          image: "00_button_sweep_press.png" COMP;
2383          image: "00_button_sweep_dim.png" COMP;
2384          image: "00_button_sweep_focus.png" COMP;
2385       }
2386       script {
2387          public button_state = BUTTON_STATE_ENABLED;
2388       }
2389       parts {
2390          part { name: "button_image";
2391             scale: 1;
2392             description { state: "default" 0.0;
2393                min: BUTTON_SWEEP_BG_NORMAL_MIN_INC;
2394                image {
2395                   normal: "00_button_sweep.png";
2396                   border: BUTTON_SWEEP_BG_BORDER_INC;
2397                   border_scale: 1;
2398                }
2399             }
2400             description { state: "clicked" 0.0;
2401                inherit: "default" 0.0;
2402                image.normal: "00_button_sweep_press.png";
2403             }
2404             description { state: "disabled" 0.0;
2405                inherit: "default" 0.0;
2406                image.normal: "00_button_sweep_dim.png";
2407             }
2408             description { state: "focused" 0.0;
2409                inherit: "default" 0.0;
2410                image.normal: "00_button_sweep_focus.png";
2411             }
2412          }
2413          part { name: "padding_left_top";
2414             type: RECT;
2415             scale: 1;
2416             mouse_events: 0;
2417             description { state: "default" 0.0;
2418                align: 0.0 0.0;
2419                rel2.relative: 0.0 0.0;
2420                min: BUTTON_SWEEP_PADDING_MIN_INC;
2421                fixed: 1 1;
2422                visible: 0;
2423             }
2424          }
2425          part { name: "padding_right_bottom";
2426             type: RECT;
2427             scale: 1;
2428             mouse_events: 0;
2429             description { state: "default" 0.0;
2430                align: 1.0 1.0;
2431                rel1.relative: 1.0 1.0;
2432                min: BUTTON_SWEEP_PADDING_MIN_INC;
2433                fixed: 1 1;
2434                visible: 0;
2435             }
2436          }
2437          part { name: "icon_rect";
2438             type: RECT;
2439             scale: 1;
2440             mouse_events: 0;
2441             description { state: "default" 0.0;
2442                min: BUTTON_SWEEP_ICON_RECT_MIN_INC;
2443                fixed: 1 0;
2444                rel1 {
2445                   relative: 0.0 1.0;
2446                   to_x: "elm.swallow.content";
2447                   to_y: "padding_left_top";
2448                }
2449                rel2 {
2450                   relative: 1.0 0.0;
2451                   to_x: "elm.swallow.content";
2452                   to_y: "padding_right_bottom";
2453                }
2454                align: 0.0 0.5;
2455                color: 0 0 0 0;
2456             }
2457          }
2458          part { name: "padding_icon_text";
2459             type: RECT;
2460             scale: 1;
2461             mouse_events: 0;
2462             description { state: "default" 0.0; //when only icon or no icon is there
2463                align: 0.0 0.0;
2464                rel1 {
2465                   relative: 1.0 0.0;
2466                   to: "icon_rect";
2467                }
2468                rel2.to: "icon_rect";
2469                fixed: 1 0;
2470                min: 0 0;
2471                color: 0 0 0 0;
2472             }
2473             description { state: "icononly" 0.0;
2474                inherit: "default" 0.0;
2475             }
2476             description { state: "visible" 0.0; //when icon is visible
2477                align: 0.0 0.0;
2478                rel1 {
2479                   relative: 1.0 0.0;
2480                   to: "icon_rect";
2481                }
2482                rel2.to: "icon_rect";
2483                fixed: 1 0;
2484                min: BUTTON_SWEEP_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
2485                color: 0 0 0 0;
2486             }
2487          }
2488          part { name: "elm.swallow.content";
2489             type: SWALLOW;
2490             scale: 1;
2491             clip_to: "clipper";
2492             description { state: "default" 0.0;
2493                visible: 0;
2494                align: 0.0 0.5;
2495                rel1 {
2496                   relative: 1.0 1.0;
2497                   to: "padding_left_top";
2498                }
2499                rel2 {
2500                   relative: 1.0 0.0;
2501                   to_x: "padding_left_top";
2502                   to_y: "padding_right_bottom";
2503                }
2504                fixed: 1 0;
2505             }
2506             description { state: "visible" 0.0;
2507                fixed: 1 0;
2508                align: 0.0 0.5;
2509                rel1 {
2510                   relative: 1.0 1.0;
2511                   to: "padding_left_top";
2512                }
2513                rel2 {
2514                   relative: 1.0 0.0;
2515                   to_x: "padding_left_top";
2516                   to_y: "padding_right_bottom";
2517                }
2518                aspect: 1.0 1.0;
2519                aspect_preference: VERTICAL;
2520             }
2521             description { state: "icononly" 0.0;
2522                min: BUTTON_SWEEP_ICONONLY_ICON_MIN_INC;
2523                rel1 {
2524                   relative: 1.0 1.0;
2525                   to: "padding_left_top";
2526                }
2527                rel2 {
2528                   relative: 1.0 0.0;
2529                   to_x: "padding_left_top";
2530                   to_y: "padding_right_bottom";
2531                }
2532             }
2533          }
2534          part { name: "elm.text";
2535             type: TEXT;
2536             mouse_events: 0;
2537             scale: 1;
2538             clip_to: "clipper";
2539             description { state: "default" 0.0;
2540                visible: 0;
2541                rel1 {
2542                   relative: 1.0 1.0;
2543                   to_x: "padding_icon_text";
2544                   to_y: "padding_left_top";
2545                }
2546                rel2 {
2547                   relative: 0.0 0.0;
2548                   to: "padding_right_bottom";
2549                }
2550                color: BUTTON_SWEEP_BUTTON_TEXT_NORMAL_COLOR_INC;
2551                text {
2552                   font: "SLP:style=Medium";
2553                   size: BUTTON_SWEEP_FONT_SIZE_INC;
2554                   min: 0 0;
2555                   text_class: "slp_medium";
2556                }
2557             }
2558             description { state: "visible" 0.0;
2559                inherit: "default" 0.0;
2560                visible: 1;
2561                min: BUTTON_SWEEP_TEXT_MIN_INC;
2562             }
2563             description { state: "clicked" 0.0;
2564                inherit: "default" 0.0;
2565                visible: 1;
2566                min: 0 0;
2567                color: BUTTON_SWEEP_BUTTON_TEXT_PRESSED_COLOR_INC;
2568             }
2569             description { state: "disabled" 0.0;
2570                inherit: "default" 0.0;
2571                color: 0 0 0 128;
2572             }
2573             description { state: "disabled_visible" 0.0;
2574                inherit: "default" 0.0;
2575                color: BUTTON_SWEEP_BUTTON_TEXT_DISABLED_COLOR_INC;
2576                visible: 1;
2577                min: BUTTON_SWEEP_TEXT_MIN_INC;
2578             }
2579             description { state: "focused" 0.0;
2580                inherit: "default" 0.0;
2581                visible: 1;
2582                min: 0 0;
2583                color: BUTTON_SWEEP_BUTTON_TEXT_FOCUSED_COLOR_INC;
2584             }
2585          }
2586          part { name: "over2";
2587             type: RECT;
2588             repeat_events: 1;
2589             ignore_flags: ON_HOLD;
2590             description { state: "default" 0.0;
2591                color: 0 0 0 0;
2592             }
2593          }
2594          part { name: "over3";
2595             type: RECT;
2596             repeat_events: 1;
2597             description { state: "default" 0.0;
2598                color: 0 0 0 0;
2599             }
2600          }
2601          part { name: "clipper";
2602             type: RECT;
2603             description { state: "default" 0.0;
2604                color: 255 255 255 255;
2605             }
2606          }
2607          part { name: "disabler";
2608             type: RECT;
2609             description { state: "default" 0.0;
2610                color: 0 0 0 0;
2611                visible: 0;
2612             }
2613             description { state: "disabled" 0.0;
2614                inherit: "default" 0.0;
2615                visible: 1;
2616             }
2617          }
2618       }
2619       programs {
2620          program { name: "button_click";
2621             signal: "mouse,down,1";
2622             source: "over2";
2623             action: SIGNAL_EMIT "elm,action,press" "";
2624             after: "button_click_anim";
2625          }
2626          program { name: "button_click_anim";
2627             action: STATE_SET "clicked" 0.0;
2628             target: "button_image";
2629             after: "text_clicked";
2630          }
2631          program { name: "text_clicked";
2632             script {
2633                new st[31];
2634                new Float:vl;
2635                get_state(PART:"elm.text", st, 30, vl);
2636                if (!strcmp(st, "visible"))
2637                  set_state(PART:"elm.text", "clicked", 0.0);
2638             }
2639          }
2640          program { name: "button_unpress";
2641             action: SIGNAL_EMIT "elm,action,unpress" "";
2642          }
2643          program { name: "button_mouseout_clicked";
2644             signal: "mouse,up,1";
2645             source: "over3";
2646             script {
2647                new st[31];
2648                new Float:vl;
2649                get_state(PART:"elm.swallow.content", st, 30, vl);
2650                if (strcmp(st, "icononly"))
2651                  {
2652                     emit("elm,action,default,text,set", "");
2653                     set_state(PART:"elm.text", "visible", 0.0);
2654                  }
2655                if (get_int(button_state) != BUTTON_STATE_DISABLED)
2656                  set_state(PART:"button_image", "default", 0.0);
2657             }
2658             after: button_unpress;
2659          }
2660          program { name: "touch_snd";
2661             signal: "mouse,clicked,1";
2662             source: "over2";
2663             action: PLAY_SAMPLE "touch_sound" 1.0;
2664             after: button_unclick3;
2665          }
2666          program { name: "button_unclick3";
2667             action: SIGNAL_EMIT "elm,action,click" "";
2668          }
2669          program { name: "text_show";
2670             signal: "elm,state,text,visible";
2671             source: "elm";
2672             script {
2673                new st[31];
2674                new Float:vl;
2675                get_state(PART:"elm.swallow.content", st, 30, vl);
2676                if (!strcmp(st, "icononly"))
2677                  {
2678                     set_state(PART:"elm.swallow.content", "visible", 0.0);
2679                     set_state(PART:"padding_icon_text", "visible", 0.0);
2680                  }
2681                if (get_int(button_state) != BUTTON_STATE_DISABLED)
2682                  set_state(PART:"elm.text", "visible", 0.0);
2683                else
2684                  set_state(PART:"elm.text", "disabled_visible", 0.0);
2685             }
2686          }
2687          program { name: "text_hide";
2688             signal: "elm,state,text,hidden";
2689             source: "elm";
2690             script {
2691                new st[31];
2692                new Float:vl;
2693                get_state(PART:"elm.swallow.content", st, 30, vl);
2694                if (!strcmp(st, "visible"))
2695                  {
2696                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
2697                     set_state(PART:"padding_icon_text", "icononly", 0.0);
2698                  }
2699                set_state(PART:"elm.text", "default", 0.0);
2700             }
2701          }
2702          program { name: "icon_show";
2703             signal: "elm,state,icon,visible";
2704             source: "elm";
2705             script {
2706                new st[31];
2707                new Float:vl;
2708                get_state(PART:"elm.text", st, 30, vl);
2709                if (!strcmp(st, "visible"))
2710                  {
2711                     set_state(PART:"elm.swallow.content", "visible", 0.0);
2712                     set_state(PART:"padding_icon_text", "visible", 0.0);
2713                  }
2714                else
2715                  {
2716                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
2717                     set_state(PART:"padding_icon_text", "icononly", 0.0);
2718                  }
2719             }
2720          }
2721          program { name: "icon_hide";
2722             signal: "elm,state,icon,hidden";
2723             source: "elm";
2724             action: STATE_SET "default" 0.0;
2725             target: "elm.swallow.content";
2726             target: "padding_icon_text";
2727          }
2728          program { name: "disable";
2729             signal: "elm,state,disabled";
2730             source: "elm";
2731             action: STATE_SET "disabled" 0.0;
2732             target: "button_image";
2733             target: "disabler";
2734             after: "disable_text";
2735          }
2736          program { name: "disable_text";
2737             script {
2738                new st[31];
2739                new Float:vl;
2740                get_state(PART:"elm.text", st, 30, vl);
2741                if (!strcmp(st, "visible"))
2742                  set_state(PART:"elm.text", "disabled_visible", 0.0);
2743                else
2744                  set_state(PART:"elm.text", "disabled", 0.0);
2745                set_int(button_state, BUTTON_STATE_DISABLED);
2746             }
2747          }
2748          program { name: "enable";
2749             signal: "elm,state,enabled";
2750             source: "elm";
2751             action: STATE_SET "default" 0.0;
2752             target: "button_image";
2753             target: "disabler";
2754             after: "enable_text";
2755          }
2756          program { name: "enable_text";
2757             script {
2758                new st[31];
2759                new Float:vl;
2760                get_state(PART:"elm.text", st, 30, vl);
2761                if (!strcmp(st, "disabled_visible"))
2762                  set_state(PART:"elm.text", "visible", 0.0);
2763                else
2764                  set_state(PART:"elm.text", "default", 0.0);
2765                set_int(button_state, BUTTON_STATE_ENABLED);
2766             }
2767          }
2768          program { name: "focused";
2769             //signal: "elm,action,focus";
2770             //source: "elm";
2771             action: STATE_SET "focused" 0.0;
2772             target: "button_image";
2773             target: "elm.text";
2774          }
2775          program { name: "unfocused";
2776             //signal: "elm,action,unfocus";
2777             //source: "elm";
2778             action: STATE_SET "default" 0.0;
2779             target: "button_image";
2780             after: "unfocus_text";
2781          }
2782          program { name: "unfocus_text";
2783             action: STATE_SET "visible" 0.0;
2784             target: "elm.text";
2785          }
2786       }
2787    }
2788
2789 ///////////////////////////////////////////////////////////////////////////////////////
2790    group { name: "elm/button/base/sweep/multiline";
2791       images {
2792          image: "00_button_sweep.png" COMP;
2793          image: "00_button_sweep_press.png" COMP;
2794          image: "00_button_sweep_dim.png" COMP;
2795          image: "00_button_sweep_focus.png" COMP;
2796       }
2797       styles{
2798          style { name: "btn_sweep_multiline";
2799             base: "font=SLP:style=Roman font_size="BUTTON_SWEEP_MULTILINE_FONT_SIZE_INC" align=center color=#ffffff wrap=mixed ellipise=1.0 text_class=slp_roman";
2800             tag: "br" "\n";
2801             tag: "ps" "ps";
2802             tag: "tab" "\t";
2803          }
2804       }
2805       script {
2806          public button_state = BUTTON_STATE_ENABLED;
2807       }
2808       parts {
2809          part { name: "button_image";
2810             scale: 1;
2811             description { state: "default" 0.0;
2812                min: BUTTON_SWEEP_BG_NORMAL_MIN_INC;
2813                image {
2814                   normal: "00_button_sweep.png";
2815                   border: BUTTON_SWEEP_BG_BORDER_INC;
2816                   border_scale: 1;
2817                }
2818             }
2819             description { state: "clicked" 0.0;
2820                inherit: "default" 0.0;
2821                image.normal: "00_button_sweep_press.png";
2822             }
2823             description { state: "disabled" 0.0;
2824                inherit: "default" 0.0;
2825                image.normal: "00_button_sweep_dim.png";
2826             }
2827             description { state: "focused" 0.0;
2828                inherit: "default" 0.0;
2829                image.normal: "00_button_sweep_focus.png";
2830             }
2831          }
2832          part { name: "padding_left_top";
2833             type: RECT;
2834             scale: 1;
2835             mouse_events: 0;
2836             description { state: "default" 0.0;
2837                align: 0.0 0.0;
2838                rel2.relative: 0.0 0.0;
2839                min: BUTTON_SWEEP_PADDING_MIN_INC;
2840                fixed: 1 1;
2841                visible: 0;
2842             }
2843          }
2844          part { name: "padding_right_bottom";
2845             type: RECT;
2846             scale: 1;
2847             mouse_events: 0;
2848             description { state: "default" 0.0;
2849                align: 1.0 1.0;
2850                rel1.relative: 1.0 1.0;
2851                min: BUTTON_SWEEP_PADDING_MIN_INC;
2852                fixed: 1 1;
2853                visible: 0;
2854             }
2855          }
2856          part { name: "icon_rect";
2857             type: RECT;
2858             scale: 1;
2859             mouse_events: 0;
2860             description { state: "default" 0.0;
2861                min: BUTTON_SWEEP_ICON_RECT_MIN_INC;
2862                fixed: 1 0;
2863                rel1 {
2864                   relative: 0.0 1.0;
2865                   to_x: "elm.swallow.content";
2866                   to_y: "padding_left_top";
2867                }
2868                rel2 {
2869                   relative: 1.0 0.0;
2870                   to_x: "elm.swallow.content";
2871                   to_y: "padding_right_bottom";
2872                }
2873                align: 0.0 0.5;
2874                color: 0 0 0 0;
2875             }
2876          }
2877          part { name: "padding_icon_text";
2878             type: RECT;
2879             scale: 1;
2880             mouse_events: 0;
2881             description { state: "default" 0.0; //when only icon or no icon is there
2882                align: 0.0 0.0;
2883                rel1 {
2884                   relative: 1.0 0.0;
2885                   to: "icon_rect";
2886                }
2887                rel2.to: "icon_rect";
2888                fixed: 1 0;
2889                min: 0 0;
2890                color: 0 0 0 0;
2891             }
2892             description { state: "icononly" 0.0;
2893                inherit: "default" 0.0;
2894             }
2895             description { state: "visible" 0.0; //when icon is visible
2896                align: 0.0 0.0;
2897                rel1 {
2898                   relative: 1.0 0.0;
2899                   to: "icon_rect";
2900                }
2901                rel2.to: "icon_rect";
2902                fixed: 1 0;
2903                min: BUTTON_SWEEP_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
2904                color: 0 0 0 0;
2905             }
2906          }
2907          part { name: "elm.swallow.content";
2908             type: SWALLOW;
2909             scale: 1;
2910             clip_to: "clipper";
2911             description { state: "default" 0.0;
2912                visible: 0;
2913                align: 0.0 0.5;
2914                rel1 {
2915                   relative: 1.0 1.0;
2916                   to: "padding_left_top";
2917                }
2918                rel2 {
2919                   relative: 1.0 0.0;
2920                   to_x: "padding_left_top";
2921                   to_y: "padding_right_bottom";
2922                }
2923                fixed: 1 0;
2924             }
2925             description { state: "visible" 0.0;
2926                fixed: 1 0;
2927                align: 0.0 0.5;
2928                rel1 {
2929                   relative: 1.0 1.0;
2930                   to: "padding_left_top";
2931                }
2932                rel2 {
2933                   relative: 1.0 0.0;
2934                   to_x: "padding_left_top";
2935                   to_y: "padding_right_bottom";
2936                }
2937                aspect: 1.0 1.0;
2938                aspect_preference: VERTICAL;
2939             }
2940             description { state: "icononly" 0.0;
2941                min: BUTTON_SWEEP_ICONONLY_ICON_MIN_INC;
2942                rel1 {
2943                   relative: 1.0 1.0;
2944                   to: "padding_left_top";
2945                }
2946                rel2 {
2947                   relative: 1.0 0.0;
2948                   to_x: "padding_left_top";
2949                   to_y: "padding_right_bottom";
2950                }
2951             }
2952          }
2953          part { name: "elm.text";
2954             type: TEXTBLOCK;
2955             mouse_events: 0;
2956             scale: 1;
2957             clip_to: "clipper";
2958             description { state: "default" 0.0;
2959                visible: 0;
2960                rel1 {
2961                   relative: 1.0 1.0;
2962                   to_x: "padding_icon_text";
2963                   to_y: "padding_left_top";
2964                }
2965                rel2 {
2966                   relative: 0.0 0.0;
2967                   to: "padding_right_bottom";
2968                }
2969                color: BUTTON_SWEEP_BUTTON_TEXT_NORMAL_COLOR_INC;
2970                text {
2971                   style: "btn_sweep_multiline";
2972                   min: 0 0;
2973                   max: 0 1;
2974                }
2975             }
2976             description { state: "visible" 0.0;
2977                inherit: "default" 0.0;
2978                visible: 1;
2979                min: BUTTON_SWEEP_TEXT_MIN_INC;
2980             }
2981             description { state: "clicked" 0.0;
2982                inherit: "default" 0.0;
2983                visible: 1;
2984                min: 0 0;
2985                color: BUTTON_SWEEP_BUTTON_TEXT_PRESSED_COLOR_INC;
2986             }
2987             description { state: "disabled" 0.0;
2988                inherit: "default" 0.0;
2989                color: 0 0 0 128;
2990             }
2991             description { state: "disabled_visible" 0.0;
2992                inherit: "default" 0.0;
2993                color: BUTTON_SWEEP_BUTTON_TEXT_DISABLED_COLOR_INC;
2994                visible: 1;
2995                min: BUTTON_SWEEP_TEXT_MIN_INC;
2996             }
2997             description { state: "focused" 0.0;
2998                inherit: "default" 0.0;
2999                visible: 1;
3000                min: 0 0;
3001                color: BUTTON_SWEEP_BUTTON_TEXT_FOCUSED_COLOR_INC;
3002             }
3003          }
3004          part { name: "over2";
3005             type: RECT;
3006             repeat_events: 1;
3007             ignore_flags: ON_HOLD;
3008             description { state: "default" 0.0;
3009                color: 0 0 0 0;
3010             }
3011          }
3012          part { name: "over3";
3013             type: RECT;
3014             repeat_events: 1;
3015             description { state: "default" 0.0;
3016                color: 0 0 0 0;
3017             }
3018          }
3019          part { name: "clipper";
3020             type: RECT;
3021             description { state: "default" 0.0;
3022                color: 255 255 255 255;
3023             }
3024          }
3025          part { name: "disabler";
3026             type: RECT;
3027             description { state: "default" 0.0;
3028                color: 0 0 0 0;
3029                visible: 0;
3030             }
3031             description { state: "disabled" 0.0;
3032                inherit: "default" 0.0;
3033                visible: 1;
3034             }
3035          }
3036       }
3037       programs {
3038          program { name: "button_click";
3039             signal: "mouse,down,1";
3040             source: "over2";
3041             action: SIGNAL_EMIT "elm,action,press" "";
3042             after: "button_click_anim";
3043          }
3044          program { name: "button_click_anim";
3045             action: STATE_SET "clicked" 0.0;
3046             target: "button_image";
3047             after: "text_clicked";
3048          }
3049          program { name: "text_clicked";
3050             script {
3051                new st[31];
3052                new Float:vl;
3053                get_state(PART:"elm.text", st, 30, vl);
3054                if (!strcmp(st, "visible"))
3055                  set_state(PART:"elm.text", "clicked", 0.0);
3056             }
3057          }
3058          program { name: "button_unpress";
3059             action: SIGNAL_EMIT "elm,action,unpress" "";
3060          }
3061          program { name: "button_mouseout_clicked";
3062             signal: "mouse,up,1";
3063             source: "over3";
3064             script {
3065                new st[31];
3066                new Float:vl;
3067                get_state(PART:"elm.swallow.content", st, 30, vl);
3068                if (strcmp(st, "icononly"))
3069                  {
3070                     emit("elm,action,default,text,set", "");
3071                     set_state(PART:"elm.text", "visible", 0.0);
3072                  }
3073                if (get_int(button_state) != BUTTON_STATE_DISABLED)
3074                  set_state(PART:"button_image", "default", 0.0);
3075             }
3076             after: button_unpress;
3077          }
3078          program { name: "touch_snd";
3079             signal: "mouse,clicked,1";
3080             source: "over2";
3081             action: PLAY_SAMPLE "touch_sound" 1.0;
3082             after: button_unclick3;
3083          }
3084          program { name: "button_unclick3";
3085             action: SIGNAL_EMIT "elm,action,click" "";
3086          }
3087          program { name: "text_show";
3088             signal: "elm,state,text,visible";
3089             source: "elm";
3090             script {
3091                new st[31];
3092                new Float:vl;
3093                get_state(PART:"elm.swallow.content", st, 30, vl);
3094                if (!strcmp(st, "icononly"))
3095                  {
3096                     set_state(PART:"elm.swallow.content", "visible", 0.0);
3097                     set_state(PART:"padding_icon_text", "visible", 0.0);
3098                  }
3099                if (get_int(button_state) != BUTTON_STATE_DISABLED)
3100                  set_state(PART:"elm.text", "visible", 0.0);
3101                else
3102                  set_state(PART:"elm.text", "disabled_visible", 0.0);
3103             }
3104          }
3105          program { name: "text_hide";
3106             signal: "elm,state,text,hidden";
3107             source: "elm";
3108             script {
3109                new st[31];
3110                new Float:vl;
3111                get_state(PART:"elm.swallow.content", st, 30, vl);
3112                if (!strcmp(st, "visible"))
3113                  {
3114                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
3115                     set_state(PART:"padding_icon_text", "icononly", 0.0);
3116                  }
3117                set_state(PART:"elm.text", "default", 0.0);
3118             }
3119          }
3120          program { name: "icon_show";
3121             signal: "elm,state,icon,visible";
3122             source: "elm";
3123             script {
3124                new st[31];
3125                new Float:vl;
3126                get_state(PART:"elm.text", st, 30, vl);
3127                if (!strcmp(st, "visible"))
3128                  {
3129                     set_state(PART:"elm.swallow.content", "visible", 0.0);
3130                     set_state(PART:"padding_icon_text", "visible", 0.0);
3131                  }
3132                else
3133                  {
3134                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
3135                     set_state(PART:"padding_icon_text", "icononly", 0.0);
3136                  }
3137             }
3138          }
3139          program { name: "icon_hide";
3140             signal: "elm,state,icon,hidden";
3141             source: "elm";
3142             action: STATE_SET "default" 0.0;
3143             target: "elm.swallow.content";
3144             target: "padding_icon_text";
3145          }
3146          program { name: "disable";
3147             signal: "elm,state,disabled";
3148             source: "elm";
3149             action: STATE_SET "disabled" 0.0;
3150             target: "button_image";
3151             target: "disabler";
3152             after: "disable_text";
3153          }
3154          program { name: "disable_text";
3155             script {
3156                new st[31];
3157                new Float:vl;
3158                get_state(PART:"elm.text", st, 30, vl);
3159                if (!strcmp(st, "visible"))
3160                  set_state(PART:"elm.text", "disabled_visible", 0.0);
3161                else
3162                  set_state(PART:"elm.text", "disabled", 0.0);
3163                set_int(button_state, BUTTON_STATE_DISABLED);
3164             }
3165          }
3166          program { name: "enable";
3167             signal: "elm,state,enabled";
3168             source: "elm";
3169             action: STATE_SET "default" 0.0;
3170             target: "button_image";
3171             target: "disabler";
3172             after: "enable_text";
3173          }
3174          program { name: "enable_text";
3175             script {
3176                new st[31];
3177                new Float:vl;
3178                get_state(PART:"elm.text", st, 30, vl);
3179                if (!strcmp(st, "disabled_visible"))
3180                  set_state(PART:"elm.text", "visible", 0.0);
3181                else
3182                  set_state(PART:"elm.text", "default", 0.0);
3183                set_int(button_state, BUTTON_STATE_ENABLED);
3184             }
3185          }
3186          program { name: "focused";
3187             //signal: "elm,action,focus";
3188             //source: "elm";
3189             action: STATE_SET "focused" 0.0;
3190             target: "button_image";
3191             target: "elm.text";
3192          }
3193          program { name: "unfocused";
3194             //signal: "elm,action,unfocus";
3195             //source: "elm";
3196             action: STATE_SET "default" 0.0;
3197             target: "button_image";
3198             after: "unfocus_text";
3199          }
3200          program { name: "unfocus_text";
3201             action: STATE_SET "visible" 0.0;
3202             target: "elm.text";
3203          }
3204       }
3205    }
3206 ///////////////////////////////////////////////////////////////////////////////////////
3207 group { name: "elm/button/base/searchbar/default";
3208       images {
3209          image: "00_button_01_normal.png" COMP;
3210          image: "00_button_01_normal_press.png" COMP;
3211          image: "00_button_01_normal_dim.png" COMP;
3212          image: "00_button_01_normal_Focus.png" COMP;
3213       }
3214       script {
3215          public button_state = BUTTON_STATE_ENABLED;
3216       }
3217       parts {
3218          part { name: "button_image";
3219             scale: 1;
3220             description { state: "default" 0.0;
3221                min: BUTTON_SEARCHBAR_BG_NORMAL_MIN_INC;
3222                image {
3223                   normal: "00_button_01_normal.png";
3224                   border: BUTTON_DEFAULT_STYLE_BG_BORDER_INC;
3225                   border_scale: 1;
3226                }
3227             }
3228             description { state: "clicked" 0.0;
3229                inherit: "default" 0.0;
3230                image.normal: "00_button_01_normal_press.png";
3231             }
3232             description { state: "disabled" 0.0;
3233                inherit: "default" 0.0;
3234                image.normal: "00_button_01_normal_dim.png";
3235             }
3236             description { state: "focused" 0.0;
3237                inherit: "default" 0.0;
3238                image.normal: "00_button_01_normal_Focus.png";
3239             }
3240          }
3241          part { name: "padding_left_top";
3242             type: RECT;
3243             scale: 1;
3244             mouse_events: 0;
3245             description { state: "default" 0.0;
3246                align: 0.0 0.0;
3247                rel2.relative: 0.0 0.0;
3248                min: BUTTON_SEARCHBAR_PADDING_MIN_INC;
3249                fixed: 1 1;
3250                visible: 0;
3251             }
3252          }
3253          part { name: "padding_right_bottom";
3254             type: RECT;
3255             scale: 1;
3256             mouse_events: 0;
3257             description { state: "default" 0.0;
3258                align: 1.0 1.0;
3259                rel1.relative: 1.0 1.0;
3260                min: BUTTON_SEARCHBAR_PADDING_MIN_INC;
3261                fixed: 1 1;
3262                visible: 0;
3263             }
3264          }
3265          part { name: "icon_rect";
3266             type: RECT;
3267             scale: 1;
3268             mouse_events: 0;
3269             description { state: "default" 0.0;
3270                min: BUTTON_SEARCHBAR_ICON_RECT_MIN_INC;
3271                fixed: 1 0;
3272                rel1 {
3273                   relative: 0.0 1.0;
3274                   to_x: "elm.swallow.content";
3275                   to_y: "padding_left_top";
3276                }
3277                rel2 {
3278                   relative: 1.0 0.0;
3279                   to_x: "elm.swallow.content";
3280                   to_y: "padding_right_bottom";
3281                }
3282                align: 0.0 0.5;
3283                color: 0 0 0 0;
3284             }
3285          }
3286          part { name: "padding_icon_text";
3287             type: RECT;
3288             scale: 1;
3289             mouse_events: 0;
3290             description { state: "default" 0.0; //when only icon or no icon is there
3291                align: 0.0 0.0;
3292                rel1 {
3293                   relative: 1.0 0.0;
3294                   to: "icon_rect";
3295                }
3296                rel2.to: "icon_rect";
3297                fixed: 1 0;
3298                min: 0 0;
3299                color: 0 0 0 0;
3300             }
3301             description { state: "icononly" 0.0;
3302                inherit: "default" 0.0;
3303             }
3304             description { state: "visible" 0.0; //when icon is visible
3305                align: 0.0 0.0;
3306                rel1 {
3307                   relative: 1.0 0.0;
3308                   to: "icon_rect";
3309                }
3310                rel2.to: "icon_rect";
3311                fixed: 1 0;
3312                min: BUTTON_SEARCHBAR_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
3313                color: 0 0 0 0;
3314             }
3315          }
3316          part { name: "elm.swallow.content";
3317             type: SWALLOW;
3318             scale: 1;
3319             clip_to: "clipper";
3320             description { state: "default" 0.0;
3321                visible: 0;
3322                align: 0.0 0.5;
3323                rel1 {
3324                   relative: 1.0 1.0;
3325                   to: "padding_left_top";
3326                }
3327                rel2 {
3328                   relative: 1.0 0.0;
3329                   to_x: "padding_left_top";
3330                   to_y: "padding_right_bottom";
3331                }
3332                fixed: 1 0;
3333             }
3334             description { state: "visible" 0.0;
3335                fixed: 1 0;
3336                align: 0.0 0.5;
3337                rel1 {
3338                   relative: 1.0 1.0;
3339                   to: "padding_left_top";
3340                }
3341                rel2 {
3342                   relative: 1.0 0.0;
3343                   to_x: "padding_left_top";
3344                   to_y: "padding_right_bottom";
3345                }
3346                aspect: 1.0 1.0;
3347                aspect_preference: VERTICAL;
3348             }
3349             description { state: "icononly" 0.0;
3350                min: BUTTON_SEARCHBAR_ICONONLY_ICON_MIN_INC;
3351                rel1 {
3352                   relative: 1.0 1.0;
3353                   to: "padding_left_top";
3354                }
3355                rel2 {
3356                   relative: 1.0 0.0;
3357                   to_x: "padding_left_top";
3358                   to_y: "padding_right_bottom";
3359                }
3360             }
3361          }
3362          part { name: "elm.text";
3363             type: TEXT;
3364             mouse_events: 0;
3365             scale: 1;
3366             clip_to: "clipper";
3367             description { state: "default" 0.0;
3368                visible: 0;
3369                rel1 {
3370                   relative: 1.0 1.0;
3371                   to_x: "padding_icon_text";
3372                   to_y: "padding_left_top";
3373                }
3374                rel2 {
3375                   relative: 0.0 0.0;
3376                   to: "padding_right_bottom";
3377                }
3378                color: BUTTON_SWEEP_BUTTON_TEXT_NORMAL_COLOR_INC;
3379                text {
3380                   font: "SLP:style=Medium";
3381                   size: BUTTON_SEARCHBAR_FONT_SIZE_INC;
3382                   min: 0 0;
3383                   text_class: "slp_medium";
3384                }
3385             }
3386             description { state: "visible" 0.0;
3387                inherit: "default" 0.0;
3388                visible: 1;
3389                min: BUTTON_SEARCHBAR_TEXT_MIN_INC;
3390             }
3391             description { state: "clicked" 0.0;
3392                inherit: "default" 0.0;
3393                visible: 1;
3394                min: 0 0;
3395                color: BUTTON_SWEEP_BUTTON_TEXT_PRESSED_COLOR_INC;
3396             }
3397             description { state: "disabled" 0.0;
3398                inherit: "default" 0.0;
3399                color: 0 0 0 128;
3400             }
3401             description { state: "disabled_visible" 0.0;
3402                inherit: "default" 0.0;
3403                color: BUTTON_SWEEP_BUTTON_TEXT_DISABLED_COLOR_INC;
3404                visible: 1;
3405                min: BUTTON_SWEEP_TEXT_MIN_INC;
3406             }
3407             description { state: "focused" 0.0;
3408                inherit: "default" 0.0;
3409                visible: 1;
3410                min: 0 0;
3411                color: BUTTON_SWEEP_BUTTON_TEXT_FOCUSED_COLOR_INC;
3412             }
3413          }
3414          part { name: "over2";
3415             type: RECT;
3416             repeat_events: 1;
3417             ignore_flags: ON_HOLD;
3418             description { state: "default" 0.0;
3419                color: 0 0 0 0;
3420             }
3421          }
3422          part { name: "over3";
3423             type: RECT;
3424             repeat_events: 1;
3425             description { state: "default" 0.0;
3426                color: 0 0 0 0;
3427             }
3428          }
3429          part { name: "clipper";
3430             type: RECT;
3431             description { state: "default" 0.0;
3432                color: 255 255 255 255;
3433             }
3434          }
3435          part { name: "disabler";
3436             type: RECT;
3437             description { state: "default" 0.0;
3438                color: 0 0 0 0;
3439                visible: 0;
3440             }
3441             description { state: "disabled" 0.0;
3442                inherit: "default" 0.0;
3443                visible: 1;
3444             }
3445          }
3446       }
3447       programs {
3448          program { name: "button_click";
3449             signal: "mouse,down,1";
3450             source: "over2";
3451             action: SIGNAL_EMIT "elm,action,press" "";
3452             after: "button_click_anim";
3453          }
3454          program { name: "button_click_anim";
3455             action: STATE_SET "clicked" 0.0;
3456             target: "button_image";
3457             after: "text_clicked";
3458          }
3459          program { name: "text_clicked";
3460             script {
3461                new st[31];
3462                new Float:vl;
3463                get_state(PART:"elm.text", st, 30, vl);
3464                if (!strcmp(st, "visible"))
3465                  set_state(PART:"elm.text", "clicked", 0.0);
3466             }
3467          }
3468          program { name: "button_unpress";
3469             action: SIGNAL_EMIT "elm,action,unpress" "";
3470          }
3471          program { name: "button_mouseout_clicked";
3472             signal: "mouse,up,1";
3473             source: "over3";
3474             script {
3475                new st[31];
3476                new Float:vl;
3477                get_state(PART:"elm.swallow.content", st, 30, vl);
3478                if (strcmp(st, "icononly"))
3479                  {
3480                     emit("elm,action,default,text,set", "");
3481                     set_state(PART:"elm.text", "visible", 0.0);
3482                  }
3483                if (get_int(button_state) != BUTTON_STATE_DISABLED)
3484                  set_state(PART:"button_image", "default", 0.0);
3485             }
3486             after: button_unpress;
3487          }
3488          program { name: "touch_snd";
3489             signal: "mouse,clicked,1";
3490             source: "over2";
3491             action: PLAY_SAMPLE "touch_sound" 1.0;
3492             after: button_unclick3;
3493          }
3494          program { name: "button_unclick3";
3495             action: SIGNAL_EMIT "elm,action,click" "";
3496          }
3497          program { name: "text_show";
3498             signal: "elm,state,text,visible";
3499             source: "elm";
3500             script {
3501                new st[31];
3502                new Float:vl;
3503                get_state(PART:"elm.swallow.content", st, 30, vl);
3504                if (!strcmp(st, "icononly"))
3505                  {
3506                     set_state(PART:"elm.swallow.content", "visible", 0.0);
3507                     set_state(PART:"padding_icon_text", "visible", 0.0);
3508                  }
3509                if (get_int(button_state) != BUTTON_STATE_DISABLED)
3510                  set_state(PART:"elm.text", "visible", 0.0);
3511                else
3512                  set_state(PART:"elm.text", "disabled_visible", 0.0);
3513             }
3514          }
3515          program { name: "text_hide";
3516             signal: "elm,state,text,hidden";
3517             source: "elm";
3518             script {
3519                new st[31];
3520                new Float:vl;
3521                get_state(PART:"elm.swallow.content", st, 30, vl);
3522                if (!strcmp(st, "visible"))
3523                  {
3524                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
3525                     set_state(PART:"padding_icon_text", "icononly", 0.0);
3526                  }
3527                set_state(PART:"elm.text", "default", 0.0);
3528             }
3529          }
3530          program { name: "icon_show";
3531             signal: "elm,state,icon,visible";
3532             source: "elm";
3533             script {
3534                new st[31];
3535                new Float:vl;
3536                get_state(PART:"elm.text", st, 30, vl);
3537                if (!strcmp(st, "visible"))
3538                  {
3539                     set_state(PART:"elm.swallow.content", "visible", 0.0);
3540                     set_state(PART:"padding_icon_text", "visible", 0.0);
3541                  }
3542                else
3543                  {
3544                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
3545                     set_state(PART:"padding_icon_text", "icononly", 0.0);
3546                  }
3547             }
3548          }
3549          program { name: "icon_hide";
3550             signal: "elm,state,icon,hidden";
3551             source: "elm";
3552             action: STATE_SET "default" 0.0;
3553             target: "elm.swallow.content";
3554             target: "padding_icon_text";
3555          }
3556          program { name: "disable";
3557             signal: "elm,state,disabled";
3558             source: "elm";
3559             action: STATE_SET "disabled" 0.0;
3560             target: "button_image";
3561             target: "disabler";
3562             after: "disable_text";
3563          }
3564          program { name: "disable_text";
3565             script {
3566                new st[31];
3567                new Float:vl;
3568                get_state(PART:"elm.text", st, 30, vl);
3569                if (!strcmp(st, "visible"))
3570                  set_state(PART:"elm.text", "disabled_visible", 0.0);
3571                else
3572                  set_state(PART:"elm.text", "disabled", 0.0);
3573                set_int(button_state, BUTTON_STATE_DISABLED);
3574             }
3575          }
3576          program { name: "enable";
3577             signal: "elm,state,enabled";
3578             source: "elm";
3579             action: STATE_SET "default" 0.0;
3580             target: "button_image";
3581             target: "disabler";
3582             after: "enable_text";
3583          }
3584          program { name: "enable_text";
3585             script {
3586                new st[31];
3587                new Float:vl;
3588                get_state(PART:"elm.text", st, 30, vl);
3589                if (!strcmp(st, "disabled_visible"))
3590                  set_state(PART:"elm.text", "visible", 0.0);
3591                else
3592                  set_state(PART:"elm.text", "default", 0.0);
3593                set_int(button_state, BUTTON_STATE_ENABLED);
3594             }
3595          }
3596          program { name: "focused";
3597             //signal: "elm,action,focus";
3598             //source: "elm";
3599             action: STATE_SET "focused" 0.0;
3600             target: "button_image";
3601             target: "elm.text";
3602          }
3603          program { name: "unfocused";
3604             //signal: "elm,action,unfocus";
3605             //source: "elm";
3606             action: STATE_SET "default" 0.0;
3607             target: "button_image";
3608             after: "unfocus_text";
3609          }
3610          program { name: "unfocus_text";
3611             action: STATE_SET "visible" 0.0;
3612             target: "elm.text";
3613          }
3614       }
3615    }
3616
3617 ///////////////////////////////////////////////////////////////////////////////////////
3618    group { name: "elm/button/base/sweep/delete";
3619       images {
3620          image: "00_button_sweep_dim.png" COMP;
3621          image: "00_button_sweep_delete.png" COMP;
3622          image: "00_button_sweep_delete_press.png" COMP;
3623          image: "00_button_sweep_focus.png" COMP;
3624       }
3625       script {
3626          public button_state = BUTTON_STATE_ENABLED;
3627       }
3628       parts {
3629          part { name: "button_image";
3630             scale: 1;
3631             description { state: "default" 0.0;
3632                min: BUTTON_SWEEP_BG_NORMAL_MIN_INC;
3633                image {
3634                   normal: "00_button_sweep_delete.png";
3635                   border: BUTTON_SWEEP_BG_BORDER_INC;
3636                   border_scale: 1;
3637                }
3638             }
3639             description { state: "clicked" 0.0;
3640                inherit: "default" 0.0;
3641                image.normal: "00_button_sweep_delete_press.png";
3642             }
3643             description { state: "disabled" 0.0;
3644                inherit: "default" 0.0;
3645                image.normal: "00_button_sweep_dim.png";
3646             }
3647             description { state: "focused" 0.0;
3648                inherit: "default" 0.0;
3649                image.normal: "00_button_sweep_focus.png";
3650             }
3651          }
3652          part { name: "padding_left_top";
3653             type: RECT;
3654             scale: 1;
3655             mouse_events: 0;
3656             description { state: "default" 0.0;
3657                align: 0.0 0.0;
3658                rel2.relative: 0.0 0.0;
3659                min: BUTTON_SWEEP_PADDING_MIN_INC;
3660                fixed: 1 1;
3661                visible: 0;
3662             }
3663          }
3664          part { name: "padding_right_bottom";
3665             type: RECT;
3666             scale: 1;
3667             mouse_events: 0;
3668             description { state: "default" 0.0;
3669                align: 1.0 1.0;
3670                rel1.relative: 1.0 1.0;
3671                min: BUTTON_SWEEP_PADDING_MIN_INC;
3672                fixed: 1 1;
3673                visible: 0;
3674             }
3675          }
3676          part { name: "icon_rect";
3677             type: RECT;
3678             scale: 1;
3679             mouse_events: 0;
3680             description { state: "default" 0.0;
3681                min: BUTTON_SWEEP_ICON_RECT_MIN_INC;
3682                fixed: 1 0;
3683                rel1 {
3684                   relative: 0.0 1.0;
3685                   to_x: "elm.swallow.content";
3686                   to_y: "padding_left_top";
3687                }
3688                rel2 {
3689                   relative: 1.0 0.0;
3690                   to_x: "elm.swallow.content";
3691                   to_y: "padding_right_bottom";
3692                }
3693                align: 0.0 0.5;
3694                color: 0 0 0 0;
3695             }
3696          }
3697          part { name: "padding_icon_text";
3698             type: RECT;
3699             scale: 1;
3700             mouse_events: 0;
3701             description { state: "default" 0.0; //when only icon or no icon is there
3702                align: 0.0 0.0;
3703                rel1 {
3704                   relative: 1.0 0.0;
3705                   to: "icon_rect";
3706                }
3707                rel2.to: "icon_rect";
3708                fixed: 1 0;
3709                min: 0 0;
3710                color: 0 0 0 0;
3711             }
3712             description { state: "icononly" 0.0;
3713                inherit: "default" 0.0;
3714             }
3715             description { state: "visible" 0.0; //when icon is visible
3716                align: 0.0 0.0;
3717                rel1 {
3718                   relative: 1.0 0.0;
3719                   to: "icon_rect";
3720                }
3721                rel2.to: "icon_rect";
3722                fixed: 1 0;
3723                min: BUTTON_SWEEP_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
3724                color: 0 0 0 0;
3725             }
3726          }
3727          part { name: "elm.swallow.content";
3728             type: SWALLOW;
3729             scale: 1;
3730             clip_to: "clipper";
3731             description { state: "default" 0.0;
3732                visible: 0;
3733                align: 0.0 0.5;
3734                rel1 {
3735                   relative: 1.0 1.0;
3736                   to: "padding_left_top";
3737                }
3738                rel2 {
3739                   relative: 1.0 0.0;
3740                   to_x: "padding_left_top";
3741                   to_y: "padding_right_bottom";
3742                }
3743                fixed: 1 0;
3744             }
3745             description { state: "visible" 0.0;
3746                fixed: 1 0;
3747                align: 0.0 0.5;
3748                rel1 {
3749                   relative: 1.0 1.0;
3750                   to: "padding_left_top";
3751                }
3752                rel2 {
3753                   relative: 1.0 0.0;
3754                   to_x: "padding_left_top";
3755                   to_y: "padding_right_bottom";
3756                }
3757                aspect: 1.0 1.0;
3758                aspect_preference: VERTICAL;
3759             }
3760             description { state: "icononly" 0.0;
3761                min: BUTTON_SWEEP_ICONONLY_ICON_MIN_INC;
3762                rel1 {
3763                   relative: 1.0 1.0;
3764                   to: "padding_left_top";
3765                }
3766                rel2 {
3767                   relative: 1.0 0.0;
3768                   to_x: "padding_left_top";
3769                   to_y: "padding_right_bottom";
3770                }
3771             }
3772          }
3773          part { name: "elm.text";
3774             type: TEXT;
3775             mouse_events: 0;
3776             scale: 1;
3777             clip_to: "clipper";
3778             description { state: "default" 0.0;
3779                rel1 {
3780                   relative: 1.0 1.0;
3781                   to_x: "padding_icon_text";
3782                   to_y: "padding_left_top";
3783                }
3784                rel2 {
3785                   relative: 0.0 0.0;
3786                   to: "padding_right_bottom";
3787                }
3788                color: BUTTON_SWEEP_BUTTON_TEXT_NORMAL_COLOR_INC;
3789                text {
3790                   font: "SLP:style=Medium";
3791                   size: BUTTON_SWEEP_FONT_SIZE_INC;
3792                   min: 1 0;
3793                   text: "Delete";
3794                   max: 1 0;
3795                   text_class: "slp_medium";
3796                }
3797             }
3798             description { state: "visible" 0.0;
3799                inherit: "default" 0.0;
3800             }
3801             description { state: "clicked" 0.0;
3802                inherit: "default" 0.0;
3803                color: BUTTON_SWEEP_BUTTON_TEXT_PRESSED_COLOR_INC;
3804             }
3805             description { state: "disabled" 0.0;
3806                inherit: "default" 0.0;
3807                color: 0 0 0 128;
3808             }
3809             description { state: "disabled_visible" 0.0;
3810                inherit: "default" 0.0;
3811                color: BUTTON_SWEEP_BUTTON_TEXT_DISABLED_COLOR_INC;
3812             }
3813             description { state: "focused" 0.0;
3814                inherit: "default" 0.0;
3815                visible: 1;
3816                min: 0 0;
3817                color: BUTTON_SWEEP_BUTTON_TEXT_FOCUSED_COLOR_INC;
3818             }
3819          }
3820          part { name: "over2";
3821             type: RECT;
3822             repeat_events: 1;
3823             ignore_flags: ON_HOLD;
3824             description { state: "default" 0.0;
3825                color: 0 0 0 0;
3826             }
3827          }
3828          part { name: "over3";
3829             type: RECT;
3830             repeat_events: 1;
3831             description { state: "default" 0.0;
3832                color: 0 0 0 0;
3833             }
3834          }
3835          part { name: "clipper";
3836             type: RECT;
3837             description { state: "default" 0.0;
3838                color: 255 255 255 255;
3839             }
3840          }
3841          part { name: "disabler";
3842             type: RECT;
3843             description { state: "default" 0.0;
3844                color: 0 0 0 0;
3845                visible: 0;
3846             }
3847             description { state: "disabled" 0.0;
3848                inherit: "default" 0.0;
3849                visible: 1;
3850             }
3851          }
3852       }
3853       programs {
3854          program { name: "button_click";
3855             signal: "mouse,down,1";
3856             source: "over2";
3857             action: SIGNAL_EMIT "elm,action,press" "";
3858             after: "button_click_anim";
3859          }
3860          program { name: "button_click_anim";
3861             action: STATE_SET "clicked" 0.0;
3862             target: "button_image";
3863             after: "text_clicked";
3864          }
3865          program { name: "text_clicked";
3866             script {
3867                new st[31];
3868                new Float:vl;
3869                get_state(PART:"elm.text", st, 30, vl);
3870                if (!strcmp(st, "visible"))
3871                  set_state(PART:"elm.text", "clicked", 0.0);
3872             }
3873          }
3874          program { name: "button_unpress";
3875             action: SIGNAL_EMIT "elm,action,unpress" "";
3876          }
3877          program { name: "button_mouseout_clicked";
3878             signal: "mouse,up,1";
3879             source: "over3";
3880             script {
3881                new st[31];
3882                new Float:vl;
3883                get_state(PART:"elm.swallow.content", st, 30, vl);
3884                if (strcmp(st, "icononly"))
3885                  {
3886                     emit("elm,action,default,text,set", "");
3887                     set_state(PART:"elm.text", "visible", 0.0);
3888                  }
3889                if (get_int(button_state) != BUTTON_STATE_DISABLED)
3890                  set_state(PART:"button_image", "default", 0.0);
3891             }
3892             after: button_unpress;
3893          }
3894          program { name: "touch_snd";
3895             signal: "mouse,clicked,1";
3896             source: "over2";
3897             action: PLAY_SAMPLE "touch_sound" 1.0;
3898             after: button_unclick3;
3899          }
3900          program { name: "button_unclick3";
3901             action: SIGNAL_EMIT "elm,action,click" "";
3902          }
3903          program { name: "text_show";
3904             signal: "elm,state,text,visible";
3905             source: "elm";
3906             script {
3907                new st[31];
3908                new Float:vl;
3909                get_state(PART:"elm.swallow.content", st, 30, vl);
3910                if (!strcmp(st, "icononly"))
3911                  {
3912                     set_state(PART:"elm.swallow.content", "visible", 0.0);
3913                     set_state(PART:"padding_icon_text", "visible", 0.0);
3914                  }
3915                if (get_int(button_state) != BUTTON_STATE_DISABLED)
3916                  set_state(PART:"elm.text", "visible", 0.0);
3917                else
3918                  set_state(PART:"elm.text", "disabled_visible", 0.0);
3919             }
3920          }
3921          program { name: "text_hide";
3922             signal: "elm,state,text,hidden";
3923             source: "elm";
3924             script {
3925                new st[31];
3926                new Float:vl;
3927                get_state(PART:"elm.swallow.content", st, 30, vl);
3928                if (!strcmp(st, "visible"))
3929                  {
3930                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
3931                     set_state(PART:"padding_icon_text", "icononly", 0.0);
3932                  }
3933                set_state(PART:"elm.text", "default", 0.0);
3934             }
3935          }
3936          program { name: "icon_show";
3937             signal: "elm,state,icon,visible";
3938             source: "elm";
3939             script {
3940                new st[31];
3941                new Float:vl;
3942                get_state(PART:"elm.text", st, 30, vl);
3943                if (!strcmp(st, "visible"))
3944                  {
3945                     set_state(PART:"elm.swallow.content", "visible", 0.0);
3946                     set_state(PART:"padding_icon_text", "visible", 0.0);
3947                  }
3948                else
3949                  {
3950                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
3951                     set_state(PART:"padding_icon_text", "icononly", 0.0);
3952                  }
3953             }
3954          }
3955          program { name: "icon_hide";
3956             signal: "elm,state,icon,hidden";
3957             source: "elm";
3958             action: STATE_SET "default" 0.0;
3959             target: "elm.swallow.content";
3960             target: "padding_icon_text";
3961          }
3962          program { name: "disable";
3963             signal: "elm,state,disabled";
3964             source: "elm";
3965             action: STATE_SET "disabled" 0.0;
3966             target: "button_image";
3967             target: "disabler";
3968             after: "disable_text";
3969          }
3970          program { name: "disable_text";
3971             script {
3972                new st[31];
3973                new Float:vl;
3974                get_state(PART:"elm.text", st, 30, vl);
3975                if (!strcmp(st, "visible"))
3976                  set_state(PART:"elm.text", "disabled_visible", 0.0);
3977                else
3978                  set_state(PART:"elm.text", "disabled", 0.0);
3979                set_int(button_state, BUTTON_STATE_DISABLED);
3980             }
3981          }
3982          program { name: "enable";
3983             signal: "elm,state,enabled";
3984             source: "elm";
3985             action: STATE_SET "default" 0.0;
3986             target: "button_image";
3987             target: "disabler";
3988             after: "enable_text";
3989          }
3990          program { name: "enable_text";
3991             script {
3992                new st[31];
3993                new Float:vl;
3994                get_state(PART:"elm.text", st, 30, vl);
3995                if (!strcmp(st, "disabled_visible"))
3996                  set_state(PART:"elm.text", "visible", 0.0);
3997                else
3998                  set_state(PART:"elm.text", "default", 0.0);
3999                set_int(button_state, BUTTON_STATE_ENABLED);
4000             }
4001          }
4002          program { name: "focused";
4003             //signal: "elm,action,focus";
4004             //source: "elm";
4005             action: STATE_SET "focused" 0.0;
4006             target: "button_image";
4007             target: "elm.text";
4008          }
4009          program { name: "unfocused";
4010             //signal: "elm,action,unfocus";
4011             //source: "elm";
4012             action: STATE_SET "default" 0.0;
4013             target: "button_image";
4014             after: "unfocus_text";
4015          }
4016          program { name: "unfocus_text";
4017             action: STATE_SET "visible" 0.0;
4018             target: "elm.text";
4019          }
4020       }
4021    }
4022
4023 ///////////////////////////////////////////////////////////////////////////////////////
4024    group { name: "elm/button/base/popup_button/default";
4025       alias: "elm/button/base/popup_button/menustyle";
4026       alias: "elm/button/base/popup_button/liststyle";
4027       alias: "elm/button/base/popup_button/volumebarstyle";
4028       alias: "elm/button/base/popup_button/customstyle";
4029       alias: "elm/button/base/popup_button/verticalbuttonstyle";
4030       images {
4031          image: "00_button_popup_normal.png" COMP;
4032          image: "00_button_popup_press.png" COMP;
4033          image: "00_button_popup_normal_focus.png" COMP;
4034          image: "00_button_popup_dim.png" COMP;
4035       }
4036       script {
4037          public button_state = BUTTON_STATE_ENABLED;
4038       }
4039       parts {
4040          part { name: "button_image";
4041             scale: 1;
4042             description { state: "default" 0.0;
4043                min: BUTTON_POPUP_BG_NORMAL_MIN_INC;
4044                image {
4045                   normal: "00_button_popup_normal.png";
4046                   border: BUTTON_POPUP_BG_BORDER_INC;
4047                   border_scale: 1;
4048                }
4049             }
4050             description { state: "clicked" 0.0;
4051                inherit: "default" 0.0;
4052                image.normal: "00_button_popup_press.png";
4053             }
4054             description { state: "disabled" 0.0;
4055                inherit: "default" 0.0;
4056                image.normal: "00_button_popup_dim.png";
4057             }
4058             description { state: "focused" 0.0;
4059                inherit: "default" 0.0;
4060                image.normal: "00_button_popup_normal_focus.png";
4061             }
4062          }
4063          part { name: "padding_left_top";
4064             type: RECT;
4065             scale: 1;
4066             mouse_events: 0;
4067             description { state: "default" 0.0;
4068                align: 0.0 0.0;
4069                rel2.relative: 0.0 0.0;
4070                min: BUTTON_POPUP_PADDING_MIN_INC;
4071                fixed: 1 1;
4072                visible: 0;
4073             }
4074          }
4075          part { name: "padding_right_bottom";
4076             type: RECT;
4077             scale: 1;
4078             description { state: "default" 0.0;
4079                align: 1.0 0.0;
4080                rel1.relative: 1.0 1.0;
4081                min: BUTTON_POPUP_PADDING_MIN_INC;
4082                fixed: 1 1;
4083                visible: 0;
4084             }
4085          }
4086          part { name: "padding_icon_text";
4087             type: RECT;
4088             scale: 1;
4089             description { state: "default" 0.0; //when only icon or no icon is there
4090                align: 0.0 0.0;
4091                rel1 {
4092                   relative: 1.0 0.0;
4093                   to: "elm.swallow.content";
4094                }
4095                rel2.to: "elm.swallow.content";
4096                fixed: 1 0;
4097                min: 0 0;
4098                visible: 0;
4099             }
4100             description { state: "icononly" 0.0;
4101                inherit: "default" 0.0;
4102             }
4103             description { state: "visible" 0.0; //when icon is visible
4104                inherit: "default" 0.0;
4105                min: BUTTON_POPUP_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
4106             }
4107          }
4108          part { name: "elm.swallow.content";
4109             type: SWALLOW;
4110             scale: 1;
4111             clip_to: "clipper";
4112             description { state: "default" 0.0;
4113                visible: 0;
4114                align: 0.0 0.5;
4115                rel1 {
4116                   relative: 1.0 1.0;
4117                   to: "padding_left_top";
4118                }
4119                rel2 {
4120                   relative: 1.0 0.0;
4121                   to_x: "padding_left_top";
4122                   to_y: "padding_right_bottom";
4123                }
4124                fixed: 1 0;
4125             }
4126             description { state: "visible" 0.0;
4127                inherit: "default" 0.0;
4128                fixed: 1 0;
4129                visible: 1;
4130                aspect: 1.0 1.0;
4131                aspect_preference: VERTICAL;
4132             }
4133             description { state: "icononly" 0.0;
4134                min: BUTTON_POPUP_ICON_ICONONLY_MIN_INC;
4135                rel1 {
4136                   relative: 1.0 1.0;
4137                   to: "padding_left_top";
4138                }
4139                rel2 {
4140                   relative: 1.0 0.0;
4141                   to_x: "padding_left_top";
4142                   to_y: "padding_right_bottom";
4143                }
4144             }
4145          }
4146          part { name: "elm.text";
4147             type: TEXT;
4148             mouse_events: 0;
4149             scale: 1;
4150             clip_to: "clipper";
4151             description { state: "default" 0.0;
4152                visible: 0;
4153                rel1 {
4154                   relative: 1.0 1.0;
4155                   to_x: "padding_icon_text";
4156                   to_y: "padding_left_top";
4157                }
4158                rel2 {
4159                   relative: 0.0 0.0;
4160                   to: "padding_right_bottom";
4161                }
4162                color: BUTTON_POPUP_BUTTON_TEXT_NORMAL_COLOR_INC;
4163                text {
4164                   font: "SLP:style=Medium";
4165                   size: BUTTON_POPUP_TEXT_FONT_SIZE_INC;
4166                   min: 0 0;
4167                   text_class: "slp_medium";
4168                }
4169             }
4170             description { state: "visible" 0.0;
4171                inherit: "default" 0.0;
4172                visible: 1;
4173                min: BUTTON_POPUP_TEXT_MIN_INC;
4174             }
4175             description { state: "clicked" 0.0;
4176                inherit: "default" 0.0;
4177                visible: 1;
4178                min: 0 0;
4179                color: BUTTON_POPUP_BUTTON_TEXT_PRESSED_COLOR_INC;
4180             }
4181             description { state: "disabled" 0.0;
4182                inherit: "default" 0.0;
4183                color: 0 0 0 128;
4184             }
4185             description { state: "disabled_visible" 0.0;
4186                inherit: "default" 0.0;
4187                color: BUTTON_POPUP_BUTTON_TEXT_DISABLED_COLOR_INC;
4188                visible: 1;
4189                min: BUTTON_POPUP_TEXT_MIN_INC;
4190             }
4191             description { state: "focused" 0.0;
4192                inherit: "default" 0.0;
4193                visible: 1;
4194                min: 0 0;
4195                color: BUTTON_POPUP_BUTTON_TEXT_FOCUSED_COLOR_INC;
4196             }
4197          }
4198          part { name: "over2";
4199             type: RECT;
4200             repeat_events: 1;
4201             ignore_flags: ON_HOLD;
4202             description { state: "default" 0.0;
4203                color: 0 0 0 0;
4204             }
4205          }
4206          part { name: "over3";
4207             type: RECT;
4208             repeat_events: 1;
4209             description { state: "default" 0.0;
4210                color: 0 0 0 0;
4211             }
4212          }
4213          part { name: "clipper";
4214             type: RECT;
4215             description { state: "default" 0.0;
4216                color: 255 255 255 255;
4217             }
4218          }
4219          part { name: "disabler";
4220             type: RECT;
4221             description { state: "default" 0.0;
4222                color: 0 0 0 0;
4223                visible: 0;
4224             }
4225             description { state: "disabled" 0.0;
4226                inherit: "default" 0.0;
4227                visible: 1;
4228             }
4229          }
4230       }
4231       programs {
4232          program { name: "button_click";
4233             signal: "mouse,down,1";
4234             source: "over2";
4235             action: SIGNAL_EMIT "elm,action,press" "";
4236             after: "button_click_anim";
4237          }
4238          program { name: "button_click_anim";
4239             action: STATE_SET "clicked" 0.0;
4240             target: "button_image";
4241             after: "text_clicked";
4242          }
4243          program { name: "text_clicked";
4244             script {
4245                new st[31];
4246                new Float:vl;
4247                get_state(PART:"elm.text", st, 30, vl);
4248                if (!strcmp(st, "visible"))
4249                  set_state(PART:"elm.text", "clicked", 0.0);
4250             }
4251          }
4252          program { name: "button_unpress";
4253             action: SIGNAL_EMIT "elm,action,unpress" "";
4254          }
4255          program { name: "button_mouseout_clicked";
4256             signal: "mouse,up,1";
4257             source: "over3";
4258             script {
4259                new st[31];
4260                new Float:vl;
4261                get_state(PART:"elm.swallow.content", st, 30, vl);
4262                if (strcmp(st, "icononly"))
4263                  {
4264                     emit("elm,action,default,text,set", "");
4265                     set_state(PART:"elm.text", "visible", 0.0);
4266                  }
4267                if (get_int(button_state) != BUTTON_STATE_DISABLED)
4268                  set_state(PART:"button_image", "default", 0.0);
4269             }
4270             after: button_unpress;
4271          }
4272          program { name: "touch_snd";
4273             signal: "mouse,clicked,1";
4274             source: "over2";
4275             action: PLAY_SAMPLE "touch_sound" 1.0;
4276             after: button_unclick3;
4277          }
4278          program { name: "button_unclick3";
4279             action: SIGNAL_EMIT "elm,action,click" "";
4280          }
4281          program { name: "text_show";
4282             signal: "elm,state,text,visible";
4283             source: "elm";
4284             script {
4285                new st[31];
4286                new Float:vl;
4287                get_state(PART:"elm.swallow.content", st, 30, vl);
4288                if (!strcmp(st, "icononly"))
4289                  {
4290                     set_state(PART:"elm.swallow.content", "visible", 0.0);
4291                     set_state(PART:"padding_icon_text", "visible", 0.0);
4292                  }
4293                if (get_int(button_state) != BUTTON_STATE_DISABLED)
4294                  set_state(PART:"elm.text", "visible", 0.0);
4295                else
4296                  set_state(PART:"elm.text", "disabled_visible", 0.0);
4297             }
4298          }
4299          program { name: "text_hide";
4300             signal: "elm,state,text,hidden";
4301             source: "elm";
4302             script {
4303                new st[31];
4304                new Float:vl;
4305                get_state(PART:"elm.swallow.content", st, 30, vl);
4306                if (!strcmp(st, "visible"))
4307                  {
4308                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
4309                     set_state(PART:"padding_icon_text", "icononly", 0.0);
4310                  }
4311                set_state(PART:"elm.text", "default", 0.0);
4312             }
4313          }
4314          program { name: "icon_show";
4315             signal: "elm,state,icon,visible";
4316             source: "elm";
4317             script {
4318                new st[31];
4319                new Float:vl;
4320                get_state(PART:"elm.text", st, 30, vl);
4321                if (!strcmp(st, "visible"))
4322                  {
4323                     set_state(PART:"elm.swallow.content", "visible", 0.0);
4324                     set_state(PART:"padding_icon_text", "visible", 0.0);
4325                  }
4326                else
4327                  {
4328                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
4329                     set_state(PART:"padding_icon_text", "icononly", 0.0);
4330                  }
4331             }
4332          }
4333          program { name: "icon_hide";
4334             signal: "elm,state,icon,hidden";
4335             source: "elm";
4336             action: STATE_SET "default" 0.0;
4337             target: "elm.swallow.content";
4338             target: "padding_icon_text";
4339          }
4340          program { name: "disable";
4341             signal: "elm,state,disabled";
4342             source: "elm";
4343             action: STATE_SET "disabled" 0.0;
4344             target: "button_image";
4345             target: "disabler";
4346             after: "disable_text";
4347          }
4348          program { name: "disable_text";
4349             script {
4350                new st[31];
4351                new Float:vl;
4352                get_state(PART:"elm.text", st, 30, vl);
4353                if (!strcmp(st, "visible"))
4354                  set_state(PART:"elm.text", "disabled_visible", 0.0);
4355                else
4356                  set_state(PART:"elm.text", "disabled", 0.0);
4357                set_int(button_state, BUTTON_STATE_DISABLED);
4358             }
4359          }
4360          program { name: "enable";
4361             signal: "elm,state,enabled";
4362             source: "elm";
4363             action: STATE_SET "default" 0.0;
4364             target: "button_image";
4365             target: "disabler";
4366             after: "enable_text";
4367          }
4368          program { name: "enable_text";
4369             script {
4370                new st[31];
4371                new Float:vl;
4372                get_state(PART:"elm.text", st, 30, vl);
4373                if (!strcmp(st, "disabled_visible"))
4374                  set_state(PART:"elm.text", "visible", 0.0);
4375                else
4376                  set_state(PART:"elm.text", "default", 0.0);
4377                set_int(button_state, BUTTON_STATE_ENABLED);
4378             }
4379          }
4380          program { name: "focused";
4381             //signal: "elm,action,focus";
4382             //source: "elm";
4383             action: STATE_SET "focused" 0.0;
4384             target: "button_image";
4385             target: "elm.text";
4386          }
4387          program { name: "unfocused";
4388             //signal: "elm,action,unfocus";
4389             //source: "elm";
4390             action: STATE_SET "default" 0.0;
4391             target: "button_image";
4392             after: "unfocus_text";
4393          }
4394          program { name: "unfocus_text";
4395             action: STATE_SET "visible" 0.0;
4396             target: "elm.text";
4397          }
4398       }
4399    }
4400 ///////////////////////////////////////////////////////////////////////////////////////
4401    group { name: "elm/button/base/popup_button/default/multiline";
4402       images {
4403          image: "00_button_popup_normal.png" COMP;
4404          image: "00_button_popup_press.png" COMP;
4405          image: "00_button_popup_normal_focus.png" COMP;
4406          image: "00_button_popup_dim.png" COMP;
4407       }
4408       styles{
4409          style { name: "btn_popup_multiline_style";
4410             base: "font=SLP:style=Roman font_size="BUTTON_POPUP_MULTILINE_TEXT_FONT_SIZE_INC" align=center color=#ffffff wrap=mixed text_class=slp_roman";
4411             tag: "br" "\n";
4412             tag: "ps" "ps";
4413             tag: "tab" "\t";
4414          }
4415       }
4416       script {
4417          public button_state = BUTTON_STATE_ENABLED;
4418       }
4419       parts {
4420          part { name: "button_image";
4421             scale: 1;
4422             description { state: "default" 0.0;
4423                min: BUTTON_POPUP_BG_NORMAL_MIN_INC;
4424                image {
4425                   normal: "00_button_popup_normal.png";
4426                   border: BUTTON_POPUP_BG_BORDER_INC;
4427                   border_scale: 1;
4428                }
4429             }
4430             description { state: "clicked" 0.0;
4431                inherit: "default" 0.0;
4432                image.normal: "00_button_popup_press.png";
4433             }
4434             description { state: "disabled" 0.0;
4435                inherit: "default" 0.0;
4436                image.normal: "00_button_popup_dim.png";
4437             }
4438             description { state: "focused" 0.0;
4439                inherit: "default" 0.0;
4440                image.normal: "00_button_popup_normal_focus.png";
4441             }
4442          }
4443          part { name: "padding_left_top";
4444             type: RECT;
4445             scale: 1;
4446             mouse_events: 0;
4447             description { state: "default" 0.0;
4448                align: 0.0 0.0;
4449                rel2.relative: 0.0 0.0;
4450                min: BUTTON_POPUP_PADDING_MIN_INC;
4451                fixed: 1 1;
4452                visible: 0;
4453             }
4454          }
4455          part { name: "padding_right_bottom";
4456             type: RECT;
4457             scale: 1;
4458             description { state: "default" 0.0;
4459                align: 1.0 0.0;
4460                rel1.relative: 1.0 1.0;
4461                min: BUTTON_POPUP_PADDING_MIN_INC;
4462                fixed: 1 1;
4463                visible: 0;
4464             }
4465          }
4466          part { name: "padding_icon_text";
4467             type: RECT;
4468             scale: 1;
4469             description { state: "default" 0.0; //when only icon or no icon is there
4470                align: 0.0 0.0;
4471                rel1 {
4472                   relative: 1.0 0.0;
4473                   to: "elm.swallow.content";
4474                }
4475                rel2.to: "elm.swallow.content";
4476                fixed: 1 0;
4477                min: 0 0;
4478                visible: 0;
4479             }
4480             description { state: "icononly" 0.0;
4481                inherit: "default" 0.0;
4482             }
4483             description { state: "visible" 0.0; //when icon is visible
4484                inherit: "default" 0.0;
4485                min: BUTTON_POPUP_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
4486             }
4487          }
4488          part { name: "elm.swallow.content";
4489             type: SWALLOW;
4490             scale: 1;
4491             clip_to: "clipper";
4492             description { state: "default" 0.0;
4493                visible: 0;
4494                align: 0.0 0.5;
4495                rel1 {
4496                   relative: 1.0 1.0;
4497                   to: "padding_left_top";
4498                }
4499                rel2 {
4500                   relative: 1.0 0.0;
4501                   to_x: "padding_left_top";
4502                   to_y: "padding_right_bottom";
4503                }
4504                fixed: 1 0;
4505             }
4506             description { state: "visible" 0.0;
4507                inherit: "default" 0.0;
4508                fixed: 1 0;
4509                visible: 1;
4510                aspect: 1.0 1.0;
4511                aspect_preference: VERTICAL;
4512             }
4513             description { state: "icononly" 0.0;
4514                min: BUTTON_POPUP_ICON_ICONONLY_MIN_INC;
4515                rel1 {
4516                   relative: 1.0 1.0;
4517                   to: "padding_left_top";
4518                }
4519                rel2 {
4520                   relative: 1.0 0.0;
4521                   to_x: "padding_left_top";
4522                   to_y: "padding_right_bottom";
4523                }
4524             }
4525          }
4526          part { name: "elm.text";
4527             type: TEXTBLOCK;
4528             mouse_events: 0;
4529             scale: 1;
4530             clip_to: "clipper";
4531             description { state: "default" 0.0;
4532                visible: 0;
4533                rel1 {
4534                   relative: 1.0 1.0;
4535                   to_x: "padding_icon_text";
4536                   to_y: "padding_left_top";
4537                }
4538                rel2 {
4539                   relative: 0.0 0.0;
4540                   to: "padding_right_bottom";
4541                }
4542                color: BUTTON_POPUP_BUTTON_TEXT_NORMAL_COLOR_INC;
4543                text {
4544                   style: "btn_popup_multiline_style";
4545                   min: 0 0;
4546                   max: 0 1;
4547                }
4548             }
4549             description { state: "visible" 0.0;
4550                inherit: "default" 0.0;
4551                visible: 1;
4552                min: BUTTON_POPUP_TEXT_MIN_INC;
4553             }
4554             description { state: "clicked" 0.0;
4555                inherit: "default" 0.0;
4556                visible: 1;
4557                min: 0 0;
4558                color: BUTTON_POPUP_BUTTON_TEXT_PRESSED_COLOR_INC;
4559             }
4560             description { state: "disabled" 0.0;
4561                inherit: "default" 0.0;
4562                color: 0 0 0 128;
4563             }
4564             description { state: "disabled_visible" 0.0;
4565                inherit: "default" 0.0;
4566                color: BUTTON_POPUP_BUTTON_TEXT_DISABLED_COLOR_INC;
4567                visible: 1;
4568                min: BUTTON_POPUP_TEXT_MIN_INC;
4569             }
4570             description { state: "focused" 0.0;
4571                inherit: "default" 0.0;
4572                visible: 1;
4573                min: 0 0;
4574                color: BUTTON_POPUP_BUTTON_TEXT_FOCUSED_COLOR_INC;
4575             }
4576          }
4577          part { name: "over2";
4578             type: RECT;
4579             repeat_events: 1;
4580             ignore_flags: ON_HOLD;
4581             description { state: "default" 0.0;
4582                color: 0 0 0 0;
4583             }
4584          }
4585          part { name: "over3";
4586             type: RECT;
4587             repeat_events: 1;
4588             description { state: "default" 0.0;
4589                color: 0 0 0 0;
4590             }
4591          }
4592          part { name: "clipper";
4593             type: RECT;
4594             description { state: "default" 0.0;
4595                color: 255 255 255 255;
4596             }
4597          }
4598          part { name: "disabler";
4599             type: RECT;
4600             description { state: "default" 0.0;
4601                color: 0 0 0 0;
4602                visible: 0;
4603             }
4604             description { state: "disabled" 0.0;
4605                inherit: "default" 0.0;
4606                visible: 1;
4607             }
4608          }
4609       }
4610       programs {
4611          program { name: "button_click";
4612             signal: "mouse,down,1";
4613             source: "over2";
4614             action: SIGNAL_EMIT "elm,action,press" "";
4615             after: "button_click_anim";
4616          }
4617          program { name: "button_click_anim";
4618             action: STATE_SET "clicked" 0.0;
4619             target: "button_image";
4620             after: "text_clicked";
4621          }
4622          program { name: "text_clicked";
4623             script {
4624                new st[31];
4625                new Float:vl;
4626                get_state(PART:"elm.text", st, 30, vl);
4627                if (!strcmp(st, "visible"))
4628                  set_state(PART:"elm.text", "clicked", 0.0);
4629             }
4630          }
4631          program { name: "button_unpress";
4632             action: SIGNAL_EMIT "elm,action,unpress" "";
4633          }
4634          program { name: "button_mouseout_clicked";
4635             signal: "mouse,up,1";
4636             source: "over3";
4637             script {
4638                new st[31];
4639                new Float:vl;
4640                get_state(PART:"elm.swallow.content", st, 30, vl);
4641                if (strcmp(st, "icononly"))
4642                  {
4643                     emit("elm,action,default,text,set", "");
4644                     set_state(PART:"elm.text", "visible", 0.0);
4645                  }
4646                if (get_int(button_state) != BUTTON_STATE_DISABLED)
4647                  set_state(PART:"button_image", "default", 0.0);
4648             }
4649             after: button_unpress;
4650          }
4651          program { name: "touch_snd";
4652             signal: "mouse,clicked,1";
4653             source: "over2";
4654             action: PLAY_SAMPLE "touch_sound" 1.0;
4655             after: button_unclick3;
4656          }
4657          program { name: "button_unclick3";
4658             action: SIGNAL_EMIT "elm,action,click" "";
4659          }
4660          program { name: "text_show";
4661             signal: "elm,state,text,visible";
4662             source: "elm";
4663             script {
4664                new st[31];
4665                new Float:vl;
4666                get_state(PART:"elm.swallow.content", st, 30, vl);
4667                if (!strcmp(st, "icononly"))
4668                  {
4669                     set_state(PART:"elm.swallow.content", "visible", 0.0);
4670                     set_state(PART:"padding_icon_text", "visible", 0.0);
4671                  }
4672                if (get_int(button_state) != BUTTON_STATE_DISABLED)
4673                  set_state(PART:"elm.text", "visible", 0.0);
4674                else
4675                  set_state(PART:"elm.text", "disabled_visible", 0.0);
4676             }
4677          }
4678          program { name: "text_hide";
4679             signal: "elm,state,text,hidden";
4680             source: "elm";
4681             script {
4682                new st[31];
4683                new Float:vl;
4684                get_state(PART:"elm.swallow.content", st, 30, vl);
4685                if (!strcmp(st, "visible"))
4686                  {
4687                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
4688                     set_state(PART:"padding_icon_text", "icononly", 0.0);
4689                  }
4690                set_state(PART:"elm.text", "default", 0.0);
4691             }
4692          }
4693          program { name: "icon_show";
4694             signal: "elm,state,icon,visible";
4695             source: "elm";
4696             script {
4697                new st[31];
4698                new Float:vl;
4699                get_state(PART:"elm.text", st, 30, vl);
4700                if (!strcmp(st, "visible"))
4701                  {
4702                     set_state(PART:"elm.swallow.content", "visible", 0.0);
4703                     set_state(PART:"padding_icon_text", "visible", 0.0);
4704                  }
4705                else
4706                  {
4707                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
4708                     set_state(PART:"padding_icon_text", "icononly", 0.0);
4709                  }
4710             }
4711          }
4712          program { name: "icon_hide";
4713             signal: "elm,state,icon,hidden";
4714             source: "elm";
4715             action: STATE_SET "default" 0.0;
4716             target: "elm.swallow.content";
4717             target: "padding_icon_text";
4718          }
4719          program { name: "disable";
4720             signal: "elm,state,disabled";
4721             source: "elm";
4722             action: STATE_SET "disabled" 0.0;
4723             target: "button_image";
4724             target: "disabler";
4725             after: "disable_text";
4726          }
4727          program { name: "disable_text";
4728             script {
4729                new st[31];
4730                new Float:vl;
4731                get_state(PART:"elm.text", st, 30, vl);
4732                if (!strcmp(st, "visible"))
4733                  set_state(PART:"elm.text", "disabled_visible", 0.0);
4734                else
4735                  set_state(PART:"elm.text", "disabled", 0.0);
4736                set_int(button_state, BUTTON_STATE_DISABLED);
4737             }
4738          }
4739          program { name: "enable";
4740             signal: "elm,state,enabled";
4741             source: "elm";
4742             action: STATE_SET "default" 0.0;
4743             target: "button_image";
4744             target: "disabler";
4745             after: "enable_text";
4746          }
4747          program { name: "enable_text";
4748             script {
4749                new st[31];
4750                new Float:vl;
4751                get_state(PART:"elm.text", st, 30, vl);
4752                if (!strcmp(st, "disabled_visible"))
4753                  set_state(PART:"elm.text", "visible", 0.0);
4754                else
4755                  set_state(PART:"elm.text", "default", 0.0);
4756                set_int(button_state, BUTTON_STATE_ENABLED);
4757             }
4758          }
4759          program { name: "focused";
4760             //signal: "elm,action,focus";
4761             //source: "elm";
4762             action: STATE_SET "focused" 0.0;
4763             target: "button_image";
4764             target: "elm.text";
4765          }
4766          program { name: "unfocused";
4767             //signal: "elm,action,unfocus";
4768             //source: "elm";
4769             action: STATE_SET "default" 0.0;
4770             target: "button_image";
4771             after: "unfocus_text";
4772          }
4773          program { name: "unfocus_text";
4774             action: STATE_SET "visible" 0.0;
4775             target: "elm.text";
4776          }
4777       }
4778    }
4779
4780 ///////////////////////////////////////////////////////////////////////////////////////
4781 #define BUTTON_CIRCLE_STYLES(style_name, circle_normal, circle_press, image_normal, image_press, min_width, min_height) \
4782    group { name: "elm/button/base/"style_name; \
4783       images { \
4784          image: circle_normal COMP; \
4785          image: circle_press COMP; \
4786          image: image_normal COMP; \
4787          image: image_press COMP; \
4788       } \
4789       parts { \
4790          part { name: "button_image"; \
4791             scale: 1; \
4792             description { state: "default" 0.0; \
4793                min: BUTTON_CIRCLE_STYLE_BG_MIN_MAX_INC; \
4794                max: BUTTON_CIRCLE_STYLE_BG_MIN_MAX_INC; \
4795                image.normal: circle_normal; \
4796                color: 255 255 255 255; \
4797             } \
4798             description { \
4799                state: "clicked" 0.0; \
4800                inherit: "default" 0.0; \
4801                image.normal: circle_press; \
4802             } \
4803             description { \
4804                state: "disabled" 0.0; \
4805                inherit: "default" 0.0; \
4806                color: 255 255 255 128; \
4807             } \
4808          } \
4809          part { name: "button_center_part"; \
4810             scale: 1; \
4811             description { state: "default" 0.0; \
4812                min: BUTTON_CIRCLE_STYLE_IMAGE_MIN_MAX_INC; \
4813                max: BUTTON_CIRCLE_STYLE_IMAGE_MIN_MAX_INC; \
4814                image.normal: image_normal; \
4815                color: 255 255 255 255; \
4816             } \
4817             description { \
4818                state: "clicked" 0.0; \
4819                inherit: "default" 0.0; \
4820                image.normal: image_press; \
4821             } \
4822             description { \
4823                state: "disabled" 0.0; \
4824                inherit: "default" 0.0; \
4825                color: 255 255 255 128; \
4826             } \
4827          } \
4828          part { name: "over1"; \
4829             type: RECT; \
4830             ignore_flags: ON_HOLD; \
4831             description { state: "default" 0.0; \
4832                color: 0 0 0 0; \
4833                min: min_width min_height; \
4834             } \
4835          } \
4836          part { name: "over2"; \
4837             repeat_events: 1; \
4838             description { state: "default" 0.0; \
4839                color: 0 0 0 0; \
4840             } \
4841          } \
4842          part { name: "disabler"; \
4843             type: RECT; \
4844             description { state: "default" 0.0; \
4845                color: 0 0 0 0; \
4846                visible: 0; \
4847             } \
4848             description { state: "disabled" 0.0; \
4849                inherit: "default" 0.0; \
4850                visible: 1; \
4851             } \
4852          } \
4853       } \
4854       programs { \
4855          program { name: "button_click"; \
4856             signal: "mouse,down,1"; \
4857             source: "over1"; \
4858             action: SIGNAL_EMIT "elm,action,press" ""; \
4859             after: "button_click_anim"; \
4860          } \
4861          program { name: "button_click_anim"; \
4862             action: STATE_SET "clicked" 0.0; \
4863             target: "button_image"; \
4864             target: "button_center_part"; \
4865          } \
4866          program { name: "button_unclick"; \
4867             signal: "mouse,up,1"; \
4868             source: "over2"; \
4869             action: SIGNAL_EMIT "elm,action,unpress" ""; \
4870             after: "button_unclick_anim"; \
4871          } \
4872          program { name: "button_unclick_anim"; \
4873             action: STATE_SET "default" 0.0; \
4874             target: "button_image"; \
4875             target: "button_center_part"; \
4876          } \
4877          program { name: "touch_snd"; \
4878             signal: "mouse,clicked,1"; \
4879             source: "over1"; \
4880             action: PLAY_SAMPLE "touch_sound" 1.0; \
4881             after: button_unclick3; \
4882          } \
4883          program { name: "button_unclick3"; \
4884             action: SIGNAL_EMIT "elm,action,click" ""; \
4885          } \
4886          program { name: "disable"; \
4887             signal: "elm,state,disabled"; \
4888             source: "elm"; \
4889             action: STATE_SET "disabled" 0.0; \
4890             target: "disabler"; \
4891             target: "button_image"; \
4892             target: "button_center_part"; \
4893          } \
4894          program { name: "enable"; \
4895             signal: "elm,state,enabled"; \
4896             source: "elm"; \
4897             action: STATE_SET "default" 0.0; \
4898             target: "disabler"; \
4899             target: "button_image"; \
4900             target: "button_center_part"; \
4901          } \
4902       } \
4903    }
4904
4905 ///////////////////////////////////////////////////////////////////////////////////////
4906    BUTTON_CIRCLE_STYLES("reveal", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_reveal.png", "00_button_reveal_press.png", BUTTON_CIRCLE_NORMAL_MIN_WIDTH_INC, BUTTON_CIRCLE_NORMAL_MIN_HEIGHT_INC)
4907
4908 ///////////////////////////////////////////////////////////////////////////////////////
4909    BUTTON_CIRCLE_STYLES("reveal/extended", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_reveal.png", "00_button_reveal_press.png", BUTTON_CIRCLE_EXTENEDED_MIN_WIDTH_INC, BUTTON_CIRCLE_EXTENEDED_MIN_HEIGHT_INC)
4910
4911 ///////////////////////////////////////////////////////////////////////////////////////
4912    BUTTON_CIRCLE_STYLES("expand/closed", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_expand_closed.png", "00_button_expand_closed_press.png", BUTTON_CIRCLE_NORMAL_MIN_WIDTH_INC, BUTTON_CIRCLE_NORMAL_MIN_HEIGHT_INC)
4913
4914 ///////////////////////////////////////////////////////////////////////////////////////
4915    BUTTON_CIRCLE_STYLES("expand/closed/extended", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_expand_closed.png", "00_button_expand_closed_press.png", BUTTON_CIRCLE_EXTENEDED_MIN_WIDTH_INC, BUTTON_CIRCLE_EXTENEDED_MIN_HEIGHT_INC)
4916
4917 ///////////////////////////////////////////////////////////////////////////////////////
4918    BUTTON_CIRCLE_STYLES("expand/opened", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_expand_opened.png", "00_button_expand_opened_press.png", BUTTON_CIRCLE_NORMAL_MIN_WIDTH_INC, BUTTON_CIRCLE_NORMAL_MIN_HEIGHT_INC)
4919
4920 ///////////////////////////////////////////////////////////////////////////////////////
4921    BUTTON_CIRCLE_STYLES("expand/opened/extended", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_expand_opened.png", "00_button_expand_opened_press.png", BUTTON_CIRCLE_EXTENEDED_MIN_WIDTH_INC, BUTTON_CIRCLE_EXTENEDED_MIN_HEIGHT_INC)
4922
4923 ///////////////////////////////////////////////////////////////////////////////////////
4924    BUTTON_CIRCLE_STYLES("info", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_info.png", "00_button_info_press.png", BUTTON_CIRCLE_NORMAL_MIN_WIDTH_INC, BUTTON_CIRCLE_NORMAL_MIN_HEIGHT_INC)
4925
4926 ///////////////////////////////////////////////////////////////////////////////////////
4927    BUTTON_CIRCLE_STYLES("info/extended", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_info.png", "00_button_info_press.png", BUTTON_CIRCLE_EXTENEDED_MIN_WIDTH_INC, BUTTON_CIRCLE_EXTENEDED_MIN_HEIGHT_INC)
4928
4929 ///////////////////////////////////////////////////////////////////////////////////////
4930    BUTTON_CIRCLE_STYLES("rename", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_rename.png", "00_button_rename_press.png", BUTTON_CIRCLE_NORMAL_MIN_WIDTH_INC, BUTTON_CIRCLE_NORMAL_MIN_HEIGHT_INC)
4931
4932 ///////////////////////////////////////////////////////////////////////////////////////
4933    BUTTON_CIRCLE_STYLES("rename/extended", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_rename.png", "00_button_rename_press.png", BUTTON_CIRCLE_EXTENEDED_MIN_WIDTH_INC, BUTTON_CIRCLE_EXTENEDED_MIN_HEIGHT_INC)
4934
4935 ///////////////////////////////////////////////////////////////////////////////////////
4936    BUTTON_CIRCLE_STYLES("call", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_call.png", "00_button_call_press.png", BUTTON_CIRCLE_NORMAL_MIN_WIDTH_INC, BUTTON_CIRCLE_NORMAL_MIN_HEIGHT_INC)
4937
4938 ///////////////////////////////////////////////////////////////////////////////////////
4939    BUTTON_CIRCLE_STYLES("call/extended", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_call.png", "00_button_call_press.png", BUTTON_CIRCLE_EXTENEDED_MIN_WIDTH_INC, BUTTON_CIRCLE_EXTENEDED_MIN_HEIGHT_INC)
4940
4941 ///////////////////////////////////////////////////////////////////////////////////////
4942    BUTTON_CIRCLE_STYLES("warning", "00_btn_circle_bg_normal_01.png", "00_btn_circle_bg_press_01.png", "00_button_warning.png", "00_button_warning_press.png", BUTTON_CIRCLE_NORMAL_MIN_WIDTH_INC, BUTTON_CIRCLE_NORMAL_MIN_HEIGHT_INC)
4943
4944 ///////////////////////////////////////////////////////////////////////////////////////
4945    BUTTON_CIRCLE_STYLES("warning/extended", "00_btn_circle_bg_normal_01.png", "00_btn_circle_bg_press_01.png", "00_button_warning.png", "00_button_warning_press.png", BUTTON_CIRCLE_EXTENEDED_MIN_WIDTH_INC, BUTTON_CIRCLE_EXTENEDED_MIN_HEIGHT_INC)
4946
4947 ///////////////////////////////////////////////////////////////////////////////////////
4948    BUTTON_CIRCLE_STYLES("plus", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_plus.png", "00_button_plus_press.png", BUTTON_CIRCLE_NORMAL_MIN_WIDTH_INC, BUTTON_CIRCLE_NORMAL_MIN_HEIGHT_INC)
4949
4950 ///////////////////////////////////////////////////////////////////////////////////////
4951    BUTTON_CIRCLE_STYLES("plus/extended", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_plus.png", "00_button_plus_press.png", BUTTON_CIRCLE_EXTENEDED_MIN_WIDTH_INC, BUTTON_CIRCLE_EXTENEDED_MIN_HEIGHT_INC)
4952
4953 ///////////////////////////////////////////////////////////////////////////////////////
4954    BUTTON_CIRCLE_STYLES("minus", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_minus.png", "00_button_minus_press.png", BUTTON_CIRCLE_NORMAL_MIN_WIDTH_INC, BUTTON_CIRCLE_NORMAL_MIN_HEIGHT_INC)
4955
4956 ///////////////////////////////////////////////////////////////////////////////////////
4957    BUTTON_CIRCLE_STYLES("minus/extended", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_minus.png", "00_button_minus_press.png", BUTTON_CIRCLE_EXTENEDED_MIN_WIDTH_INC, BUTTON_CIRCLE_EXTENEDED_MIN_HEIGHT_INC)
4958
4959 ///////////////////////////////////////////////////////////////////////////////////////
4960    BUTTON_CIRCLE_STYLES("cancel", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_cancel.png", "00_button_cancel_press.png", BUTTON_CIRCLE_NORMAL_MIN_WIDTH_INC, BUTTON_CIRCLE_NORMAL_MIN_HEIGHT_INC)
4961
4962 ///////////////////////////////////////////////////////////////////////////////////////
4963    BUTTON_CIRCLE_STYLES("cancel/extended", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_cancel.png", "00_button_cancel_press.png", BUTTON_CIRCLE_EXTENEDED_MIN_WIDTH_INC, BUTTON_CIRCLE_EXTENEDED_MIN_HEIGHT_INC)
4964
4965 ///////////////////////////////////////////////////////////////////////////////////////
4966    BUTTON_CIRCLE_STYLES("send", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_send.png", "00_button_send_press.png", BUTTON_CIRCLE_NORMAL_MIN_WIDTH_INC, BUTTON_CIRCLE_NORMAL_MIN_HEIGHT_INC)
4967
4968 ///////////////////////////////////////////////////////////////////////////////////////
4969    BUTTON_CIRCLE_STYLES("send/extended", "00_btn_circle_bg_normal.png", "00_btn_circle_bg_press.png", "00_button_send.png", "00_button_send_press.png", BUTTON_CIRCLE_EXTENEDED_MIN_WIDTH_INC, BUTTON_CIRCLE_EXTENEDED_MIN_HEIGHT_INC)
4970 ///////////////////////////////////////////////////////////////////////////////////////
4971
4972    group { name: "elm/button/base/circle/empty";
4973       images {
4974          image: "00_btn_circle_bg_normal.png" COMP;
4975          image: "00_btn_circle_bg_press.png" COMP;
4976       }
4977       parts {
4978          part { name: "button_image";
4979             scale: 1;
4980             description { state: "default" 0.0;
4981                min: BUTTON_CIRCLE_STYLE_BG_MIN_MAX_INC;
4982                max: BUTTON_CIRCLE_STYLE_BG_MIN_MAX_INC;
4983                fixed: 1 1;
4984                image.normal: "00_btn_circle_bg_normal.png";
4985                color: 255 255 255 255;
4986             }
4987             description { state: "clicked" 0.0;
4988                inherit: "default" 0.0;
4989                image.normal: "00_btn_circle_bg_press.png";
4990             }
4991             description { state: "disabled" 0.0;
4992                inherit: "default" 0.0;
4993                color: 255 255 255 128;
4994             }
4995          }
4996          part { name: "elm.swallow.content";
4997             type: SWALLOW;
4998             scale: 1;
4999             description { state: "default" 0.0;
5000                min: BUTTON_CIRCLE_STYLE_CONTENT_MIN_MAX_INC;
5001                max: BUTTON_CIRCLE_STYLE_CONTENT_MIN_MAX_INC;
5002                fixed: 1 1;
5003                color: 255 255 255 255;
5004             }
5005             description {
5006                state: "disabled" 0.0;
5007                inherit: "default" 0.0;
5008                color: 255 255 255 128;
5009             }
5010          }
5011          part { name: "over1";
5012             type: RECT;
5013             ignore_flags: ON_HOLD;
5014             description { state: "default" 0.0;
5015                color: 0 0 0 0;
5016             }
5017          }
5018          part { name: "over2";
5019             repeat_events: 1;
5020             description { state: "default" 0.0;
5021                color: 0 0 0 0;
5022             }
5023          }
5024          part { name: "disabler";
5025             type: RECT;
5026             description { state: "default" 0.0;
5027                color: 0 0 0 0;
5028                visible: 0;
5029             }
5030             description { state: "disabled" 0.0;
5031                inherit: "default" 0.0;
5032                visible: 1;
5033             }
5034          }
5035       }
5036       programs {
5037          program { name: "button_click";
5038             signal: "mouse,down,1";
5039             source: "over1";
5040             action: SIGNAL_EMIT "elm,action,press" "";
5041             after: "button_click_anim";
5042          }
5043          program { name: "button_click_anim";
5044             action: STATE_SET "clicked" 0.0;
5045             target: "button_image";
5046          }
5047          program { name: "touch_snd";
5048             signal: "mouse,clicked,1";
5049             source: "over1";
5050             action: PLAY_SAMPLE "touch_sound" 1.0;
5051             after: button_unclick2;
5052          }
5053          program { name: "button_unclick2";
5054             action: SIGNAL_EMIT "elm,action,click" "";
5055          }
5056          program { name: "button_unclick";
5057             signal: "mouse,up,1";
5058             source: "over2";
5059             action: SIGNAL_EMIT "elm,action,unpress" "";
5060             after: "button_unclick_anim";
5061          }
5062          program { name: "button_unclick_anim";
5063             action: STATE_SET "default" 0.0;
5064             target: "button_image";
5065          }
5066          program { name: "disable";
5067             signal: "elm,state,disabled";
5068             source: "elm";
5069             action: STATE_SET "disabled" 0.0;
5070             target: "disabler";
5071             target: "button_image";
5072          }
5073          program { name: "enable";
5074             signal: "elm,state,enabled";
5075             source: "elm";
5076             action: STATE_SET "default" 0.0;
5077             target: "disabler";
5078             target: "button_image";
5079          }
5080          program { name: "icon_show";
5081             signal: "elm,state,icon,visible";
5082             source: "elm";
5083             action: STATE_SET "visible" 0.0;
5084             target: "elm.swallow.content";
5085          }
5086          program { name: "icon_hide";
5087             signal: "elm,state,icon,hidden";
5088             source: "elm";
5089             action: STATE_SET "default" 0.0;
5090             target: "elm.swallow.content";
5091          }
5092       }
5093    }
5094
5095 ///////////////////////////////////////////////////////////////////////////////////////
5096 #define BUTTON_EDIT_STYLES(style_name, edit_normal, edit_press, image_normal, image_press, min_width, min_height) \
5097    group { name: "elm/button/base/contacts/"style_name; \
5098    alias: "elm/button/base/"style_name; \
5099       images { \
5100          image: image_normal COMP; \
5101          image: image_press COMP; \
5102          image: edit_normal COMP; \
5103          image: edit_press COMP; \
5104          image: "00_button_edit_dim.png" COMP; \
5105          image: "00_button_edit_focus.png" COMP; \
5106       } \
5107       parts { \
5108          part { name: "button_image"; \
5109             scale: 1; \
5110             description { state: "default" 0.0; \
5111                min: BUTTON_EDIT_STYLE_BG_NORMAL_MIN_MAX_INC; \
5112                max: BUTTON_EDIT_STYLE_BG_NORMAL_MIN_MAX_INC; \
5113                image { \
5114                   normal: edit_normal; \
5115                   border: BUTTON_EDIT_STYLE_BORDER_INC; \
5116                   border_scale: 1; \
5117                } \
5118             } \
5119             description { \
5120                state: "clicked" 0.0; \
5121                inherit: "default" 0.0; \
5122                image.normal: edit_press; \
5123             } \
5124             description { \
5125                state: "disabled" 0.0; \
5126                inherit: "default" 0.0; \
5127                image.normal: "00_button_edit_dim.png"; \
5128             } \
5129             description { \
5130                state: "focused" 0.0; \
5131                inherit: "default" 0.0; \
5132                image.normal: "00_button_edit_focus.png"; \
5133             } \
5134          } \
5135          part { name: "button_center_part"; \
5136             mouse_events: 0; \
5137             scale: 1; \
5138             description { state: "default" 0.0; \
5139                min: BUTTON_EDIT_STYLE_IMAGE_NORMAL_MIN_MAX_INC; \
5140                max: BUTTON_EDIT_STYLE_IMAGE_NORMAL_MIN_MAX_INC; \
5141                image { \
5142                   normal: image_normal; \
5143                   border: BUTTON_EDIT_STYLE_BORDER_INC; \
5144                   border_scale: 1; \
5145                } \
5146             } \
5147             description { \
5148                state: "clicked" 0.0; \
5149                inherit: "default" 0.0; \
5150                image.normal: image_press; \
5151             } \
5152          } \
5153          part { name: "over1"; \
5154             type: RECT; \
5155             repeat_events: 1; \
5156             ignore_flags: ON_HOLD; \
5157             description { state: "default" 0.0; \
5158                color: 0 0 0 0; \
5159                min: min_width min_height; \
5160             } \
5161          } \
5162          part { name: "over2"; \
5163             repeat_events: 1; \
5164             description { state: "default" 0.0; \
5165                color: 0 0 0 0; \
5166             } \
5167          } \
5168          part { name: "disabler"; \
5169             type: RECT; \
5170             description { state: "default" 0.0; \
5171                color: 0 0 0 0; \
5172                visible: 0; \
5173             } \
5174             description { state: "disabled" 0.0; \
5175                inherit: "default" 0.0; \
5176                visible: 1; \
5177             } \
5178          } \
5179       } \
5180       programs { \
5181          program { name: "button_click"; \
5182             signal: "mouse,down,1"; \
5183             source: "over1"; \
5184             action: SIGNAL_EMIT "elm,action,press" ""; \
5185             after: "button_click_anim"; \
5186          } \
5187          program { name: "button_click_anim"; \
5188             action: STATE_SET "clicked" 0.0; \
5189             target: "button_image"; \
5190             target: "button_center_part"; \
5191          } \
5192          program { name: "button_unclick"; \
5193             signal: "mouse,up,1"; \
5194             source: "over2"; \
5195             action: SIGNAL_EMIT "elm,action,unpress" ""; \
5196             after: "button_unclick_anim"; \
5197          } \
5198          program { name: "button_unclick_anim"; \
5199             action: STATE_SET "default" 0.0; \
5200             target: "button_image"; \
5201             target: "button_center_part"; \
5202          } \
5203          program { name: "touch_snd"; \
5204             signal: "mouse,clicked,1"; \
5205             source: "over1"; \
5206             action: PLAY_SAMPLE "touch_sound" 1.0; \
5207             after: button_unclick3; \
5208          } \
5209          program { name: "button_unclick3"; \
5210             action: SIGNAL_EMIT "elm,action,click" ""; \
5211          } \
5212          program { name: "disable"; \
5213             signal: "elm,state,disabled"; \
5214             source: "elm"; \
5215             action: STATE_SET "disabled" 0.0; \
5216             target: "disabler"; \
5217             target: "button_image"; \
5218          } \
5219          program { name: "enable"; \
5220             signal: "elm,state,enabled"; \
5221             source: "elm"; \
5222             action: STATE_SET "default" 0.0; \
5223             target: "disabler"; \
5224             target: "button_image"; \
5225          } \
5226       } \
5227    }
5228 ///////////////////////////////////////////////////////////////////////////////////////
5229    BUTTON_EDIT_STYLES("icon_plus", "00_button_edit.png", "00_button_edit_press.png", "00_button_icon_plus.png", "00_button_icon_plus_press.png", BUTTON_EDIT_NORMAL_MIN_WIDTH_INC, BUTTON_EDIT_NORMAL_MIN_HEIGHT_INC)
5230
5231 ///////////////////////////////////////////////////////////////////////////////////////
5232    BUTTON_EDIT_STYLES("icon_plus/extended", "00_button_edit.png", "00_button_edit_press.png", "00_button_icon_plus.png", "00_button_icon_plus_press.png", BUTTON_EDIT_EXTENDED_MIN_WIDTH_INC, BUTTON_EDIT_EXTENDED_MIN_HEIGHT_INC)
5233
5234 ///////////////////////////////////////////////////////////////////////////////////////
5235    BUTTON_EDIT_STYLES("icon_minus", "00_button_edit_Delete.png", "00_button_edit_Delete_press.png", "00_button_icon_minus.png", "00_button_icon_minus_press.png", BUTTON_EDIT_NORMAL_MIN_WIDTH_INC, BUTTON_EDIT_NORMAL_MIN_HEIGHT_INC)
5236
5237 ///////////////////////////////////////////////////////////////////////////////////////
5238    BUTTON_EDIT_STYLES("icon_minus/extended", "00_button_edit_Delete.png", "00_button_edit_Delete_press.png", "00_button_icon_minus.png", "00_button_icon_minus_press.png", BUTTON_EDIT_EXTENDED_MIN_WIDTH_INC, BUTTON_EDIT_EXTENDED_MIN_HEIGHT_INC)
5239
5240 ///////////////////////////////////////////////////////////////////////////////////////
5241    BUTTON_EDIT_STYLES("icon_expand", "00_button_edit.png", "00_button_edit_press.png", "00_button_icon_expand.png", "00_button_icon_expand_press.png", BUTTON_EDIT_NORMAL_MIN_WIDTH_INC, BUTTON_EDIT_NORMAL_MIN_HEIGHT_INC)
5242
5243 ///////////////////////////////////////////////////////////////////////////////////////
5244    BUTTON_EDIT_STYLES("icon_expand/extended", "00_button_edit.png", "00_button_edit_press.png", "00_button_icon_expand.png", "00_button_icon_expand_press.png", BUTTON_EDIT_EXTENDED_MIN_WIDTH_INC, BUTTON_EDIT_EXTENDED_MIN_HEIGHT_INC)
5245
5246 ///////////////////////////////////////////////////////////////////////////////////////
5247    BUTTON_EDIT_STYLES("icon_expand_closed", "00_button_edit.png", "00_button_edit_press.png", "00_button_icon_expand_closed.png", "00_button_icon_expand_closed_press.png", BUTTON_EDIT_NORMAL_MIN_WIDTH_INC, BUTTON_EDIT_NORMAL_MIN_HEIGHT_INC)
5248
5249 ///////////////////////////////////////////////////////////////////////////////////////
5250    BUTTON_EDIT_STYLES("icon_expand_opened", "00_button_edit.png", "00_button_edit_press.png", "00_button_icon_expand_opened.png", "00_button_icon_expand_opened_press.png", BUTTON_EDIT_NORMAL_MIN_WIDTH_INC, BUTTON_EDIT_NORMAL_MIN_HEIGHT_INC)
5251
5252 ///////////////////////////////////////////////////////////////////////////////////////
5253    group { name: "elm/button/base/contacts/delete";
5254       images {
5255          image: "00_button_edit_Delete.png" COMP;
5256          image: "00_button_edit_Delete_press.png" COMP;
5257          image: "00_button_edit_dim.png" COMP;
5258          image: "00_button_edit_focus.png" COMP;
5259       }
5260       script {
5261          public button_state = BUTTON_STATE_ENABLED;
5262       }
5263       parts {
5264          part { name: "button_image";
5265             scale: 1;
5266             description { state: "default" 0.0;
5267                min: BUTTON_CONTACT_DELETE_BG_NORMAL_MIN_INC;
5268                image {
5269                   normal: "00_button_edit_Delete.png";
5270                   border: BUTTON_CONTACT_DELETE_BG_BORDER_INC;
5271                   border_scale: 1;
5272                }
5273             }
5274             description { state: "clicked" 0.0;
5275                inherit: "default" 0.0;
5276                image.normal: "00_button_edit_Delete_press.png";
5277             }
5278             description { state: "disabled" 0.0;
5279                inherit: "default" 0.0;
5280                image.normal: "00_button_edit_dim.png";
5281             }
5282             description { state: "focused" 0.0;
5283                inherit: "default" 0.0;
5284                image.normal: "00_button_edit_focus.png";
5285             }
5286          }
5287          part { name: "padding_left_top";
5288             type: RECT;
5289             scale: 1;
5290             mouse_events: 0;
5291             description { state: "default" 0.0;
5292                align: 0.0 0.0;
5293                rel2.relative: 0.0 0.0;
5294                min: BUTTON_CONTACT_DELETE_PADDING_LEFT_TOP_MIN_INC;
5295                fixed: 1 1;
5296                visible: 0;
5297             }
5298          }
5299          part { name: "padding_right_bottom";
5300             type: RECT;
5301             scale: 1;
5302             mouse_events: 0;
5303             description { state: "default" 0.0;
5304                align: 1.0 1.0;
5305                rel1.relative: 1.0 1.0;
5306                min: BUTTON_CONTACT_DELETE_PADDING_RIGHT_BOTTOM_MIN_INC;
5307                fixed: 1 1;
5308                visible: 0;
5309             }
5310          }
5311          part { name: "padding_icon_text";
5312             type: RECT;
5313             scale: 1;
5314             mouse_events: 0;
5315             description { state: "default" 0.0; //when only icon or no icon is there
5316                align: 0.0 0.0;
5317                rel1 {
5318                   relative: 1.0 0.0;
5319                   to: "elm.swallow.content";
5320                }
5321                rel2.to: "elm.swallow.content";
5322                fixed: 1 0;
5323                min: 0 0;
5324                visible: 0;
5325             }
5326             description { state: "icononly" 0.0;
5327                inherit: "default" 0.0;
5328             }
5329             description { state: "visible" 0.0; //when icon is visible
5330                inherit: "default" 0.0;
5331                min: BUTTON_CONTACT_DELETE_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
5332             }
5333          }
5334          part { name: "elm.swallow.content";
5335             type: SWALLOW;
5336             scale: 1;
5337             clip_to: "clipper";
5338             description { state: "default" 0.0;
5339                visible: 0;
5340                align: 0.0 0.5;
5341                rel1 {
5342                   relative: 1.0 1.0;
5343                   to: "padding_left_top";
5344                }
5345                rel2 {
5346                   relative: 1.0 0.0;
5347                   to_x: "padding_left_top";
5348                   to_y: "padding_right_bottom";
5349                }
5350                fixed: 1 0;
5351             }
5352             description { state: "visible" 0.0;
5353                fixed: 1 0;
5354                align: 0.0 0.5;
5355                rel1 {
5356                   relative: 1.0 1.0;
5357                   to: "padding_left_top";
5358                }
5359                rel2 {
5360                   relative: 1.0 0.0;
5361                   to_x: "padding_left_top";
5362                   to_y: "padding_right_bottom";
5363                }
5364                aspect: 1.0 1.0;
5365                aspect_preference: VERTICAL;
5366             }
5367             description { state: "icononly" 0.0;
5368                min: BUTTON_CONTACT_DELETE_ICON_ICONONLY_MIN_INC;
5369                rel1 {
5370                   relative: 1.0 1.0;
5371                   to: "padding_left_top";
5372                }
5373                rel2 {
5374                   relative: 0.0 0.0;
5375                   to: "padding_right_bottom";
5376                }
5377                aspect: 1.0 1.0;
5378                aspect_preference: VERTICAL;
5379             }
5380          }
5381          part { name: "elm.text";
5382             type: TEXT;
5383             mouse_events: 0;
5384             scale: 1;
5385             clip_to: "clipper";
5386             description { state: "default" 0.0;
5387                rel1 {
5388                   relative: 1.0 1.0;
5389                   to_x: "padding_icon_text";
5390                   to_y: "padding_left_top";
5391                }
5392                rel2 {
5393                   relative: 0.0 0.0;
5394                   to: "padding_right_bottom";
5395                }
5396                color: BUTTON_TEXT_CONTACTS_DELETE_NORMAL_COLOR_INC;
5397                text {
5398                   font: "SLP:style=Medium";
5399                   size: BUTTON_CONTACT_DELETE_FONT_SIZE_INC;
5400                   min: 1 0;
5401                   text: "Delete";
5402                   max: 1 0;
5403                   text_class: "slp_medium";
5404                }
5405             }
5406             description { state: "visible" 0.0;
5407                inherit: "default" 0.0;
5408             }
5409             description { state: "clicked" 0.0;
5410                inherit: "default" 0.0;
5411                color: BUTTON_TEXT_CONTACTS_DELETE_PRESSED_COLOR_INC;
5412             }
5413             description { state: "disabled" 0.0;
5414                inherit: "default" 0.0;
5415                color: 0 0 0 128;
5416             }
5417             description { state: "disabled_visible" 0.0;
5418                inherit: "default" 0.0;
5419                color: BUTTON_TEXT_CONTACTS_DELETE_DISABLED_COLOR_INC;
5420             }
5421             description { state: "focused" 0.0;
5422                inherit: "default" 0.0;
5423                min: 0 0;
5424                color: BUTTON_TEXT_CONTACTS_DELETE_PRESSED_COLOR_INC;
5425             }
5426          }
5427          part { name: "over2";
5428             type: RECT;
5429             repeat_events: 1;
5430             ignore_flags: ON_HOLD;
5431             description { state: "default" 0.0;
5432                color: 0 0 0 0;
5433             }
5434          }
5435          part { name: "over3";
5436             type: RECT;
5437             repeat_events: 1;
5438             description { state: "default" 0.0;
5439                color: 0 0 0 0;
5440             }
5441          }
5442          part { name: "clipper";
5443             type: RECT;
5444             description { state: "default" 0.0;
5445                color: 255 255 255 255;
5446             }
5447          }
5448          part { name: "disabler";
5449             type: RECT;
5450             description { state: "default" 0.0;
5451                color: 0 0 0 0;
5452                visible: 0;
5453             }
5454             description { state: "disabled" 0.0;
5455                inherit: "default" 0.0;
5456                visible: 1;
5457             }
5458          }
5459       }
5460       programs {
5461          program { name: "button_click";
5462             signal: "mouse,down,1";
5463             source: "over2";
5464             action: SIGNAL_EMIT "elm,action,press" "";
5465             after: "button_click_anim";
5466          }
5467          program { name: "button_click_anim";
5468             action: STATE_SET "clicked" 0.0;
5469             target: "button_image";
5470             after: "text_clicked";
5471          }
5472          program { name: "text_clicked";
5473             script {
5474                new st[31];
5475                new Float:vl;
5476                get_state(PART:"elm.text", st, 30, vl);
5477                if (!strcmp(st, "visible"))
5478                  set_state(PART:"elm.text", "clicked", 0.0);
5479             }
5480          }
5481          program { name: "button_unpress";
5482             action: SIGNAL_EMIT "elm,action,unpress" "";
5483          }
5484          program { name: "button_mouseout_clicked";
5485             signal: "mouse,up,1";
5486             source: "over3";
5487             script {
5488                new st[31];
5489                new Float:vl;
5490                get_state(PART:"elm.swallow.content", st, 30, vl);
5491                if (strcmp(st, "icononly"))
5492                  {
5493                     emit("elm,action,default,text,set", "");
5494                     set_state(PART:"elm.text", "visible", 0.0);
5495                  }
5496                if (get_int(button_state) != BUTTON_STATE_DISABLED)
5497                  set_state(PART:"button_image", "default", 0.0);
5498             }
5499             after: button_unpress;
5500          }
5501          program { name: "touch_snd";
5502             signal: "mouse,clicked,1";
5503             source: "over2";
5504             action: PLAY_SAMPLE "touch_sound" 1.0;
5505             after: button_unclick3;
5506          }
5507          program { name: "button_unclick3";
5508             action: SIGNAL_EMIT "elm,action,click" "";
5509          }
5510          program { name: "text_show";
5511             signal: "elm,state,text,visible";
5512             source: "elm";
5513             script {
5514                new st[31];
5515                new Float:vl;
5516                get_state(PART:"elm.swallow.content", st, 30, vl);
5517                if (!strcmp(st, "icononly"))
5518                  {
5519                     set_state(PART:"elm.swallow.content", "visible", 0.0);
5520                     set_state(PART:"padding_icon_text", "visible", 0.0);
5521                  }
5522                if (get_int(button_state) != BUTTON_STATE_DISABLED)
5523                  set_state(PART:"elm.text", "visible", 0.0);
5524                else
5525                  set_state(PART:"elm.text", "disabled_visible", 0.0);
5526             }
5527          }
5528          program { name: "text_hide";
5529             signal: "elm,state,text,hidden";
5530             source: "elm";
5531             script {
5532                new st[31];
5533                new Float:vl;
5534                get_state(PART:"elm.swallow.content", st, 30, vl);
5535                if (!strcmp(st, "visible"))
5536                  {
5537                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
5538                     set_state(PART:"padding_icon_text", "icononly", 0.0);
5539                  }
5540                set_state(PART:"elm.text", "default", 0.0);
5541             }
5542          }
5543          program { name: "icon_show";
5544             signal: "elm,state,icon,visible";
5545             source: "elm";
5546             script {
5547                new st[31];
5548                new Float:vl;
5549                get_state(PART:"elm.text", st, 30, vl);
5550                if (!strcmp(st, "visible"))
5551                  {
5552                     set_state(PART:"elm.swallow.content", "visible", 0.0);
5553                     set_state(PART:"padding_icon_text", "visible", 0.0);
5554                  }
5555                else
5556                  {
5557                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
5558                     set_state(PART:"padding_icon_text", "icononly", 0.0);
5559                  }
5560             }
5561          }
5562          program { name: "icon_hide";
5563             signal: "elm,state,icon,hidden";
5564             source: "elm";
5565             action: STATE_SET "default" 0.0;
5566             target: "elm.swallow.content";
5567             target: "padding_icon_text";
5568          }
5569          program { name: "disable";
5570             signal: "elm,state,disabled";
5571             source: "elm";
5572             action: STATE_SET "disabled" 0.0;
5573             target: "button_image";
5574             target: "disabler";
5575             after: "disable_text";
5576          }
5577          program { name: "disable_text";
5578             script {
5579                new st[31];
5580                new Float:vl;
5581                get_state(PART:"elm.text", st, 30, vl);
5582                if (!strcmp(st, "visible"))
5583                  set_state(PART:"elm.text", "disabled_visible", 0.0);
5584                else
5585                  set_state(PART:"elm.text", "disabled", 0.0);
5586                set_int(button_state, BUTTON_STATE_DISABLED);
5587             }
5588          }
5589          program { name: "enable";
5590             signal: "elm,state,enabled";
5591             source: "elm";
5592             action: STATE_SET "default" 0.0;
5593             target: "button_image";
5594             target: "disabler";
5595             after: "enable_text";
5596          }
5597          program { name: "enable_text";
5598             script {
5599                new st[31];
5600                new Float:vl;
5601                get_state(PART:"elm.text", st, 30, vl);
5602                if (!strcmp(st, "disabled_visible"))
5603                  set_state(PART:"elm.text", "visible", 0.0);
5604                else
5605                  set_state(PART:"elm.text", "default", 0.0);
5606                set_int(button_state, BUTTON_STATE_ENABLED);
5607             }
5608          }
5609          program { name: "focused";
5610             //signal: "elm,action,focus";
5611             //source: "elm";
5612             action: STATE_SET "focused" 0.0;
5613             target: "button_image";
5614             target: "elm.text";
5615          }
5616          program { name: "unfocused";
5617             //signal: "elm,action,unfocus";
5618             //source: "elm";
5619             action: STATE_SET "default" 0.0;
5620             target: "button_image";
5621             after: "unfocus_text";
5622          }
5623          program { name: "unfocus_text";
5624             action: STATE_SET "visible" 0.0;
5625             target: "elm.text";
5626          }
5627       }
5628    }
5629
5630 ///////////////////////////////////////////////////////////////////////////////////////
5631    group { name: "elm/button/base/multiline";
5632       alias: "elm/button/base/text_only/multiline";
5633       images {
5634          image: "00_button_04_normal.png" COMP;
5635          image: "00_button_04_press.png" COMP;
5636          image: "00_button_04_dim.png" COMP;
5637          image: "00_button_04_normal_focus.png" COMP;
5638       }
5639       script {
5640          public button_state = BUTTON_STATE_ENABLED;
5641       }
5642       styles{
5643          style { name: "btn_multiline_style";
5644             base: "font=SLP:style=Medium font_size=18 align=center color=#ffffff wrap=mixed text_class=slp_medium";
5645             tag: "br" "\n";
5646             tag: "ps" "ps";
5647             tag: "tab" "\t";
5648          }
5649       }
5650       parts {
5651          part { name: "button_image";
5652             scale: 1;
5653             description { state: "default" 0.0;
5654                min: 10 46;
5655                image {
5656                   normal: "00_button_04_normal.png";
5657                   border: 4 4 3 3;
5658                   border_scale: 1;
5659                }
5660             }
5661             description { state: "clicked" 0.0;
5662                inherit: "default" 0.0;
5663                image.normal: "00_button_04_press.png";
5664             }
5665             description { state: "disabled" 0.0;
5666                inherit: "default" 0.0;
5667                image.normal: "00_button_04_dim.png";
5668             }
5669             description { state: "focused" 0.0;
5670                inherit: "default" 0.0;
5671                image.normal: "00_button_04_normal_focus.png";
5672             }
5673          }
5674          part { name: "padding_left_top";
5675             type: RECT;
5676             scale: 1;
5677             mouse_events: 0;
5678             description { state: "default" 0.0;
5679                align: 0.0 0.0;
5680                rel2.relative: 0.0 0.0;
5681                min: 2 2;
5682                fixed: 1 1;
5683                visible: 0;
5684             }
5685          }
5686          part { name: "padding_right_bottom";
5687             type: RECT;
5688             scale: 1;
5689             mouse_events: 0;
5690             description { state: "default" 0.0;
5691                align: 1.0 1.0;
5692                rel1.relative: 1.0 1.0;
5693                min: 2 2;
5694                fixed: 1 1;
5695                visible: 0;
5696             }
5697          }
5698          part { name: "icon_rect";
5699             type: RECT;
5700             scale: 1;
5701             mouse_events: 0;
5702             description { state: "default" 0.0;
5703                visible: 1;
5704                min: 0 40;
5705                fixed: 1 0;
5706                rel1 {
5707                   relative: 0.0 1.0;
5708                   to_x: "elm.swallow.content";
5709                   to_y: "padding_left_top";
5710                }
5711                rel2 {
5712                   relative: 1.0 0.0;
5713                   to_x: "elm.swallow.content";
5714                   to_y: "padding_right_bottom";
5715                }
5716                align: 0.0 0.5;
5717                color: 0 0 0 0;
5718             }
5719          }
5720          part { name: "padding_icon_text";
5721             type: RECT;
5722             scale: 1;
5723             mouse_events: 0;
5724             description { state: "default" 0.0; //when only icon or no icon is there
5725                align: 0.0 0.0;
5726                rel1 {
5727                   relative: 1.0 0.0;
5728                   to: "icon_rect";
5729                }
5730                rel2.to: "icon_rect";
5731                fixed: 1 0;
5732                min: 0 0;
5733                color: 0 0 0 0;
5734             }
5735             description { state: "icononly" 0.0;
5736                inherit: "default" 0.0;
5737             }
5738             description { state: "visible" 0.0; //when icon is visible
5739                align: 0.0 0.0;
5740                rel1 {
5741                   relative: 1.0 0.0;
5742                   to: "icon_rect";
5743                }
5744                rel2.to: "icon_rect";
5745                fixed: 1 0;
5746                min: 5 0;
5747                color: 0 0 0 0;
5748             }
5749          }
5750          part { name: "elm.swallow.content";
5751             type: SWALLOW;
5752             scale: 1;
5753             clip_to: "clipper";
5754             description { state: "default" 0.0;
5755                visible: 0;
5756                align: 0.0 0.5;
5757                rel1 {
5758                   relative: 1.0 1.0;
5759                   to: "padding_left_top";
5760                }
5761                rel2 {
5762                   relative: 1.0 0.0;
5763                   to_x: "padding_left_top";
5764                   to_y: "padding_right_bottom";
5765                }
5766                fixed: 1 0;
5767             }
5768             description { state: "visible" 0.0;
5769                fixed: 1 0;
5770                align: 0.0 0.5;
5771                rel1 {
5772                   relative: 1.0 1.0;
5773                   to: "padding_left_top";
5774                }
5775                rel2 {
5776                   relative: 1.0 0.0;
5777                   to_x: "padding_left_top";
5778                   to_y: "padding_right_bottom";
5779                }
5780                aspect: 1.0 1.0;
5781                aspect_preference: VERTICAL;
5782             }
5783             description { state: "icononly" 0.0;
5784                min: 40 40;
5785                rel1 {
5786                   relative: 1.0 1.0;
5787                   to: "padding_left_top";
5788                }
5789                rel2 {
5790                   relative: 0.0 0.0;
5791                   to: "padding_right_bottom";
5792                }
5793                aspect: 1.0 1.0;
5794                aspect_preference: VERTICAL;
5795             }
5796          }
5797          part { name: "elm.text";
5798             type: TEXTBLOCK;
5799             mouse_events: 0;
5800             scale: 1;
5801             clip_to: "clipper";
5802             description { state: "default" 0.0;
5803                visible: 0;
5804                rel1 {
5805                   relative: 1.0 1.0;
5806                   to_x: "padding_icon_text";
5807                   to_y: "padding_left_top";
5808                }
5809                rel2 {
5810                   relative: 0.0 0.0;
5811                   to: "padding_right_bottom";
5812                }
5813                color: BUTTON_TEXT_STYLE1_NORMAL_COLOR_INC;
5814                text {
5815                   style: "btn_multiline_style";
5816                   min: 0 0;
5817                   max: 0 1;
5818                }
5819             }
5820             description { state: "visible" 0.0;
5821                inherit: "default" 0.0;
5822                visible: 1;
5823                min: 80 0;
5824             }
5825             description { state: "clicked" 0.0;
5826                inherit: "default" 0.0;
5827                visible: 1;
5828                min: 0 0;
5829                color: BUTTON_TEXT_STYLE1_PRESSED_COLOR_INC;
5830             }
5831             description { state: "disabled" 0.0;
5832                inherit: "default" 0.0;
5833                color: 0 0 0 128;
5834             }
5835             description { state: "disabled_visible" 0.0;
5836                inherit: "default" 0.0;
5837                color: BUTTON_TEXT_STYLE1_TEXT_DISABLED_COLOR_INC;
5838                visible: 1;
5839                min: 80 0;
5840             }
5841             description { state: "focused" 0.0;
5842                inherit: "default" 0.0;
5843                visible: 1;
5844                min: 0 0;
5845                color: BUTTON_TEXT_STYLE1_DISABLED_COLOR_INC;
5846             }
5847          }
5848          part { name: "over2";
5849             type: RECT;
5850             repeat_events: 1;
5851             ignore_flags: ON_HOLD;
5852             description { state: "default" 0.0;
5853                color: 0 0 0 0;
5854             }
5855          }
5856          part { name: "over3";
5857             type: RECT;
5858             repeat_events: 1;
5859             description { state: "default" 0.0;
5860                color: 0 0 0 0;
5861             }
5862          }
5863          part { name: "clipper";
5864             type: RECT;
5865             description { state: "default" 0.0;
5866                color: 255 255 255 255;
5867             }
5868          }
5869          part { name: "disabler";
5870             type: RECT;
5871             description { state: "default" 0.0;
5872                color: 0 0 0 0;
5873                visible: 0;
5874             }
5875             description { state: "disabled" 0.0;
5876                inherit: "default" 0.0;
5877                visible: 1;
5878             }
5879          }
5880       }
5881       programs {
5882          program { name: "button_click";
5883             signal: "mouse,down,1";
5884             source: "over2";
5885             action: SIGNAL_EMIT "elm,action,press" "";
5886             after: "button_click_anim";
5887          }
5888          program { name: "button_click_anim";
5889             action: STATE_SET "clicked" 0.0;
5890             target: "button_image";
5891             after: "text_clicked";
5892          }
5893          program { name: "text_clicked";
5894             script {
5895                new st[31];
5896                new Float:vl;
5897                get_state(PART:"elm.text", st, 30, vl);
5898                if (!strcmp(st, "visible"))
5899                  set_state(PART:"elm.text", "clicked", 0.0);
5900             }
5901          }
5902          program { name: "button_unpress";
5903             action: SIGNAL_EMIT "elm,action,unpress" "";
5904          }
5905          program { name: "button_mouseout_clicked";
5906             signal: "mouse,up,1";
5907             source: "over3";
5908             script {
5909                new st[31];
5910                new Float:vl;
5911                get_state(PART:"elm.swallow.content", st, 30, vl);
5912                if (strcmp(st, "icononly"))
5913                  {
5914                     emit("elm,action,default,text,set", "");
5915                     set_state(PART:"elm.text", "visible", 0.0);
5916                  }
5917                if (get_int(button_state) != BUTTON_STATE_DISABLED)
5918                  set_state(PART:"button_image", "default", 0.0);
5919             }
5920             after: button_unpress;
5921          }
5922          program { name: "touch_snd";
5923             signal: "mouse,clicked,1";
5924             source: "over2";
5925             action: PLAY_SAMPLE "touch_sound" 1.0;
5926             after: button_unclick3;
5927          }
5928          program { name: "button_unclick3";
5929             action: SIGNAL_EMIT "elm,action,click" "";
5930          }
5931          program { name: "text_show";
5932             signal: "elm,state,text,visible";
5933             source: "elm";
5934             script {
5935                new st[31];
5936                new Float:vl;
5937                get_state(PART:"elm.swallow.content", st, 30, vl);
5938                if (!strcmp(st, "icononly"))
5939                  {
5940                     set_state(PART:"elm.swallow.content", "visible", 0.0);
5941                     set_state(PART:"padding_icon_text", "visible", 0.0);
5942                  }
5943                if (get_int(button_state) != BUTTON_STATE_DISABLED)
5944                  set_state(PART:"elm.text", "visible", 0.0);
5945                else
5946                  set_state(PART:"elm.text", "disabled_visible", 0.0);
5947             }
5948          }
5949          program { name: "text_hide";
5950             signal: "elm,state,text,hidden";
5951             source: "elm";
5952             script {
5953                new st[31];
5954                new Float:vl;
5955                get_state(PART:"elm.swallow.content", st, 30, vl);
5956                if (!strcmp(st, "visible"))
5957                  {
5958                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
5959                     set_state(PART:"padding_icon_text", "icononly", 0.0);
5960                  }
5961                set_state(PART:"elm.text", "default", 0.0);
5962             }
5963          }
5964          program { name: "icon_show";
5965             signal: "elm,state,icon,visible";
5966             source: "elm";
5967             script {
5968                new st[31];
5969                new Float:vl;
5970                get_state(PART:"elm.text", st, 30, vl);
5971                if (!strcmp(st, "visible"))
5972                  {
5973                     set_state(PART:"elm.swallow.content", "visible", 0.0);
5974                     set_state(PART:"padding_icon_text", "visible", 0.0);
5975                  }
5976                else
5977                  {
5978                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
5979                     set_state(PART:"padding_icon_text", "icononly", 0.0);
5980                  }
5981             }
5982          }
5983          program { name: "icon_hide";
5984             signal: "elm,state,icon,hidden";
5985             source: "elm";
5986             action: STATE_SET "default" 0.0;
5987             target: "elm.swallow.content";
5988             target: "padding_icon_text";
5989          }
5990          program { name: "disable";
5991             signal: "elm,state,disabled";
5992             source: "elm";
5993             action: STATE_SET "disabled" 0.0;
5994             target: "button_image";
5995             target: "disabler";
5996             after: "disable_text";
5997          }
5998          program { name: "disable_text";
5999             script {
6000                new st[31];
6001                new Float:vl;
6002                get_state(PART:"elm.text", st, 30, vl);
6003                if (!strcmp(st, "visible"))
6004                  set_state(PART:"elm.text", "disabled_visible", 0.0);
6005                else
6006                  set_state(PART:"elm.text", "disabled", 0.0);
6007                set_int(button_state, BUTTON_STATE_DISABLED);
6008             }
6009          }
6010          program { name: "enable";
6011             signal: "elm,state,enabled";
6012             source: "elm";
6013             action: STATE_SET "default" 0.0;
6014             target: "button_image";
6015             target: "disabler";
6016             after: "enable_text";
6017          }
6018          program { name: "enable_text";
6019             script {
6020                new st[31];
6021                new Float:vl;
6022                get_state(PART:"elm.text", st, 30, vl);
6023                if (!strcmp(st, "disabled_visible"))
6024                  set_state(PART:"elm.text", "visible", 0.0);
6025                else
6026                  set_state(PART:"elm.text", "default", 0.0);
6027                set_int(button_state, BUTTON_STATE_ENABLED);
6028             }
6029          }
6030          program { name: "focused";
6031             //signal: "elm,action,focus";
6032             //source: "elm";
6033             action: STATE_SET "focused" 0.0;
6034             target: "button_image";
6035             target: "elm.text";
6036          }
6037          program { name: "unfocused";
6038             //signal: "elm,action,unfocus";
6039             //source: "elm";
6040             action: STATE_SET "default" 0.0;
6041             target: "button_image";
6042             after: "unfocus_text";
6043          }
6044          program { name: "unfocus_text";
6045             action: STATE_SET "visible" 0.0;
6046             target: "elm.text";
6047          }
6048       }
6049    }
6050
6051 ///////////////////////////////////////////////////////////////////////////////////////
6052    group { name: "elm/button/base/default";
6053       images {
6054          image: "00_button_01_normal.png" COMP;
6055          image: "00_button_01_normal_press.png" COMP;
6056          image: "00_button_01_normal_dim.png" COMP;
6057          image: "00_button_01_normal_Focus.png" COMP;
6058       }
6059       script {
6060          public button_state = BUTTON_STATE_ENABLED;
6061       }
6062       parts {
6063          part { name: "button_image";
6064             scale: 1;
6065             description { state: "default" 0.0;
6066                min: BUTTON_DEFAULT_STYLE_BG_MIN_INC;
6067                image {
6068                   normal: "00_button_01_normal.png";
6069                   border: BUTTON_DEFAULT_STYLE_BG_BORDER_INC;
6070                   border_scale: 1;
6071                }
6072             }
6073             description { state: "clicked" 0.0;
6074                inherit: "default" 0.0;
6075                image.normal: "00_button_01_normal_press.png";
6076             }
6077             description { state: "disabled" 0.0;
6078                inherit: "default" 0.0;
6079                image.normal: "00_button_01_normal_dim.png";
6080             }
6081             description { state: "focused" 0.0;
6082                inherit: "default" 0.0;
6083                image.normal: "00_button_01_normal_Focus.png";
6084             }
6085          }
6086          part { name: "padding_left_top";
6087             type: RECT;
6088             scale: 1;
6089             mouse_events: 0;
6090             description { state: "default" 0.0;
6091                align: 0.0 0.0;
6092                rel2.relative: 0.0 0.0;
6093                min: BUTTON_DEFAULT_STYLE_PADDING_MIN_INC;
6094                fixed: 1 1;
6095                visible: 0;
6096             }
6097          }
6098          part { name: "padding_right_bottom";
6099             type: RECT;
6100             scale: 1;
6101             mouse_events: 0;
6102             description { state: "default" 0.0;
6103                align: 1.0 1.0;
6104                rel1.relative: 1.0 1.0;
6105                min: BUTTON_DEFAULT_STYLE_PADDING_MIN_INC;
6106                fixed: 1 1;
6107                visible: 0;
6108             }
6109          }
6110          part { name: "padding_icon_text";
6111             type: RECT;
6112             scale: 1;
6113             mouse_events: 0;
6114             description { state: "default" 0.0; //when only icon or no icon is there
6115                align: 0.0 0.0;
6116                visible: 0;
6117                rel1 {
6118                   relative: 1.0 0.0;
6119                   to: "elm.swallow.content";
6120                }
6121                rel2.to: "elm.swallow.content";
6122                fixed: 1 0;
6123                min: 0 0;
6124             }
6125             description { state: "icononly" 0.0;
6126                inherit: "default" 0.0;
6127             }
6128             description { state: "visible" 0.0; //when icon is visible
6129                inherit: "default" 0.0;
6130                min: BUTTON_DEFAULT_STYLE_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
6131             }
6132          }
6133          part { name: "elm.swallow.content";
6134             type: SWALLOW;
6135             scale: 1;
6136             clip_to: "clipper";
6137             description { state: "default" 0.0;
6138                visible: 0;
6139                align: 0.0 0.5;
6140                rel1 {
6141                   relative: 1.0 1.0;
6142                   to: "padding_left_top";
6143                }
6144                rel2 {
6145                   relative: 1.0 0.0;
6146                   to_x: "padding_left_top";
6147                   to_y: "padding_right_bottom";
6148                }
6149                fixed: 1 0;
6150             }
6151             description { state: "visible" 0.0;
6152                fixed: 1 0;
6153                align: 0.0 0.5;
6154                rel1 {
6155                   relative: 1.0 1.0;
6156                   to: "padding_left_top";
6157                }
6158                rel2 {
6159                   relative: 1.0 0.0;
6160                   to_x: "padding_left_top";
6161                   to_y: "padding_right_bottom";
6162                }
6163                aspect: 1.0 1.0;
6164                aspect_preference: VERTICAL;
6165             }
6166             description { state: "icononly" 0.0;
6167                min: BUTTON_DEFAULT_STYLE_ICONONLY_ICON_MIN_INC;
6168                rel1 {
6169                   relative: 1.0 0.0;
6170                   to_x: "padding_left_top";
6171                }
6172                rel2 {
6173                   relative: 0.0 1.0;
6174                   to_x: "padding_right_bottom";
6175                }
6176                aspect: 1.0 1.0;
6177                aspect_preference: VERTICAL;
6178             }
6179          }
6180          part { name: "elm.text";
6181             type: TEXT;
6182             mouse_events: 0;
6183             scale: 1;
6184             clip_to: "clipper";
6185             description { state: "default" 0.0;
6186                visible: 0;
6187                align: 0.0 0.5;
6188                rel1 {
6189                   relative: 1.0 1.0;
6190                   to_x: "padding_icon_text";
6191                   to_y: "padding_left_top";
6192                }
6193                rel2 {
6194                   relative: 0.0 0.0;
6195                   to: "padding_right_bottom";
6196                }
6197                color: BUTTON_DEFAULT_STYLE_BUTTON_TEXT_NORMAL_COLOR_INC;
6198                text {
6199                   font: "SLP:style=Medium";
6200                   size: BUTTON_DEFAULT_STYLE_FONT_SIZE_INC;
6201                   min: 0 0;
6202                   text_class: "slp_medium";
6203                }
6204             }
6205             description { state: "visible" 0.0;
6206                inherit: "default" 0.0;
6207                visible: 1;
6208                min: BUTTON_DEFAULT_STYLE_TEXT_MIN_INC;
6209             }
6210             description { state: "clicked" 0.0;
6211                inherit: "default" 0.0;
6212                visible: 1;
6213                min: BUTTON_DEFAULT_STYLE_TEXT_MIN_INC;
6214                color: BUTTON_DEFAULT_STYLE_BUTTON_TEXT_PRESSED_COLOR_INC;
6215             }
6216             description { state: "disabled" 0.0;
6217                inherit: "default" 0.0;
6218             }
6219             description { state: "disabled_visible" 0.0;
6220                inherit: "default" 0.0;
6221                color: BUTTON_DEFAULT_STYLE_BUTTON_TEXT_DISABLED_COLOR_INC;
6222                visible: 1;
6223                min: BUTTON_DEFAULT_STYLE_TEXT_MIN_INC;
6224             }
6225             description { state: "focused" 0.0;
6226                inherit: "default" 0.0;
6227                visible: 1;
6228                min: 0 0;
6229                color: BUTTON_DEFAULT_STYLE_BUTTON_TEXT_FOCUSED_COLOR_INC;
6230             }
6231          }
6232          part { name: "over2";
6233             type: RECT;
6234             repeat_events: 1;
6235             ignore_flags: ON_HOLD;
6236             description { state: "default" 0.0;
6237                color: 0 0 0 0;
6238             }
6239          }
6240          part { name: "over3";
6241             type: RECT;
6242             repeat_events: 1;
6243             description { state: "default" 0.0;
6244                color: 0 0 0 0;
6245             }
6246          }
6247          part { name: "clipper";
6248             type: RECT;
6249             description { state: "default" 0.0;
6250                color: 255 255 255 255;
6251             }
6252          }
6253          part { name: "disabler";
6254             type: RECT;
6255             description { state: "default" 0.0;
6256                color: 0 0 0 0;
6257                visible: 0;
6258             }
6259             description { state: "disabled" 0.0;
6260                inherit: "default" 0.0;
6261                visible: 1;
6262             }
6263          }
6264       }
6265       programs {
6266          program { name: "button_click";
6267             signal: "mouse,down,1";
6268             source: "over2";
6269             action: SIGNAL_EMIT "elm,action,press" "";
6270             after: "button_click_anim";
6271          }
6272          program { name: "button_click_anim";
6273             action: STATE_SET "clicked" 0.0;
6274             target: "button_image";
6275             after: "text_clicked";
6276          }
6277          program { name: "text_clicked";
6278             script {
6279                new st[31];
6280                new Float:vl;
6281                get_state(PART:"elm.text", st, 30, vl);
6282                if (!strcmp(st, "visible"))
6283                  set_state(PART:"elm.text", "clicked", 0.0);
6284             }
6285          }
6286          program { name: "button_unpress";
6287             action: SIGNAL_EMIT "elm,action,unpress" "";
6288          }
6289          program { name: "button_mouseout_clicked";
6290             signal: "mouse,up,1";
6291             source: "over3";
6292             script {
6293                new st[31];
6294                new Float:vl;
6295                get_state(PART:"elm.swallow.content", st, 30, vl);
6296                if (strcmp(st, "icononly"))
6297                  {
6298                     emit("elm,action,default,text,set", "");
6299                     set_state(PART:"elm.text", "visible", 0.0);
6300                  }
6301                if (get_int(button_state) != BUTTON_STATE_DISABLED)
6302                  set_state(PART:"button_image", "default", 0.0);
6303             }
6304             after: button_unpress;
6305          }
6306          program { name: "touch_snd";
6307             signal: "mouse,clicked,1";
6308             source: "over2";
6309             action: PLAY_SAMPLE "touch_sound" 1.0;
6310             after: button_unclick3;
6311          }
6312          program { name: "button_unclick3";
6313             action: SIGNAL_EMIT "elm,action,click" "";
6314          }
6315          program { name: "text_show";
6316             signal: "elm,state,text,visible";
6317             source: "elm";
6318             script {
6319                new st[31];
6320                new Float:vl;
6321                get_state(PART:"elm.swallow.content", st, 30, vl);
6322                if (!strcmp(st, "icononly"))
6323                  {
6324                     set_state(PART:"elm.swallow.content", "visible", 0.0);
6325                     set_state(PART:"padding_icon_text", "visible", 0.0);
6326                  }
6327                if (get_int(button_state) != BUTTON_STATE_DISABLED)
6328                  set_state(PART:"elm.text", "visible", 0.0);
6329                else
6330                  set_state(PART:"elm.text", "disabled_visible", 0.0);
6331             }
6332          }
6333          program { name: "text_hide";
6334             signal: "elm,state,text,hidden";
6335             source: "elm";
6336             script {
6337                new st[31];
6338                new Float:vl;
6339                get_state(PART:"elm.swallow.content", st, 30, vl);
6340                if (!strcmp(st, "visible"))
6341                  {
6342                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
6343                     set_state(PART:"padding_icon_text", "icononly", 0.0);
6344                  }
6345                set_state(PART:"elm.text", "default", 0.0);
6346             }
6347          }
6348          program { name: "icon_show";
6349             signal: "elm,state,icon,visible";
6350             source: "elm";
6351             script {
6352                new st[31];
6353                new Float:vl;
6354                get_state(PART:"elm.text", st, 30, vl);
6355                if (!strcmp(st, "visible"))
6356                  {
6357                     set_state(PART:"elm.swallow.content", "visible", 0.0);
6358                     set_state(PART:"padding_icon_text", "visible", 0.0);
6359                  }
6360                else
6361                  {
6362                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
6363                     set_state(PART:"padding_icon_text", "icononly", 0.0);
6364                  }
6365             }
6366          }
6367          program { name: "icon_hide";
6368             signal: "elm,state,icon,hidden";
6369             source: "elm";
6370             action: STATE_SET "default" 0.0;
6371             target: "elm.swallow.content";
6372             target: "padding_icon_text";
6373          }
6374          program { name: "disable";
6375             signal: "elm,state,disabled";
6376             source: "elm";
6377             action: STATE_SET "disabled" 0.0;
6378             target: "button_image";
6379             target: "disabler";
6380             after: "disable_text";
6381          }
6382          program { name: "disable_text";
6383             script {
6384                new st[31];
6385                new Float:vl;
6386                get_state(PART:"elm.text", st, 30, vl);
6387                if (!strcmp(st, "visible"))
6388                  set_state(PART:"elm.text", "disabled_visible", 0.0);
6389                else
6390                  set_state(PART:"elm.text", "disabled", 0.0);
6391                set_int(button_state, BUTTON_STATE_DISABLED);
6392             }
6393          }
6394          program { name: "enable";
6395             signal: "elm,state,enabled";
6396             source: "elm";
6397             action: STATE_SET "default" 0.0;
6398             target: "button_image";
6399             target: "disabler";
6400             after: "enable_text";
6401          }
6402          program { name: "enable_text";
6403             script {
6404                new st[31];
6405                new Float:vl;
6406                get_state(PART:"elm.text", st, 30, vl);
6407                if (!strcmp(st, "disabled_visible"))
6408                  set_state(PART:"elm.text", "visible", 0.0);
6409                else
6410                  set_state(PART:"elm.text", "default", 0.0);
6411                set_int(button_state, BUTTON_STATE_ENABLED);
6412             }
6413          }
6414          program { name: "focused";
6415             //signal: "elm,action,focus";
6416             //source: "elm";
6417             action: STATE_SET "focused" 0.0;
6418             target: "button_image";
6419             target: "elm.text";
6420          }
6421          program { name: "unfocused";
6422             //signal: "elm,action,unfocus";
6423             //source: "elm";
6424             action: STATE_SET "default" 0.0;
6425             target: "button_image";
6426             after: "unfocus_text";
6427          }
6428          program { name: "unfocus_text";
6429             action: STATE_SET "visible" 0.0;
6430             target: "elm.text";
6431          }
6432       }
6433    }
6434
6435 ///////////////////////////////////////////////////////////////////////////////////////
6436 #define BUTTON_COLORSELECTOR_STYLES(style_name, image_normal, image_press,image_disable) \
6437    group { name: "elm/button/base/"style_name; \
6438       images { \
6439          image: image_normal COMP; \
6440          image: image_press COMP; \
6441          image: image_disable COMP; \
6442          image: "00_button_01_normal.png" COMP; \
6443          image: "00_button_01_normal_press.png" COMP; \
6444          image: "00_button_01_normal_dim.png" COMP; \
6445          image: "00_button_01_normal_Focus.png" COMP; \
6446       } \
6447       parts { \
6448          part { name: "button_image"; \
6449             scale: 1; \
6450             description { state: "default" 0.0; \
6451                min: BUTTON_COLORSELECTOR_BG_DEFAULT_MIN_INC; \
6452                max: BUTTON_COLORSELECTOR_BG_DEFAULT_MIN_INC; \
6453                image { \
6454                   normal: "00_button_01_normal.png"; \
6455                   border: BUTTON_COLORSELECTOR_BG_BORDER_INC; \
6456                   border_scale: 1; \
6457                } \
6458             } \
6459             description { \
6460                state: "clicked" 0.0; \
6461                inherit: "default" 0.0; \
6462                image.normal: "00_button_01_normal_press.png"; \
6463             } \
6464             description { \
6465                state: "disabled" 0.0; \
6466                inherit: "default" 0.0; \
6467                image.normal: "00_button_01_normal_dim.png"; \
6468             } \
6469             description { \
6470                state: "focused" 0.0; \
6471                inherit: "default" 0.0; \
6472                image.normal: "00_button_01_normal_Focus.png"; \
6473             } \
6474          } \
6475          part { name: "button_center_part"; \
6476             scale: 1; \
6477             description { state: "default" 0.0; \
6478                min: BUTTON_COLORSELECTOR_IMAGE_MIN_MAX_INC; \
6479                max: BUTTON_COLORSELECTOR_IMAGE_MIN_MAX_INC; \
6480                image.normal: image_normal; \
6481             } \
6482             description { \
6483                state: "clicked" 0.0; \
6484                inherit: "default" 0.0; \
6485                image.normal: image_press; \
6486             } \
6487             description { \
6488                state: "disabled" 0.0; \
6489                inherit: "default" 0.0; \
6490                image.normal: image_disable; \
6491             } \
6492          } \
6493          part { name: "over1"; \
6494             type: RECT; \
6495             ignore_flags: ON_HOLD; \
6496             description { state: "default" 0.0; \
6497                color: 0 0 0 0; \
6498             } \
6499          } \
6500          part { name: "over2"; \
6501             repeat_events: 1; \
6502             description { state: "default" 0.0; \
6503                color: 0 0 0 0; \
6504             } \
6505          } \
6506          part { name: "disabler"; \
6507             type: RECT; \
6508             description { state: "default" 0.0; \
6509                color: 0 0 0 0; \
6510                visible: 0; \
6511             } \
6512             description { state: "disabled" 0.0; \
6513                inherit: "default" 0.0; \
6514                visible: 1; \
6515             } \
6516          } \
6517       } \
6518       programs { \
6519          program { name: "button_click"; \
6520             signal: "mouse,down,1"; \
6521             source: "over1"; \
6522             action: SIGNAL_EMIT "elm,action,press" ""; \
6523             after: "button_click_anim"; \
6524          } \
6525          program { name: "button_click_anim"; \
6526             action: STATE_SET "clicked" 0.0; \
6527             target: "button_image"; \
6528             target: "button_center_part"; \
6529          } \
6530          program { name: "button_unclick"; \
6531             signal: "mouse,up,1"; \
6532             source: "over2"; \
6533             action: SIGNAL_EMIT "elm,action,unpress" ""; \
6534             after: "button_unclick_anim"; \
6535          } \
6536          program { name: "button_unclick_anim"; \
6537             action: STATE_SET "default" 0.0; \
6538             target: "button_image"; \
6539             target: "button_center_part"; \
6540          } \
6541          program { name: "touch_snd"; \
6542             signal: "mouse,clicked,1"; \
6543             source: "over1"; \
6544             action: PLAY_SAMPLE "touch_sound" 1.0; \
6545             after: button_unclick3; \
6546          } \
6547          program { name: "button_unclick3"; \
6548             action: SIGNAL_EMIT "elm,action,click" ""; \
6549          } \
6550          program { name: "disable"; \
6551             signal: "elm,state,disabled"; \
6552             source: "elm"; \
6553             action: STATE_SET "disabled" 0.0; \
6554             target: "disabler"; \
6555             target: "button_image"; \
6556             target: "button_center_part"; \
6557          } \
6558          program { name: "enable"; \
6559             signal: "elm,state,enabled"; \
6560             source: "elm"; \
6561             action: STATE_SET "default" 0.0; \
6562             target: "disabler"; \
6563             target: "button_image"; \
6564             target: "button_center_part"; \
6565          } \
6566       } \
6567    }
6568 ///////////////////////////////////////////////////////////////////////////////////////
6569    BUTTON_COLORSELECTOR_STYLES("colorselector/left/default", "00_color_picker_btn_left.png", "00_color_picker_btn_left_press.png", "00_color_picker_btn_left_dim.png")
6570 ///////////////////////////////////////////////////////////////////////////////////////
6571    BUTTON_COLORSELECTOR_STYLES("colorselector/right/default", "00_color_picker_btn_right.png", "00_color_picker_btn_right_press.png", "00_color_picker_btn_right_dim.png")
6572 ///////////////////////////////////////////////////////////////////////////////////////
6573    group { name: "elm/button/base/hidden";
6574       images {
6575          image: "00_button_sweep.png" COMP;
6576          image: "00_button_sweep_press.png" COMP;
6577          image: "00_button_sweep_focus.png" COMP;
6578          image: "00_button_sweep_dim.png" COMP;
6579       }
6580       script {
6581          public button_state = BUTTON_STATE_ENABLED;
6582       }
6583       parts {
6584          part { name: "button_image";
6585             scale: 1;
6586             description { state: "default" 0.0;
6587                min: BUTTON_HIDDEN_BG_NORMAL_MIN_INC;
6588                image {
6589                   normal: "00_button_sweep.png";
6590                   border: BUTTON_HIDDEN_BG_BORDER_INC;
6591                   border_scale: 1;
6592                }
6593             }
6594             description { state: "clicked" 0.0;
6595                inherit: "default" 0.0;
6596                image.normal: "00_button_sweep_press.png";
6597             }
6598             description { state: "disabled" 0.0;
6599                inherit: "default" 0.0;
6600                image.normal: "00_button_sweep_dim.png";
6601             }
6602             description { state: "focused" 0.0;
6603                inherit: "default" 0.0;
6604                image.normal: "00_button_sweep_focus.png";
6605             }
6606          }
6607          part { name: "padding_left_top";
6608             type: RECT;
6609             scale: 1;
6610             mouse_events: 0;
6611             description { state: "default" 0.0;
6612                align: 0.0 0.0;
6613                rel2.relative: 0.0 0.0;
6614                min: BUTTON_HIDDEN_PADDING_MIN_INC;
6615                fixed: 1 1;
6616                visible: 0;
6617             }
6618          }
6619          part { name: "padding_right_bottom";
6620             type: RECT;
6621             scale: 1;
6622             mouse_events: 0;
6623             description { state: "default" 0.0;
6624                align: 1.0 1.0;
6625                rel1.relative: 1.0 1.0;
6626                min: BUTTON_HIDDEN_PADDING_MIN_INC;
6627                fixed: 1 1;
6628                visible: 0;
6629             }
6630          }
6631          part { name: "icon_rect";
6632             type: RECT;
6633             scale: 1;
6634             mouse_events: 0;
6635             description { state: "default" 0.0;
6636                min: BUTTON_HIDDEN_ICON_RECT_MIN_INC;
6637                fixed: 1 0;
6638                rel1 {
6639                   relative: 0.0 1.0;
6640                   to_x: "elm.swallow.content";
6641                   to_y: "padding_left_top";
6642                }
6643                rel2 {
6644                   relative: 1.0 0.0;
6645                   to_x: "elm.swallow.content";
6646                   to_y: "padding_right_bottom";
6647                }
6648                align: 0.0 0.5;
6649                color: 0 0 0 0;
6650             }
6651          }
6652          part { name: "padding_icon_text";
6653             type: RECT;
6654             scale: 1;
6655             mouse_events: 0;
6656             description { state: "default" 0.0; //when only icon or no icon is there
6657                align: 0.0 0.0;
6658                rel1 {
6659                   relative: 1.0 0.0;
6660                   to: "icon_rect";
6661                }
6662                rel2.to: "icon_rect";
6663                fixed: 1 0;
6664                min: 0 0;
6665                color: 0 0 0 0;
6666             }
6667             description { state: "icononly" 0.0;
6668                inherit: "default" 0.0;
6669             }
6670             description { state: "visible" 0.0; //when icon is visible
6671                align: 0.0 0.0;
6672                rel1 {
6673                   relative: 1.0 0.0;
6674                   to: "icon_rect";
6675                }
6676                rel2.to: "icon_rect";
6677                fixed: 1 0;
6678                min: BUTTON_HIDDEN_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
6679                color: 0 0 0 0;
6680             }
6681          }
6682          part { name: "elm.swallow.content";
6683             type: SWALLOW;
6684             scale: 1;
6685             clip_to: "clipper";
6686             description { state: "default" 0.0;
6687                visible: 0;
6688                align: 0.0 0.5;
6689                rel1 {
6690                   relative: 1.0 1.0;
6691                   to: "padding_left_top";
6692                }
6693                rel2 {
6694                   relative: 1.0 0.0;
6695                   to_x: "padding_left_top";
6696                   to_y: "padding_right_bottom";
6697                }
6698                fixed: 1 0;
6699             }
6700             description { state: "visible" 0.0;
6701                fixed: 1 0;
6702                align: 0.0 0.5;
6703                rel1 {
6704                   relative: 1.0 1.0;
6705                   to: "padding_left_top";
6706                }
6707                rel2 {
6708                   relative: 1.0 0.0;
6709                   to_x: "padding_left_top";
6710                   to_y: "padding_right_bottom";
6711                }
6712                aspect: 1.0 1.0;
6713                aspect_preference: VERTICAL;
6714             }
6715             description { state: "icononly" 0.0;
6716                min: BUTTON_HIDDEN_ICON_ICONONLY_MIN_INC;
6717                rel1 {
6718                   relative: 1.0 1.0;
6719                   to: "padding_left_top";
6720                }
6721                rel2 {
6722                   relative: 1.0 0.0;
6723                   to_x: "padding_left_top";
6724                   to_y: "padding_right_bottom";
6725                }
6726                aspect: 1.0 1.0;
6727                aspect_preference: VERTICAL;
6728             }
6729          }
6730          part { name: "elm.text";
6731             type: TEXT;
6732             mouse_events: 0;
6733             scale: 1;
6734             clip_to: "clipper";
6735             description { state: "default" 0.0;
6736                visible: 0;
6737                rel1 {
6738                   relative: 1.0 1.0;
6739                   to_x: "padding_icon_text";
6740                   to_y: "padding_left_top";
6741                }
6742                rel2 {
6743                   relative: 0.0 0.0;
6744                   to: "padding_right_bottom";
6745                }
6746                color: BUTTON_HIDDEN_BUTTON_TEXT_NORMAL_COLOR_INC;
6747                text {
6748                   font: "SLP:style=Medium";
6749                   size: BUTTON_HIDDEN_FONT_SIZE_INC;
6750                   min: 0 0;
6751                   text_class: "slp_medium";
6752                }
6753             }
6754             description { state: "visible" 0.0;
6755                inherit: "default" 0.0;
6756                visible: 1;
6757                min: BUTTON_HIDDEN_TEXT_MIN_INC;
6758             }
6759             description { state: "clicked" 0.0;
6760                inherit: "default" 0.0;
6761                visible: 1;
6762                min: 0 0;
6763                color: BUTTON_HIDDEN_BUTTON_TEXT_PRESSED_COLOR_INC;
6764             }
6765             description { state: "disabled" 0.0;
6766                inherit: "default" 0.0;
6767                color: 0 0 0 128;
6768             }
6769             description { state: "disabled_visible" 0.0;
6770                inherit: "default" 0.0;
6771                color: BUTTON_HIDDEN_BUTTON_TEXT_DISABLED_COLOR_INC;
6772                visible: 1;
6773                min: BUTTON_HIDDEN_TEXT_MIN_INC;
6774             }
6775             description { state: "focused" 0.0;
6776                inherit: "default" 0.0;
6777                visible: 1;
6778                min: 0 0;
6779                color: BUTTON_HIDDEN_BUTTON_TEXT_FOCUSED_COLOR_INC;
6780             }
6781          }
6782          part { name: "over2";
6783             type: RECT;
6784             repeat_events: 1;
6785             ignore_flags: ON_HOLD;
6786             description { state: "default" 0.0;
6787                color: 0 0 0 0;
6788             }
6789          }
6790          part { name: "over3";
6791             type: RECT;
6792             repeat_events: 1;
6793             description { state: "default" 0.0;
6794                color: 0 0 0 0;
6795             }
6796          }
6797          part { name: "clipper";
6798             type: RECT;
6799             description { state: "default" 0.0;
6800                color: 255 255 255 255;
6801             }
6802          }
6803          part { name: "disabler";
6804             type: RECT;
6805             description { state: "default" 0.0;
6806                color: 0 0 0 0;
6807                visible: 0;
6808             }
6809             description { state: "disabled" 0.0;
6810                inherit: "default" 0.0;
6811                visible: 1;
6812             }
6813          }
6814       }
6815       programs {
6816          program { name: "button_click";
6817             signal: "mouse,down,1";
6818             source: "over2";
6819             action: SIGNAL_EMIT "elm,action,press" "";
6820             after: "button_click_anim";
6821          }
6822          program { name: "button_click_anim";
6823             action: STATE_SET "clicked" 0.0;
6824             target: "button_image";
6825             after: "text_clicked";
6826          }
6827          program { name: "text_clicked";
6828             script {
6829                new st[31];
6830                new Float:vl;
6831                get_state(PART:"elm.text", st, 30, vl);
6832                if (!strcmp(st, "visible"))
6833                  set_state(PART:"elm.text", "clicked", 0.0);
6834             }
6835          }
6836          program { name: "button_unpress";
6837             action: SIGNAL_EMIT "elm,action,unpress" "";
6838          }
6839          program { name: "button_mouseout_clicked";
6840             signal: "mouse,up,1";
6841             source: "over3";
6842             script {
6843                new st[31];
6844                new Float:vl;
6845                get_state(PART:"elm.swallow.content", st, 30, vl);
6846                if (strcmp(st, "icononly"))
6847                  {
6848                     emit("elm,action,default,text,set", "");
6849                     set_state(PART:"elm.text", "visible", 0.0);
6850                  }
6851                if (get_int(button_state) != BUTTON_STATE_DISABLED)
6852                  set_state(PART:"button_image", "default", 0.0);
6853             }
6854             after: button_unpress;
6855          }
6856          program { name: "touch_snd";
6857             signal: "mouse,clicked,1";
6858             source: "over2";
6859             action: PLAY_SAMPLE "touch_sound" 1.0;
6860             after: button_unclick3;
6861          }
6862          program { name: "button_unclick3";
6863             action: SIGNAL_EMIT "elm,action,click" "";
6864          }
6865          program { name: "text_show";
6866             signal: "elm,state,text,visible";
6867             source: "elm";
6868             script {
6869                new st[31];
6870                new Float:vl;
6871                get_state(PART:"elm.swallow.content", st, 30, vl);
6872                if (!strcmp(st, "icononly"))
6873                  {
6874                     set_state(PART:"elm.swallow.content", "visible", 0.0);
6875                     set_state(PART:"padding_icon_text", "visible", 0.0);
6876                  }
6877                if (get_int(button_state) != BUTTON_STATE_DISABLED)
6878                  set_state(PART:"elm.text", "visible", 0.0);
6879                else
6880                  set_state(PART:"elm.text", "disabled_visible", 0.0);
6881             }
6882          }
6883          program { name: "text_hide";
6884             signal: "elm,state,text,hidden";
6885             source: "elm";
6886             script {
6887                new st[31];
6888                new Float:vl;
6889                get_state(PART:"elm.swallow.content", st, 30, vl);
6890                if (!strcmp(st, "visible"))
6891                  {
6892                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
6893                     set_state(PART:"padding_icon_text", "icononly", 0.0);
6894                  }
6895                set_state(PART:"elm.text", "default", 0.0);
6896             }
6897          }
6898          program { name: "icon_show";
6899             signal: "elm,state,icon,visible";
6900             source: "elm";
6901             script {
6902                new st[31];
6903                new Float:vl;
6904                get_state(PART:"elm.text", st, 30, vl);
6905                if (!strcmp(st, "visible"))
6906                  {
6907                     set_state(PART:"elm.swallow.content", "visible", 0.0);
6908                     set_state(PART:"padding_icon_text", "visible", 0.0);
6909                  }
6910                else
6911                  {
6912                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
6913                     set_state(PART:"padding_icon_text", "icononly", 0.0);
6914                  }
6915             }
6916          }
6917          program { name: "icon_hide";
6918             signal: "elm,state,icon,hidden";
6919             source: "elm";
6920             action: STATE_SET "default" 0.0;
6921             target: "elm.swallow.content";
6922             target: "padding_icon_text";
6923          }
6924          program { name: "disable";
6925             signal: "elm,state,disabled";
6926             source: "elm";
6927             action: STATE_SET "disabled" 0.0;
6928             target: "button_image";
6929             target: "disabler";
6930             after: "disable_text";
6931          }
6932          program { name: "disable_text";
6933             script {
6934                new st[31];
6935                new Float:vl;
6936                get_state(PART:"elm.text", st, 30, vl);
6937                if (!strcmp(st, "visible"))
6938                  set_state(PART:"elm.text", "disabled_visible", 0.0);
6939                else
6940                  set_state(PART:"elm.text", "disabled", 0.0);
6941                set_int(button_state, BUTTON_STATE_DISABLED);
6942             }
6943          }
6944          program { name: "enable";
6945             signal: "elm,state,enabled";
6946             source: "elm";
6947             action: STATE_SET "default" 0.0;
6948             target: "button_image";
6949             target: "disabler";
6950             after: "enable_text";
6951          }
6952          program { name: "enable_text";
6953             script {
6954                new st[31];
6955                new Float:vl;
6956                get_state(PART:"elm.text", st, 30, vl);
6957                if (!strcmp(st, "disabled_visible"))
6958                  set_state(PART:"elm.text", "visible", 0.0);
6959                else
6960                  set_state(PART:"elm.text", "default", 0.0);
6961                set_int(button_state, BUTTON_STATE_ENABLED);
6962             }
6963          }
6964          program { name: "focused";
6965             //signal: "elm,action,focus";
6966             //source: "elm";
6967             action: STATE_SET "focused" 0.0;
6968             target: "button_image";
6969             target: "elm.text";
6970          }
6971          program { name: "unfocused";
6972             //signal: "elm,action,unfocus";
6973             //source: "elm";
6974             action: STATE_SET "default" 0.0;
6975             target: "button_image";
6976             after: "unfocus_text";
6977          }
6978          program { name: "unfocus_text";
6979             action: STATE_SET "visible" 0.0;
6980             target: "elm.text";
6981          }
6982       }
6983    }
6984
6985 ///////////////////////////////////////////////////////////////////////////////////////
6986    group { name: "elm/button/base/picker/bar/default";
6987       images {
6988          image: "00_picker_btn_normal.png" COMP;
6989          image: "00_picker_btn_press.png" COMP;
6990          image: "00_picker_btn_normal_focus.png" COMP;
6991       }
6992       script {
6993          public button_state = BUTTON_STATE_ENABLED;
6994       }
6995       parts {
6996          part { name: "button_image";
6997             scale: 1;
6998             description { state: "default" 0.0;
6999                min: BUTTON_PICKER_BAR_DEFAULT_BG_DEFAULT_MIN_INC;
7000                image {
7001                   normal: "00_picker_btn_normal.png";
7002                   border: BUTTON_PICKER_BAR_DEFAULT_BG_DEFAULT_IMAGE_BORDER_INC;
7003                   border_scale: 1;
7004                }
7005             }
7006             description { state: "clicked" 0.0;
7007                inherit: "default" 0.0;
7008                image.normal: "00_picker_btn_press.png";
7009             }
7010             description { state: "disabled" 0.0;
7011                inherit: "default" 0.0;
7012             }
7013             description { state: "focused" 0.0;
7014                inherit: "default" 0.0;
7015                image.normal: "00_picker_btn_normal_focus.png";
7016             }
7017          }
7018          part { name: "padding_left_top";
7019             type: RECT;
7020             scale: 1;
7021             mouse_events: 0;
7022             description { state: "default" 0.0;
7023                align: 0.0 0.0;
7024                rel2.relative: 0.0 0.0;
7025                min: BUTTON_PICKER_BAR_DEFAULT_PADDING_MIN_INC;
7026                fixed: 1 1;
7027                visible: 0;
7028             }
7029          }
7030          part { name: "padding_right_bottom";
7031             type: RECT;
7032             scale: 1;
7033             mouse_events: 0;
7034             description { state: "default" 0.0;
7035                align: 1.0 1.0;
7036                rel1.relative: 1.0 1.0;
7037                min: BUTTON_PICKER_BAR_DEFAULT_PADDING_MIN_INC;
7038                fixed: 1 1;
7039                visible: 0;
7040             }
7041          }
7042          part { name: "icon_rect";
7043             type: RECT;
7044             scale: 1;
7045             mouse_events: 0;
7046             description { state: "default" 0.0;
7047                min: BUTTON_PICKER_BAR_DEFAULT_ICON_RECT_DEFAULT_MIN_INC;
7048                fixed: 1 0;
7049                rel1 {
7050                   relative: 0.0 1.0;
7051                   to_x: "elm.swallow.content";
7052                   to_y: "padding_left_top";
7053                }
7054                rel2 {
7055                   relative: 1.0 0.0;
7056                   to_x: "elm.swallow.content";
7057                   to_y: "padding_right_bottom";
7058                }
7059                align: 0.0 0.5;
7060                color: 0 0 0 0;
7061             }
7062          }
7063          part { name: "padding_icon_text";
7064             type: RECT;
7065             scale: 1;
7066             mouse_events: 0;
7067             description { state: "default" 0.0; //when only icon or no icon is there
7068                align: 0.0 0.0;
7069                rel1 {
7070                   relative: 1.0 0.0;
7071                   to: "icon_rect";
7072                }
7073                rel2.to: "icon_rect";
7074                fixed: 1 0;
7075                min: 0 0;
7076                color: 0 0 0 0;
7077             }
7078             description { state: "icononly" 0.0;
7079                inherit: "default" 0.0;
7080             }
7081             description { state: "visible" 0.0; //when icon is visible
7082                align: 0.0 0.0;
7083                rel1 {
7084                   relative: 1.0 0.0;
7085                   to: "icon_rect";
7086                }
7087                rel2.to: "icon_rect";
7088                fixed: 1 0;
7089                min: BUTTON_PICKER_BAR_DEFAULT_PADDING_ICON_RECT_TEXT_MIN_INC;
7090                color: 0 0 0 0;
7091             }
7092          }
7093          part { name: "elm.swallow.content";
7094             type: SWALLOW;
7095             scale: 1;
7096             clip_to: "clipper";
7097             description { state: "default" 0.0;
7098                visible: 0;
7099                align: 0.0 0.5;
7100                rel1 {
7101                   relative: 1.0 1.0;
7102                   to: "padding_left_top";
7103                }
7104                rel2 {
7105                   relative: 1.0 0.0;
7106                   to_x: "padding_left_top";
7107                   to_y: "padding_right_bottom";
7108                }
7109                fixed: 1 0;
7110             }
7111             description { state: "visible" 0.0;
7112                fixed: 1 0;
7113                align: 0.0 0.5;
7114                rel1 {
7115                   relative: 1.0 1.0;
7116                   to: "padding_left_top";
7117                }
7118                rel2 {
7119                   relative: 1.0 0.0;
7120                   to_x: "padding_left_top";
7121                   to_y: "padding_right_bottom";
7122                }
7123                aspect: 1.0 1.0;
7124                aspect_preference: VERTICAL;
7125             }
7126             description { state: "icononly" 0.0;
7127                min: BUTTON_PICKER_BAR_DEFAULT_CONTENT_ICONONLY_MIN_INC;
7128                rel1 {
7129                   relative: 1.0 1.0;
7130                   to: "padding_left_top";
7131                }
7132                rel2 {
7133                   relative: 1.0 0.0;
7134                   to_x: "padding_left_top";
7135                   to_y: "padding_right_bottom";
7136                }
7137                aspect: 1.0 1.0;
7138                aspect_preference: VERTICAL;
7139             }
7140          }
7141          part { name: "elm.text";
7142             type: TEXT;
7143             mouse_events: 0;
7144             scale: 1;
7145             clip_to: "clipper";
7146             description { state: "default" 0.0;
7147                visible: 0;
7148                rel1 {
7149                   relative: 1.0 1.0;
7150                   to_x: "padding_icon_text";
7151                   to_y: "padding_left_top";
7152                }
7153                rel2 {
7154                   relative: 0.0 0.0;
7155                   to: "padding_right_bottom";
7156                }
7157                color: BUTTON_PICKER_TEXT_DEFAULT_COLOR_INC;
7158                text {
7159                   font: "SLP:style=Medium";
7160                   size: BUTTON_PICKER_BAR_DEFAULT_TEXT_FONT_SIZE_INC;
7161                   min: 1 0;
7162                   max: 0 0;
7163                   text_class: "slp_medium";
7164                }
7165             }
7166             description { state: "visible" 0.0;
7167                inherit: "default" 0.0;
7168                visible: 1;
7169                min: BUTTON_PICKER_BAR_DEFAULT_TEXT_VISIBLE_MIN_INC;
7170             }
7171             description { state: "clicked" 0.0;
7172                inherit: "default" 0.0;
7173                visible: 1;
7174                min: 0 0;
7175                color: BUTTON_PICKER_TEXT_CLICKED_COLOR_INC;
7176             }
7177             description { state: "disabled" 0.0;
7178                inherit: "default" 0.0;
7179                color: BUTTON_PICKER_TEXT_DISABLED_COLOR_INC;
7180             }
7181             description { state: "disabled_visible" 0.0;
7182                inherit: "default" 0.0;
7183                color: BUTTON_PICKER_TEXT_DISABLED_COLOR_INC;
7184                visible: 1;
7185                min: BUTTON_PICKER_BAR_DEFAULT_TEXT_VISIBLE_MIN_INC;
7186             }
7187             description { state: "focused" 0.0;
7188                inherit: "default" 0.0;
7189                visible: 1;
7190                min: 0 0;
7191                color: BUTTON_PICKER_TEXT_FOCUSED_COLOR_INC;
7192             }
7193          }
7194          part { name: "over2";
7195             type: RECT;
7196             repeat_events: 1;
7197             ignore_flags: ON_HOLD;
7198             description { state: "default" 0.0;
7199                color: 0 0 0 0;
7200             }
7201          }
7202          part { name: "over3";
7203             type: RECT;
7204             repeat_events: 1;
7205             description { state: "default" 0.0;
7206                color: 0 0 0 0;
7207             }
7208          }
7209          part { name: "clipper";
7210             type: RECT;
7211             description { state: "default" 0.0;
7212                color: 255 255 255 255;
7213             }
7214          }
7215          part { name: "disabler";
7216             type: RECT;
7217             description { state: "default" 0.0;
7218                color: 0 0 0 0;
7219                visible: 0;
7220             }
7221             description { state: "disabled" 0.0;
7222                inherit: "default" 0.0;
7223                visible: 1;
7224             }
7225          }
7226       }
7227       programs {
7228          program { name: "button_click";
7229             signal: "mouse,down,1";
7230             source: "over2";
7231             action: SIGNAL_EMIT "elm,action,press" "";
7232             after: "button_click_anim";
7233          }
7234          program { name: "button_click_anim";
7235             action: STATE_SET "clicked" 0.0;
7236             target: "button_image";
7237             after: "text_clicked";
7238          }
7239          program { name: "text_clicked";
7240             script {
7241                new st[31];
7242                new Float:vl;
7243                get_state(PART:"elm.text", st, 30, vl);
7244                if (!strcmp(st, "visible"))
7245                  set_state(PART:"elm.text", "clicked", 0.0);
7246             }
7247          }
7248          program { name: "button_unpress";
7249             action: SIGNAL_EMIT "elm,action,unpress" "";
7250          }
7251          program { name: "button_mouseout_clicked";
7252             signal: "mouse,up,1";
7253             source: "over3";
7254             script {
7255                new st[31];
7256                new Float:vl;
7257                get_state(PART:"elm.swallow.content", st, 30, vl);
7258                if (strcmp(st, "icononly"))
7259                  {
7260                     emit("elm,action,default,text,set", "");
7261                     set_state(PART:"elm.text", "visible", 0.0);
7262                  }
7263                if (get_int(button_state) != BUTTON_STATE_DISABLED)
7264                  set_state(PART:"button_image", "default", 0.0);
7265             }
7266             after: button_unpress;
7267          }
7268          program { name: "touch_snd";
7269             signal: "mouse,clicked,1";
7270             source: "over2";
7271             action: PLAY_SAMPLE "touch_sound" 1.0;
7272             after: button_unclick3;
7273          }
7274          program { name: "button_unclick3";
7275             action: SIGNAL_EMIT "elm,action,click" "";
7276          }
7277          program { name: "text_show";
7278             signal: "elm,state,text,visible";
7279             source: "elm";
7280             script {
7281                new st[31];
7282                new Float:vl;
7283                get_state(PART:"elm.swallow.content", st, 30, vl);
7284                if (!strcmp(st, "icononly"))
7285                  {
7286                     set_state(PART:"elm.swallow.content", "visible", 0.0);
7287                     set_state(PART:"padding_icon_text", "visible", 0.0);
7288                  }
7289                if (get_int(button_state) != BUTTON_STATE_DISABLED)
7290                  set_state(PART:"elm.text", "visible", 0.0);
7291                else
7292                  set_state(PART:"elm.text", "disabled_visible", 0.0);
7293             }
7294          }
7295          program { name: "text_hide";
7296             signal: "elm,state,text,hidden";
7297             source: "elm";
7298             script {
7299                new st[31];
7300                new Float:vl;
7301                get_state(PART:"elm.swallow.content", st, 30, vl);
7302                if (!strcmp(st, "visible"))
7303                  {
7304                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
7305                     set_state(PART:"padding_icon_text", "icononly", 0.0);
7306                  }
7307                set_state(PART:"elm.text", "default", 0.0);
7308             }
7309          }
7310          program { name: "icon_show";
7311             signal: "elm,state,icon,visible";
7312             source: "elm";
7313             script {
7314                new st[31];
7315                new Float:vl;
7316                get_state(PART:"elm.text", st, 30, vl);
7317                if (!strcmp(st, "visible"))
7318                  {
7319                     set_state(PART:"elm.swallow.content", "visible", 0.0);
7320                     set_state(PART:"padding_icon_text", "visible", 0.0);
7321                  }
7322                else
7323                  {
7324                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
7325                     set_state(PART:"padding_icon_text", "icononly", 0.0);
7326                  }
7327             }
7328          }
7329          program { name: "icon_hide";
7330             signal: "elm,state,icon,hidden";
7331             source: "elm";
7332             action: STATE_SET "default" 0.0;
7333             target: "elm.swallow.content";
7334             target: "padding_icon_text";
7335          }
7336          program { name: "disable";
7337             signal: "elm,state,disabled";
7338             source: "elm";
7339             action: STATE_SET "disabled" 0.0;
7340             target: "button_image";
7341             target: "disabler";
7342             after: "disable_text";
7343          }
7344          program { name: "disable_text";
7345             script {
7346                new st[31];
7347                new Float:vl;
7348                get_state(PART:"elm.text", st, 30, vl);
7349                if (!strcmp(st, "visible"))
7350                  set_state(PART:"elm.text", "disabled_visible", 0.0);
7351                else
7352                  set_state(PART:"elm.text", "disabled", 0.0);
7353                set_int(button_state, BUTTON_STATE_DISABLED);
7354             }
7355          }
7356          program { name: "enable";
7357             signal: "elm,state,enabled";
7358             source: "elm";
7359             action: STATE_SET "default" 0.0;
7360             target: "button_image";
7361             target: "disabler";
7362             after: "enable_text";
7363          }
7364          program { name: "enable_text";
7365             script {
7366                new st[31];
7367                new Float:vl;
7368                get_state(PART:"elm.text", st, 30, vl);
7369                if (!strcmp(st, "disabled_visible"))
7370                  set_state(PART:"elm.text", "visible", 0.0);
7371                else
7372                  set_state(PART:"elm.text", "default", 0.0);
7373                set_int(button_state, BUTTON_STATE_ENABLED);
7374             }
7375          }
7376          program { name: "focused";
7377             //signal: "elm,action,focus";
7378             //source: "elm";
7379             action: STATE_SET "focused" 0.0;
7380             target: "button_image";
7381             target: "elm.text";
7382          }
7383          program { name: "unfocused";
7384             //signal: "elm,action,unfocus";
7385             //source: "elm";
7386             action: STATE_SET "default" 0.0;
7387             target: "button_image";
7388             after: "unfocus_text";
7389          }
7390          program { name: "unfocus_text";
7391             action: STATE_SET "visible" 0.0;
7392             target: "elm.text";
7393          }
7394       }
7395    }
7396
7397 ///////////////////////////////////////////////////////////////////////////////////////
7398    group { name: "elm/button/base/picker/prev/text/default";
7399       alias: "elm/button/base/picker/next/text/default";
7400       images {
7401          image: "00_picker_btn_normal.png" COMP;
7402          image: "00_picker_btn_press.png" COMP;
7403          image: "00_picker_btn_normal_focus.png" COMP;
7404       }
7405       script {
7406          public button_state = BUTTON_STATE_ENABLED;
7407       }
7408       parts {
7409          part { name: "button_image";
7410             scale: 1;
7411             description { state: "default" 0.0;
7412                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_BG_DEFAULT_MIN_INC;
7413                image {
7414                   normal: "00_picker_btn_normal.png";
7415                   border: BUTTON_PICKER_PREV_TEXT_DEFAULT_BG_DEFAULT_BORDER_INC;
7416                   border_scale: 1;
7417                }
7418             }
7419             description { state: "clicked" 0.0;
7420                inherit: "default" 0.0;
7421                image.normal: "00_picker_btn_press.png";
7422             }
7423             description { state: "disabled" 0.0;
7424                inherit: "default" 0.0;
7425                color: 0 0 0 128;
7426             }
7427             description { state: "focused" 0.0;
7428                inherit: "default" 0.0;
7429                image.normal: "00_picker_btn_normal_focus.png";
7430             }
7431          }
7432          part { name: "padding_left_top";
7433             type: RECT;
7434             scale: 1;
7435             mouse_events: 0;
7436             description { state: "default" 0.0;
7437                align: 0.0 0.0;
7438                rel2.relative: 0.0 0.0;
7439                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_PADDING_MIN_INC;
7440                fixed: 1 1;
7441                visible: 0;
7442             }
7443          }
7444          part { name: "padding_right_bottom";
7445             type: RECT;
7446             scale: 1;
7447             mouse_events: 0;
7448             description { state: "default" 0.0;
7449                align: 1.0 1.0;
7450                rel1.relative: 1.0 1.0;
7451                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_PADDING_MIN_INC;
7452                fixed: 1 1;
7453                visible: 0;
7454             }
7455          }
7456          part { name: "icon_rect";
7457             type: RECT;
7458             scale: 1;
7459             mouse_events: 0;
7460             description { state: "default" 0.0;
7461                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_ICON_RECT_MIN_INC;
7462                fixed: 1 0;
7463                rel1 {
7464                   relative: 0.0 1.0;
7465                   to_x: "elm.swallow.content";
7466                   to_y: "padding_left_top";
7467                }
7468                rel2 {
7469                   relative: 1.0 0.0;
7470                   to_x: "elm.swallow.content";
7471                   to_y: "padding_right_bottom";
7472                }
7473                align: 0.0 0.5;
7474                color: 0 0 0 0;
7475             }
7476          }
7477          part { name: "padding_icon_text";
7478             type: RECT;
7479             scale: 1;
7480             mouse_events: 0;
7481             description { state: "default" 0.0; //when only icon or no icon is there
7482                align: 0.0 0.0;
7483                rel1 {
7484                   relative: 1.0 0.0;
7485                   to: "icon_rect";
7486                }
7487                rel2.to: "icon_rect";
7488                fixed: 1 0;
7489                min: 0 0;
7490                color: 0 0 0 0;
7491             }
7492             description { state: "icononly" 0.0;
7493                inherit: "default" 0.0;
7494             }
7495             description { state: "visible" 0.0; //when icon is visible
7496                align: 0.0 0.0;
7497                rel1 {
7498                   relative: 1.0 0.0;
7499                   to: "icon_rect";
7500                }
7501                rel2.to: "icon_rect";
7502                fixed: 1 0;
7503                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_PADDING_ICON_RECT_TEXT_MIN_INC;
7504                color: 0 0 0 0;
7505             }
7506          }
7507          part { name: "elm.swallow.content";
7508             type: SWALLOW;
7509             scale: 1;
7510             clip_to: "clipper";
7511             description { state: "default" 0.0;
7512                visible: 0;
7513                align: 0.0 0.5;
7514                rel1 {
7515                   relative: 1.0 1.0;
7516                   to: "padding_left_top";
7517                }
7518                rel2 {
7519                   relative: 1.0 0.0;
7520                   to_x: "padding_left_top";
7521                   to_y: "padding_right_bottom";
7522                }
7523                fixed: 1 0;
7524             }
7525             description { state: "visible" 0.0;
7526                fixed: 1 0;
7527                align: 0.0 0.5;
7528                rel1 {
7529                   relative: 1.0 1.0;
7530                   to: "padding_left_top";
7531                }
7532                rel2 {
7533                   relative: 1.0 0.0;
7534                   to_x: "padding_left_top";
7535                   to_y: "padding_right_bottom";
7536                }
7537                aspect: 1.0 1.0;
7538                aspect_preference: VERTICAL;
7539             }
7540             description { state: "icononly" 0.0;
7541                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_CONTENT_ICON_ONLY_MIN_INC;
7542                rel1 {
7543                   relative: 1.0 1.0;
7544                   to: "padding_left_top";
7545                }
7546                rel2 {
7547                   relative: 1.0 0.0;
7548                   to_x: "padding_left_top";
7549                   to_y: "padding_right_bottom";
7550                }
7551                aspect: 1.0 1.0;
7552                aspect_preference: VERTICAL;
7553             }
7554          }
7555          part { name: "elm.text";
7556             type: TEXT;
7557             mouse_events: 0;
7558             scale: 1;
7559             clip_to: "clipper";
7560             description { state: "default" 0.0;
7561                visible: 0;
7562                rel1 {
7563                   relative: 1.0 1.0;
7564                   to_x: "padding_icon_text";
7565                   to_y: "padding_left_top";
7566                }
7567                rel2 {
7568                   relative: 0.0 0.0;
7569                   to: "padding_right_bottom";
7570                }
7571                color: BUTTON_PICKER_TEXT_DEFAULT_COLOR_INC;
7572                text {
7573                   font: "SLP:style=Medium";
7574                   size: BUTTON_PICKER_PREV_TEXT_DEFAULT_TEXT_FONT_SIZE_INC;
7575                   min: 1 0;
7576                   max: 1 0;
7577                   text_class: "slp_medium";
7578                }
7579             }
7580             description { state: "visible" 0.0;
7581                inherit: "default" 0.0;
7582                visible: 1;
7583                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_TEXT_VISIBLE_MIN_INC;
7584             }
7585             description { state: "clicked" 0.0;
7586                inherit: "default" 0.0;
7587                visible: 1;
7588                min: 0 0;
7589                color: BUTTON_PICKER_TEXT_CLICKED_COLOR_INC;
7590             }
7591             description { state: "disabled" 0.0;
7592                inherit: "default" 0.0;
7593                color: BUTTON_PICKER_TEXT_DISABLED_COLOR_INC;
7594             }
7595             description { state: "disabled_visible" 0.0;
7596                inherit: "default" 0.0;
7597                color: BUTTON_PICKER_TEXT_DISABLED_COLOR_INC;
7598                visible: 1;
7599                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_TEXT_VISIBLE_MIN_INC;
7600             }
7601             description { state: "focused" 0.0;
7602                inherit: "default" 0.0;
7603                visible: 1;
7604                min: 0 0;
7605                color: BUTTON_PICKER_TEXT_FOCUSED_COLOR_INC;
7606             }
7607          }
7608          part { name: "over2";
7609             type: RECT;
7610             repeat_events: 1;
7611             ignore_flags: ON_HOLD;
7612             description { state: "default" 0.0;
7613                color: 0 0 0 0;
7614             }
7615          }
7616          part { name: "over3";
7617             type: RECT;
7618             repeat_events: 1;
7619             description { state: "default" 0.0;
7620                color: 0 0 0 0;
7621             }
7622          }
7623          part { name: "clipper";
7624             type: RECT;
7625             description { state: "default" 0.0;
7626                color: 255 255 255 255;
7627             }
7628          }
7629          part { name: "disabler";
7630             type: RECT;
7631             description { state: "default" 0.0;
7632                color: 0 0 0 0;
7633                visible: 0;
7634             }
7635             description { state: "disabled" 0.0;
7636                inherit: "default" 0.0;
7637                visible: 1;
7638             }
7639          }
7640       }
7641       programs {
7642          program { name: "button_click";
7643             signal: "mouse,down,1";
7644             source: "over2";
7645             action: SIGNAL_EMIT "elm,action,press" "";
7646             after: "button_click_anim";
7647          }
7648          program { name: "button_click_anim";
7649             action: STATE_SET "clicked" 0.0;
7650             target: "button_image";
7651             after: "text_clicked";
7652          }
7653          program { name: "text_clicked";
7654             script {
7655                new st[31];
7656                new Float:vl;
7657                get_state(PART:"elm.text", st, 30, vl);
7658                if (!strcmp(st, "visible"))
7659                  set_state(PART:"elm.text", "clicked", 0.0);
7660             }
7661          }
7662          program { name: "button_unpress";
7663             action: SIGNAL_EMIT "elm,action,unpress" "";
7664          }
7665          program { name: "button_mouseout_clicked";
7666             signal: "mouse,up,1";
7667             source: "over3";
7668             script {
7669                new st[31];
7670                new Float:vl;
7671                get_state(PART:"elm.swallow.content", st, 30, vl);
7672                if (strcmp(st, "icononly"))
7673                  {
7674                     emit("elm,action,default,text,set", "");
7675                     set_state(PART:"elm.text", "visible", 0.0);
7676                  }
7677                if (get_int(button_state) != BUTTON_STATE_DISABLED)
7678                  set_state(PART:"button_image", "default", 0.0);
7679             }
7680             after: button_unpress;
7681          }
7682          program { name: "touch_snd";
7683             signal: "mouse,clicked,1";
7684             source: "over2";
7685             action: PLAY_SAMPLE "touch_sound" 1.0;
7686             after: button_unclick3;
7687          }
7688          program { name: "button_unclick3";
7689             action: SIGNAL_EMIT "elm,action,click" "";
7690          }
7691          program { name: "text_show";
7692             signal: "elm,state,text,visible";
7693             source: "elm";
7694             script {
7695                new st[31];
7696                new Float:vl;
7697                get_state(PART:"elm.swallow.content", st, 30, vl);
7698                if (!strcmp(st, "icononly"))
7699                  {
7700                     set_state(PART:"elm.swallow.content", "visible", 0.0);
7701                     set_state(PART:"padding_icon_text", "visible", 0.0);
7702                  }
7703                if (get_int(button_state) != BUTTON_STATE_DISABLED)
7704                  set_state(PART:"elm.text", "visible", 0.0);
7705                else
7706                  set_state(PART:"elm.text", "disabled_visible", 0.0);
7707             }
7708          }
7709          program { name: "text_hide";
7710             signal: "elm,state,text,hidden";
7711             source: "elm";
7712             script {
7713                new st[31];
7714                new Float:vl;
7715                get_state(PART:"elm.swallow.content", st, 30, vl);
7716                if (!strcmp(st, "visible"))
7717                  {
7718                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
7719                     set_state(PART:"padding_icon_text", "icononly", 0.0);
7720                  }
7721                set_state(PART:"elm.text", "default", 0.0);
7722             }
7723          }
7724          program { name: "icon_show";
7725             signal: "elm,state,icon,visible";
7726             source: "elm";
7727             script {
7728                new st[31];
7729                new Float:vl;
7730                get_state(PART:"elm.text", st, 30, vl);
7731                if (!strcmp(st, "visible"))
7732                  {
7733                     set_state(PART:"elm.swallow.content", "visible", 0.0);
7734                     set_state(PART:"padding_icon_text", "visible", 0.0);
7735                  }
7736                else
7737                  {
7738                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
7739                     set_state(PART:"padding_icon_text", "icononly", 0.0);
7740                  }
7741             }
7742          }
7743          program { name: "icon_hide";
7744             signal: "elm,state,icon,hidden";
7745             source: "elm";
7746             action: STATE_SET "default" 0.0;
7747             target: "elm.swallow.content";
7748             target: "padding_icon_text";
7749          }
7750          program { name: "disable";
7751             signal: "elm,state,disabled";
7752             source: "elm";
7753             action: STATE_SET "disabled" 0.0;
7754             target: "button_image";
7755             target: "disabler";
7756             after: "disable_text";
7757          }
7758          program { name: "disable_text";
7759             script {
7760                new st[31];
7761                new Float:vl;
7762                get_state(PART:"elm.text", st, 30, vl);
7763                if (!strcmp(st, "visible"))
7764                  set_state(PART:"elm.text", "disabled_visible", 0.0);
7765                else
7766                  set_state(PART:"elm.text", "disabled", 0.0);
7767                set_int(button_state, BUTTON_STATE_DISABLED);
7768             }
7769          }
7770          program { name: "enable";
7771             signal: "elm,state,enabled";
7772             source: "elm";
7773             action: STATE_SET "default" 0.0;
7774             target: "button_image";
7775             target: "disabler";
7776             after: "enable_text";
7777          }
7778          program { name: "enable_text";
7779             script {
7780                new st[31];
7781                new Float:vl;
7782                get_state(PART:"elm.text", st, 30, vl);
7783                if (!strcmp(st, "disabled_visible"))
7784                  set_state(PART:"elm.text", "visible", 0.0);
7785                else
7786                  set_state(PART:"elm.text", "default", 0.0);
7787                set_int(button_state, BUTTON_STATE_ENABLED);
7788             }
7789          }
7790          program { name: "focused";
7791             //signal: "elm,action,focus";
7792             //source: "elm";
7793             action: STATE_SET "focused" 0.0;
7794             target: "button_image";
7795             target: "elm.text";
7796          }
7797          program { name: "unfocused";
7798             //signal: "elm,action,unfocus";
7799             //source: "elm";
7800             action: STATE_SET "default" 0.0;
7801             target: "button_image";
7802             after: "unfocus_text";
7803          }
7804          program { name: "unfocus_text";
7805             action: STATE_SET "visible" 0.0;
7806             target: "elm.text";
7807          }
7808       }
7809    }
7810
7811 ///////////////////////////////////////////////////////////////////////////////////////
7812 #define BUTTON_CONTACT_STYLES(style_name, image_normal, image_press) \
7813    group { name: "elm/button/base/contact/"style_name; \
7814       images { \
7815          image: "00_contacts_circle_bg.png" COMP; \
7816          image: image_normal COMP; \
7817          image: image_press COMP; \
7818       } \
7819       parts { \
7820          part { name: "button_image"; \
7821             scale: 1; \
7822             description { state: "default" 0.0; \
7823                min: BUTTON_CONTACT_STYLE_BG_MIN_MAX_INC; \
7824                max: BUTTON_CONTACT_STYLE_BG_MIN_MAX_INC; \
7825                image.normal: "00_contacts_circle_bg.png"; \
7826                color: 255 255 255 255; \
7827             } \
7828             description { \
7829                state: "clicked" 0.0; \
7830                inherit: "default" 0.0; \
7831                image.normal: "00_contacts_circle_bg.png"; \
7832             } \
7833             description { \
7834                state: "disabled" 0.0; \
7835                inherit: "default" 0.0; \
7836                color: 255 255 255 128; \
7837             } \
7838          } \
7839          part { name: "button_center_part"; \
7840             scale: 1; \
7841             description { state: "default" 0.0; \
7842                min: BUTTON_CONTACT_STYLE_IMAGE_MIN_MAX_INC; \
7843                max: BUTTON_CONTACT_STYLE_IMAGE_MIN_MAX_INC; \
7844                image.normal: image_normal; \
7845                color: 255 255 255 255; \
7846             } \
7847             description { \
7848                state: "clicked" 0.0; \
7849                inherit: "default" 0.0; \
7850                image.normal: image_press; \
7851             } \
7852             description { \
7853                state: "disabled" 0.0; \
7854                inherit: "default" 0.0; \
7855                color: 255 255 255 128; \
7856             } \
7857          } \
7858          part { name: "over1"; \
7859             type: RECT; \
7860             ignore_flags: ON_HOLD; \
7861             description { state: "default" 0.0; \
7862                color: 0 0 0 0; \
7863             } \
7864          } \
7865          part { name: "over2"; \
7866             repeat_events: 1; \
7867             description { state: "default" 0.0; \
7868                color: 0 0 0 0; \
7869             } \
7870          } \
7871          part { name: "disabler"; \
7872             type: RECT; \
7873             description { state: "default" 0.0; \
7874                color: 0 0 0 0; \
7875                visible: 0; \
7876             } \
7877             description { state: "disabled" 0.0; \
7878                inherit: "default" 0.0; \
7879                visible: 1; \
7880             } \
7881          } \
7882       } \
7883       programs { \
7884          program { name: "button_click"; \
7885             signal: "mouse,down,1"; \
7886             source: "over1"; \
7887             action: SIGNAL_EMIT "elm,action,press" ""; \
7888             after: "button_click_anim"; \
7889          } \
7890          program { name: "button_click_anim"; \
7891             action: STATE_SET "clicked" 0.0; \
7892             target: "button_image"; \
7893             target: "button_center_part"; \
7894          } \
7895          program { name: "button_unclick"; \
7896             signal: "mouse,up,1"; \
7897             source: "over2"; \
7898             action: SIGNAL_EMIT "elm,action,unpress" ""; \
7899             after: "button_unclick_anim"; \
7900          } \
7901          program { name: "button_unclick_anim"; \
7902             action: STATE_SET "default" 0.0; \
7903             target: "button_image"; \
7904             target: "button_center_part"; \
7905          } \
7906          program { name: "touch_snd"; \
7907             signal: "mouse,clicked,1"; \
7908             source: "over1"; \
7909             action: PLAY_SAMPLE "touch_sound" 1.0; \
7910             after: button_unclick3; \
7911          } \
7912          program { name: "button_unclick3"; \
7913             action: SIGNAL_EMIT "elm,action,click" ""; \
7914          } \
7915          program { name: "disable"; \
7916             signal: "elm,state,disabled"; \
7917             source: "elm"; \
7918             action: STATE_SET "disabled" 0.0; \
7919             target: "disabler"; \
7920             target: "button_image"; \
7921             target: "button_center_part"; \
7922          } \
7923          program { name: "enable"; \
7924             signal: "elm,state,enabled"; \
7925             source: "elm"; \
7926             action: STATE_SET "default" 0.0; \
7927             target: "disabler"; \
7928             target: "button_image"; \
7929             target: "button_center_part"; \
7930          } \
7931       } \
7932    }
7933
7934 ///////////////////////////////////////////////////////////////////////////////////////
7935    BUTTON_CONTACT_STYLES("expand_closed", "00_button_expand_closed.png", "00_button_expand_closed_press.png")
7936
7937    BUTTON_CONTACT_STYLES("expand_opened", "00_button_expand_opened.png", "00_button_expand_opened_press.png")
7938
7939    BUTTON_CONTACT_STYLES("plus", "00_button_plus.png", "00_button_plus_press.png")
7940
7941 ///////////////////////////////////////////////////////////////////////////////////////
7942    group { name: "elm/button/base/contact";
7943       alias: "elm/button/base/text_only/contact";
7944       images {
7945          image: "00_contacts_button_bg.png" COMP;
7946          image: "00_contacts_button_bg_press.png" COMP;
7947       }
7948       script {
7949          public button_state = BUTTON_STATE_ENABLED;
7950       }
7951       parts {
7952          part { name: "button_image";
7953             scale: 1;
7954             description { state: "default" 0.0;
7955                rel1 {
7956                   to_x: "padding.left";
7957                   to_y: "elm.text";
7958                }
7959                rel2 {
7960                   to_x: "padding.right";
7961                   to_y: "elm.text";
7962                }
7963                min: BUTTON_CONTACT_BG_MIN_INC;
7964                image {
7965                   normal: "00_contacts_button_bg.png";
7966                   border: BUTTON_CONTACT_BG_BORDER_INC;
7967                   border_scale: 1;
7968                }
7969             }
7970             description { state: "clicked" 0.0;
7971                inherit: "default" 0.0;
7972                image.normal: "00_contacts_button_bg_press.png";
7973             }
7974             description { state: "disabled" 0.0;
7975                inherit: "default" 0.0;
7976                color: 0 0 0 128;
7977             }
7978             description { state: "focused" 0.0;
7979                inherit: "default" 0.0;
7980             }
7981          }
7982          part { name: "padding.left";
7983             type: RECT;
7984             scale: 1;
7985             description { state: "default" 0.0;
7986                visible: 0;
7987                min: BUTTON_CONTACT_PADDING_MIN_INC;
7988                fixed: 1 0;
7989                color: 0 0 0 0;
7990                rel2 {
7991                   relative: 0.0 1.0;
7992                   to_x: "elm.text";
7993                }
7994                align: 1.0 0.0;
7995             }
7996          }
7997          part { name: "padding.right";
7998             type: RECT;
7999             scale: 1;
8000             description { state: "default" 0.0;
8001                visible: 0;
8002                min: BUTTON_CONTACT_PADDING_MIN_INC;
8003                fixed: 1 0;
8004                color: 0 0 0 0;
8005                rel1 {
8006                   relative: 1.0 0.0;
8007                   to_x: "elm.text";
8008                }
8009                align: 0.0 0.0;
8010             }
8011          }
8012          part {   name: "elm.text";
8013             type: TEXT;
8014             mouse_events: 0;
8015             scale: 1;
8016             description { state: "default" 0.0;
8017                visible: 0;
8018                fixed: 1 1;
8019                color: BUTTON_CONTACT_BUTTON_TEXT_NORMAL_COLOR_INC;
8020                text {
8021                   font: "SLP:style=Medium";
8022                   size: BUTTON_CONTACT_FONT_SIZE_INC;
8023                   min: 1 1;
8024                   text_class: "slp_medium";
8025                }
8026             }
8027             description { state: "visible" 0.0;
8028                inherit: "default" 0.0;
8029                visible: 1;
8030                min: 1 1;
8031             }
8032             description { state: "clicked" 0.0;
8033                inherit: "default" 0.0;
8034                visible: 1;
8035                min: 1 1;
8036                color: BUTTON_CONTACT_BUTTON_TEXT_PRESSED_COLOR_INC;
8037             }
8038             description { state: "disabled" 0.0;
8039                inherit: "default" 0.0;
8040                color: 0 0 0 128;
8041             }
8042             description { state: "disabled_visible" 0.0;
8043                inherit: "default" 0.0;
8044                color: BUTTON_CONTACT_BUTTON_TEXT_DISABLED_COLOR_INC;
8045                visible: 1;
8046                min: 1 1;
8047             }
8048             description { state: "focused" 0.0;
8049                inherit: "default" 0.0;
8050                visible: 1;
8051                min: 1 1;
8052                color: BUTTON_CONTACT_BUTTON_TEXT_FOCUSED_COLOR_INC;
8053             }
8054          }
8055          part { name: "over1";
8056             mouse_events: 0;
8057             description { state: "default" 0.0;
8058                rel2.relative: 1.0 0.5;
8059             }
8060          }
8061          part { name: "over2";
8062             repeat_events: 1;
8063             ignore_flags: ON_HOLD;
8064             description { state: "default" 0.0;
8065                rel1.to: "button_image";
8066                rel2.to: "button_image";
8067             }
8068          }
8069          part { name: "over3";
8070             repeat_events: 1;
8071             description { state: "default" 0.0;
8072                rel1.to: "button_image";
8073                rel2.to: "button_image";
8074                color: 0 0 0 0;
8075             }
8076          }
8077          part { name: "disabler";
8078             type: RECT;
8079             description { state: "default" 0.0;
8080                rel1.to: "button_image";
8081                rel2.to: "button_image";
8082                color: 0 0 0 0;
8083                visible: 0;
8084             }
8085             description { state: "disabled" 0.0;
8086                inherit: "default" 0.0;
8087                visible: 1;
8088             }
8089          }
8090       }
8091       programs {
8092          program { name: "button_click";
8093             signal: "mouse,down,1";
8094             source: "over2";
8095             action: SIGNAL_EMIT "elm,action,press" "";
8096             after: "button_click_anim";
8097          }
8098          program { name: "button_click_anim";
8099             action: STATE_SET "clicked" 0.0;
8100             target: "button_image";
8101             target: "elm.text";
8102          }
8103          program { name: "button_unpress";
8104             action: SIGNAL_EMIT "elm,action,unpress" "";
8105          }
8106          program { name: "button_mouseout_clicked";
8107             signal: "mouse,up,1";
8108             source: "over3";
8109             script {
8110                new st[31];
8111                new Float:vl;
8112                get_state(PART:"elm.text", st, 30, vl);
8113                if (!strcmp(st, "clicked") || !strcmp(st, "focused"))
8114                  {
8115                     emit("elm,action,default,text,set", "");
8116                     set_state(PART:"elm.text", "visible", 0.0);
8117                  }
8118                if (get_int(button_state) != BUTTON_STATE_DISABLED)
8119                  set_state(PART:"button_image", "default", 0.0);
8120             }
8121             after: button_unpress;
8122          }
8123          program { name: "touch_snd";
8124             signal: "mouse,clicked,1";
8125             source: "over2";
8126             action: PLAY_SAMPLE "touch_sound" 1.0;
8127             after: button_unclick3;
8128          }
8129          program { name: "button_unclick3";
8130             action: SIGNAL_EMIT "elm,action,click" "";
8131          }
8132          program { name: "text_show";
8133             signal: "elm,state,text,visible";
8134             source: "elm";
8135             script {
8136                if (get_int(button_state) != BUTTON_STATE_DISABLED)
8137                  set_state(PART:"elm.text", "visible", 0.0);
8138                else
8139                  set_state(PART:"elm.text", "disabled_visible", 0.0);
8140             }
8141          }
8142          program { name: "text_hide";
8143             signal: "elm,state,text,hidden";
8144             source: "elm";
8145             action: STATE_SET "default" 0.0;
8146             target: "elm.text";
8147          }
8148          program { name: "disable";
8149             signal: "elm,state,disabled";
8150             source: "elm";
8151             action: STATE_SET "disabled" 0.0;
8152             target: "button_image";
8153             target: "disabler";
8154             after: "disable_text";
8155          }
8156          program { name: "disable_text";
8157             script {
8158                new st[31];
8159                new Float:vl;
8160                get_state(PART:"elm.text", st, 30, vl);
8161                if (!strcmp(st, "visible"))
8162                  set_state(PART:"elm.text", "disabled_visible", 0.0);
8163                else
8164                  set_state(PART:"elm.text", "disabled", 0.0);
8165                set_int(button_state, BUTTON_STATE_DISABLED);
8166             }
8167          }
8168          program { name: "enable";
8169             signal: "elm,state,enabled";
8170             source: "elm";
8171             action: STATE_SET "default" 0.0;
8172             target: "button_image";
8173             target: "disabler";
8174             after: "enable_text";
8175          }
8176          program { name: "enable_text";
8177             script {
8178                new st[31];
8179                new Float:vl;
8180                get_state(PART:"elm.text", st, 30, vl);
8181                if (!strcmp(st, "disabled_visible"))
8182                  set_state(PART:"elm.text", "visible", 0.0);
8183                else
8184                  set_state(PART:"elm.text", "default", 0.0);
8185                set_int(button_state, BUTTON_STATE_ENABLED);
8186             }
8187          }
8188          program { name: "focused";
8189             //signal: "elm,action,focus";
8190             //source: "elm";
8191             action: STATE_SET "focused" 0.0;
8192             target: "button_image";
8193             target: "elm.text";
8194          }
8195          program { name: "unfocused";
8196             //signal: "elm,action,unfocus";
8197             //source: "elm";
8198             action: STATE_SET "default" 0.0;
8199             target: "button_image";
8200             action: STATE_SET "visible" 0.0;
8201             target: "elm.text";
8202          }
8203       }
8204    }
8205
8206 ///////////////////////////////////////////////////////////////////////////////////////
8207    group { name: "elm/button/base/naviframe/back_btn/default";
8208       alias: "elm/button/base/naviframe/prev_btn/default";
8209       alias: "elm/button/base/naviframe/end_btn/default";
8210       images {
8211          image: "00_winset_toolbar_press.png" COMP;
8212         image: "00_winset_Back.png" COMP;
8213       }
8214       script {
8215          public button_state = BUTTON_STATE_ENABLED;
8216       }
8217       parts {
8218          part { name: "button_image";
8219             scale: 1;
8220             description { state: "default" 0.0;
8221                min: BUTTON_NAVIFRAME_BACK_BUTTON_BG_MIN_MAX_INC;
8222                max: BUTTON_NAVIFRAME_BACK_BUTTON_BG_MIN_MAX_INC;
8223                color: 0 0 0 0;
8224             }
8225             description { state: "clicked" 0.0;
8226                min: BUTTON_NAVIFRAME_BACK_BUTTON_BG_MIN_MAX_INC;
8227                max: BUTTON_NAVIFRAME_BACK_BUTTON_BG_MIN_MAX_INC;
8228                image {
8229                   normal: "00_winset_toolbar_press.png";
8230                   border: BUTTON_NAVIFRAME_BACK_BUTTON_BG_BORDER_INC;
8231                }
8232             }
8233             description { state: "disabled" 0.0;
8234                inherit: "default" 0.0;
8235                color: 127 127 127 127;
8236             }
8237             description { state: "focused" 0.0;
8238                min: BUTTON_NAVIFRAME_BACK_BUTTON_BG_MIN_MAX_INC;
8239                max: BUTTON_NAVIFRAME_BACK_BUTTON_BG_MIN_MAX_INC;
8240                image {
8241                   normal: "00_winset_toolbar_press.png";
8242                   border: BUTTON_NAVIFRAME_BACK_BUTTON_BG_BORDER_INC;
8243                }
8244             }
8245          }
8246          part { name: "back_button";
8247             scale: 1;
8248             mouse_events: 0;
8249             description { state: "default" 0.0;
8250                min: BUTTON_NAVIFRAME_BACK_BUTTON_MIN_MAX_INC;
8251                max: BUTTON_NAVIFRAME_BACK_BUTTON_MIN_MAX_INC;
8252                rel1.to: "button_image";
8253                rel2.to: "button_image";
8254                image.normal: "00_winset_Back.png";
8255             }
8256             description { state: "clicked" 0.0;
8257                inherit: "default" 0.0;
8258             }
8259             description { state: "disabled" 0.0;
8260                inherit: "default" 0.0;
8261                color: 127 127 127 127;
8262             }
8263          }
8264          part { name: "over2";
8265             type: RECT;
8266             repeat_events: 1;
8267             ignore_flags: ON_HOLD;
8268             description { state: "default" 0.0;
8269                color: 0 0 0 0;
8270             }
8271          }
8272          part { name: "over3";
8273             type: RECT;
8274             repeat_events: 1;
8275             description { state: "default" 0.0;
8276                color: 0 0 0 0;
8277             }
8278          }
8279          part { name: "disabler";
8280             type: RECT;
8281             description { state: "default" 0.0;
8282                color: 0 0 0 0;
8283                visible: 0;
8284             }
8285             description { state: "disabled" 0.0;
8286                inherit: "default" 0.0;
8287                visible: 1;
8288             }
8289          }
8290       }
8291       programs {
8292          program { name: "button_click";
8293             signal: "mouse,down,1";
8294             source: "over2";
8295             action: SIGNAL_EMIT "elm,action,press" "";
8296             after: "button_click_anim";
8297          }
8298          program { name: "button_click_anim";
8299             action: STATE_SET "clicked" 0.0;
8300             target: "button_image";
8301          }
8302          program { name: "button_unpress";
8303             action: SIGNAL_EMIT "elm,action,unpress" "";
8304          }
8305          program { name: "button_mouseout_clicked";
8306             signal: "mouse,up,1";
8307             source: "over3";
8308             script {
8309                if (get_int(button_state) != BUTTON_STATE_DISABLED)
8310                  set_state(PART:"button_image", "default", 0.0);
8311             }
8312             after: button_unpress;
8313          }
8314          program { name: "touch_snd";
8315             signal: "mouse,clicked,1";
8316             source: "over2";
8317             action: PLAY_SAMPLE "touch_sound" 1.0;
8318             after: button_unclick3;
8319          }
8320          program { name: "button_unclick3";
8321             action: SIGNAL_EMIT "elm,action,click" "";
8322          }
8323          program { name: "disable";
8324             signal: "elm,state,disabled";
8325             source: "elm";
8326             action: STATE_SET "disabled" 0.0;
8327             target: "button_image";
8328             target: "disabler";
8329             target: "back_button";
8330             after: "disable_button";
8331          }
8332          program { name: "disable_button";
8333             script {
8334                set_int(button_state, BUTTON_STATE_DISABLED);
8335             }
8336          }
8337          program { name: "enable";
8338             signal: "elm,state,enabled";
8339             source: "elm";
8340             action: STATE_SET "default" 0.0;
8341             target: "button_image";
8342             target: "disabler";
8343             target: "back_button";
8344             after: "enable_button";
8345          }
8346          program { name: "enable_button";
8347             script {
8348                set_int(button_state, BUTTON_STATE_ENABLED);
8349             }
8350          }
8351          program { name: "focused";
8352             //signal: "elm,action,focus";
8353             //source: "elm";
8354             action: STATE_SET "focused" 0.0;
8355             target: "button_image";
8356          }
8357          program { name: "unfocused";
8358             //signal: "elm,action,unfocus";
8359             //source: "elm";
8360             action: STATE_SET "default" 0.0;
8361             target: "button_image";
8362          }
8363       }
8364    }
8365
8366 ///////////////////////////////////////////////////////////////////////////////////////
8367    group { name: "elm/button/base/picker/prev/icon/default";
8368       images {
8369          image: "00_picker_btn_normal.png" COMP;
8370          image: "00_picker_btn_press.png" COMP;
8371          image: "00_picker_btn_normal_focus.png" COMP;
8372          image: "00_picker_arrow_left.png" COMP;
8373          image: "00_picker_arrow_left_press.png" COMP;
8374       }
8375       script {
8376          public button_state = BUTTON_STATE_ENABLED;
8377       }
8378       parts {
8379          part { name: "button_image";
8380             scale: 1;
8381             description { state: "default" 0.0;
8382                min: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_MIN_MAX_INC;
8383                max: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_MIN_MAX_INC;
8384                image {
8385                   normal: "00_picker_btn_normal.png";
8386                   border: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_BORDER_INC;
8387                   border_scale: 1;
8388                }
8389             }
8390             description { state: "clicked" 0.0;
8391                inherit: "default" 0.0;
8392                image.normal: "00_picker_btn_press.png";
8393             }
8394             description { state: "disabled" 0.0;
8395                inherit: "default" 0.0;
8396             }
8397             description { state: "focused" 0.0;
8398                inherit: "default" 0.0;
8399                image.normal: "00_picker_btn_normal_focus.png";
8400             }
8401          }
8402          part { name: "padding_left_top";
8403             type: RECT;
8404             scale: 1;
8405             mouse_events: 0;
8406             description { state: "default" 0.0;
8407                align: 0.0 0.0;
8408                rel2.relative: 0.0 0.0;
8409                min: BUTTON_PICKER_PREV_ICON_DEFAULT_PADDING_MIN_INC;
8410                fixed: 1 1;
8411                visible: 0;
8412             }
8413          }
8414          part { name: "padding_right_bottom";
8415             type: RECT;
8416             scale: 1;
8417             mouse_events: 0;
8418             description { state: "default" 0.0;
8419                align: 1.0 1.0;
8420                rel1.relative: 1.0 1.0;
8421                min: BUTTON_PICKER_PREV_ICON_DEFAULT_PADDING_MIN_INC;
8422                fixed: 1 1;
8423                visible: 0;
8424             }
8425          }
8426          part { name: "left_arrow";
8427             scale: 1;
8428             mouse_events: 0;
8429             description { state: "default" 0.0;
8430                min: BUTTON_PICKER_PREV_ICON_DEFAULT_IMAGE_MIN_MAX_INC;
8431                max: BUTTON_PICKER_PREV_ICON_DEFAULT_IMAGE_MIN_MAX_INC;
8432                rel1 {
8433                   relative: 1.0 1.0;
8434                   to: "padding_left_top";
8435                }
8436                rel2 {
8437                   relative: 0.0 0.0;
8438                   to: "padding_right_bottom";
8439                }
8440                image.normal: "00_picker_arrow_left.png";
8441             }
8442             description { state: "clicked" 0.0;
8443                inherit: "default" 0.0;
8444                image.normal: "00_picker_arrow_left_press.png";
8445             }
8446          }
8447          part { name: "over2";
8448             type: RECT;
8449             repeat_events: 1;
8450             ignore_flags: ON_HOLD;
8451             description { state: "default" 0.0;
8452                color: 0 0 0 0;
8453             }
8454          }
8455          part { name: "over3";
8456             type: RECT;
8457             repeat_events: 1;
8458             description { state: "default" 0.0;
8459                color: 0 0 0 0;
8460             }
8461          }
8462          part { name: "disabler";
8463             type: RECT;
8464             description { state: "default" 0.0;
8465                color: 0 0 0 0;
8466                visible: 0;
8467             }
8468             description { state: "disabled" 0.0;
8469                inherit: "default" 0.0;
8470                visible: 1;
8471             }
8472          }
8473       }
8474       programs {
8475          program { name: "button_click";
8476             signal: "mouse,down,1";
8477             source: "over2";
8478             action: SIGNAL_EMIT "elm,action,press" "";
8479             after: "button_click_anim";
8480          }
8481          program { name: "button_click_anim";
8482             action: STATE_SET "clicked" 0.0;
8483             target: "button_image";
8484          }
8485          program { name: "button_unpress";
8486             action: SIGNAL_EMIT "elm,action,unpress" "";
8487          }
8488          program { name: "button_mouseout_clicked";
8489             signal: "mouse,up,1";
8490             source: "over3";
8491             script {
8492                if (get_int(button_state) != BUTTON_STATE_DISABLED)
8493                  set_state(PART:"button_image", "default", 0.0);
8494             }
8495             after: button_unpress;
8496          }
8497          program { name: "touch_snd";
8498             signal: "mouse,clicked,1";
8499             source: "over2";
8500             action: PLAY_SAMPLE "touch_sound" 1.0;
8501             after: button_unclick3;
8502          }
8503          program { name: "button_unclick3";
8504             action: SIGNAL_EMIT "elm,action,click" "";
8505          }
8506          program { name: "disable";
8507             signal: "elm,state,disabled";
8508             source: "elm";
8509             action: STATE_SET "disabled" 0.0;
8510             target: "button_image";
8511             target: "disabler";
8512             after: "disable_button";
8513          }
8514          program { name: "disable_button";
8515             script {
8516                set_int(button_state, BUTTON_STATE_DISABLED);
8517             }
8518          }
8519          program { name: "enable";
8520             signal: "elm,state,enabled";
8521             source: "elm";
8522             action: STATE_SET "default" 0.0;
8523             target: "button_image";
8524             target: "disabler";
8525             after: "enable_button";
8526          }
8527          program { name: "enable_button";
8528             script {
8529                set_int(button_state, BUTTON_STATE_ENABLED);
8530             }
8531          }
8532          program { name: "focused";
8533             //signal: "elm,action,focus";
8534             //source: "elm";
8535             action: STATE_SET "focused" 0.0;
8536             target: "button_image";
8537          }
8538          program { name: "unfocused";
8539             //signal: "elm,action,unfocus";
8540             //source: "elm";
8541             action: STATE_SET "default" 0.0;
8542             target: "button_image";
8543          }
8544       }
8545    }
8546
8547 ///////////////////////////////////////////////////////////////////////////////////////
8548    group { name: "elm/button/base/picker/next/icon/default";
8549       images {
8550          image: "00_picker_btn_normal.png" COMP;
8551          image: "00_picker_btn_press.png" COMP;
8552          image: "00_picker_btn_normal_focus.png" COMP;
8553          image: "00_picker_arrow_right.png" COMP;
8554          image: "00_picker_arrow_right_press.png" COMP;
8555       }
8556       script {
8557          public button_state = BUTTON_STATE_ENABLED;
8558       }
8559       parts {
8560          part { name: "button_image";
8561             scale: 1;
8562             description { state: "default" 0.0;
8563                min: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_MIN_MAX_INC;
8564                max: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_MIN_MAX_INC;
8565                image {
8566                   normal: "00_picker_btn_normal.png";
8567                   border: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_BORDER_INC;
8568                   border_scale: 1;
8569                }
8570             }
8571             description { state: "clicked" 0.0;
8572                inherit: "default" 0.0;
8573                image.normal: "00_picker_btn_press.png";
8574             }
8575             description { state: "disabled" 0.0;
8576                inherit: "default" 0.0;
8577             }
8578             description { state: "focused" 0.0;
8579                inherit: "default" 0.0;
8580                image.normal: "00_picker_btn_normal_focus.png";
8581             }
8582          }
8583          part { name: "padding_left_top";
8584             type: RECT;
8585             scale: 1;
8586             mouse_events: 0;
8587             description { state: "default" 0.0;
8588                align: 0.0 0.0;
8589                rel2.relative: 0.0 0.0;
8590                min: BUTTON_PICKER_PREV_ICON_DEFAULT_PADDING_MIN_INC;
8591                fixed: 1 1;
8592                visible: 0;
8593             }
8594          }
8595          part { name: "padding_right_bottom";
8596             type: RECT;
8597             scale: 1;
8598             mouse_events: 0;
8599             description { state: "default" 0.0;
8600                align: 1.0 1.0;
8601                rel1.relative: 1.0 1.0;
8602                min: BUTTON_PICKER_PREV_ICON_DEFAULT_PADDING_MIN_INC;
8603                fixed: 1 1;
8604                visible: 0;
8605             }
8606          }
8607          part { name: "right_arrow";
8608             scale: 1;
8609             mouse_events: 0;
8610             description { state: "default" 0.0;
8611                min: BUTTON_PICKER_PREV_ICON_DEFAULT_IMAGE_MIN_MAX_INC;
8612                max: BUTTON_PICKER_PREV_ICON_DEFAULT_IMAGE_MIN_MAX_INC;
8613                rel1 {
8614                   relative: 1.0 1.0;
8615                   to: "padding_left_top";
8616                }
8617                rel2 {
8618                   relative: 0.0 0.0;
8619                   to: "padding_right_bottom";
8620                }
8621                image.normal: "00_picker_arrow_right.png";
8622             }
8623             description { state: "clicked" 0.0;
8624                inherit: "default" 0.0;
8625                image.normal: "00_picker_arrow_right_press.png";
8626             }
8627          }
8628          part { name: "over2";
8629             type: RECT;
8630             repeat_events: 1;
8631             ignore_flags: ON_HOLD;
8632             description { state: "default" 0.0;
8633                color: 0 0 0 0;
8634             }
8635          }
8636          part { name: "over3";
8637             type: RECT;
8638             repeat_events: 1;
8639             description { state: "default" 0.0;
8640                color: 0 0 0 0;
8641             }
8642          }
8643          part { name: "disabler";
8644             type: RECT;
8645             description { state: "default" 0.0;
8646                color: 0 0 0 0;
8647                visible: 0;
8648             }
8649             description { state: "disabled" 0.0;
8650                inherit: "default" 0.0;
8651                visible: 1;
8652             }
8653          }
8654       }
8655       programs {
8656          program { name: "button_click";
8657             signal: "mouse,down,1";
8658             source: "over2";
8659             action: SIGNAL_EMIT "elm,action,press" "";
8660             after: "button_click_anim";
8661          }
8662          program { name: "button_click_anim";
8663             action: STATE_SET "clicked" 0.0;
8664             target: "button_image";
8665          }
8666          program { name: "button_unpress";
8667             action: SIGNAL_EMIT "elm,action,unpress" "";
8668          }
8669          program { name: "button_mouseout_clicked";
8670             signal: "mouse,up,1";
8671             source: "over3";
8672             script {
8673                if (get_int(button_state) != BUTTON_STATE_DISABLED)
8674                  set_state(PART:"button_image", "default", 0.0);
8675             }
8676             after: button_unpress;
8677          }
8678          program { name: "touch_snd";
8679             signal: "mouse,clicked,1";
8680             source: "over2";
8681             action: PLAY_SAMPLE "touch_sound" 1.0;
8682             after: button_unclick3;
8683          }
8684          program { name: "button_unclick3";
8685             action: SIGNAL_EMIT "elm,action,click" "";
8686          }
8687          program { name: "disable";
8688             signal: "elm,state,disabled";
8689             source: "elm";
8690             action: STATE_SET "disabled" 0.0;
8691             target: "button_image";
8692             target: "disabler";
8693             after: "disable_button";
8694          }
8695          program { name: "disable_button";
8696             script {
8697                set_int(button_state, BUTTON_STATE_DISABLED);
8698             }
8699          }
8700          program { name: "enable";
8701             signal: "elm,state,enabled";
8702             source: "elm";
8703             action: STATE_SET "default" 0.0;
8704             target: "button_image";
8705             target: "disabler";
8706             after: "enable_button";
8707          }
8708          program { name: "enable_button";
8709             script {
8710                set_int(button_state, BUTTON_STATE_ENABLED);
8711             }
8712          }
8713          program { name: "focused";
8714             //signal: "elm,action,focus";
8715             //source: "elm";
8716             action: STATE_SET "focused" 0.0;
8717             target: "button_image";
8718          }
8719          program { name: "unfocused";
8720             //signal: "elm,action,unfocus";
8721             //source: "elm";
8722             action: STATE_SET "default" 0.0;
8723             target: "button_image";
8724          }
8725       }
8726    }
8727
8728 ///////////////////////////////////////////////////////////////////////////////////////
8729    group { name: "elm/button/base/naviframe_control/default";
8730       alias: "elm/button/base/naviframe_control/center";
8731       script {
8732          public button_state = BUTTON_STATE_ENABLED;
8733       }
8734       images {
8735          image: "00_Option_header_bt.png" COMP;
8736          image: "00_Option_header_bt_dim.png" COMP;
8737          image: "00_Option_header_bt_press.png" COMP;
8738          image: "00_Option_header_bt_focus.png" COMP;
8739       }
8740       parts {
8741          part { name: "button_image";
8742             scale: 1;
8743             description { state: "default" 0.0;
8744                min: BUTTON_NAVIFRAME_CENTER_BG_NORMAL_MIN_INC;
8745                color: 0 0 0 0;
8746                rel1.offset: 0 0;
8747                rel2.offset: -1 -1;
8748                image {
8749                   normal: "00_Option_header_bt.png";
8750                   border: BUTTON_NAVIFRAME_CENTER_BG_NORMAL_BORDER_INC;
8751                }
8752                color: 255 255 255 255;
8753             }
8754             description { state: "disabled" 0.0;
8755                inherit: "default" 0.0;
8756                image.normal: "00_Option_header_bt_dim.png";
8757             }
8758             description { state: "clicked" 0.0;
8759                inherit: "default" 0.0;
8760                image.normal: "00_Option_header_bt_press.png";
8761             }
8762             description { state: "focused" 0.0;
8763                inherit: "default" 0.0;
8764                image.normal: "00_Option_header_bt_focus.png";
8765             }
8766          }
8767          part { name: "padding_left_top";
8768             type: RECT;
8769             scale: 1;
8770             mouse_events: 0;
8771             description { state: "default" 0.0;
8772                align: 0.0 0.0;
8773                rel2.relative: 0.0 0.0;
8774                min: BUTTON_NAVIFRAME_CENTER_PADDING_MIN_MAX_INC;
8775                fixed: 1 1;
8776                visible: 0;
8777             }
8778          }
8779          part { name: "padding_right_bottom";
8780             type: RECT;
8781             scale: 1;
8782             mouse_events: 0;
8783             description { state: "default" 0.0;
8784                align: 1.0 1.0;
8785                rel1.relative: 1.0 1.0;
8786                min: BUTTON_NAVIFRAME_CENTER_PADDING_MIN_MAX_INC;
8787                fixed: 1 1;
8788                visible: 0;
8789             }
8790          }
8791          part { name: "icon_rect";
8792             type: RECT;
8793             scale: 1;
8794             mouse_events: 0;
8795             description { state: "default" 0.0;
8796                min: 0 0;
8797                fixed: 1 0;
8798                rel1 {
8799                   relative: 1.0 1.0;
8800                   to: "padding_left_top";
8801                }
8802                rel2 {
8803                   relative: 1.0 0.0;
8804                   to_x: "padding_left_top";
8805                   to_y: "padding_right_bottom";
8806                }
8807                align: 0.0 0.5;
8808                color: 0 0 0 0;
8809             }
8810             description { state: "visible" 0.0;
8811                min: BUTTON_NAVIFRAME_CENTER_ICON_RECT_VISIBLE_MIN_SIZE;
8812                fixed: 1 0;
8813                rel1 {
8814                   relative: 1.0 1.0;
8815                   to: "padding_left_top";
8816                }
8817                rel2 {
8818                   relative: 1.0 0.0;
8819                   to_x: "padding_left_top";
8820                   to_y: "padding_right_bottom";
8821                }
8822                align: 0.0 0.5;
8823                color: 0 0 0 0;
8824             }
8825             description { state: "icononly" 0.0;
8826                inherit: "default" 0.0;
8827             }
8828          }
8829          part { name: "padding_after_icon";
8830             type: RECT;
8831             scale: 1;
8832             mouse_events: 0;
8833             description { state: "default" 0.0; //when only icon or no icon is there
8834                align: 0.0 0.0;
8835                rel1 {
8836                   relative: 1.0 0.0;
8837                   to: "icon_rect";
8838                }
8839                rel2.to: "icon_rect";
8840                fixed: 1 0;
8841                min: 0 0;
8842                color: 0 0 0 0;
8843             }
8844             description { state: "visible" 0.0;
8845                align: 0.0 0.0;
8846                rel1 {
8847                   relative: 1.0 0.0;
8848                   to: "icon_rect";
8849                }
8850                rel2.to: "icon_rect";
8851                fixed: 1 0;
8852                min: BUTTON_NAVIFRAME_CENTER_PADDING_AFTER_ICON_VISIBLE_MIN_INC;
8853                color: 0 0 0 0;
8854             }
8855             description { state: "icononly" 0.0;
8856                inherit: "default" 0.0;
8857             }
8858          }
8859          part { name: "padding_before_text";
8860             type: RECT;
8861             scale: 1;
8862             mouse_events: 0;
8863             description { state: "default" 0.0; //when only icon or no icon is there
8864                align: 1.0 0.5;
8865                rel1 {
8866                   relative: 0.0 1.0;
8867                   to_x: "elm.text";
8868                   to_y: "padding_left_top";
8869                }
8870                rel2 {
8871                   relative: 0.0 0.0;
8872                   to_x: "elm.text";
8873                   to_y: "padding_right_bottom";
8874                }
8875                fixed: 1 0;
8876                min: BUTTON_NAVIFRAME_CENTER_PADDING_BEFORE_TEXT_DEFAULT_MIN_INC;
8877                color: 0 0 0 0;
8878             }
8879          }
8880          part { name: "elm.swallow.content";
8881             type: SWALLOW;
8882             scale: 1;
8883             clip_to: "clipper";
8884             description { state: "default" 0.0;
8885                visible: 0;
8886                align: 0.0 0.5;
8887                rel1 {
8888                   relative: 1.0 1.0;
8889                   to: "padding_left_top";
8890                }
8891                rel2 {
8892                   relative: 1.0 0.0;
8893                   to_x: "padding_left_top";
8894                   to_y: "padding_right_bottom";
8895                }
8896                fixed: 1 0;
8897             }
8898             description { state: "visible" 0.0;
8899                fixed: 1 0;
8900                min: BUTTON_NAVIFRAME_CENTER_SWALLOW_VISIBLE_MIN_MAX_INC;
8901                max: BUTTON_NAVIFRAME_CENTER_SWALLOW_VISIBLE_MIN_MAX_INC;
8902                align: 1.0 0.5;
8903                rel1 {
8904                   relative: 0.0 1.0;
8905                   to_x: "padding_before_text";
8906                   to_y: "padding_left_top";
8907                }
8908                rel2 {
8909                   relative: 0.0 0.0;
8910                   to_x: "padding_before_text";
8911                   to_y: "padding_right_bottom";
8912                }
8913                aspect: 1.0 1.0;
8914                aspect_preference: VERTICAL;
8915             }
8916             description { state: "icononly" 0.0;
8917                min: BUTTON_NAVIFRAME_CENTER_SWALLOW_ICONONLY_MIN_MAX_INC;
8918                max: BUTTON_NAVIFRAME_CENTER_SWALLOW_ICONONLY_MIN_MAX_INC;
8919                rel1 {
8920                   relative: 1.0 1.0;
8921                   to: "padding_left_top";
8922                }
8923                rel2 {
8924                   relative: 0.0 0.0;
8925                   to: "padding_right_bottom";
8926                }
8927                aspect: 1.0 1.0;
8928                aspect_preference: VERTICAL;
8929             }
8930          }
8931          part { name: "elm.text";
8932             type: TEXT;
8933             mouse_events: 0;
8934             scale: 1;
8935             clip_to: "clipper";
8936             description { state: "default" 0.0;
8937                visible: 0;
8938                rel1 {
8939                   relative: 1.0 1.0;
8940                   to_x: "padding_after_icon";
8941                   to_y: "padding_left_top";
8942                }
8943                rel2 {
8944                   relative: 0.0 0.0;
8945                   to: "padding_right_bottom";
8946                }
8947                color: BUTTON_NAVIFRAME_DEFAULT_TEXT_COLOR_INC;
8948                text {
8949                   font: "SLP:style=Medium";
8950                   size: BUTTON_NAVIFRAME_CENTER_TEXT_FONT_SIZE_INC;
8951                   min: 0 0;
8952                   max: 1 0;
8953                   text_class: "slp_medium";
8954                }
8955             }
8956             description { state: "visible" 0.0;
8957                inherit: "default" 0.0;
8958                visible: 1;
8959             }
8960             description { state: "clicked" 0.0;
8961                inherit: "default" 0.0;
8962                visible: 1;
8963                min: 0 0;
8964             }
8965             description { state: "focused" 0.0;
8966                inherit: "default" 0.0;
8967                visible: 1;
8968                min: 0 0;
8969                color: BUTTON_NAVIFRAME_FOCUSED_TEXT_COLOR_INC;
8970             }
8971          }
8972          part { name: "over2";
8973             type: RECT;
8974             repeat_events: 1;
8975             ignore_flags: ON_HOLD;
8976             description { state: "default" 0.0;
8977                color: 0 0 0 0;
8978             }
8979          }
8980          part { name: "over3";
8981             type: RECT;
8982             repeat_events: 1;
8983             description { state: "default" 0.0;
8984                color: 0 0 0 0;
8985             }
8986          }
8987          part { name: "clipper";
8988             type: RECT;
8989             description { state: "default" 0.0;
8990                color: 255 255 255 255;
8991             }
8992             description { state: "disabled" 0.0;
8993                color: 255 255 255 127;
8994             }
8995          }
8996          part { name: "disabler";
8997             type: RECT;
8998             description { state: "default" 0.0;
8999                color: 0 0 0 0;
9000                visible: 0;
9001             }
9002             description { state: "disabled" 0.0;
9003                inherit: "default" 0.0;
9004                visible: 1;
9005             }
9006          }
9007       }
9008       programs {
9009          program { name: "button_click";
9010             signal: "mouse,down,1";
9011             source: "over2";
9012             action: SIGNAL_EMIT "elm,action,press" "";
9013             after: "button_click_anim";
9014          }
9015          program { name: "button_click_anim";
9016             action: STATE_SET "clicked" 0.0;
9017             target: "button_image";
9018             after: "text_clicked";
9019          }
9020          program { name: "text_clicked";
9021             script {
9022                new st[31];
9023                new Float:vl;
9024                get_state(PART:"elm.text", st, 30, vl);
9025                if (!strcmp(st, "visible"))
9026                  set_state(PART:"elm.text", "clicked", 0.0);
9027             }
9028          }
9029          program { name: "button_unpress";
9030             action: SIGNAL_EMIT "elm,action,unpress" "";
9031          }
9032          program { name: "button_mouseout_clicked";
9033             signal: "mouse,up,1";
9034             source: "over3";
9035             script {
9036                new st[31];
9037                new Float:vl;
9038                get_state(PART:"elm.swallow.content", st, 30, vl);
9039                if (strcmp(st, "icononly"))
9040                  {
9041                     emit("elm,action,default,text,set", "");
9042                     set_state(PART:"elm.text", "visible", 0.0);
9043                  }
9044                if (get_int(button_state) != BUTTON_STATE_DISABLED)
9045                  set_state(PART:"button_image", "default", 0.0);
9046             }
9047             after: button_unpress;
9048          }
9049          program { name: "touch_snd";
9050             signal: "mouse,clicked,1";
9051             source: "over2";
9052             action: PLAY_SAMPLE "touch_sound" 1.0;
9053             after: button_unclick3;
9054          }
9055          program { name: "button_unclick3";
9056             action: SIGNAL_EMIT "elm,action,click" "";
9057          }
9058          program { name: "text_show";
9059             signal: "elm,state,text,visible";
9060             source: "elm";
9061             script {
9062                new st[31];
9063                new Float:vl;
9064                get_state(PART:"elm.swallow.content", st, 30, vl);
9065                if (!strcmp(st, "icononly"))
9066                  {
9067                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9068                     set_state(PART:"icon_rect", "visible", 0.0);
9069                     set_state(PART:"padding_after_icon", "visible", 0.0);
9070                  }
9071                set_state(PART:"elm.text", "visible", 0.0);
9072             }
9073          }
9074          program { name: "text_hide";
9075             signal: "elm,state,text,hidden";
9076             source: "elm";
9077             script {
9078                new st[31];
9079                new Float:vl;
9080                get_state(PART:"elm.swallow.content", st, 30, vl);
9081                if (!strcmp(st, "visible"))
9082                  {
9083                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9084                     set_state(PART:"icon_rect", "icononly", 0.0);
9085                     set_state(PART:"padding_after_icon", "icononly", 0.0);
9086                  }
9087                set_state(PART:"elm.text", "default", 0.0);
9088             }
9089          }
9090          program { name: "icon_show";
9091             signal: "elm,state,icon,visible";
9092             source: "elm";
9093             script {
9094                new st[31];
9095                new Float:vl;
9096                get_state(PART:"elm.text", st, 30, vl);
9097                if (!strcmp(st, "visible"))
9098                  {
9099                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9100                     set_state(PART:"icon_rect", "visible", 0.0);
9101                     set_state(PART:"padding_after_icon", "visible", 0.0);
9102                  }
9103                else
9104                  {
9105                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9106                     set_state(PART:"icon_rect", "icononly", 0.0);
9107                     set_state(PART:"padding_after_icon", "icononly", 0.0);
9108                  }
9109             }
9110          }
9111          program { name: "icon_hide";
9112             signal: "elm,state,icon,hidden";
9113             source: "elm";
9114             action: STATE_SET "default" 0.0;
9115             target: "elm.swallow.content";
9116             target: "icon_rect";
9117             target: "padding_after_icon";
9118          }
9119          program { name: "disable";
9120             signal: "elm,state,disabled";
9121             source: "elm";
9122             action: STATE_SET "disabled" 0.0;
9123             target: "button_image";
9124             target: "clipper";
9125             target: "disabler";
9126             after: "disable_text";
9127          }
9128          program { name: "disable_text";
9129             script {
9130                new st[31];
9131                new Float:vl;
9132                set_int(button_state, BUTTON_STATE_DISABLED);
9133                get_state(PART:"elm.text", st, 30, vl);
9134                if (!strcmp(st, "clicked") || !strcmp(st, "focused"))
9135                  set_state(PART:"elm.text", "visible", 0.0);
9136             }
9137          }
9138          program { name: "enable";
9139             signal: "elm,state,enabled";
9140             source: "elm";
9141             action: STATE_SET "default" 0.0;
9142             target: "button_image";
9143             target: "clipper";
9144             target: "disabler";
9145             after: "enable_text";
9146          }
9147          program { name: "enable_text";
9148             script {
9149                new st[31];
9150                new Float:vl;
9151                set_int(button_state, BUTTON_STATE_ENABLED);
9152                get_state(PART:"elm.text", st, 30, vl);
9153                if (!strcmp(st, "clicked") || !strcmp(st, "focused"))
9154                  set_state(PART:"elm.text", "visible", 0.0);
9155             }
9156          }
9157          program { name: "focused";
9158             //signal: "elm,action,focus";
9159             //source: "elm";
9160             action: STATE_SET "focused" 0.0;
9161             target: "button_image";
9162             target: "elm.text";
9163          }
9164          program { name: "unfocused";
9165             //signal: "elm,action,unfocus";
9166             //source: "elm";
9167             action: STATE_SET "default" 0.0;
9168             target: "button_image";
9169             after: "unfocus_text";
9170          }
9171          program { name: "unfocus_text";
9172             action: STATE_SET "visible" 0.0;
9173             target: "elm.text";
9174          }
9175       }
9176    }
9177
9178 ///////////////////////////////////////////////////////////////////////////////////////
9179    group { name: "elm/button/base/naviframe_control/multiline";
9180       script {
9181          public button_state = BUTTON_STATE_ENABLED;
9182       }
9183       images {
9184          image: "00_Option_header_bt.png" COMP;
9185          image: "00_Option_header_bt_dim.png" COMP;
9186          image: "00_Option_header_bt_press.png" COMP;
9187          image: "00_Option_header_bt_focus.png" COMP;
9188       }
9189       styles{
9190          style { name: "btn_multiline_naviframe_controlbar_style";
9191             base: "font=SLP:style=Medium font_size="BUTTON_NAVIFRAME_MULTILINE_TEXT_FONT_SIZE_INC" align=center color=#ffffff wrap=mixed text_class=slp_medium";
9192             tag: "br" "\n";
9193             tag: "ps" "ps";
9194             tag: "tab" "\t";
9195          }
9196       }
9197       parts {
9198          part { name: "button_image";
9199             scale: 1;
9200             description { state: "default" 0.0;
9201                min: BUTTON_NAVIFRAME_CENTER_BG_NORMAL_MIN_INC;
9202                rel1.offset: 0 0;
9203                rel2.offset: -1 -1;
9204                image {
9205                   normal: "00_Option_header_bt.png";
9206                   border: BUTTON_NAVIFRAME_CENTER_BG_NORMAL_BORDER_INC;
9207                }
9208                color: 255 255 255 255;
9209             }
9210             description { state: "disabled" 0.0;
9211                inherit: "default" 0.0;
9212                image.normal: "00_Option_header_bt_dim.png";
9213             }
9214             description { state: "clicked" 0.0;
9215                inherit: "default" 0.0;
9216                image.normal: "00_Option_header_bt_press.png";
9217             }
9218             description { state: "focused" 0.0;
9219                inherit: "default" 0.0;
9220                image.normal: "00_Option_header_bt_focus.png";
9221             }
9222          }
9223          part { name: "padding_left_top";
9224             type: RECT;
9225             scale: 1;
9226             mouse_events: 0;
9227             description { state: "default" 0.0;
9228                align: 0.0 0.0;
9229                rel2.relative: 0.0 0.0;
9230                min: BUTTON_NAVIFRAME_CENTER_PADDING_MIN_MAX_INC;
9231                fixed: 1 1;
9232                visible: 0;
9233             }
9234          }
9235          part { name: "padding_right_bottom";
9236             type: RECT;
9237             scale: 1;
9238             mouse_events: 0;
9239             description { state: "default" 0.0;
9240                align: 1.0 1.0;
9241                rel1.relative: 1.0 1.0;
9242                min: BUTTON_NAVIFRAME_CENTER_PADDING_MIN_MAX_INC;
9243                fixed: 1 1;
9244                visible: 0;
9245             }
9246          }
9247          part { name: "icon_rect";
9248             type: RECT;
9249             scale: 1;
9250             mouse_events: 0;
9251             description { state: "default" 0.0;
9252                visible: 0;
9253                min: 0 0;
9254                fixed: 1 0;
9255                rel1 {
9256                   relative: 0.0 1.0;
9257                   to_x: "elm.swallow.content";
9258                   to_y: "padding_left_top";
9259                }
9260                rel2 {
9261                   relative: 1.0 0.0;
9262                   to_x: "elm.swallow.content";
9263                   to_y: "padding_right_bottom";
9264                }
9265                align: 0.0 0.5;
9266             }
9267          }
9268          part { name: "padding_icon_text";
9269             type: RECT;
9270             scale: 1;
9271             mouse_events: 0;
9272             description { state: "default" 0.0; //when only icon or no icon is there
9273                visible: 0;
9274                align: 0.0 0.0;
9275                rel1 {
9276                   relative: 1.0 0.0;
9277                   to: "icon_rect";
9278                }
9279                rel2 {
9280                   relative: 1.0 1.0;
9281                   to: "icon_rect";
9282                }
9283                fixed: 1 0;
9284                min: 0 0;
9285             }
9286             description { state: "visible" 0.0;
9287                inherit: "default" 0.0;
9288                min: BUTTON_NAVIFRAME_CENTER_PADDING_AFTER_ICON_VISIBLE_MIN_INC;
9289                rel1 {
9290                   relative: 1.0 0.0;
9291                   to: "icon_rect";
9292                }
9293                rel2 {
9294                   relative: 1.0 1.0;
9295                   to: "icon_rect";
9296                }
9297            }
9298             description { state: "icononly" 0.0;
9299                inherit: "default" 0.0;
9300             }
9301          }
9302          part { name: "elm.swallow.content";
9303             type: SWALLOW;
9304             scale: 1;
9305             clip_to: "clipper";
9306             description { state: "default" 0.0;
9307                visible: 0;
9308                align: 0.0 0.5;
9309                rel1 {
9310                   relative: 1.0 1.0;
9311                   to: "padding_left_top";
9312                }
9313                rel2 {
9314                   relative: 1.0 0.0;
9315                   to_x: "padding_left_top";
9316                   to_y: "padding_right_bottom";
9317                }
9318                fixed: 1 0;
9319             }
9320             description { state: "visible" 0.0;
9321                fixed: 1 0;
9322                min: BUTTON_NAVIFRAME_CENTER_SWALLOW_VISIBLE_MIN_MAX_INC;
9323                max: BUTTON_NAVIFRAME_CENTER_SWALLOW_VISIBLE_MIN_MAX_INC;
9324                align: 0.0 0.5;
9325                rel1 {
9326                   relative: 1.0 1.0;
9327                   to: "padding_left_top";
9328                }
9329                rel2 {
9330                   relative: 0.0 0.0;
9331                   to_x: "padding_left_top";
9332                   to_y: "padding_right_bottom";
9333                }
9334             }
9335             description { state: "icononly" 0.0;
9336                min: BUTTON_NAVIFRAME_CENTER_SWALLOW_ICONONLY_MIN_MAX_INC;
9337                max: BUTTON_NAVIFRAME_CENTER_SWALLOW_ICONONLY_MIN_MAX_INC;
9338                rel1 {
9339                   relative: 1.0 1.0;
9340                   to: "padding_left_top";
9341                }
9342                rel2 {
9343                   relative: 0.0 0.0;
9344                   to: "padding_right_bottom";
9345                }
9346             }
9347          }
9348          part { name: "elm.text";
9349             type: TEXTBLOCK;
9350             mouse_events: 0;
9351             scale: 1;
9352             clip_to: "clipper";
9353             description { state: "default" 0.0;
9354                visible: 0;
9355                rel1 {
9356                   relative: 1.0 1.0;
9357                   to_x: "padding_icon_text";
9358                   to_y: "padding_left_top";
9359                }
9360                rel2 {
9361                    relative: 0.0 0.0;
9362                    to: "padding_right_bottom";
9363                }
9364                color: BUTTON_NAVIFRAME_DEFAULT_TEXT_COLOR_INC;
9365                text {
9366                   style: "btn_multiline_naviframe_controlbar_style";
9367                   min: 0 0;
9368                   max: 0 1;
9369                }
9370             }
9371             description { state: "visible" 0.0;
9372                inherit: "default" 0.0;
9373                visible: 1;
9374                min: 80 0;
9375             }
9376             description { state: "clicked" 0.0;
9377                inherit: "default" 0.0;
9378                visible: 1;
9379                min: 0 0;
9380             }
9381             description { state: "focused" 0.0;
9382                inherit: "default" 0.0;
9383                visible: 1;
9384                min: 0 0;
9385                color: BUTTON_NAVIFRAME_FOCUSED_TEXT_COLOR_INC;
9386             }
9387          }
9388          part { name: "over2";
9389             type: RECT;
9390             repeat_events: 1;
9391             ignore_flags: ON_HOLD;
9392             description { state: "default" 0.0;
9393                color: 0 0 0 0;
9394             }
9395          }
9396          part { name: "over3";
9397             type: RECT;
9398             repeat_events: 1;
9399             description { state: "default" 0.0;
9400                color: 0 0 0 0;
9401             }
9402          }
9403          part { name: "clipper";
9404             type: RECT;
9405             description { state: "default" 0.0;
9406                color: 255 255 255 255;
9407             }
9408             description { state: "disabled" 0.0;
9409                color: 255 255 255 127;
9410             }
9411          }
9412          part { name: "disabler";
9413             type: RECT;
9414             description { state: "default" 0.0;
9415                color: 0 0 0 0;
9416                visible: 0;
9417             }
9418             description { state: "disabled" 0.0;
9419                inherit: "default" 0.0;
9420                visible: 1;
9421             }
9422          }
9423       }
9424       programs {
9425          program { name: "button_click";
9426             signal: "mouse,down,1";
9427             source: "over2";
9428             action: SIGNAL_EMIT "elm,action,press" "";
9429             after: "button_click_anim";
9430          }
9431          program { name: "button_click_anim";
9432             action: STATE_SET "clicked" 0.0;
9433             target: "button_image";
9434             after: "text_clicked";
9435          }
9436          program { name: "text_clicked";
9437             script {
9438                new st[31];
9439                new Float:vl;
9440                get_state(PART:"elm.text", st, 30, vl);
9441                if (!strcmp(st, "visible"))
9442                  set_state(PART:"elm.text", "clicked", 0.0);
9443             }
9444          }
9445          program { name: "button_unpress";
9446             action: SIGNAL_EMIT "elm,action,unpress" "";
9447          }
9448          program { name: "button_mouseout_clicked";
9449             signal: "mouse,up,1";
9450             source: "over3";
9451             script {
9452                new st[31];
9453                new Float:vl;
9454                get_state(PART:"elm.swallow.content", st, 30, vl);
9455                if (strcmp(st, "icononly"))
9456                  {
9457                     emit("elm,action,default,text,set", "");
9458                     set_state(PART:"elm.text", "visible", 0.0);
9459                  }
9460                if (get_int(button_state) != BUTTON_STATE_DISABLED)
9461                  set_state(PART:"button_image", "default", 0.0);
9462             }
9463             after: button_unpress;
9464          }
9465          program { name: "touch_snd";
9466             signal: "mouse,clicked,1";
9467             source: "over2";
9468             action: PLAY_SAMPLE "touch_sound" 1.0;
9469             after: button_unclick3;
9470          }
9471          program { name: "button_unclick3";
9472             action: SIGNAL_EMIT "elm,action,click" "";
9473          }
9474          program { name: "text_show";
9475             signal: "elm,state,text,visible";
9476             source: "elm";
9477             script {
9478                new st[31];
9479                new Float:vl;
9480                get_state(PART:"elm.swallow.content", st, 30, vl);
9481                if (!strcmp(st, "icononly"))
9482                  {
9483                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9484                     set_state(PART:"padding_icon_text", "visible", 0.0);
9485                  }
9486                set_state(PART:"elm.text", "visible", 0.0);
9487             }
9488          }
9489          program { name: "text_hide";
9490             signal: "elm,state,text,hidden";
9491             source: "elm";
9492             script {
9493                new st[31];
9494                new Float:vl;
9495                get_state(PART:"elm.swallow.content", st, 30, vl);
9496                if (!strcmp(st, "visible"))
9497                  {
9498                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9499                     set_state(PART:"padding_icon_text", "icononly", 0.0);
9500                  }
9501                set_state(PART:"elm.text", "default", 0.0);
9502             }
9503          }
9504          program { name: "icon_show";
9505             signal: "elm,state,icon,visible";
9506             source: "elm";
9507             script {
9508                new st[31];
9509                new Float:vl;
9510                get_state(PART:"elm.text", st, 30, vl);
9511                if (!strcmp(st, "visible"))
9512                  {
9513                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9514                     set_state(PART:"padding_icon_text", "visible", 0.0);
9515                  }
9516                else
9517                  {
9518                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9519                     set_state(PART:"padding_icon_text", "icononly", 0.0);
9520                  }
9521             }
9522          }
9523          program { name: "icon_hide";
9524             signal: "elm,state,icon,hidden";
9525             source: "elm";
9526             action: STATE_SET "default" 0.0;
9527             target: "elm.swallow.content";
9528             target: "padding_icon_text";
9529          }
9530          program { name: "disable";
9531             signal: "elm,state,disabled";
9532             source: "elm";
9533             action: STATE_SET "disabled" 0.0;
9534             target: "button_image";
9535             target: "clipper";
9536             target: "disabler";
9537             after: "disable_text";
9538          }
9539          program { name: "disable_text";
9540             script {
9541                new st[31];
9542                new Float:vl;
9543                set_int(button_state, BUTTON_STATE_DISABLED);
9544                get_state(PART:"elm.text", st, 30, vl);
9545                if (!strcmp(st, "clicked") || !strcmp(st, "focused"))
9546                  set_state(PART:"elm.text", "visible", 0.0);
9547             }
9548          }
9549          program { name: "enable";
9550             signal: "elm,state,enabled";
9551             source: "elm";
9552             action: STATE_SET "default" 0.0;
9553             target: "button_image";
9554             target: "clipper";
9555             target: "disabler";
9556             after: "enable_text";
9557          }
9558          program { name: "enable_text";
9559             script {
9560                new st[31];
9561                new Float:vl;
9562                set_int(button_state, BUTTON_STATE_ENABLED);
9563                get_state(PART:"elm.text", st, 30, vl);
9564                if (!strcmp(st, "clicked") || !strcmp(st, "focused"))
9565                  set_state(PART:"elm.text", "visible", 0.0);
9566             }
9567          }
9568          program { name: "focused";
9569             //signal: "elm,action,focus";
9570             //source: "elm";
9571             action: STATE_SET "focused" 0.0;
9572             target: "button_image";
9573             target: "elm.text";
9574          }
9575          program { name: "unfocused";
9576             //signal: "elm,action,unfocus";
9577             //source: "elm";
9578             action: STATE_SET "default" 0.0;
9579             target: "button_image";
9580             after: "unfocus_text";
9581          }
9582          program { name: "unfocus_text";
9583             action: STATE_SET "visible" 0.0;
9584             target: "elm.text";
9585          }
9586       }
9587    }
9588
9589 /////////////////////////////////////////////////////////////
9590    group { name: "elm/button/base/naviframe/title1/default";
9591       images {
9592          image: "00_winset_Back_btn_normal.png" COMP;
9593          image: "00_winset_Back_btn_press.png" COMP;
9594          image: "00_winset_Back_btn_normal_focus.png" COMP;
9595       }
9596       script {
9597          public button_state = BUTTON_STATE_ENABLED;
9598       }
9599       parts {
9600          part { name: "button_image";
9601             scale: 1;
9602             description { state: "default" 0.0;
9603                min: BUTTON_NAVIFRAME_TITLE1_BG_MIN_INC;
9604                image {
9605                   normal: "00_winset_Back_btn_normal.png";
9606                   border: BUTTON_NAVIFRAME_TITLE1_BG_BORDER_INC;
9607                   border_scale: 1;
9608                }
9609             }
9610             description { state: "clicked" 0.0;
9611                inherit: "default" 0.0;
9612                image.normal: "00_winset_Back_btn_press.png";
9613             }
9614             description { state: "disabled" 0.0;
9615                inherit: "default" 0.0;
9616                color: 127 127 127 127;
9617             }
9618             description { state: "focused" 0.0;
9619                inherit: "default" 0.0;
9620                image.normal: "00_winset_Back_btn_normal_focus.png";
9621             }
9622          }
9623          part { name: "padding_left_top";
9624             type: RECT;
9625             scale: 1;
9626             mouse_events: 0;
9627             description { state: "default" 0.0;
9628                align: 0.0 0.0;
9629                rel2.relative: 0.0 0.0;
9630                min: BUTTON_NAVIFRAME_TITLE1_PADDING_MIN_INC;
9631                fixed: 1 1;
9632                visible: 0;
9633             }
9634          }
9635          part { name: "bg";
9636             type: RECT;
9637             scale: 1;
9638             mouse_events: 0;
9639             description { state: "default" 0.0;
9640                min: BUTTON_NAVIFRAME_TITLE1_BG_MIN_INC;
9641                visible: 0;
9642             }
9643             description { state: "visible" 0.0;
9644                inherit: "default" 0.0;
9645                min: BUTTON_NAVIFRAME_TITLE1_BG_MIN_INC;
9646             }
9647             description { state: "icononly" 0.0;
9648                inherit: "default" 0.0;
9649                min: BUTTON_NAVIFRAME_TITLE1_BG_MIN_INC;
9650             }
9651          }
9652          part { name: "padding_right_bottom";
9653             type: RECT;
9654             scale: 1;
9655             mouse_events: 0;
9656             description { state: "default" 0.0;
9657                align: 1.0 1.0;
9658                rel1.relative: 1.0 1.0;
9659                min: BUTTON_NAVIFRAME_TITLE1_PADDING_MIN_INC;
9660                fixed: 1 1;
9661                visible: 0;
9662             }
9663          }
9664          part { name: "icon_rect";
9665             type: RECT;
9666             scale: 1;
9667             mouse_events: 0;
9668             description { state: "default" 0.0;
9669                visible: 0;
9670                min: 0 0;
9671                fixed: 1 0;
9672                rel1 {
9673                   relative: 1.0 1.0;
9674                   to: "padding_left_top";
9675                }
9676                rel2 {
9677                   relative: 1.0 0.0;
9678                   to_x: "padding_left_top";
9679                   to_y: "padding_right_bottom";
9680                }
9681                align: 0.0 0.5;
9682             }
9683             description { state: "visible" 0.0;
9684                visible: 0;
9685                min: BUTTON_NAVIFRAME_TITLE1_VISIBLE_ICON_RECT_MIN_MAX_INC;
9686                max: BUTTON_NAVIFRAME_TITLE1_VISIBLE_ICON_RECT_MIN_MAX_INC;
9687                fixed: 1 0;
9688                rel1 {
9689                   relative: 1.0 1.0;
9690                   to: "padding_left_top";
9691                }
9692                rel2 {
9693                   relative: 1.0 0.0;
9694                   to_x: "padding_left_top";
9695                   to_y: "padding_right_bottom";
9696                }
9697                align: 0.0 0.5;
9698             }
9699             description { state: "icononly" 0.0;
9700                inherit: "default" 0.0;
9701             }
9702          }
9703          part { name: "padding_after_icon";
9704             type: RECT;
9705             scale: 1;
9706             mouse_events: 0;
9707             description { state: "default" 0.0; //when only icon or no icon is there
9708                align: 0.0 0.0;
9709                rel1 {
9710                   relative: 1.0 0.0;
9711                   to: "icon_rect";
9712                }
9713                rel2.to: "icon_rect";
9714                fixed: 1 0;
9715                min: 0 0;
9716                visible: 0;
9717             }
9718             description { state: "visible" 0.0;
9719                visible: 0;
9720                align: 0.0 0.0;
9721                rel1 {
9722                   relative: 1.0 0.0;
9723                   to: "icon_rect";
9724                }
9725                rel2.to: "icon_rect";
9726                fixed: 1 0;
9727                min: BUTTON_NAVIFRAME_TITLE1_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
9728             }
9729             description { state: "icononly" 0.0;
9730                inherit: "default" 0.0;
9731             }
9732          }
9733          part { name: "padding_before_text";
9734             type: RECT;
9735             scale: 1;
9736             mouse_events: 0;
9737             description { state: "default" 0.0; //when only icon or no icon is there
9738                align: 1.0 0.5;
9739                rel1 {
9740                   relative: 0.0 1.0;
9741                   to_x: "elm.text";
9742                   to_y: "padding_left_top";
9743                }
9744                rel2 {
9745                   relative: 0.0 0.0;
9746                   to_x: "elm.text";
9747                   to_y: "padding_right_bottom";
9748                }
9749                fixed: 1 0;
9750                min: BUTTON_NAVIFRAME_TITLE1_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
9751                visible: 0;
9752             }
9753          }
9754          part { name: "elm.swallow.content";
9755             type: SWALLOW;
9756             scale: 1;
9757             clip_to: "clipper";
9758             description { state: "default" 0.0;
9759                visible: 0;
9760                align: 0.0 0.5;
9761                rel1 {
9762                   relative: 1.0 1.0;
9763                   to: "padding_left_top";
9764                }
9765                rel2 {
9766                   relative: 1.0 0.0;
9767                   to_x: "padding_left_top";
9768                   to_y: "padding_right_bottom";
9769                }
9770                fixed: 1 0;
9771             }
9772             description { state: "visible" 0.0;
9773                fixed: 1 0;
9774                min: BUTTON_NAVIFRAME_TITLE1_VISIBLE_ICON_MIN_MAX_INC;
9775                max: BUTTON_NAVIFRAME_TITLE1_VISIBLE_ICON_MIN_MAX_INC;
9776                align: 1.0 0.5;
9777                rel1 {
9778                   relative: 0.0 1.0;
9779                   to_x: "padding_before_text";
9780                   to_y: "padding_left_top";
9781                }
9782                rel2 {
9783                   relative: 0.0 0.0;
9784                   to_x: "padding_before_text";
9785                   to_y: "padding_right_bottom";
9786                }
9787             }
9788             description { state: "icononly" 0.0;
9789                min: BUTTON_NAVIFRAME_TITLE1_ICONONLY_ICON_MIN_MAX_INC;
9790                max: BUTTON_NAVIFRAME_TITLE1_ICONONLY_ICON_MIN_MAX_INC;
9791             }
9792          }
9793          part { name: "elm.text";
9794             type: TEXT;
9795             mouse_events: 0;
9796             scale: 1;
9797             clip_to: "clipper";
9798             description { state: "default" 0.0;
9799                visible: 0;
9800                rel1 {
9801                   relative: 1.0 1.0;
9802                   to_x: "padding_after_icon";
9803                   to_y: "padding_left_top";
9804                }
9805                rel2 {
9806                   relative: 0.0 0.0;
9807                   to: "padding_right_bottom";
9808                }
9809                color: BUTTON_NAVIFRAME_TITLE1_NORMAL_COLOR_INC;
9810                text {
9811                   font: "SLP:style=Medium";
9812                   size: BUTTON_NAVIFRAME_TITLE1_FONT_SIZE_INC;
9813                   min: 1 0;
9814                   max: 1 0;
9815                   text_class: "slp_medium";
9816                }
9817             }
9818             description { state: "visible" 0.0;
9819                inherit: "default" 0.0;
9820                visible: 1;
9821             }
9822             description { state: "clicked" 0.0;
9823                inherit: "default" 0.0;
9824                visible: 1;
9825                color: BUTTON_NAVIFRAME_TITLE1_PRESSED_COLOR_INC;
9826             }
9827             description { state: "disabled" 0.0;
9828                inherit: "default" 0.0;
9829                color: 0 0 0 128;
9830             }
9831             description { state: "disabled_visible" 0.0;
9832                inherit: "default" 0.0;
9833                color: BUTTON_NAVIFRAME_TITLE1_DISABLED_COLOR_INC;
9834                visible: 1;
9835             }
9836             description { state: "focused" 0.0;
9837                inherit: "default" 0.0;
9838                visible: 1;
9839                color: BUTTON_NAVIFRAME_TITLE1_FOCUSED_COLOR_INC;
9840             }
9841          }
9842          part { name: "over2";
9843             type: RECT;
9844             repeat_events: 1;
9845             ignore_flags: ON_HOLD;
9846             description { state: "default" 0.0;
9847                color: 0 0 0 0;
9848             }
9849          }
9850          part { name: "over3";
9851             type: RECT;
9852             repeat_events: 1;
9853             description { state: "default" 0.0;
9854                color: 0 0 0 0;
9855             }
9856          }
9857          part { name: "clipper";
9858             type: RECT;
9859             description { state: "default" 0.0;
9860                color: 255 255 255 255;
9861             }
9862          }
9863          part { name: "disabler";
9864             type: RECT;
9865             description { state: "default" 0.0;
9866                color: 0 0 0 0;
9867                visible: 0;
9868             }
9869             description { state: "disabled" 0.0;
9870                inherit: "default" 0.0;
9871                visible: 1;
9872             }
9873          }
9874       }
9875       programs {
9876          program { name: "button_click";
9877             signal: "mouse,down,1";
9878             source: "over2";
9879             action: SIGNAL_EMIT "elm,action,press" "";
9880             after: "button_click_anim";
9881          }
9882          program { name: "button_click_anim";
9883             action: STATE_SET "clicked" 0.0;
9884             target: "button_image";
9885             after: "text_clicked";
9886          }
9887          program { name: "text_clicked";
9888             script {
9889                new st[31];
9890                new Float:vl;
9891                get_state(PART:"elm.text", st, 30, vl);
9892                if (!strcmp(st, "visible"))
9893                  set_state(PART:"elm.text", "clicked", 0.0);
9894             }
9895          }
9896          program { name: "button_unpress";
9897             action: SIGNAL_EMIT "elm,action,unpress" "";
9898          }
9899          program { name: "button_mouseout_clicked";
9900             signal: "mouse,up,1";
9901             source: "over3";
9902             script {
9903                new st[31];
9904                new Float:vl;
9905                get_state(PART:"elm.swallow.content", st, 30, vl);
9906                if (strcmp(st, "icononly"))
9907                  {
9908                     emit("elm,action,default,text,set", "");
9909                     set_state(PART:"elm.text", "visible", 0.0);
9910                  }
9911                if (get_int(button_state) != BUTTON_STATE_DISABLED)
9912                  set_state(PART:"button_image", "default", 0.0);
9913             }
9914             after: button_unpress;
9915          }
9916          program { name: "touch_snd";
9917             signal: "mouse,clicked,1";
9918             source: "over2";
9919             action: PLAY_SAMPLE "touch_sound" 1.0;
9920             after: button_unclick3;
9921          }
9922          program { name: "button_unclick3";
9923             action: SIGNAL_EMIT "elm,action,click" "";
9924          }
9925          program { name: "text_show";
9926             signal: "elm,state,text,visible";
9927             source: "elm";
9928             script {
9929                new st[31];
9930                new Float:vl;
9931                get_state(PART:"elm.swallow.content", st, 30, vl);
9932                if (!strcmp(st, "icononly"))
9933                  {
9934                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9935                     set_state(PART:"icon_rect", "visible", 0.0);
9936                     set_state(PART:"padding_after_icon", "visible", 0.0);
9937                     set_state(PART:"bg", "visible", 0.0);
9938                  }
9939                if (get_int(button_state) != BUTTON_STATE_DISABLED)
9940                  set_state(PART:"elm.text", "visible", 0.0);
9941                else
9942                  set_state(PART:"elm.text", "disabled_visible", 0.0);
9943             }
9944          }
9945          program { name: "text_hide";
9946             signal: "elm,state,text,hidden";
9947             source: "elm";
9948             script {
9949                new st[31];
9950                new Float:vl;
9951                get_state(PART:"elm.swallow.content", st, 30, vl);
9952                if (!strcmp(st, "visible"))
9953                  {
9954                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9955                     set_state(PART:"icon_rect", "icononly", 0.0);
9956                     set_state(PART:"padding_after_icon", "icononly", 0.0);
9957                     set_state(PART:"bg", "icononly", 0.0);
9958                  }
9959                set_state(PART:"elm.text", "default", 0.0);
9960             }
9961          }
9962          program { name: "icon_show";
9963             signal: "elm,state,icon,visible";
9964             source: "elm";
9965             script {
9966                new st[31];
9967                new Float:vl;
9968                get_state(PART:"elm.text", st, 30, vl);
9969                if (!strcmp(st, "visible"))
9970                  {
9971                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9972                     set_state(PART:"icon_rect", "visible", 0.0);
9973                     set_state(PART:"padding_after_icon", "visible", 0.0);
9974                     set_state(PART:"bg", "visible", 0.0);
9975                  }
9976                else
9977                  {
9978                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9979                     set_state(PART:"icon_rect", "icononly", 0.0);
9980                     set_state(PART:"padding_after_icon", "icononly", 0.0);
9981                     set_state(PART:"bg", "icononly", 0.0);
9982                  }
9983             }
9984          }
9985          program { name: "icon_hide";
9986             signal: "elm,state,icon,hidden";
9987             source: "elm";
9988             action: STATE_SET "default" 0.0;
9989             target: "elm.swallow.content";
9990             target: "padding_after_icon";
9991             target: "icon_rect";
9992             target: "bg";
9993          }
9994          program { name: "disable";
9995             signal: "elm,state,disabled";
9996             source: "elm";
9997             action: STATE_SET "disabled" 0.0;
9998             target: "button_image";
9999             target: "disabler";
10000             after: "disable_text";
10001          }
10002          program { name: "disable_text";
10003             script {
10004                new st[31];
10005                new Float:vl;
10006                get_state(PART:"elm.text", st, 30, vl);
10007                if (!strcmp(st, "visible"))
10008                  set_state(PART:"elm.text", "disabled_visible", 0.0);
10009                else
10010                  set_state(PART:"elm.text", "disabled", 0.0);
10011                set_int(button_state, BUTTON_STATE_DISABLED);
10012             }
10013          }
10014          program { name: "enable";
10015             signal: "elm,state,enabled";
10016             source: "elm";
10017             action: STATE_SET "default" 0.0;
10018             target: "button_image";
10019             target: "disabler";
10020             after: "enable_text";
10021          }
10022          program { name: "enable_text";
10023             script {
10024                new st[31];
10025                new Float:vl;
10026                get_state(PART:"elm.text", st, 30, vl);
10027                if (!strcmp(st, "disabled_visible"))
10028                  set_state(PART:"elm.text", "visible", 0.0);
10029                else
10030                  set_state(PART:"elm.text", "default", 0.0);
10031                set_int(button_state, BUTTON_STATE_ENABLED);
10032             }
10033          }
10034          program { name: "focused";
10035             //signal: "elm,action,focus";
10036             //source: "elm";
10037             action: STATE_SET "focused" 0.0;
10038             target: "button_image";
10039             target: "elm.text";
10040          }
10041          program { name: "unfocused";
10042             //signal: "elm,action,unfocus";
10043             //source: "elm";
10044             action: STATE_SET "default" 0.0;
10045             target: "button_image";
10046             after: "unfocus_text";
10047          }
10048          program { name: "unfocus_text";
10049             action: STATE_SET "visible" 0.0;
10050             target: "elm.text";
10051          }
10052       }
10053    }
10054
10055 //////////////////////////////////////////////////////////////
10056    group { name: "elm/button/base/naviframe/title/default";
10057       script {
10058          public button_state = BUTTON_STATE_ENABLED;
10059       }
10060       images {
10061          image: "00_title_btn_bg_press.png" COMP;
10062       }
10063       styles{
10064          style { name: "btn_naviframe_style";
10065             base: "font=SLP:style=Medium font_size="BUTTON_NAVIFRAME_TITLE_TEXT_FONT_SIZE_INC" align=center color=#ffffff wrap=mixed ellipise=1.0 text_class=slp_medium";
10066             tag: "br" "\n";
10067             tag: "ps" "ps";
10068             tag: "tab" "\t";
10069          }
10070       }
10071       parts {
10072          part { name: "button_image";
10073             scale: 1;
10074             description { state: "default" 0.0;
10075                min: BUTTON_NAVIFRAME_TITLE_TEXT_BG_NORMAL_MIN_INC;
10076                max: BUTTON_NAVIFRAME_TITLE_TEXT_BG_NORMAL_MIN_INC;
10077                color: 0 0 0 0;
10078             }
10079             description { state: "clicked" 0.0;
10080                min: BUTTON_NAVIFRAME_TITLE_TEXT_BG_PRESSED_MIN_INC;
10081                max: BUTTON_NAVIFRAME_TITLE_TEXT_BG_PRESSED_MIN_INC;
10082                image {
10083                   normal: "00_title_btn_bg_press.png";
10084                   border: BUTTON_NAVIFRAME_TITLE_TEXT_BG_PRESSED_BORDER_INC;
10085                   border_scale: 1;
10086                }
10087             }
10088             description { state: "disabled" 0.0;
10089                inherit: "default" 0.0;
10090             }
10091             description { state: "focused" 0.0;
10092                inherit: "default" 0.0;
10093             }
10094          }
10095          part { name: "padding_left_top";
10096             type: RECT;
10097             scale: 1;
10098             mouse_events: 0;
10099             description { state: "default" 0.0;
10100                align: 0.0 0.0;
10101                rel2.relative: 0.0 0.0;
10102                min: BUTTON_NAVIFRAME_TITLE_TEXT_PADDING_MIN_INC;
10103                fixed: 1 1;
10104                visible: 0;
10105             }
10106          }
10107          part { name: "padding_right_bottom";
10108             type: RECT;
10109             scale: 1;
10110             mouse_events: 0;
10111             description { state: "default" 0.0;
10112                align: 1.0 1.0;
10113                rel1.relative: 1.0 1.0;
10114                min: BUTTON_NAVIFRAME_TITLE_TEXT_PADDING_MIN_INC;
10115                fixed: 1 1;
10116                visible: 0;
10117             }
10118          }
10119          part { name: "icon_rect";
10120             type: RECT;
10121             scale: 1;
10122             mouse_events: 0;
10123             description { state: "default" 0.0;
10124                visible: 0;
10125                min: 0 0;
10126                fixed: 1 0;
10127                rel1 {
10128                   relative: 1.0 1.0;
10129                   to: "padding_left_top";
10130                }
10131                rel2 {
10132                   relative: 1.0 0.0;
10133                   to_x: "padding_left_top";
10134                   to_y: "padding_right_bottom";
10135                }
10136                align: 0.0 0.5;
10137             }
10138             description { state: "visible" 0.0;
10139                visible: 0;
10140                min: BUTTON_NAVIFRAME_TITLE_VISIBLE_ICON_RECT_MIN_MAX_INC;
10141                max: BUTTON_NAVIFRAME_TITLE_VISIBLE_ICON_RECT_MIN_MAX_INC;
10142                fixed: 1 0;
10143                rel1 {
10144                   relative: 1.0 1.0;
10145                   to: "padding_left_top";
10146                }
10147                rel2 {
10148                   relative: 1.0 0.0;
10149                   to_x: "padding_left_top";
10150                   to_y: "padding_right_bottom";
10151                }
10152                align: 0.0 0.5;
10153             }
10154             description { state: "icononly" 0.0;
10155                inherit: "default" 0.0;
10156             }
10157          }
10158          part { name: "padding_after_icon";
10159             type: RECT;
10160             scale: 1;
10161             mouse_events: 0;
10162             description { state: "default" 0.0; //when only icon or no icon is there
10163                align: 0.0 0.0;
10164                rel1 {
10165                   relative: 1.0 0.0;
10166                   to: "icon_rect";
10167                }
10168                rel2.to: "icon_rect";
10169                fixed: 1 0;
10170                min: 0 0;
10171                visible: 0;
10172             }
10173             description { state: "visible" 0.0;
10174                visible: 0;
10175                align: 0.0 0.0;
10176                rel1 {
10177                   relative: 1.0 0.0;
10178                   to: "icon_rect";
10179                }
10180                rel2.to: "icon_rect";
10181                fixed: 1 0;
10182                min: BUTTON_NAVIFRAME_TITLE_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
10183             }
10184             description { state: "icononly" 0.0;
10185                inherit: "default" 0.0;
10186             }
10187          }
10188          part { name: "padding_before_text";
10189             type: RECT;
10190             scale: 1;
10191             mouse_events: 0;
10192             description { state: "default" 0.0; //when only icon or no icon is there
10193                align: 1.0 0.5;
10194                rel1 {
10195                   relative: 0.0 1.0;
10196                   to_x: "elm.text";
10197                   to_y: "padding_left_top";
10198                }
10199                rel2 {
10200                   relative: 0.0 0.0;
10201                   to_x: "elm.text";
10202                   to_y: "padding_right_bottom";
10203                }
10204                fixed: 1 0;
10205                min: BUTTON_NAVIFRAME_TITLE_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
10206                visible: 0;
10207             }
10208          }
10209          part { name: "elm.swallow.content";
10210             type: SWALLOW;
10211             scale: 1;
10212             clip_to: "clipper";
10213             description { state: "default" 0.0;
10214                visible: 0;
10215                align: 0.0 0.5;
10216                rel1 {
10217                   relative: 1.0 1.0;
10218                   to: "padding_left_top";
10219                }
10220                rel2 {
10221                   relative: 1.0 0.0;
10222                   to_x: "padding_left_top";
10223                   to_y: "padding_right_bottom";
10224                }
10225                fixed: 1 0;
10226             }
10227             description { state: "visible" 0.0;
10228                fixed: 1 0;
10229                min: BUTTON_NAVIFRAME_TITLE_VISIBLE_ICON_RECT_MIN_MAX_INC;
10230                max: BUTTON_NAVIFRAME_TITLE_VISIBLE_ICON_RECT_MIN_MAX_INC;
10231                align: 1.0 0.5;
10232                rel1 {
10233                   relative: 0.0 1.0;
10234                   to_x: "padding_before_text";
10235                   to_y: "padding_left_top";
10236                }
10237                rel2 {
10238                   relative: 0.0 0.0;
10239                   to_x: "padding_before_text";
10240                   to_y: "padding_right_bottom";
10241                }
10242             }
10243             description { state: "icononly" 0.0;
10244                min: BUTTON_NAVIFRAME_TITLE_ICONONLY_ICON_MIN_MAX_INC;
10245                max: BUTTON_NAVIFRAME_TITLE_ICONONLY_ICON_MIN_MAX_INC;
10246             }
10247          }
10248          part { name: "elm.text";
10249             type: TEXTBLOCK;
10250             mouse_events: 0;
10251             scale: 1;
10252             clip_to: "clipper";
10253             description { state: "default" 0.0;
10254                visible: 0;
10255                rel1 {
10256                   relative: 1.0 1.0;
10257                   to_x: "padding_after_icon";
10258                   to_y: "padding_left_top";
10259                }
10260                rel2 {
10261                   relative: 0.0 0.0;
10262                   to: "padding_right_bottom";
10263                }
10264                color: BUTTON_NAVIFRAME_TITLE_TEXT_NORMAL_COLOR_INC;
10265                text {
10266                    style: "btn_naviframe_style";
10267                    min: 0 0;
10268                    max: 0 1;
10269                }
10270             }
10271             description { state: "visible" 0.0;
10272                inherit: "default" 0.0;
10273                visible: 1;
10274             }
10275             description { state: "clicked" 0.0;
10276                inherit: "default" 0.0;
10277                visible: 1;
10278                color: BUTTON_NAVIFRAME_TITLE_TEXT_PRESSED_COLOR_INC;
10279             }
10280             description { state: "disabled" 0.0;
10281                inherit: "default" 0.0;
10282                color: 0 0 0 128;
10283             }
10284             description { state: "disabled_visible" 0.0;
10285                inherit: "default" 0.0;
10286                color: BUTTON_NAVIFRAME_TITLE_TEXT_DISABLED_COLOR_INC;
10287                visible: 1;
10288             }
10289             description { state: "focused" 0.0;
10290                inherit: "default" 0.0;
10291                visible: 1;
10292                color: BUTTON_NAVIFRAME_TITLE_TEXT_FOCUSED_COLOR_INC;
10293             }
10294          }
10295          part { name: "over2";
10296             type: RECT;
10297             repeat_events: 1;
10298             ignore_flags: ON_HOLD;
10299             description { state: "default" 0.0;
10300                color: 0 0 0 0;
10301             }
10302          }
10303          part { name: "over3";
10304             type: RECT;
10305             repeat_events: 1;
10306             description { state: "default" 0.0;
10307                color: 0 0 0 0;
10308             }
10309          }
10310          part { name: "clipper";
10311             type: RECT;
10312             description { state: "default" 0.0;
10313                color: 255 255 255 255;
10314             }
10315          }
10316          part { name: "disabler";
10317             type: RECT;
10318             description { state: "default" 0.0;
10319                color: 0 0 0 0;
10320                visible: 0;
10321             }
10322             description { state: "disabled" 0.0;
10323                inherit: "default" 0.0;
10324                visible: 1;
10325             }
10326          }
10327       }
10328       programs {
10329          program { name: "button_click";
10330             signal: "mouse,down,1";
10331             source: "over2";
10332             action: SIGNAL_EMIT "elm,action,press" "";
10333             after: "button_click_anim";
10334          }
10335          program { name: "button_click_anim";
10336             action: STATE_SET "clicked" 0.0;
10337             target: "button_image";
10338             after: "text_clicked";
10339          }
10340          program { name: "text_clicked";
10341             script {
10342                new st[31];
10343                new Float:vl;
10344                get_state(PART:"elm.text", st, 30, vl);
10345                if (!strcmp(st, "visible"))
10346                  set_state(PART:"elm.text", "clicked", 0.0);
10347             }
10348          }
10349          program { name: "button_unpress";
10350             action: SIGNAL_EMIT "elm,action,unpress" "";
10351          }
10352          program { name: "button_mouseout_clicked";
10353             signal: "mouse,up,1";
10354             source: "over3";
10355             script {
10356                new st[31];
10357                new Float:vl;
10358                get_state(PART:"elm.swallow.content", st, 30, vl);
10359                if (strcmp(st, "icononly"))
10360                  {
10361                     emit("elm,action,default,text,set", "");
10362                     set_state(PART:"elm.text", "visible", 0.0);
10363                  }
10364                if (get_int(button_state) != BUTTON_STATE_DISABLED)
10365                  set_state(PART:"button_image", "default", 0.0);
10366             }
10367             after: button_unpress;
10368          }
10369          program { name: "touch_snd";
10370             signal: "mouse,clicked,1";
10371             source: "over2";
10372             action: PLAY_SAMPLE "touch_sound" 1.0;
10373             after: button_unclick3;
10374          }
10375          program { name: "button_unclick3";
10376             action: SIGNAL_EMIT "elm,action,click" "";
10377          }
10378          program { name: "text_show";
10379             signal: "elm,state,text,visible";
10380             source: "elm";
10381             script {
10382                new st[31];
10383                new Float:vl;
10384                get_state(PART:"elm.swallow.content", st, 30, vl);
10385                if (!strcmp(st, "icononly"))
10386                  {
10387                     set_state(PART:"elm.swallow.content", "visible", 0.0);
10388                     set_state(PART:"icon_rect", "visible", 0.0);
10389                     set_state(PART:"padding_after_icon", "visible", 0.0);
10390                  }
10391                if (get_int(button_state) != BUTTON_STATE_DISABLED)
10392                  set_state(PART:"elm.text", "visible", 0.0);
10393                else
10394                  set_state(PART:"elm.text", "disabled_visible", 0.0);
10395             }
10396          }
10397          program { name: "text_hide";
10398             signal: "elm,state,text,hidden";
10399             source: "elm";
10400             script {
10401                new st[31];
10402                new Float:vl;
10403                get_state(PART:"elm.swallow.content", st, 30, vl);
10404                if (!strcmp(st, "visible"))
10405                  {
10406                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
10407                     set_state(PART:"icon_rect", "icononly", 0.0);
10408                     set_state(PART:"padding_after_icon", "icononly", 0.0);
10409                  }
10410                set_state(PART:"elm.text", "default", 0.0);
10411             }
10412          }
10413          program { name: "icon_show";
10414             signal: "elm,state,icon,visible";
10415             source: "elm";
10416             script {
10417                new st[31];
10418                new Float:vl;
10419                get_state(PART:"elm.text", st, 30, vl);
10420                if (!strcmp(st, "visible"))
10421                  {
10422                     set_state(PART:"elm.swallow.content", "visible", 0.0);
10423                     set_state(PART:"icon_rect", "visible", 0.0);
10424                     set_state(PART:"padding_after_icon", "visible", 0.0);
10425                  }
10426                else
10427                  {
10428                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
10429                     set_state(PART:"icon_rect", "icononly", 0.0);
10430                     set_state(PART:"padding_after_icon", "icononly", 0.0);
10431                  }
10432             }
10433          }
10434          program { name: "icon_hide";
10435             signal: "elm,state,icon,hidden";
10436             source: "elm";
10437             action: STATE_SET "default" 0.0;
10438             target: "elm.swallow.content";
10439             target: "padding_after_icon";
10440             target: "icon_rect";
10441          }
10442          program { name: "disable";
10443             signal: "elm,state,disabled";
10444             source: "elm";
10445             action: STATE_SET "disabled" 0.0;
10446             target: "button_image";
10447             target: "disabler";
10448             after: "disable_text";
10449          }
10450          program { name: "disable_text";
10451             script {
10452                new st[31];
10453                new Float:vl;
10454                get_state(PART:"elm.text", st, 30, vl);
10455                if (!strcmp(st, "visible"))
10456                  set_state(PART:"elm.text", "disabled_visible", 0.0);
10457                else
10458                  set_state(PART:"elm.text", "disabled", 0.0);
10459                set_int(button_state, BUTTON_STATE_DISABLED);
10460             }
10461          }
10462          program { name: "enable";
10463             signal: "elm,state,enabled";
10464             source: "elm";
10465             action: STATE_SET "default" 0.0;
10466             target: "button_image";
10467             target: "disabler";
10468             after: "enable_text";
10469          }
10470          program { name: "enable_text";
10471             script {
10472                new st[31];
10473                new Float:vl;
10474                get_state(PART:"elm.text", st, 30, vl);
10475                if (!strcmp(st, "disabled_visible"))
10476                  set_state(PART:"elm.text", "visible", 0.0);
10477                else
10478                  set_state(PART:"elm.text", "default", 0.0);
10479                set_int(button_state, BUTTON_STATE_ENABLED);
10480             }
10481          }
10482          program { name: "focused";
10483             //signal: "elm,action,focus";
10484             //source: "elm";
10485             action: STATE_SET "focused" 0.0;
10486             target: "button_image";
10487             target: "elm.text";
10488          }
10489          program { name: "unfocused";
10490             //signal: "elm,action,unfocus";
10491             //source: "elm";
10492             action: STATE_SET "default" 0.0;
10493             target: "button_image";
10494             after: "unfocus_text";
10495          }
10496          program { name: "unfocus_text";
10497             action: STATE_SET "visible" 0.0;
10498             target: "elm.text";
10499          }
10500       }
10501    }
10502
10503 ///////////////////////////////////////////////////////////////////////////////////////
10504 #define BUTTON_NAVIFRAME_TITLE_ICON_STYLES(style_name, image_normal, image_press, min_width, min_height) \
10505    group { name: "elm/button/base/naviframe/title/icon/"style_name; \
10506       images { \
10507          image: image_normal COMP; \
10508          image: image_press COMP; \
10509          image: "00_title_btn_bg_press.png" COMP; \
10510       } \
10511       parts { \
10512          part { name: "button_image"; \
10513             scale: 1; \
10514             description { state: "default" 0.0; \
10515                min: BUTTON_NAVIFRAME_TITLE_ICON_BG_NORMAL_MIN_INC; \
10516                max: BUTTON_NAVIFRAME_TITLE_ICON_BG_NORMAL_MIN_INC; \
10517                color: 0 0 0 0; \
10518             } \
10519             description { \
10520                state: "clicked" 0.0; \
10521                min: BUTTON_NAVIFRAME_TITLE_ICON_BG_PRESSED_MIN_INC; \
10522                max: BUTTON_NAVIFRAME_TITLE_ICON_BG_PRESSED_MIN_INC; \
10523                image { \
10524                   normal: "00_title_btn_bg_press.png"; \
10525                   border: BUTTON_NAVIFRAME_TITLE_ICON_BG_PRESSED_BORDER_INC; \
10526                   border_scale: 1; \
10527                } \
10528             } \
10529             description { \
10530                state: "disabled" 0.0; \
10531                inherit: "default" 0.0; \
10532             } \
10533             description { state: "focused" 0.0; \
10534                inherit: "default" 0.0;\
10535             } \
10536          } \
10537          part { name: "icon_part"; \
10538             scale: 1; \
10539             description { state: "default" 0.0; \
10540                min: min_width min_height; \
10541                max: min_width min_height; \
10542                rel1.to: "button_image"; \
10543                rel2.to: "button_image"; \
10544                image.normal: image_normal; \
10545             } \
10546             description { \
10547                state: "clicked" 0.0; \
10548                inherit: "default" 0.0; \
10549                image.normal: image_press; \
10550             } \
10551             description { \
10552                state: "disabled" 0.0; \
10553                inherit: "default" 0.0; \
10554                color: 127 127 127 127; \
10555             } \
10556          } \
10557          part { name: "over1"; \
10558             type: RECT; \
10559             ignore_flags: ON_HOLD; \
10560             description { state: "default" 0.0; \
10561                color: 0 0 0 0; \
10562             } \
10563          } \
10564          part { name: "over2"; \
10565             repeat_events: 1; \
10566             description { state: "default" 0.0; \
10567                color: 0 0 0 0; \
10568             } \
10569          } \
10570          part { name: "disabler"; \
10571             type: RECT; \
10572             description { state: "default" 0.0; \
10573                color: 0 0 0 0; \
10574                visible: 0; \
10575             } \
10576             description { state: "disabled" 0.0; \
10577                inherit: "default" 0.0; \
10578                visible: 1; \
10579             } \
10580          } \
10581       } \
10582       programs { \
10583          program { name: "button_click"; \
10584             signal: "mouse,down,1"; \
10585             source: "over1"; \
10586             action: SIGNAL_EMIT "elm,action,press" ""; \
10587             after: "button_click_anim"; \
10588          } \
10589          program { name: "button_click_anim"; \
10590             action: STATE_SET "clicked" 0.0; \
10591             target: "button_image"; \
10592             target: "icon_part"; \
10593          } \
10594          program { name: "button_unclick"; \
10595             signal: "mouse,up,1"; \
10596             source: "over2"; \
10597             action: SIGNAL_EMIT "elm,action,unpress" ""; \
10598             after: "button_unclick_anim"; \
10599          } \
10600          program { name: "button_unclick_anim"; \
10601             action: STATE_SET "default" 0.0; \
10602             target: "button_image"; \
10603             target: "icon_part"; \
10604          } \
10605          program { name: "touch_snd"; \
10606             signal: "mouse,clicked,1"; \
10607             source: "over1"; \
10608             action: PLAY_SAMPLE "touch_sound" 1.0; \
10609             after: button_unclick3; \
10610          } \
10611          program { name: "button_unclick3"; \
10612             action: SIGNAL_EMIT "elm,action,click" ""; \
10613          } \
10614          program { name: "disable"; \
10615             signal: "elm,state,disabled"; \
10616             source: "elm"; \
10617             action: STATE_SET "disabled" 0.0; \
10618             target: "disabler"; \
10619             target: "button_image"; \
10620             target: "icon_part"; \
10621          } \
10622          program { name: "enable"; \
10623             signal: "elm,state,enabled"; \
10624             source: "elm"; \
10625             action: STATE_SET "default" 0.0; \
10626             target: "disabler"; \
10627             target: "button_image"; \
10628             target: "icon_part"; \
10629          } \
10630       } \
10631    }
10632 ///////////////////////////////////////////////////////////////////////////////////////
10633    BUTTON_NAVIFRAME_TITLE_ICON_STYLES("cancel", "00_button_cancel.png", "00_button_cancel_pressed.png", BUTTON_NAVIFRAME_TITLE_ICON_CANCEL_MIN_WIDTH_INC, BUTTON_NAVIFRAME_TITLE_ICON_CANCEL_MIN_HEIGHT_INC)
10634
10635    BUTTON_NAVIFRAME_TITLE_ICON_STYLES("plus", "00_button_plus.png", "00_button_plus_pressed.png", BUTTON_NAVIFRAME_TITLE_ICON_PLUS_MIN_WIDTH_INC, BUTTON_NAVIFRAME_TITLE_ICON_PLUS_MIN_HEIGHT_INC)
10636
10637    BUTTON_NAVIFRAME_TITLE_ICON_STYLES("more", "00_winset_more.png", "00_winset_more_press.png", BUTTON_NAVIFRAME_TITLE_ICON_MORE_MIN_WIDTH_INC, BUTTON_NAVIFRAME_TITLE_ICON_MORE_MIN_HEIGHT_INC)
10638
10639    BUTTON_NAVIFRAME_TITLE_ICON_STYLES("search", "00_title_icon_search.png", "00_title_icon_search_press.png", BUTTON_NAVIFRAME_TITLE_ICON_SEARCH_MIN_WIDTH_INC, BUTTON_NAVIFRAME_TITLE_ICON_SEARCH_MIN_HEIGHT_INC)
10640
10641    BUTTON_NAVIFRAME_TITLE_ICON_STYLES("previous", "00_winset_Back.png", "00_winset_Back.png", BUTTON_NAVIFRAME_TITLE_ICON_PREV_MIN_WIDTH_INC, BUTTON_NAVIFRAME_TITLE_ICON_PREV_MIN_HEIGHT_INC)
10642
10643 /////////////////////////////////////////////////////////////////////////////////////////
10644    group { name: "elm/button/base/naviframe/more/default";
10645       images {
10646          image: "00_winset_more.png" COMP;
10647          image: "00_winset_more_press.png" COMP;
10648          image: "00_title_btn_bg_press.png" COMP;
10649       }
10650       parts {
10651          part { name: "button_image";
10652             scale: 1;
10653             description { state: "default" 0.0;
10654                min: BUTTON_NAVIFRAME_MORE_BG_MIN_MAX_INC;
10655                max: BUTTON_NAVIFRAME_MORE_BG_MIN_MAX_INC;
10656                color: 0 0 0 0;
10657             }
10658             description { state: "clicked" 0.0;
10659                min: BUTTON_NAVIFRAME_MORE_BG_PRESSED_MIN_MAX_INC;
10660                max: BUTTON_NAVIFRAME_MORE_BG_PRESSED_MIN_MAX_INC;
10661                image {
10662                   normal: "00_title_btn_bg_press.png";
10663                   border: BUTTON_NAVIFRAME_MORE_BG_PRESSED_BORDER_INC;
10664                   border_scale: 1;
10665                }
10666             }
10667             description { state: "disabled" 0.0;
10668                inherit: "default" 0.0;
10669             }
10670             description { state: "focused" 0.0;
10671                inherit: "default" 0.0;
10672             }
10673          }
10674          part { name: "more_image";
10675             scale: 1;
10676             mouse_events: 0;
10677             description { state: "default" 0.0;
10678                min: BUTTON_NAVIFRAME_MORE_DEFAULT_IMAGE_MIN_MAX_INC;
10679                max: BUTTON_NAVIFRAME_MORE_DEFAULT_IMAGE_MIN_MAX_INC;
10680                rel1.to: "button_image";
10681                rel2.to: "button_image";
10682                image.normal: "00_winset_more.png";
10683             }
10684             description { state: "clicked" 0.0;
10685                inherit: "default" 0.0;
10686                image.normal: "00_winset_more_press.png";
10687             }
10688             description { state: "disabled" 0.0;
10689                inherit: "default" 0.0;
10690                color: 255 255 255 127;
10691             }
10692          }
10693          part { name: "over2";
10694             type: RECT;
10695             repeat_events: 1;
10696             ignore_flags: ON_HOLD;
10697             description { state: "default" 0.0;
10698                color: 0 0 0 0;
10699             }
10700          }
10701          part { name: "over3";
10702             type: RECT;
10703             repeat_events: 1;
10704             description { state: "default" 0.0;
10705                color: 0 0 0 0;
10706             }
10707          }
10708          part { name: "disabler";
10709             type: RECT;
10710             description { state: "default" 0.0;
10711                color: 0 0 0 0;
10712                visible: 0;
10713             }
10714             description { state: "disabled" 0.0;
10715                inherit: "default" 0.0;
10716                visible: 1;
10717             }
10718          }
10719       }
10720       programs {
10721          program { name: "button_click";
10722             signal: "mouse,down,1";
10723             source: "over2";
10724             action: SIGNAL_EMIT "elm,action,press" "";
10725             after: "button_click_anim";
10726          }
10727          program { name: "button_click_anim";
10728             action: STATE_SET "clicked" 0.0;
10729             target: "button_image";
10730             target: "more_image";
10731          }
10732          program { name: "button_unclick";
10733             signal: "mouse,up,1";
10734             source: "over3";
10735             action: SIGNAL_EMIT "elm,action,unpress" "";
10736             after: "button_unclick_anim";
10737          }
10738          program { name: "button_unclick_anim";
10739             action: STATE_SET "default" 0.0;
10740             target: "button_image";
10741             target: "more_image";
10742          }
10743          program { name: "touch_snd";
10744             signal: "mouse,clicked,1";
10745             source: "over2";
10746             action: PLAY_SAMPLE "touch_sound" 1.0;
10747             after: button_unclick3;
10748          }
10749          program { name: "button_unclick3";
10750             action: SIGNAL_EMIT "elm,action,click" "";
10751          }
10752          program { name: "disable";
10753             signal: "elm,state,disabled";
10754             source: "elm";
10755             action: STATE_SET "disabled" 0.0;
10756             target: "disabler";
10757             target: "button_image";
10758             target: "more_image";
10759          }
10760          program { name: "enable";
10761             signal: "elm,state,enabled";
10762             source: "elm";
10763             action: STATE_SET "default" 0.0;
10764             target: "disabler";
10765             target: "button_image";
10766             target: "more_image";
10767          }
10768       }
10769    }
10770
10771 ///////////////////////////////////////////////////////////////////////////////////////
10772    group { name: "elm/button/base/tickernoti";
10773       images {
10774          image: "00_button_06_normal.png" COMP;
10775          image: "00_button_06_press.png" COMP;
10776          image: "00_button_06_dim.png" COMP;
10777          image: "00_button_06_normal_focus.png" COMP;
10778       }
10779       script {
10780          public button_state = BUTTON_STATE_ENABLED;
10781       }
10782       parts {
10783          part { name: "button_image";
10784             scale: 1;
10785             description { state: "default" 0.0;
10786                image {
10787                   normal: "00_button_06_normal.png";
10788                   border: BUTTON_TICKERNOTI_BG_BORDER_INC;
10789                   border_scale: 1;
10790                }
10791             }
10792             description { state: "clicked" 0.0;
10793                inherit: "default" 0.0;
10794                image.normal: "00_button_06_press.png";
10795             }
10796             description { state: "disabled" 0.0;
10797                inherit: "default" 0.0;
10798                image.normal: "00_button_06_dim.png";
10799             }
10800             description { state: "focused" 0.0;
10801                inherit: "default" 0.0;
10802                image.normal: "00_button_06_normal_focus.png";
10803             }
10804          }
10805          part { name: "padding_left_top";
10806             type: RECT;
10807             scale: 1;
10808             mouse_events: 0;
10809             description { state: "default" 0.0;
10810                align: 0.0 0.0;
10811                rel2.relative: 0.0 0.0;
10812                min: BUTTON_TICKERNOTI_PADDING_MIN_INC;
10813                fixed: 1 1;
10814                visible: 0;
10815             }
10816          }
10817          part { name: "bg";
10818             type: RECT;
10819             scale: 1;
10820             mouse_events: 0;
10821             description { state: "default" 0.0;
10822                min: BUTTON_TICKERNOTI_BG_MIN_INC;
10823                visible: 0;
10824             }
10825             description { state: "visible" 0.0;
10826                inherit: "default" 0.0;
10827                min: BUTTON_TICKERNOTI_VISIBLE_BG_MIN_INC;
10828             }
10829             description { state: "icononly" 0.0;
10830                inherit: "default" 0.0;
10831                min: BUTTON_TICKERNOTI_ICONONLY_BG_MIN_INC;
10832             }
10833          }
10834          part { name: "padding_right_bottom";
10835             type: RECT;
10836             scale: 1;
10837             mouse_events: 0;
10838             description { state: "default" 0.0;
10839                align: 1.0 1.0;
10840                rel1.relative: 1.0 1.0;
10841                min: BUTTON_TICKERNOTI_PADDING_MIN_INC;
10842                fixed: 1 1;
10843                visible: 0;
10844             }
10845          }
10846          part { name: "icon_rect";
10847             type: RECT;
10848             scale: 1;
10849             mouse_events: 0;
10850             description { state: "default" 0.0;
10851                visible: 0;
10852                min: 0 0;
10853                fixed: 1 0;
10854                rel1 {
10855                   relative: 1.0 1.0;
10856                   to: "padding_left_top";
10857                }
10858                rel2 {
10859                   relative: 1.0 0.0;
10860                   to_x: "padding_left_top";
10861                   to_y: "padding_right_bottom";
10862                }
10863                align: 0.0 0.5;
10864             }
10865             description { state: "visible" 0.0;
10866                visible: 0;
10867                min: BUTTON_TICKERNOTI_VISIBLE_ICON_RECT_MIN_MAX_INC;
10868                max: BUTTON_TICKERNOTI_VISIBLE_ICON_RECT_MIN_MAX_INC;
10869                fixed: 1 0;
10870                rel1 {
10871                   relative: 1.0 1.0;
10872                   to: "padding_left_top";
10873                }
10874                rel2 {
10875                   relative: 1.0 0.0;
10876                   to_x: "padding_left_top";
10877                   to_y: "padding_right_bottom";
10878                }
10879                align: 0.0 0.5;
10880             }
10881             description { state: "icononly" 0.0;
10882                inherit: "default" 0.0;
10883             }
10884          }
10885          part { name: "padding_after_icon";
10886             type: RECT;
10887             scale: 1;
10888             mouse_events: 0;
10889             description { state: "default" 0.0; //when only icon or no icon is there
10890                align: 0.0 0.0;
10891                rel1 {
10892                   relative: 1.0 0.0;
10893                   to: "icon_rect";
10894                }
10895                rel2.to: "icon_rect";
10896                fixed: 1 0;
10897                min: 0 0;
10898                visible: 0;
10899             }
10900             description { state: "visible" 0.0;
10901                visible: 0;
10902                align: 0.0 0.0;
10903                rel1 {
10904                   relative: 1.0 0.0;
10905                   to: "icon_rect";
10906                }
10907                rel2.to: "icon_rect";
10908                fixed: 1 0;
10909                min: BUTTON_TICKERNOTI_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
10910             }
10911             description { state: "icononly" 0.0;
10912                inherit: "default" 0.0;
10913             }
10914          }
10915          part { name: "padding_before_text";
10916             type: RECT;
10917             scale: 1;
10918             mouse_events: 0;
10919             description { state: "default" 0.0; //when only icon or no icon is there
10920                align: 1.0 0.5;
10921                rel1 {
10922                   relative: 0.0 1.0;
10923                   to_x: "elm.text";
10924                   to_y: "padding_left_top";
10925                }
10926                rel2 {
10927                   relative: 0.0 0.0;
10928                   to_x: "elm.text";
10929                   to_y: "padding_right_bottom";
10930                }
10931                fixed: 1 0;
10932                min: BUTTON_TICKERNOTI_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
10933                visible: 0;
10934             }
10935          }
10936          part { name: "elm.swallow.content";
10937             type: SWALLOW;
10938             scale: 1;
10939             clip_to: "clipper";
10940             description { state: "default" 0.0;
10941                visible: 0;
10942                align: 0.0 0.5;
10943                rel1 {
10944                   relative: 1.0 1.0;
10945                   to: "padding_left_top";
10946                }
10947                rel2 {
10948                   relative: 1.0 0.0;
10949                   to_x: "padding_left_top";
10950                   to_y: "padding_right_bottom";
10951                }
10952                fixed: 1 0;
10953             }
10954             description { state: "visible" 0.0;
10955                fixed: 1 0;
10956                min: BUTTON_TICKERNOTI_VISIBLE_ICON_MIN_MAX_INC;
10957                max: BUTTON_TICKERNOTI_VISIBLE_ICON_MIN_MAX_INC;
10958                align: 1.0 0.5;
10959                rel1 {
10960                   relative: 0.0 1.0;
10961                   to_x: "padding_before_text";
10962                   to_y: "padding_left_top";
10963                }
10964                rel2 {
10965                   relative: 0.0 0.0;
10966                   to_x: "padding_before_text";
10967                   to_y: "padding_right_bottom";
10968                }
10969             }
10970             description { state: "icononly" 0.0;
10971                min: BUTTON_TICKERNOTI_ICONONLY_ICON_MIN_MAX_INC;
10972                max: BUTTON_TICKERNOTI_ICONONLY_ICON_MIN_MAX_INC;
10973             }
10974          }
10975          part { name: "elm.text";
10976             type: TEXT;
10977             mouse_events: 0;
10978             scale: 1;
10979             clip_to: "clipper";
10980             description { state: "default" 0.0;
10981                visible: 0;
10982                rel1 {
10983                   relative: 1.0 1.0;
10984                   to_x: "padding_after_icon";
10985                   to_y: "padding_left_top";
10986                }
10987                rel2 {
10988                   relative: 0.0 0.0;
10989                   to: "padding_right_bottom";
10990                }
10991                color: BUTTON_TICKERNOTI_NORMAL_COLOR_INC;
10992                text {
10993                   font: "SLP:style=Medium";
10994                   size: BUTTON_TICKERNOTI_FONT_SIZE_INC;
10995                   min: 1 0;
10996                   max: 1 0;
10997                   text_class: "slp_medium";
10998                }
10999             }
11000             description { state: "visible" 0.0;
11001                inherit: "default" 0.0;
11002                visible: 1;
11003             }
11004             description { state: "clicked" 0.0;
11005                inherit: "default" 0.0;
11006                visible: 1;
11007                color: BUTTON_TICKERNOTI_PRESSED_COLOR_INC;
11008             }
11009             description { state: "disabled" 0.0;
11010                inherit: "default" 0.0;
11011                color: 0 0 0 128;
11012             }
11013             description { state: "disabled_visible" 0.0;
11014                inherit: "default" 0.0;
11015                color: BUTTON_TICKERNOTI_DISABLED_COLOR_INC;
11016                visible: 1;
11017             }
11018             description { state: "focused" 0.0;
11019                inherit: "default" 0.0;
11020                visible: 1;
11021                color: BUTTON_TICKERNOTI_PRESSED_COLOR_INC;
11022             }
11023          }
11024          part { name: "over2";
11025             type: RECT;
11026             repeat_events: 1;
11027             ignore_flags: ON_HOLD;
11028             description { state: "default" 0.0;
11029                color: 0 0 0 0;
11030             }
11031          }
11032          part { name: "over3";
11033             type: RECT;
11034             repeat_events: 1;
11035             description { state: "default" 0.0;
11036                color: 0 0 0 0;
11037             }
11038          }
11039          part { name: "clipper";
11040             type: RECT;
11041             description { state: "default" 0.0;
11042                color: 255 255 255 255;
11043             }
11044          }
11045          part { name: "disabler";
11046             type: RECT;
11047             description { state: "default" 0.0;
11048                color: 0 0 0 0;
11049                visible: 0;
11050             }
11051             description { state: "disabled" 0.0;
11052                inherit: "default" 0.0;
11053                visible: 1;
11054             }
11055          }
11056       }
11057       programs {
11058          program { name: "button_click";
11059             signal: "mouse,down,1";
11060             source: "over2";
11061             action: SIGNAL_EMIT "elm,action,press" "";
11062             after: "button_click_anim";
11063          }
11064          program { name: "button_click_anim";
11065             action: STATE_SET "clicked" 0.0;
11066             target: "button_image";
11067             after: "text_clicked";
11068          }
11069          program { name: "text_clicked";
11070             script {
11071                new st[31];
11072                new Float:vl;
11073                get_state(PART:"elm.text", st, 30, vl);
11074                if (!strcmp(st, "visible"))
11075                  set_state(PART:"elm.text", "clicked", 0.0);
11076             }
11077          }
11078          program { name: "button_unpress";
11079             action: SIGNAL_EMIT "elm,action,unpress" "";
11080          }
11081          program { name: "button_mouseout_clicked";
11082             signal: "mouse,up,1";
11083             source: "over3";
11084             script {
11085                new st[31];
11086                new Float:vl;
11087                get_state(PART:"elm.swallow.content", st, 30, vl);
11088                if (strcmp(st, "icononly"))
11089                  {
11090                     emit("elm,action,default,text,set", "");
11091                     set_state(PART:"elm.text", "visible", 0.0);
11092                  }
11093                if (get_int(button_state) != BUTTON_STATE_DISABLED)
11094                  set_state(PART:"button_image", "default", 0.0);
11095             }
11096             after: button_unpress;
11097          }
11098          program { name: "touch_snd";
11099             signal: "mouse,clicked,1";
11100             source: "over2";
11101             action: PLAY_SAMPLE "touch_sound" 1.0;
11102             after: button_unclick3;
11103          }
11104          program { name: "button_unclick3";
11105             action: SIGNAL_EMIT "elm,action,click" "";
11106          }
11107          program { name: "text_show";
11108             signal: "elm,state,text,visible";
11109             source: "elm";
11110             script {
11111                new st[31];
11112                new Float:vl;
11113                get_state(PART:"elm.swallow.content", st, 30, vl);
11114                if (!strcmp(st, "icononly"))
11115                  {
11116                     set_state(PART:"elm.swallow.content", "visible", 0.0);
11117                     set_state(PART:"icon_rect", "visible", 0.0);
11118                     set_state(PART:"padding_after_icon", "visible", 0.0);
11119                     set_state(PART:"bg", "visible", 0.0);
11120                  }
11121                if (get_int(button_state) != BUTTON_STATE_DISABLED)
11122                  set_state(PART:"elm.text", "visible", 0.0);
11123                else
11124                  set_state(PART:"elm.text", "disabled_visible", 0.0);
11125             }
11126          }
11127          program { name: "text_hide";
11128             signal: "elm,state,text,hidden";
11129             source: "elm";
11130             script {
11131                new st[31];
11132                new Float:vl;
11133                get_state(PART:"elm.swallow.content", st, 30, vl);
11134                if (!strcmp(st, "visible"))
11135                  {
11136                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
11137                     set_state(PART:"icon_rect", "icononly", 0.0);
11138                     set_state(PART:"padding_after_icon", "icononly", 0.0);
11139                     set_state(PART:"bg", "icononly", 0.0);
11140                  }
11141                set_state(PART:"elm.text", "default", 0.0);
11142             }
11143          }
11144          program { name: "icon_show";
11145             signal: "elm,state,icon,visible";
11146             source: "elm";
11147             script {
11148                new st[31];
11149                new Float:vl;
11150                get_state(PART:"elm.text", st, 30, vl);
11151                if (!strcmp(st, "visible"))
11152                  {
11153                     set_state(PART:"elm.swallow.content", "visible", 0.0);
11154                     set_state(PART:"icon_rect", "visible", 0.0);
11155                     set_state(PART:"padding_after_icon", "visible", 0.0);
11156                     set_state(PART:"bg", "visible", 0.0);
11157                  }
11158                else
11159                  {
11160                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
11161                     set_state(PART:"icon_rect", "icononly", 0.0);
11162                     set_state(PART:"padding_after_icon", "icononly", 0.0);
11163                     set_state(PART:"bg", "icononly", 0.0);
11164                  }
11165             }
11166          }
11167          program { name: "icon_hide";
11168             signal: "elm,state,icon,hidden";
11169             source: "elm";
11170             action: STATE_SET "default" 0.0;
11171             target: "elm.swallow.content";
11172             target: "padding_after_icon";
11173             target: "icon_rect";
11174             target: "bg";
11175          }
11176          program { name: "disable";
11177             signal: "elm,state,disabled";
11178             source: "elm";
11179             action: STATE_SET "disabled" 0.0;
11180             target: "button_image";
11181             target: "disabler";
11182             after: "disable_text";
11183          }
11184          program { name: "disable_text";
11185             script {
11186                new st[31];
11187                new Float:vl;
11188                get_state(PART:"elm.text", st, 30, vl);
11189                if (!strcmp(st, "visible"))
11190                  set_state(PART:"elm.text", "disabled_visible", 0.0);
11191                else
11192                  set_state(PART:"elm.text", "disabled", 0.0);
11193                set_int(button_state, BUTTON_STATE_DISABLED);
11194             }
11195          }
11196          program { name: "enable";
11197             signal: "elm,state,enabled";
11198             source: "elm";
11199             action: STATE_SET "default" 0.0;
11200             target: "button_image";
11201             target: "disabler";
11202             after: "enable_text";
11203          }
11204          program { name: "enable_text";
11205             script {
11206                new st[31];
11207                new Float:vl;
11208                get_state(PART:"elm.text", st, 30, vl);
11209                if (!strcmp(st, "disabled_visible"))
11210                  set_state(PART:"elm.text", "visible", 0.0);
11211                else
11212                  set_state(PART:"elm.text", "default", 0.0);
11213                set_int(button_state, BUTTON_STATE_ENABLED);
11214             }
11215          }
11216          program { name: "focused";
11217             //signal: "elm,action,focus";
11218             //source: "elm";
11219             action: STATE_SET "focused" 0.0;
11220             target: "button_image";
11221             target: "elm.text";
11222          }
11223          program { name: "unfocused";
11224             //signal: "elm,action,unfocus";
11225             //source: "elm";
11226             action: STATE_SET "default" 0.0;
11227             target: "button_image";
11228             after: "unfocus_text";
11229          }
11230          program { name: "unfocus_text";
11231             action: STATE_SET "visible" 0.0;
11232             target: "elm.text";
11233          }
11234       }
11235    }
11236
11237 ///////////////////////////////////////////////////////////////////////////////////////
11238    group { name: "elm/button/base/expandable_number";
11239       alias: "elm/button/base/text_only/expandable_number";
11240       images {
11241          image: "00_button_05_normal.png" COMP;
11242          image: "00_button_05_press.png" COMP;
11243          image: "00_button_05_dim.png" COMP;
11244          image: "00_button_05_normal_focus.png" COMP;
11245          image: "00_arrow_expand.png" COMP;
11246          image: "00_arrow_expand_press.png" COMP;
11247          image: "00_arrow_expand_dim.png" COMP;
11248       }
11249       script {
11250          public button_state = BUTTON_STATE_ENABLED;
11251       }
11252       parts {
11253          part { name: "button_image";
11254             scale: 1;
11255             description { state: "default" 0.0;
11256                min: BUTTON_EXPANDABLE_NUMBER_BG_NORMAL_MIN_MAX_INC;
11257                max: BUTTON_EXPANDABLE_NUMBER_BG_NORMAL_MIN_MAX_INC;
11258                image {
11259                   normal: "00_button_05_normal.png";
11260                   border: BUTTON_EXPANDABLE_NUMBER_BG_BORDER_INC;
11261                   border_scale: 1;
11262                }
11263             }
11264             description { state: "clicked" 0.0;
11265                inherit: "default" 0.0;
11266                image.normal: "00_button_05_press.png";
11267             }
11268             description { state: "disabled" 0.0;
11269                inherit: "default" 0.0;
11270                image.normal: "00_button_05_dim.png";
11271             }
11272             description { state: "focused" 0.0;
11273                inherit: "default" 0.0;
11274                image.normal: "00_button_05_normal_focus.png";
11275             }
11276          }
11277          part { name: "padding_left_top";
11278             type: RECT;
11279             scale: 1;
11280             mouse_events: 0;
11281             description { state: "default" 0.0;
11282                align: 0.0 0.0;
11283                rel2.relative: 0.0 0.0;
11284                min: BUTTON_EXPANDABLE_NUMBER_PADDING_MIN_INC;
11285                fixed: 1 1;
11286                visible: 0;
11287             }
11288          }
11289          part { name: "padding_right_bottom";
11290             type: RECT;
11291             scale: 1;
11292             mouse_events: 0;
11293             description { state: "default" 0.0;
11294                align: 1.0 1.0;
11295                rel1.relative: 1.0 1.0;
11296                min: BUTTON_EXPANDABLE_NUMBER_PADDING_MIN_INC;
11297                fixed: 1 1;
11298                visible: 0;
11299             }
11300          }
11301          part { name: "icon_rect";
11302             type: RECT;
11303             scale: 1;
11304             mouse_events: 0;
11305             description { state: "default" 0.0;
11306                visible: 0;
11307                min: BUTTON_EXPANDABLE_NUMBER_ICON_RECT_EXPAND__MIN_MAX_INC;
11308                max: BUTTON_EXPANDABLE_NUMBER_ICON_RECT_EXPAND__MIN_MAX_INC;
11309                fixed: 1 0;
11310                rel1 {
11311                   relative: 0.0 1.0;
11312                   to_x: "padding_right_bottom";
11313                   to_y: "padding_left_top";
11314                }
11315                rel2 {
11316                   relative: 0.0 0.0;
11317                   to: "padding_right_bottom";
11318                }
11319                align: 1.0 0.5;
11320                color: 0 0 0 0;
11321             }
11322          }
11323          part { name: "arrow_expand";
11324             scale: 1;
11325             mouse_events: 0;
11326             description { state: "default" 0.0;
11327                align: 0.0 0.5;
11328                min: BUTTON_EXPANDABLE_NUMBER_ICON_RECT_EXPAND__MIN_MAX_INC;
11329                max: BUTTON_EXPANDABLE_NUMBER_ICON_RECT_EXPAND__MIN_MAX_INC;
11330                fixed: 0 0;
11331                rel1.to: "icon_rect";
11332                rel2.to: "icon_rect";
11333                image.normal:"00_arrow_expand.png";
11334             }
11335             description { state: "clicked" 0.0;
11336                inherit: "default" 0.0;
11337                image.normal:"00_arrow_expand_press.png";
11338             }
11339             description { state: "disabled" 0.0;
11340                inherit: "default" 0.0;
11341                image.normal:"00_arrow_expand_dim.png";
11342             }
11343          }
11344          part { name: "elm.text";
11345             type: TEXT;
11346             mouse_events: 0;
11347             scale: 1;
11348             description { state: "default" 0.0;
11349                min: BUTTON_EXPANDABLE_NUMBER_TEXT_MIN_MAX_INC;
11350                max: BUTTON_EXPANDABLE_NUMBER_TEXT_MIN_MAX_INC;
11351                fixed:1 0;
11352                rel1 {
11353                   relative: 1.0 1.0;
11354                   to: "padding_left_top";
11355                }
11356                rel2 {
11357                   relative: 1.0 1.0;
11358                   to_x:"padding_left_top";
11359                   to_y:"padding_right_bottom";
11360                }
11361                align: 0.0 0.5;
11362                color: BUTTON_TEXT_STYLE1_NORMAL_COLOR_INC;
11363                text {
11364                   font: "SLP:style=Medium";
11365                   size: BUTTON_EXPANDABLE_NUMBER_FONT_SIZE_INC;
11366                   min: 0 0;
11367                   fit: 1 1;
11368                   size_range: 14 20;
11369                   text_class: "slp_medium";
11370                }
11371             }
11372             description { state: "visible" 0.0;
11373                inherit: "default" 0.0;
11374             }
11375             description { state: "clicked" 0.0;
11376                inherit: "default" 0.0;
11377                color: BUTTON_TEXT_STYLE1_PRESSED_COLOR_INC;
11378             }
11379             description { state: "disabled" 0.0;
11380                inherit: "default" 0.0;
11381                color: 0 0 0 128;
11382             }
11383             description { state: "disabled_visible" 0.0;
11384                inherit: "default" 0.0;
11385                color: BUTTON_TEXT_STYLE1_DISABLED_COLOR_INC;
11386             }
11387             description { state: "focused" 0.0;
11388                inherit: "default" 0.0;
11389                color: BUTTON_TEXT_STYLE1_FOCUSED_COLOR_INC;
11390             }
11391          }
11392          part { name: "over2";
11393             type: RECT;
11394             repeat_events: 1;
11395             ignore_flags: ON_HOLD;
11396             description { state: "default" 0.0;
11397                color: 0 0 0 0;
11398             }
11399          }
11400          part { name: "over3";
11401             type: RECT;
11402             repeat_events: 1;
11403             description { state: "default" 0.0;
11404                color: 0 0 0 0;
11405             }
11406          }
11407          part { name: "disabler";
11408             type: RECT;
11409             description { state: "default" 0.0;
11410                color: 0 0 0 0;
11411                visible: 0;
11412             }
11413             description { state: "disabled" 0.0;
11414                inherit: "default" 0.0;
11415                visible: 1;
11416             }
11417          }
11418       }
11419       programs {
11420          program { name: "button_click";
11421             signal: "mouse,down,1";
11422             source: "over2";
11423             action: SIGNAL_EMIT "elm,action,press" "";
11424             after: "button_click_anim";
11425          }
11426          program { name: "button_click_anim";
11427             action: STATE_SET "clicked" 0.0;
11428             target: "button_image";
11429             target: "arrow_expand";
11430             after: "text_clicked";
11431          }
11432          program { name: "text_clicked";
11433             script {
11434                new st[31];
11435                new Float:vl;
11436                get_state(PART:"elm.text", st, 30, vl);
11437                if (!strcmp(st, "visible"))
11438                  set_state(PART:"elm.text", "clicked", 0.0);
11439             }
11440          }
11441          program { name: "button_unpress";
11442             action: SIGNAL_EMIT "elm,action,unpress" "";
11443          }
11444          program { name: "button_mouseout_clicked";
11445             signal: "mouse,up,1";
11446             source: "over3";
11447             script {
11448                if (get_int(button_state) != BUTTON_STATE_DISABLED)
11449                  {
11450                     set_state(PART:"button_image", "default", 0.0);
11451                     set_state(PART:"elm.text", "visible", 0.0);
11452                     set_state(PART:"arrow_expand", "default", 0.0);
11453                  }
11454             }
11455             after: button_unpress;
11456          }
11457          program { name: "touch_snd";
11458             signal: "mouse,clicked,1";
11459             source: "over2";
11460             action: PLAY_SAMPLE "touch_sound" 1.0;
11461             after: button_unclick3;
11462          }
11463          program { name: "button_unclick3";
11464             action: SIGNAL_EMIT "elm,action,click" "";
11465          }
11466          program { name: "text_show";
11467             signal: "elm,state,text,visible";
11468             source: "elm";
11469             script {
11470                if (get_int(button_state) != BUTTON_STATE_DISABLED)
11471                  set_state(PART:"elm.text", "visible", 0.0);
11472                else
11473                  set_state(PART:"elm.text", "disabled_visible", 0.0);
11474             }
11475          }
11476          program { name: "text_hide";
11477             signal: "elm,state,text,hidden";
11478             source: "elm";
11479             script {
11480                set_state(PART:"elm.text", "default", 0.0);
11481             }
11482          }
11483          program { name: "disable";
11484             signal: "elm,state,disabled";
11485             source: "elm";
11486             action: STATE_SET "disabled" 0.0;
11487             target: "button_image";
11488             target: "disabler";
11489             after: "disable_text";
11490          }
11491          program { name: "disable_text";
11492             script {
11493                new st[31];
11494                new Float:vl;
11495                get_state(PART:"elm.text", st, 30, vl);
11496                if (!strcmp(st, "visible"))
11497                  set_state(PART:"elm.text", "disabled_visible", 0.0);
11498                else
11499                  set_state(PART:"elm.text", "disabled", 0.0);
11500                set_int(button_state, BUTTON_STATE_DISABLED);
11501             }
11502          }
11503          program { name: "enable";
11504             signal: "elm,state,enabled";
11505             source: "elm";
11506             action: STATE_SET "default" 0.0;
11507             target: "button_image";
11508             target: "disabler";
11509             after: "enable_text";
11510          }
11511          program { name: "enable_text";
11512             script {
11513                new st[31];
11514                new Float:vl;
11515                get_state(PART:"elm.text", st, 30, vl);
11516                if (!strcmp(st, "disabled_visible"))
11517                  set_state(PART:"elm.text", "visible", 0.0);
11518                else
11519                  set_state(PART:"elm.text", "default", 0.0);
11520                set_int(button_state, BUTTON_STATE_ENABLED);
11521             }
11522          }
11523          program { name: "focused";
11524             //signal: "elm,action,focus";
11525             //source: "elm";
11526             action: STATE_SET "focused" 0.0;
11527             target: "button_image";
11528             target: "elm.text";
11529          }
11530          program { name: "unfocused";
11531             //signal: "elm,action,unfocus";
11532             //source: "elm";
11533             action: STATE_SET "default" 0.0;
11534             target: "button_image";
11535             after: "unfocus_text";
11536          }
11537          program { name: "unfocus_text";
11538             action: STATE_SET "visible" 0.0;
11539             target: "elm.text";
11540          }
11541       }
11542    }
11543
11544 #undef BUTTON_STATE_ENABLED
11545 #undef BUTTON_STATE_DISABLED