[Handler] added MACRO for different border sizes
[profile/ivi/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_search_input_field_bg.png" COMP;
3210          image: "00_button_sweep_press.png" COMP;
3211          image: "00_button_sweep_dim.png" COMP;
3212          image: "00_button_sweep_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_search_input_field_bg.png";
3224                   border: BUTTON_SEARCHBAR_BG_BORDER_INC;
3225                   border_scale: 1;
3226                }
3227             }
3228             description { state: "clicked" 0.0;
3229                inherit: "default" 0.0;
3230                image {
3231                   normal: "00_button_sweep_press.png";
3232                   border: BUTTON_SWEEP_BG_BORDER_INC;
3233                   border_scale: 1;
3234                }
3235             }
3236             description { state: "disabled" 0.0;
3237                inherit: "default" 0.0;
3238                image {
3239                   normal: "00_button_sweep_dim.png";
3240                   border: BUTTON_SWEEP_BG_BORDER_INC;
3241                   border_scale: 1;
3242                }
3243             }
3244             description { state: "focused" 0.0;
3245                inherit: "default" 0.0;
3246                image {
3247                   normal: "00_button_sweep_focus.png";
3248                   border: BUTTON_SWEEP_BG_BORDER_INC;
3249                   border_scale: 1;
3250                }
3251             }
3252          }
3253          part { name: "padding_left_top";
3254             type: RECT;
3255             scale: 1;
3256             mouse_events: 0;
3257             description { state: "default" 0.0;
3258                align: 0.0 0.0;
3259                rel2.relative: 0.0 0.0;
3260                min: BUTTON_SEARCHBAR_PADDING_MIN_INC;
3261                fixed: 1 1;
3262                visible: 0;
3263             }
3264          }
3265          part { name: "padding_right_bottom";
3266             type: RECT;
3267             scale: 1;
3268             mouse_events: 0;
3269             description { state: "default" 0.0;
3270                align: 1.0 1.0;
3271                rel1.relative: 1.0 1.0;
3272                min: BUTTON_SEARCHBAR_PADDING_MIN_INC;
3273                fixed: 1 1;
3274                visible: 0;
3275             }
3276          }
3277          part { name: "icon_rect";
3278             type: RECT;
3279             scale: 1;
3280             mouse_events: 0;
3281             description { state: "default" 0.0;
3282                min: BUTTON_SEARCHBAR_ICON_RECT_MIN_INC;
3283                fixed: 1 0;
3284                rel1 {
3285                   relative: 0.0 1.0;
3286                   to_x: "elm.swallow.content";
3287                   to_y: "padding_left_top";
3288                }
3289                rel2 {
3290                   relative: 1.0 0.0;
3291                   to_x: "elm.swallow.content";
3292                   to_y: "padding_right_bottom";
3293                }
3294                align: 0.0 0.5;
3295                color: 0 0 0 0;
3296             }
3297          }
3298          part { name: "padding_icon_text";
3299             type: RECT;
3300             scale: 1;
3301             mouse_events: 0;
3302             description { state: "default" 0.0; //when only icon or no icon is there
3303                align: 0.0 0.0;
3304                rel1 {
3305                   relative: 1.0 0.0;
3306                   to: "icon_rect";
3307                }
3308                rel2.to: "icon_rect";
3309                fixed: 1 0;
3310                min: 0 0;
3311                color: 0 0 0 0;
3312             }
3313             description { state: "icononly" 0.0;
3314                inherit: "default" 0.0;
3315             }
3316             description { state: "visible" 0.0; //when icon is visible
3317                align: 0.0 0.0;
3318                rel1 {
3319                   relative: 1.0 0.0;
3320                   to: "icon_rect";
3321                }
3322                rel2.to: "icon_rect";
3323                fixed: 1 0;
3324                min: BUTTON_SEARCHBAR_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
3325                color: 0 0 0 0;
3326             }
3327          }
3328          part { name: "elm.swallow.content";
3329             type: SWALLOW;
3330             scale: 1;
3331             clip_to: "clipper";
3332             description { state: "default" 0.0;
3333                visible: 0;
3334                align: 0.0 0.5;
3335                rel1 {
3336                   relative: 1.0 1.0;
3337                   to: "padding_left_top";
3338                }
3339                rel2 {
3340                   relative: 1.0 0.0;
3341                   to_x: "padding_left_top";
3342                   to_y: "padding_right_bottom";
3343                }
3344                fixed: 1 0;
3345             }
3346             description { state: "visible" 0.0;
3347                fixed: 1 0;
3348                align: 0.0 0.5;
3349                rel1 {
3350                   relative: 1.0 1.0;
3351                   to: "padding_left_top";
3352                }
3353                rel2 {
3354                   relative: 1.0 0.0;
3355                   to_x: "padding_left_top";
3356                   to_y: "padding_right_bottom";
3357                }
3358                aspect: 1.0 1.0;
3359                aspect_preference: VERTICAL;
3360             }
3361             description { state: "icononly" 0.0;
3362                min: BUTTON_SEARCHBAR_ICONONLY_ICON_MIN_INC;
3363                rel1 {
3364                   relative: 1.0 1.0;
3365                   to: "padding_left_top";
3366                }
3367                rel2 {
3368                   relative: 1.0 0.0;
3369                   to_x: "padding_left_top";
3370                   to_y: "padding_right_bottom";
3371                }
3372             }
3373          }
3374          part { name: "elm.text";
3375             type: TEXT;
3376             mouse_events: 0;
3377             scale: 1;
3378             clip_to: "clipper";
3379             description { state: "default" 0.0;
3380                visible: 0;
3381                rel1 {
3382                   relative: 1.0 1.0;
3383                   to_x: "padding_icon_text";
3384                   to_y: "padding_left_top";
3385                }
3386                rel2 {
3387                   relative: 0.0 0.0;
3388                   to: "padding_right_bottom";
3389                }
3390                color: BUTTON_SWEEP_BUTTON_TEXT_NORMAL_COLOR_INC;
3391                text {
3392                   font: "SLP:style=Medium";
3393                   size: BUTTON_SEARCHBAR_FONT_SIZE_INC;
3394                   min: 0 0;
3395                   text_class: "slp_medium";
3396                }
3397             }
3398             description { state: "visible" 0.0;
3399                inherit: "default" 0.0;
3400                visible: 1;
3401                min: BUTTON_SEARCHBAR_TEXT_MIN_INC;
3402             }
3403             description { state: "clicked" 0.0;
3404                inherit: "default" 0.0;
3405                visible: 1;
3406                min: 0 0;
3407                color: BUTTON_SWEEP_BUTTON_TEXT_PRESSED_COLOR_INC;
3408             }
3409             description { state: "disabled" 0.0;
3410                inherit: "default" 0.0;
3411                color: 0 0 0 128;
3412             }
3413             description { state: "disabled_visible" 0.0;
3414                inherit: "default" 0.0;
3415                color: BUTTON_SWEEP_BUTTON_TEXT_DISABLED_COLOR_INC;
3416                visible: 1;
3417                min: BUTTON_SWEEP_TEXT_MIN_INC;
3418             }
3419             description { state: "focused" 0.0;
3420                inherit: "default" 0.0;
3421                visible: 1;
3422                min: 0 0;
3423                color: BUTTON_SWEEP_BUTTON_TEXT_FOCUSED_COLOR_INC;
3424             }
3425          }
3426          part { name: "over2";
3427             type: RECT;
3428             repeat_events: 1;
3429             ignore_flags: ON_HOLD;
3430             description { state: "default" 0.0;
3431                color: 0 0 0 0;
3432             }
3433          }
3434          part { name: "over3";
3435             type: RECT;
3436             repeat_events: 1;
3437             description { state: "default" 0.0;
3438                color: 0 0 0 0;
3439             }
3440          }
3441          part { name: "clipper";
3442             type: RECT;
3443             description { state: "default" 0.0;
3444                color: 255 255 255 255;
3445             }
3446          }
3447          part { name: "disabler";
3448             type: RECT;
3449             description { state: "default" 0.0;
3450                color: 0 0 0 0;
3451                visible: 0;
3452             }
3453             description { state: "disabled" 0.0;
3454                inherit: "default" 0.0;
3455                visible: 1;
3456             }
3457          }
3458       }
3459       programs {
3460          program { name: "button_click";
3461             signal: "mouse,down,1";
3462             source: "over2";
3463             action: SIGNAL_EMIT "elm,action,press" "";
3464             after: "button_click_anim";
3465          }
3466          program { name: "button_click_anim";
3467             action: STATE_SET "clicked" 0.0;
3468             target: "button_image";
3469             after: "text_clicked";
3470          }
3471          program { name: "text_clicked";
3472             script {
3473                new st[31];
3474                new Float:vl;
3475                get_state(PART:"elm.text", st, 30, vl);
3476                if (!strcmp(st, "visible"))
3477                  set_state(PART:"elm.text", "clicked", 0.0);
3478             }
3479          }
3480          program { name: "button_unpress";
3481             action: SIGNAL_EMIT "elm,action,unpress" "";
3482          }
3483          program { name: "button_mouseout_clicked";
3484             signal: "mouse,up,1";
3485             source: "over3";
3486             script {
3487                new st[31];
3488                new Float:vl;
3489                get_state(PART:"elm.swallow.content", st, 30, vl);
3490                if (strcmp(st, "icononly"))
3491                  {
3492                     emit("elm,action,default,text,set", "");
3493                     set_state(PART:"elm.text", "visible", 0.0);
3494                  }
3495                if (get_int(button_state) != BUTTON_STATE_DISABLED)
3496                  set_state(PART:"button_image", "default", 0.0);
3497             }
3498             after: button_unpress;
3499          }
3500          program { name: "touch_snd";
3501             signal: "mouse,clicked,1";
3502             source: "over2";
3503             action: PLAY_SAMPLE "touch_sound" 1.0;
3504             after: button_unclick3;
3505          }
3506          program { name: "button_unclick3";
3507             action: SIGNAL_EMIT "elm,action,click" "";
3508          }
3509          program { name: "text_show";
3510             signal: "elm,state,text,visible";
3511             source: "elm";
3512             script {
3513                new st[31];
3514                new Float:vl;
3515                get_state(PART:"elm.swallow.content", st, 30, vl);
3516                if (!strcmp(st, "icononly"))
3517                  {
3518                     set_state(PART:"elm.swallow.content", "visible", 0.0);
3519                     set_state(PART:"padding_icon_text", "visible", 0.0);
3520                  }
3521                if (get_int(button_state) != BUTTON_STATE_DISABLED)
3522                  set_state(PART:"elm.text", "visible", 0.0);
3523                else
3524                  set_state(PART:"elm.text", "disabled_visible", 0.0);
3525             }
3526          }
3527          program { name: "text_hide";
3528             signal: "elm,state,text,hidden";
3529             source: "elm";
3530             script {
3531                new st[31];
3532                new Float:vl;
3533                get_state(PART:"elm.swallow.content", st, 30, vl);
3534                if (!strcmp(st, "visible"))
3535                  {
3536                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
3537                     set_state(PART:"padding_icon_text", "icononly", 0.0);
3538                  }
3539                set_state(PART:"elm.text", "default", 0.0);
3540             }
3541          }
3542          program { name: "icon_show";
3543             signal: "elm,state,icon,visible";
3544             source: "elm";
3545             script {
3546                new st[31];
3547                new Float:vl;
3548                get_state(PART:"elm.text", st, 30, vl);
3549                if (!strcmp(st, "visible"))
3550                  {
3551                     set_state(PART:"elm.swallow.content", "visible", 0.0);
3552                     set_state(PART:"padding_icon_text", "visible", 0.0);
3553                  }
3554                else
3555                  {
3556                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
3557                     set_state(PART:"padding_icon_text", "icononly", 0.0);
3558                  }
3559             }
3560          }
3561          program { name: "icon_hide";
3562             signal: "elm,state,icon,hidden";
3563             source: "elm";
3564             action: STATE_SET "default" 0.0;
3565             target: "elm.swallow.content";
3566             target: "padding_icon_text";
3567          }
3568          program { name: "disable";
3569             signal: "elm,state,disabled";
3570             source: "elm";
3571             action: STATE_SET "disabled" 0.0;
3572             target: "button_image";
3573             target: "disabler";
3574             after: "disable_text";
3575          }
3576          program { name: "disable_text";
3577             script {
3578                new st[31];
3579                new Float:vl;
3580                get_state(PART:"elm.text", st, 30, vl);
3581                if (!strcmp(st, "visible"))
3582                  set_state(PART:"elm.text", "disabled_visible", 0.0);
3583                else
3584                  set_state(PART:"elm.text", "disabled", 0.0);
3585                set_int(button_state, BUTTON_STATE_DISABLED);
3586             }
3587          }
3588          program { name: "enable";
3589             signal: "elm,state,enabled";
3590             source: "elm";
3591             action: STATE_SET "default" 0.0;
3592             target: "button_image";
3593             target: "disabler";
3594             after: "enable_text";
3595          }
3596          program { name: "enable_text";
3597             script {
3598                new st[31];
3599                new Float:vl;
3600                get_state(PART:"elm.text", st, 30, vl);
3601                if (!strcmp(st, "disabled_visible"))
3602                  set_state(PART:"elm.text", "visible", 0.0);
3603                else
3604                  set_state(PART:"elm.text", "default", 0.0);
3605                set_int(button_state, BUTTON_STATE_ENABLED);
3606             }
3607          }
3608          program { name: "focused";
3609             //signal: "elm,action,focus";
3610             //source: "elm";
3611             action: STATE_SET "focused" 0.0;
3612             target: "button_image";
3613             target: "elm.text";
3614          }
3615          program { name: "unfocused";
3616             //signal: "elm,action,unfocus";
3617             //source: "elm";
3618             action: STATE_SET "default" 0.0;
3619             target: "button_image";
3620             after: "unfocus_text";
3621          }
3622          program { name: "unfocus_text";
3623             action: STATE_SET "visible" 0.0;
3624             target: "elm.text";
3625          }
3626       }
3627    }
3628
3629 ///////////////////////////////////////////////////////////////////////////////////////
3630    group { name: "elm/button/base/sweep/delete";
3631       images {
3632          image: "00_button_sweep_dim.png" COMP;
3633          image: "00_button_sweep_delete.png" COMP;
3634          image: "00_button_sweep_delete_press.png" COMP;
3635          image: "00_button_sweep_focus.png" COMP;
3636       }
3637       script {
3638          public button_state = BUTTON_STATE_ENABLED;
3639       }
3640       parts {
3641          part { name: "button_image";
3642             scale: 1;
3643             description { state: "default" 0.0;
3644                min: BUTTON_SWEEP_BG_NORMAL_MIN_INC;
3645                image {
3646                   normal: "00_button_sweep_delete.png";
3647                   border: BUTTON_SWEEP_BG_BORDER_INC;
3648                   border_scale: 1;
3649                }
3650             }
3651             description { state: "clicked" 0.0;
3652                inherit: "default" 0.0;
3653                image.normal: "00_button_sweep_delete_press.png";
3654             }
3655             description { state: "disabled" 0.0;
3656                inherit: "default" 0.0;
3657                image.normal: "00_button_sweep_dim.png";
3658             }
3659             description { state: "focused" 0.0;
3660                inherit: "default" 0.0;
3661                image.normal: "00_button_sweep_focus.png";
3662             }
3663          }
3664          part { name: "padding_left_top";
3665             type: RECT;
3666             scale: 1;
3667             mouse_events: 0;
3668             description { state: "default" 0.0;
3669                align: 0.0 0.0;
3670                rel2.relative: 0.0 0.0;
3671                min: BUTTON_SWEEP_PADDING_MIN_INC;
3672                fixed: 1 1;
3673                visible: 0;
3674             }
3675          }
3676          part { name: "padding_right_bottom";
3677             type: RECT;
3678             scale: 1;
3679             mouse_events: 0;
3680             description { state: "default" 0.0;
3681                align: 1.0 1.0;
3682                rel1.relative: 1.0 1.0;
3683                min: BUTTON_SWEEP_PADDING_MIN_INC;
3684                fixed: 1 1;
3685                visible: 0;
3686             }
3687          }
3688          part { name: "icon_rect";
3689             type: RECT;
3690             scale: 1;
3691             mouse_events: 0;
3692             description { state: "default" 0.0;
3693                min: BUTTON_SWEEP_ICON_RECT_MIN_INC;
3694                fixed: 1 0;
3695                rel1 {
3696                   relative: 0.0 1.0;
3697                   to_x: "elm.swallow.content";
3698                   to_y: "padding_left_top";
3699                }
3700                rel2 {
3701                   relative: 1.0 0.0;
3702                   to_x: "elm.swallow.content";
3703                   to_y: "padding_right_bottom";
3704                }
3705                align: 0.0 0.5;
3706                color: 0 0 0 0;
3707             }
3708          }
3709          part { name: "padding_icon_text";
3710             type: RECT;
3711             scale: 1;
3712             mouse_events: 0;
3713             description { state: "default" 0.0; //when only icon or no icon is there
3714                align: 0.0 0.0;
3715                rel1 {
3716                   relative: 1.0 0.0;
3717                   to: "icon_rect";
3718                }
3719                rel2.to: "icon_rect";
3720                fixed: 1 0;
3721                min: 0 0;
3722                color: 0 0 0 0;
3723             }
3724             description { state: "icononly" 0.0;
3725                inherit: "default" 0.0;
3726             }
3727             description { state: "visible" 0.0; //when icon is visible
3728                align: 0.0 0.0;
3729                rel1 {
3730                   relative: 1.0 0.0;
3731                   to: "icon_rect";
3732                }
3733                rel2.to: "icon_rect";
3734                fixed: 1 0;
3735                min: BUTTON_SWEEP_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
3736                color: 0 0 0 0;
3737             }
3738          }
3739          part { name: "elm.swallow.content";
3740             type: SWALLOW;
3741             scale: 1;
3742             clip_to: "clipper";
3743             description { state: "default" 0.0;
3744                visible: 0;
3745                align: 0.0 0.5;
3746                rel1 {
3747                   relative: 1.0 1.0;
3748                   to: "padding_left_top";
3749                }
3750                rel2 {
3751                   relative: 1.0 0.0;
3752                   to_x: "padding_left_top";
3753                   to_y: "padding_right_bottom";
3754                }
3755                fixed: 1 0;
3756             }
3757             description { state: "visible" 0.0;
3758                fixed: 1 0;
3759                align: 0.0 0.5;
3760                rel1 {
3761                   relative: 1.0 1.0;
3762                   to: "padding_left_top";
3763                }
3764                rel2 {
3765                   relative: 1.0 0.0;
3766                   to_x: "padding_left_top";
3767                   to_y: "padding_right_bottom";
3768                }
3769                aspect: 1.0 1.0;
3770                aspect_preference: VERTICAL;
3771             }
3772             description { state: "icononly" 0.0;
3773                min: BUTTON_SWEEP_ICONONLY_ICON_MIN_INC;
3774                rel1 {
3775                   relative: 1.0 1.0;
3776                   to: "padding_left_top";
3777                }
3778                rel2 {
3779                   relative: 1.0 0.0;
3780                   to_x: "padding_left_top";
3781                   to_y: "padding_right_bottom";
3782                }
3783             }
3784          }
3785          part { name: "elm.text";
3786             type: TEXT;
3787             mouse_events: 0;
3788             scale: 1;
3789             clip_to: "clipper";
3790             description { state: "default" 0.0;
3791                rel1 {
3792                   relative: 1.0 1.0;
3793                   to_x: "padding_icon_text";
3794                   to_y: "padding_left_top";
3795                }
3796                rel2 {
3797                   relative: 0.0 0.0;
3798                   to: "padding_right_bottom";
3799                }
3800                color: BUTTON_SWEEP_BUTTON_TEXT_NORMAL_COLOR_INC;
3801                text {
3802                   font: "SLP:style=Medium";
3803                   size: BUTTON_SWEEP_FONT_SIZE_INC;
3804                   min: 1 0;
3805                   text: "Delete";
3806                   max: 1 0;
3807                   text_class: "slp_medium";
3808                }
3809             }
3810             description { state: "visible" 0.0;
3811                inherit: "default" 0.0;
3812             }
3813             description { state: "clicked" 0.0;
3814                inherit: "default" 0.0;
3815                color: BUTTON_SWEEP_BUTTON_TEXT_PRESSED_COLOR_INC;
3816             }
3817             description { state: "disabled" 0.0;
3818                inherit: "default" 0.0;
3819                color: 0 0 0 128;
3820             }
3821             description { state: "disabled_visible" 0.0;
3822                inherit: "default" 0.0;
3823                color: BUTTON_SWEEP_BUTTON_TEXT_DISABLED_COLOR_INC;
3824             }
3825             description { state: "focused" 0.0;
3826                inherit: "default" 0.0;
3827                visible: 1;
3828                min: 0 0;
3829                color: BUTTON_SWEEP_BUTTON_TEXT_FOCUSED_COLOR_INC;
3830             }
3831          }
3832          part { name: "over2";
3833             type: RECT;
3834             repeat_events: 1;
3835             ignore_flags: ON_HOLD;
3836             description { state: "default" 0.0;
3837                color: 0 0 0 0;
3838             }
3839          }
3840          part { name: "over3";
3841             type: RECT;
3842             repeat_events: 1;
3843             description { state: "default" 0.0;
3844                color: 0 0 0 0;
3845             }
3846          }
3847          part { name: "clipper";
3848             type: RECT;
3849             description { state: "default" 0.0;
3850                color: 255 255 255 255;
3851             }
3852          }
3853          part { name: "disabler";
3854             type: RECT;
3855             description { state: "default" 0.0;
3856                color: 0 0 0 0;
3857                visible: 0;
3858             }
3859             description { state: "disabled" 0.0;
3860                inherit: "default" 0.0;
3861                visible: 1;
3862             }
3863          }
3864       }
3865       programs {
3866          program { name: "button_click";
3867             signal: "mouse,down,1";
3868             source: "over2";
3869             action: SIGNAL_EMIT "elm,action,press" "";
3870             after: "button_click_anim";
3871          }
3872          program { name: "button_click_anim";
3873             action: STATE_SET "clicked" 0.0;
3874             target: "button_image";
3875             after: "text_clicked";
3876          }
3877          program { name: "text_clicked";
3878             script {
3879                new st[31];
3880                new Float:vl;
3881                get_state(PART:"elm.text", st, 30, vl);
3882                if (!strcmp(st, "visible"))
3883                  set_state(PART:"elm.text", "clicked", 0.0);
3884             }
3885          }
3886          program { name: "button_unpress";
3887             action: SIGNAL_EMIT "elm,action,unpress" "";
3888          }
3889          program { name: "button_mouseout_clicked";
3890             signal: "mouse,up,1";
3891             source: "over3";
3892             script {
3893                new st[31];
3894                new Float:vl;
3895                get_state(PART:"elm.swallow.content", st, 30, vl);
3896                if (strcmp(st, "icononly"))
3897                  {
3898                     emit("elm,action,default,text,set", "");
3899                     set_state(PART:"elm.text", "visible", 0.0);
3900                  }
3901                if (get_int(button_state) != BUTTON_STATE_DISABLED)
3902                  set_state(PART:"button_image", "default", 0.0);
3903             }
3904             after: button_unpress;
3905          }
3906          program { name: "touch_snd";
3907             signal: "mouse,clicked,1";
3908             source: "over2";
3909             action: PLAY_SAMPLE "touch_sound" 1.0;
3910             after: button_unclick3;
3911          }
3912          program { name: "button_unclick3";
3913             action: SIGNAL_EMIT "elm,action,click" "";
3914          }
3915          program { name: "text_show";
3916             signal: "elm,state,text,visible";
3917             source: "elm";
3918             script {
3919                new st[31];
3920                new Float:vl;
3921                get_state(PART:"elm.swallow.content", st, 30, vl);
3922                if (!strcmp(st, "icononly"))
3923                  {
3924                     set_state(PART:"elm.swallow.content", "visible", 0.0);
3925                     set_state(PART:"padding_icon_text", "visible", 0.0);
3926                  }
3927                if (get_int(button_state) != BUTTON_STATE_DISABLED)
3928                  set_state(PART:"elm.text", "visible", 0.0);
3929                else
3930                  set_state(PART:"elm.text", "disabled_visible", 0.0);
3931             }
3932          }
3933          program { name: "text_hide";
3934             signal: "elm,state,text,hidden";
3935             source: "elm";
3936             script {
3937                new st[31];
3938                new Float:vl;
3939                get_state(PART:"elm.swallow.content", st, 30, vl);
3940                if (!strcmp(st, "visible"))
3941                  {
3942                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
3943                     set_state(PART:"padding_icon_text", "icononly", 0.0);
3944                  }
3945                set_state(PART:"elm.text", "default", 0.0);
3946             }
3947          }
3948          program { name: "icon_show";
3949             signal: "elm,state,icon,visible";
3950             source: "elm";
3951             script {
3952                new st[31];
3953                new Float:vl;
3954                get_state(PART:"elm.text", st, 30, vl);
3955                if (!strcmp(st, "visible"))
3956                  {
3957                     set_state(PART:"elm.swallow.content", "visible", 0.0);
3958                     set_state(PART:"padding_icon_text", "visible", 0.0);
3959                  }
3960                else
3961                  {
3962                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
3963                     set_state(PART:"padding_icon_text", "icononly", 0.0);
3964                  }
3965             }
3966          }
3967          program { name: "icon_hide";
3968             signal: "elm,state,icon,hidden";
3969             source: "elm";
3970             action: STATE_SET "default" 0.0;
3971             target: "elm.swallow.content";
3972             target: "padding_icon_text";
3973          }
3974          program { name: "disable";
3975             signal: "elm,state,disabled";
3976             source: "elm";
3977             action: STATE_SET "disabled" 0.0;
3978             target: "button_image";
3979             target: "disabler";
3980             after: "disable_text";
3981          }
3982          program { name: "disable_text";
3983             script {
3984                new st[31];
3985                new Float:vl;
3986                get_state(PART:"elm.text", st, 30, vl);
3987                if (!strcmp(st, "visible"))
3988                  set_state(PART:"elm.text", "disabled_visible", 0.0);
3989                else
3990                  set_state(PART:"elm.text", "disabled", 0.0);
3991                set_int(button_state, BUTTON_STATE_DISABLED);
3992             }
3993          }
3994          program { name: "enable";
3995             signal: "elm,state,enabled";
3996             source: "elm";
3997             action: STATE_SET "default" 0.0;
3998             target: "button_image";
3999             target: "disabler";
4000             after: "enable_text";
4001          }
4002          program { name: "enable_text";
4003             script {
4004                new st[31];
4005                new Float:vl;
4006                get_state(PART:"elm.text", st, 30, vl);
4007                if (!strcmp(st, "disabled_visible"))
4008                  set_state(PART:"elm.text", "visible", 0.0);
4009                else
4010                  set_state(PART:"elm.text", "default", 0.0);
4011                set_int(button_state, BUTTON_STATE_ENABLED);
4012             }
4013          }
4014          program { name: "focused";
4015             //signal: "elm,action,focus";
4016             //source: "elm";
4017             action: STATE_SET "focused" 0.0;
4018             target: "button_image";
4019             target: "elm.text";
4020          }
4021          program { name: "unfocused";
4022             //signal: "elm,action,unfocus";
4023             //source: "elm";
4024             action: STATE_SET "default" 0.0;
4025             target: "button_image";
4026             after: "unfocus_text";
4027          }
4028          program { name: "unfocus_text";
4029             action: STATE_SET "visible" 0.0;
4030             target: "elm.text";
4031          }
4032       }
4033    }
4034
4035 ///////////////////////////////////////////////////////////////////////////////////////
4036    group { name: "elm/button/base/popup_button/default";
4037       alias: "elm/button/base/popup_button/menustyle";
4038       alias: "elm/button/base/popup_button/liststyle";
4039       alias: "elm/button/base/popup_button/volumebarstyle";
4040       alias: "elm/button/base/popup_button/customstyle";
4041       alias: "elm/button/base/popup_button/verticalbuttonstyle";
4042       images {
4043          image: "00_button_popup_normal.png" COMP;
4044          image: "00_button_popup_press.png" COMP;
4045          image: "00_button_popup_normal_focus.png" COMP;
4046          image: "00_button_popup_dim.png" COMP;
4047       }
4048       script {
4049          public button_state = BUTTON_STATE_ENABLED;
4050       }
4051       parts {
4052          part { name: "button_image";
4053             scale: 1;
4054             description { state: "default" 0.0;
4055                min: BUTTON_POPUP_BG_NORMAL_MIN_INC;
4056                image {
4057                   normal: "00_button_popup_normal.png";
4058                   border: BUTTON_POPUP_BG_BORDER_INC;
4059                   border_scale: 1;
4060                }
4061             }
4062             description { state: "clicked" 0.0;
4063                inherit: "default" 0.0;
4064                image.normal: "00_button_popup_press.png";
4065             }
4066             description { state: "disabled" 0.0;
4067                inherit: "default" 0.0;
4068                image.normal: "00_button_popup_dim.png";
4069             }
4070             description { state: "focused" 0.0;
4071                inherit: "default" 0.0;
4072                image.normal: "00_button_popup_normal_focus.png";
4073             }
4074          }
4075          part { name: "padding_left_top";
4076             type: RECT;
4077             scale: 1;
4078             mouse_events: 0;
4079             description { state: "default" 0.0;
4080                align: 0.0 0.0;
4081                rel2.relative: 0.0 0.0;
4082                min: BUTTON_POPUP_PADDING_MIN_INC;
4083                fixed: 1 1;
4084                visible: 0;
4085             }
4086          }
4087          part { name: "padding_right_bottom";
4088             type: RECT;
4089             scale: 1;
4090             description { state: "default" 0.0;
4091                align: 1.0 0.0;
4092                rel1.relative: 1.0 1.0;
4093                min: BUTTON_POPUP_PADDING_MIN_INC;
4094                fixed: 1 1;
4095                visible: 0;
4096             }
4097          }
4098          part { name: "padding_icon_text";
4099             type: RECT;
4100             scale: 1;
4101             description { state: "default" 0.0; //when only icon or no icon is there
4102                align: 0.0 0.0;
4103                rel1 {
4104                   relative: 1.0 0.0;
4105                   to: "elm.swallow.content";
4106                }
4107                rel2.to: "elm.swallow.content";
4108                fixed: 1 0;
4109                min: 0 0;
4110                visible: 0;
4111             }
4112             description { state: "icononly" 0.0;
4113                inherit: "default" 0.0;
4114             }
4115             description { state: "visible" 0.0; //when icon is visible
4116                inherit: "default" 0.0;
4117                min: BUTTON_POPUP_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
4118             }
4119          }
4120          part { name: "elm.swallow.content";
4121             type: SWALLOW;
4122             scale: 1;
4123             clip_to: "clipper";
4124             description { state: "default" 0.0;
4125                visible: 0;
4126                align: 0.0 0.5;
4127                rel1 {
4128                   relative: 1.0 1.0;
4129                   to: "padding_left_top";
4130                }
4131                rel2 {
4132                   relative: 1.0 0.0;
4133                   to_x: "padding_left_top";
4134                   to_y: "padding_right_bottom";
4135                }
4136                fixed: 1 0;
4137             }
4138             description { state: "visible" 0.0;
4139                inherit: "default" 0.0;
4140                fixed: 1 0;
4141                visible: 1;
4142                aspect: 1.0 1.0;
4143                aspect_preference: VERTICAL;
4144             }
4145             description { state: "icononly" 0.0;
4146                min: BUTTON_POPUP_ICON_ICONONLY_MIN_INC;
4147                rel1 {
4148                   relative: 1.0 1.0;
4149                   to: "padding_left_top";
4150                }
4151                rel2 {
4152                   relative: 1.0 0.0;
4153                   to_x: "padding_left_top";
4154                   to_y: "padding_right_bottom";
4155                }
4156             }
4157          }
4158          part { name: "elm.text";
4159             type: TEXT;
4160             mouse_events: 0;
4161             scale: 1;
4162             clip_to: "clipper";
4163             description { state: "default" 0.0;
4164                visible: 0;
4165                rel1 {
4166                   relative: 1.0 1.0;
4167                   to_x: "padding_icon_text";
4168                   to_y: "padding_left_top";
4169                }
4170                rel2 {
4171                   relative: 0.0 0.0;
4172                   to: "padding_right_bottom";
4173                }
4174                color: BUTTON_POPUP_BUTTON_TEXT_NORMAL_COLOR_INC;
4175                text {
4176                   font: "SLP:style=Medium";
4177                   size: BUTTON_POPUP_TEXT_FONT_SIZE_INC;
4178                   min: 0 0;
4179                   text_class: "slp_medium";
4180                }
4181             }
4182             description { state: "visible" 0.0;
4183                inherit: "default" 0.0;
4184                visible: 1;
4185                min: BUTTON_POPUP_TEXT_MIN_INC;
4186             }
4187             description { state: "clicked" 0.0;
4188                inherit: "default" 0.0;
4189                visible: 1;
4190                min: 0 0;
4191                color: BUTTON_POPUP_BUTTON_TEXT_PRESSED_COLOR_INC;
4192             }
4193             description { state: "disabled" 0.0;
4194                inherit: "default" 0.0;
4195                color: 0 0 0 128;
4196             }
4197             description { state: "disabled_visible" 0.0;
4198                inherit: "default" 0.0;
4199                color: BUTTON_POPUP_BUTTON_TEXT_DISABLED_COLOR_INC;
4200                visible: 1;
4201                min: BUTTON_POPUP_TEXT_MIN_INC;
4202             }
4203             description { state: "focused" 0.0;
4204                inherit: "default" 0.0;
4205                visible: 1;
4206                min: 0 0;
4207                color: BUTTON_POPUP_BUTTON_TEXT_FOCUSED_COLOR_INC;
4208             }
4209          }
4210          part { name: "over2";
4211             type: RECT;
4212             repeat_events: 1;
4213             ignore_flags: ON_HOLD;
4214             description { state: "default" 0.0;
4215                color: 0 0 0 0;
4216             }
4217          }
4218          part { name: "over3";
4219             type: RECT;
4220             repeat_events: 1;
4221             description { state: "default" 0.0;
4222                color: 0 0 0 0;
4223             }
4224          }
4225          part { name: "clipper";
4226             type: RECT;
4227             description { state: "default" 0.0;
4228                color: 255 255 255 255;
4229             }
4230          }
4231          part { name: "disabler";
4232             type: RECT;
4233             description { state: "default" 0.0;
4234                color: 0 0 0 0;
4235                visible: 0;
4236             }
4237             description { state: "disabled" 0.0;
4238                inherit: "default" 0.0;
4239                visible: 1;
4240             }
4241          }
4242       }
4243       programs {
4244          program { name: "button_click";
4245             signal: "mouse,down,1";
4246             source: "over2";
4247             action: SIGNAL_EMIT "elm,action,press" "";
4248             after: "button_click_anim";
4249          }
4250          program { name: "button_click_anim";
4251             action: STATE_SET "clicked" 0.0;
4252             target: "button_image";
4253             after: "text_clicked";
4254          }
4255          program { name: "text_clicked";
4256             script {
4257                new st[31];
4258                new Float:vl;
4259                get_state(PART:"elm.text", st, 30, vl);
4260                if (!strcmp(st, "visible"))
4261                  set_state(PART:"elm.text", "clicked", 0.0);
4262             }
4263          }
4264          program { name: "button_unpress";
4265             action: SIGNAL_EMIT "elm,action,unpress" "";
4266          }
4267          program { name: "button_mouseout_clicked";
4268             signal: "mouse,up,1";
4269             source: "over3";
4270             script {
4271                new st[31];
4272                new Float:vl;
4273                get_state(PART:"elm.swallow.content", st, 30, vl);
4274                if (strcmp(st, "icononly"))
4275                  {
4276                     emit("elm,action,default,text,set", "");
4277                     set_state(PART:"elm.text", "visible", 0.0);
4278                  }
4279                if (get_int(button_state) != BUTTON_STATE_DISABLED)
4280                  set_state(PART:"button_image", "default", 0.0);
4281             }
4282             after: button_unpress;
4283          }
4284          program { name: "touch_snd";
4285             signal: "mouse,clicked,1";
4286             source: "over2";
4287             action: PLAY_SAMPLE "touch_sound" 1.0;
4288             after: button_unclick3;
4289          }
4290          program { name: "button_unclick3";
4291             action: SIGNAL_EMIT "elm,action,click" "";
4292          }
4293          program { name: "text_show";
4294             signal: "elm,state,text,visible";
4295             source: "elm";
4296             script {
4297                new st[31];
4298                new Float:vl;
4299                get_state(PART:"elm.swallow.content", st, 30, vl);
4300                if (!strcmp(st, "icononly"))
4301                  {
4302                     set_state(PART:"elm.swallow.content", "visible", 0.0);
4303                     set_state(PART:"padding_icon_text", "visible", 0.0);
4304                  }
4305                if (get_int(button_state) != BUTTON_STATE_DISABLED)
4306                  set_state(PART:"elm.text", "visible", 0.0);
4307                else
4308                  set_state(PART:"elm.text", "disabled_visible", 0.0);
4309             }
4310          }
4311          program { name: "text_hide";
4312             signal: "elm,state,text,hidden";
4313             source: "elm";
4314             script {
4315                new st[31];
4316                new Float:vl;
4317                get_state(PART:"elm.swallow.content", st, 30, vl);
4318                if (!strcmp(st, "visible"))
4319                  {
4320                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
4321                     set_state(PART:"padding_icon_text", "icononly", 0.0);
4322                  }
4323                set_state(PART:"elm.text", "default", 0.0);
4324             }
4325          }
4326          program { name: "icon_show";
4327             signal: "elm,state,icon,visible";
4328             source: "elm";
4329             script {
4330                new st[31];
4331                new Float:vl;
4332                get_state(PART:"elm.text", st, 30, vl);
4333                if (!strcmp(st, "visible"))
4334                  {
4335                     set_state(PART:"elm.swallow.content", "visible", 0.0);
4336                     set_state(PART:"padding_icon_text", "visible", 0.0);
4337                  }
4338                else
4339                  {
4340                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
4341                     set_state(PART:"padding_icon_text", "icononly", 0.0);
4342                  }
4343             }
4344          }
4345          program { name: "icon_hide";
4346             signal: "elm,state,icon,hidden";
4347             source: "elm";
4348             action: STATE_SET "default" 0.0;
4349             target: "elm.swallow.content";
4350             target: "padding_icon_text";
4351          }
4352          program { name: "disable";
4353             signal: "elm,state,disabled";
4354             source: "elm";
4355             action: STATE_SET "disabled" 0.0;
4356             target: "button_image";
4357             target: "disabler";
4358             after: "disable_text";
4359          }
4360          program { name: "disable_text";
4361             script {
4362                new st[31];
4363                new Float:vl;
4364                get_state(PART:"elm.text", st, 30, vl);
4365                if (!strcmp(st, "visible"))
4366                  set_state(PART:"elm.text", "disabled_visible", 0.0);
4367                else
4368                  set_state(PART:"elm.text", "disabled", 0.0);
4369                set_int(button_state, BUTTON_STATE_DISABLED);
4370             }
4371          }
4372          program { name: "enable";
4373             signal: "elm,state,enabled";
4374             source: "elm";
4375             action: STATE_SET "default" 0.0;
4376             target: "button_image";
4377             target: "disabler";
4378             after: "enable_text";
4379          }
4380          program { name: "enable_text";
4381             script {
4382                new st[31];
4383                new Float:vl;
4384                get_state(PART:"elm.text", st, 30, vl);
4385                if (!strcmp(st, "disabled_visible"))
4386                  set_state(PART:"elm.text", "visible", 0.0);
4387                else
4388                  set_state(PART:"elm.text", "default", 0.0);
4389                set_int(button_state, BUTTON_STATE_ENABLED);
4390             }
4391          }
4392          program { name: "focused";
4393             //signal: "elm,action,focus";
4394             //source: "elm";
4395             action: STATE_SET "focused" 0.0;
4396             target: "button_image";
4397             target: "elm.text";
4398          }
4399          program { name: "unfocused";
4400             //signal: "elm,action,unfocus";
4401             //source: "elm";
4402             action: STATE_SET "default" 0.0;
4403             target: "button_image";
4404             after: "unfocus_text";
4405          }
4406          program { name: "unfocus_text";
4407             action: STATE_SET "visible" 0.0;
4408             target: "elm.text";
4409          }
4410       }
4411    }
4412 ///////////////////////////////////////////////////////////////////////////////////////
4413    group { name: "elm/button/base/popup_button/default/multiline";
4414       images {
4415          image: "00_button_popup_normal.png" COMP;
4416          image: "00_button_popup_press.png" COMP;
4417          image: "00_button_popup_normal_focus.png" COMP;
4418          image: "00_button_popup_dim.png" COMP;
4419       }
4420       styles{
4421          style { name: "btn_popup_multiline_style";
4422             base: "font=SLP:style=Roman font_size="BUTTON_POPUP_MULTILINE_TEXT_FONT_SIZE_INC" align=center color=#ffffff wrap=mixed text_class=slp_roman";
4423             tag: "br" "\n";
4424             tag: "ps" "ps";
4425             tag: "tab" "\t";
4426          }
4427       }
4428       script {
4429          public button_state = BUTTON_STATE_ENABLED;
4430       }
4431       parts {
4432          part { name: "button_image";
4433             scale: 1;
4434             description { state: "default" 0.0;
4435                min: BUTTON_POPUP_BG_NORMAL_MIN_INC;
4436                image {
4437                   normal: "00_button_popup_normal.png";
4438                   border: BUTTON_POPUP_BG_BORDER_INC;
4439                   border_scale: 1;
4440                }
4441             }
4442             description { state: "clicked" 0.0;
4443                inherit: "default" 0.0;
4444                image.normal: "00_button_popup_press.png";
4445             }
4446             description { state: "disabled" 0.0;
4447                inherit: "default" 0.0;
4448                image.normal: "00_button_popup_dim.png";
4449             }
4450             description { state: "focused" 0.0;
4451                inherit: "default" 0.0;
4452                image.normal: "00_button_popup_normal_focus.png";
4453             }
4454          }
4455          part { name: "padding_left_top";
4456             type: RECT;
4457             scale: 1;
4458             mouse_events: 0;
4459             description { state: "default" 0.0;
4460                align: 0.0 0.0;
4461                rel2.relative: 0.0 0.0;
4462                min: BUTTON_POPUP_PADDING_MIN_INC;
4463                fixed: 1 1;
4464                visible: 0;
4465             }
4466          }
4467          part { name: "padding_right_bottom";
4468             type: RECT;
4469             scale: 1;
4470             description { state: "default" 0.0;
4471                align: 1.0 0.0;
4472                rel1.relative: 1.0 1.0;
4473                min: BUTTON_POPUP_PADDING_MIN_INC;
4474                fixed: 1 1;
4475                visible: 0;
4476             }
4477          }
4478          part { name: "padding_icon_text";
4479             type: RECT;
4480             scale: 1;
4481             description { state: "default" 0.0; //when only icon or no icon is there
4482                align: 0.0 0.0;
4483                rel1 {
4484                   relative: 1.0 0.0;
4485                   to: "elm.swallow.content";
4486                }
4487                rel2.to: "elm.swallow.content";
4488                fixed: 1 0;
4489                min: 0 0;
4490                visible: 0;
4491             }
4492             description { state: "icononly" 0.0;
4493                inherit: "default" 0.0;
4494             }
4495             description { state: "visible" 0.0; //when icon is visible
4496                inherit: "default" 0.0;
4497                min: BUTTON_POPUP_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
4498             }
4499          }
4500          part { name: "elm.swallow.content";
4501             type: SWALLOW;
4502             scale: 1;
4503             clip_to: "clipper";
4504             description { state: "default" 0.0;
4505                visible: 0;
4506                align: 0.0 0.5;
4507                rel1 {
4508                   relative: 1.0 1.0;
4509                   to: "padding_left_top";
4510                }
4511                rel2 {
4512                   relative: 1.0 0.0;
4513                   to_x: "padding_left_top";
4514                   to_y: "padding_right_bottom";
4515                }
4516                fixed: 1 0;
4517             }
4518             description { state: "visible" 0.0;
4519                inherit: "default" 0.0;
4520                fixed: 1 0;
4521                visible: 1;
4522                aspect: 1.0 1.0;
4523                aspect_preference: VERTICAL;
4524             }
4525             description { state: "icononly" 0.0;
4526                min: BUTTON_POPUP_ICON_ICONONLY_MIN_INC;
4527                rel1 {
4528                   relative: 1.0 1.0;
4529                   to: "padding_left_top";
4530                }
4531                rel2 {
4532                   relative: 1.0 0.0;
4533                   to_x: "padding_left_top";
4534                   to_y: "padding_right_bottom";
4535                }
4536             }
4537          }
4538          part { name: "elm.text";
4539             type: TEXTBLOCK;
4540             mouse_events: 0;
4541             scale: 1;
4542             clip_to: "clipper";
4543             description { state: "default" 0.0;
4544                visible: 0;
4545                rel1 {
4546                   relative: 1.0 1.0;
4547                   to_x: "padding_icon_text";
4548                   to_y: "padding_left_top";
4549                }
4550                rel2 {
4551                   relative: 0.0 0.0;
4552                   to: "padding_right_bottom";
4553                }
4554                color: BUTTON_POPUP_BUTTON_TEXT_NORMAL_COLOR_INC;
4555                text {
4556                   style: "btn_popup_multiline_style";
4557                   min: 0 0;
4558                   max: 0 1;
4559                }
4560             }
4561             description { state: "visible" 0.0;
4562                inherit: "default" 0.0;
4563                visible: 1;
4564                min: BUTTON_POPUP_TEXT_MIN_INC;
4565             }
4566             description { state: "clicked" 0.0;
4567                inherit: "default" 0.0;
4568                visible: 1;
4569                min: 0 0;
4570                color: BUTTON_POPUP_BUTTON_TEXT_PRESSED_COLOR_INC;
4571             }
4572             description { state: "disabled" 0.0;
4573                inherit: "default" 0.0;
4574                color: 0 0 0 128;
4575             }
4576             description { state: "disabled_visible" 0.0;
4577                inherit: "default" 0.0;
4578                color: BUTTON_POPUP_BUTTON_TEXT_DISABLED_COLOR_INC;
4579                visible: 1;
4580                min: BUTTON_POPUP_TEXT_MIN_INC;
4581             }
4582             description { state: "focused" 0.0;
4583                inherit: "default" 0.0;
4584                visible: 1;
4585                min: 0 0;
4586                color: BUTTON_POPUP_BUTTON_TEXT_FOCUSED_COLOR_INC;
4587             }
4588          }
4589          part { name: "over2";
4590             type: RECT;
4591             repeat_events: 1;
4592             ignore_flags: ON_HOLD;
4593             description { state: "default" 0.0;
4594                color: 0 0 0 0;
4595             }
4596          }
4597          part { name: "over3";
4598             type: RECT;
4599             repeat_events: 1;
4600             description { state: "default" 0.0;
4601                color: 0 0 0 0;
4602             }
4603          }
4604          part { name: "clipper";
4605             type: RECT;
4606             description { state: "default" 0.0;
4607                color: 255 255 255 255;
4608             }
4609          }
4610          part { name: "disabler";
4611             type: RECT;
4612             description { state: "default" 0.0;
4613                color: 0 0 0 0;
4614                visible: 0;
4615             }
4616             description { state: "disabled" 0.0;
4617                inherit: "default" 0.0;
4618                visible: 1;
4619             }
4620          }
4621       }
4622       programs {
4623          program { name: "button_click";
4624             signal: "mouse,down,1";
4625             source: "over2";
4626             action: SIGNAL_EMIT "elm,action,press" "";
4627             after: "button_click_anim";
4628          }
4629          program { name: "button_click_anim";
4630             action: STATE_SET "clicked" 0.0;
4631             target: "button_image";
4632             after: "text_clicked";
4633          }
4634          program { name: "text_clicked";
4635             script {
4636                new st[31];
4637                new Float:vl;
4638                get_state(PART:"elm.text", st, 30, vl);
4639                if (!strcmp(st, "visible"))
4640                  set_state(PART:"elm.text", "clicked", 0.0);
4641             }
4642          }
4643          program { name: "button_unpress";
4644             action: SIGNAL_EMIT "elm,action,unpress" "";
4645          }
4646          program { name: "button_mouseout_clicked";
4647             signal: "mouse,up,1";
4648             source: "over3";
4649             script {
4650                new st[31];
4651                new Float:vl;
4652                get_state(PART:"elm.swallow.content", st, 30, vl);
4653                if (strcmp(st, "icononly"))
4654                  {
4655                     emit("elm,action,default,text,set", "");
4656                     set_state(PART:"elm.text", "visible", 0.0);
4657                  }
4658                if (get_int(button_state) != BUTTON_STATE_DISABLED)
4659                  set_state(PART:"button_image", "default", 0.0);
4660             }
4661             after: button_unpress;
4662          }
4663          program { name: "touch_snd";
4664             signal: "mouse,clicked,1";
4665             source: "over2";
4666             action: PLAY_SAMPLE "touch_sound" 1.0;
4667             after: button_unclick3;
4668          }
4669          program { name: "button_unclick3";
4670             action: SIGNAL_EMIT "elm,action,click" "";
4671          }
4672          program { name: "text_show";
4673             signal: "elm,state,text,visible";
4674             source: "elm";
4675             script {
4676                new st[31];
4677                new Float:vl;
4678                get_state(PART:"elm.swallow.content", st, 30, vl);
4679                if (!strcmp(st, "icononly"))
4680                  {
4681                     set_state(PART:"elm.swallow.content", "visible", 0.0);
4682                     set_state(PART:"padding_icon_text", "visible", 0.0);
4683                  }
4684                if (get_int(button_state) != BUTTON_STATE_DISABLED)
4685                  set_state(PART:"elm.text", "visible", 0.0);
4686                else
4687                  set_state(PART:"elm.text", "disabled_visible", 0.0);
4688             }
4689          }
4690          program { name: "text_hide";
4691             signal: "elm,state,text,hidden";
4692             source: "elm";
4693             script {
4694                new st[31];
4695                new Float:vl;
4696                get_state(PART:"elm.swallow.content", st, 30, vl);
4697                if (!strcmp(st, "visible"))
4698                  {
4699                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
4700                     set_state(PART:"padding_icon_text", "icononly", 0.0);
4701                  }
4702                set_state(PART:"elm.text", "default", 0.0);
4703             }
4704          }
4705          program { name: "icon_show";
4706             signal: "elm,state,icon,visible";
4707             source: "elm";
4708             script {
4709                new st[31];
4710                new Float:vl;
4711                get_state(PART:"elm.text", st, 30, vl);
4712                if (!strcmp(st, "visible"))
4713                  {
4714                     set_state(PART:"elm.swallow.content", "visible", 0.0);
4715                     set_state(PART:"padding_icon_text", "visible", 0.0);
4716                  }
4717                else
4718                  {
4719                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
4720                     set_state(PART:"padding_icon_text", "icononly", 0.0);
4721                  }
4722             }
4723          }
4724          program { name: "icon_hide";
4725             signal: "elm,state,icon,hidden";
4726             source: "elm";
4727             action: STATE_SET "default" 0.0;
4728             target: "elm.swallow.content";
4729             target: "padding_icon_text";
4730          }
4731          program { name: "disable";
4732             signal: "elm,state,disabled";
4733             source: "elm";
4734             action: STATE_SET "disabled" 0.0;
4735             target: "button_image";
4736             target: "disabler";
4737             after: "disable_text";
4738          }
4739          program { name: "disable_text";
4740             script {
4741                new st[31];
4742                new Float:vl;
4743                get_state(PART:"elm.text", st, 30, vl);
4744                if (!strcmp(st, "visible"))
4745                  set_state(PART:"elm.text", "disabled_visible", 0.0);
4746                else
4747                  set_state(PART:"elm.text", "disabled", 0.0);
4748                set_int(button_state, BUTTON_STATE_DISABLED);
4749             }
4750          }
4751          program { name: "enable";
4752             signal: "elm,state,enabled";
4753             source: "elm";
4754             action: STATE_SET "default" 0.0;
4755             target: "button_image";
4756             target: "disabler";
4757             after: "enable_text";
4758          }
4759          program { name: "enable_text";
4760             script {
4761                new st[31];
4762                new Float:vl;
4763                get_state(PART:"elm.text", st, 30, vl);
4764                if (!strcmp(st, "disabled_visible"))
4765                  set_state(PART:"elm.text", "visible", 0.0);
4766                else
4767                  set_state(PART:"elm.text", "default", 0.0);
4768                set_int(button_state, BUTTON_STATE_ENABLED);
4769             }
4770          }
4771          program { name: "focused";
4772             //signal: "elm,action,focus";
4773             //source: "elm";
4774             action: STATE_SET "focused" 0.0;
4775             target: "button_image";
4776             target: "elm.text";
4777          }
4778          program { name: "unfocused";
4779             //signal: "elm,action,unfocus";
4780             //source: "elm";
4781             action: STATE_SET "default" 0.0;
4782             target: "button_image";
4783             after: "unfocus_text";
4784          }
4785          program { name: "unfocus_text";
4786             action: STATE_SET "visible" 0.0;
4787             target: "elm.text";
4788          }
4789       }
4790    }
4791
4792 ///////////////////////////////////////////////////////////////////////////////////////
4793 #define BUTTON_CIRCLE_STYLES(style_name, image_normal, image_press, min_width, min_height) \
4794    group { name: "elm/button/base/"style_name; \
4795       images { \
4796          image: "00_btn_circle_bg_normal.png" COMP; \
4797          image: "00_btn_circle_bg_press.png" COMP; \
4798          image: image_normal COMP; \
4799          image: image_press COMP; \
4800       } \
4801       parts { \
4802          part { name: "button_image"; \
4803             scale: 1; \
4804             description { state: "default" 0.0; \
4805                min: BUTTON_CIRCLE_STYLE_BG_MIN_MAX_INC; \
4806                max: BUTTON_CIRCLE_STYLE_BG_MIN_MAX_INC; \
4807                image.normal: "00_btn_circle_bg_normal.png"; \
4808                color: 255 255 255 255; \
4809             } \
4810             description { \
4811                state: "clicked" 0.0; \
4812                inherit: "default" 0.0; \
4813                image.normal: "00_btn_circle_bg_press.png"; \
4814             } \
4815             description { \
4816                state: "disabled" 0.0; \
4817                inherit: "default" 0.0; \
4818                color: 255 255 255 128; \
4819             } \
4820          } \
4821          part { name: "button_center_part"; \
4822             scale: 1; \
4823             description { state: "default" 0.0; \
4824                min: BUTTON_CIRCLE_STYLE_IMAGE_MIN_MAX_INC; \
4825                max: BUTTON_CIRCLE_STYLE_IMAGE_MIN_MAX_INC; \
4826                image.normal: image_normal; \
4827                color: 255 255 255 255; \
4828             } \
4829             description { \
4830                state: "clicked" 0.0; \
4831                inherit: "default" 0.0; \
4832                image.normal: image_press; \
4833             } \
4834             description { \
4835                state: "disabled" 0.0; \
4836                inherit: "default" 0.0; \
4837                color: 255 255 255 128; \
4838             } \
4839          } \
4840          part { name: "over1"; \
4841             type: RECT; \
4842             ignore_flags: ON_HOLD; \
4843             description { state: "default" 0.0; \
4844                color: 0 0 0 0; \
4845                min: min_width min_height; \
4846             } \
4847          } \
4848          part { name: "over2"; \
4849             repeat_events: 1; \
4850             description { state: "default" 0.0; \
4851                color: 0 0 0 0; \
4852             } \
4853          } \
4854          part { name: "disabler"; \
4855             type: RECT; \
4856             description { state: "default" 0.0; \
4857                color: 0 0 0 0; \
4858                visible: 0; \
4859             } \
4860             description { state: "disabled" 0.0; \
4861                inherit: "default" 0.0; \
4862                visible: 1; \
4863             } \
4864          } \
4865       } \
4866       programs { \
4867          program { name: "button_click"; \
4868             signal: "mouse,down,1"; \
4869             source: "over1"; \
4870             action: SIGNAL_EMIT "elm,action,press" ""; \
4871             after: "button_click_anim"; \
4872          } \
4873          program { name: "button_click_anim"; \
4874             action: STATE_SET "clicked" 0.0; \
4875             target: "button_image"; \
4876             target: "button_center_part"; \
4877          } \
4878          program { name: "button_unclick"; \
4879             signal: "mouse,up,1"; \
4880             source: "over2"; \
4881             action: SIGNAL_EMIT "elm,action,unpress" ""; \
4882             after: "button_unclick_anim"; \
4883          } \
4884          program { name: "button_unclick_anim"; \
4885             action: STATE_SET "default" 0.0; \
4886             target: "button_image"; \
4887             target: "button_center_part"; \
4888          } \
4889          program { name: "touch_snd"; \
4890             signal: "mouse,clicked,1"; \
4891             source: "over1"; \
4892             action: PLAY_SAMPLE "touch_sound" 1.0; \
4893             after: button_unclick3; \
4894          } \
4895          program { name: "button_unclick3"; \
4896             action: SIGNAL_EMIT "elm,action,click" ""; \
4897          } \
4898          program { name: "disable"; \
4899             signal: "elm,state,disabled"; \
4900             source: "elm"; \
4901             action: STATE_SET "disabled" 0.0; \
4902             target: "disabler"; \
4903             target: "button_image"; \
4904             target: "button_center_part"; \
4905          } \
4906          program { name: "enable"; \
4907             signal: "elm,state,enabled"; \
4908             source: "elm"; \
4909             action: STATE_SET "default" 0.0; \
4910             target: "disabler"; \
4911             target: "button_image"; \
4912             target: "button_center_part"; \
4913          } \
4914       } \
4915    }
4916
4917 ///////////////////////////////////////////////////////////////////////////////////////
4918    BUTTON_CIRCLE_STYLES("reveal", "00_button_reveal.png", "00_button_reveal_press.png", 40, 40)
4919
4920 ///////////////////////////////////////////////////////////////////////////////////////
4921    BUTTON_CIRCLE_STYLES("reveal/extended", "00_button_reveal.png", "00_button_reveal_press.png", 60, 70)
4922
4923 ///////////////////////////////////////////////////////////////////////////////////////
4924    BUTTON_CIRCLE_STYLES("expand/closed", "00_button_expand_closed.png", "00_button_expand_closed_press.png", 40, 40)
4925
4926 ///////////////////////////////////////////////////////////////////////////////////////
4927    BUTTON_CIRCLE_STYLES("expand/closed/extended", "00_button_expand_closed.png", "00_button_expand_closed_press.png", 60, 70)
4928
4929 ///////////////////////////////////////////////////////////////////////////////////////
4930    BUTTON_CIRCLE_STYLES("expand/opened", "00_button_expand_opened.png", "00_button_expand_opened_press.png", 40, 40)
4931
4932 ///////////////////////////////////////////////////////////////////////////////////////
4933    BUTTON_CIRCLE_STYLES("expand/opened/extended", "00_button_expand_opened.png", "00_button_expand_opened_press.png", 60, 70)
4934
4935 ///////////////////////////////////////////////////////////////////////////////////////
4936    BUTTON_CIRCLE_STYLES("info", "00_button_info.png", "00_button_info_press.png", 40, 40)
4937
4938 ///////////////////////////////////////////////////////////////////////////////////////
4939    BUTTON_CIRCLE_STYLES("info/extended", "00_button_info.png", "00_button_info_press.png", 60, 70)
4940
4941 ///////////////////////////////////////////////////////////////////////////////////////
4942    BUTTON_CIRCLE_STYLES("rename", "00_button_rename.png", "00_button_rename_press.png", 40, 40)
4943
4944 ///////////////////////////////////////////////////////////////////////////////////////
4945    BUTTON_CIRCLE_STYLES("rename/extended", "00_button_rename.png", "00_button_rename_press.png", 60, 70)
4946
4947 ///////////////////////////////////////////////////////////////////////////////////////
4948    BUTTON_CIRCLE_STYLES("call", "00_button_call.png", "00_button_call_press.png", 40, 40)
4949
4950 ///////////////////////////////////////////////////////////////////////////////////////
4951    BUTTON_CIRCLE_STYLES("call/extended", "00_button_call.png", "00_button_call_press.png", 60, 70)
4952
4953 ///////////////////////////////////////////////////////////////////////////////////////
4954    BUTTON_CIRCLE_STYLES("warning", "00_button_warning.png", "00_button_warning_press.png", 40, 40)
4955
4956 ///////////////////////////////////////////////////////////////////////////////////////
4957    BUTTON_CIRCLE_STYLES("warning/extended", "00_button_warning.png", "00_button_warning_press.png", 60, 70)
4958
4959 ///////////////////////////////////////////////////////////////////////////////////////
4960    BUTTON_CIRCLE_STYLES("plus", "00_button_plus.png", "00_button_plus_press.png", 40, 40)
4961
4962 ///////////////////////////////////////////////////////////////////////////////////////
4963    BUTTON_CIRCLE_STYLES("plus/extended", "00_button_plus.png", "00_button_plus_press.png", 60, 70)
4964
4965 ///////////////////////////////////////////////////////////////////////////////////////
4966    BUTTON_CIRCLE_STYLES("minus", "00_button_minus.png", "00_button_minus_press.png", 40, 40)
4967
4968 ///////////////////////////////////////////////////////////////////////////////////////
4969    BUTTON_CIRCLE_STYLES("minus/extended", "00_button_minus.png", "00_button_minus_press.png", 60, 70)
4970
4971 ///////////////////////////////////////////////////////////////////////////////////////
4972    BUTTON_CIRCLE_STYLES("cancel", "00_button_cancel.png", "00_button_cancel_press.png", 40, 40)
4973
4974 ///////////////////////////////////////////////////////////////////////////////////////
4975    BUTTON_CIRCLE_STYLES("cancel/extended", "00_button_cancel.png", "00_button_cancel_press.png", 60, 70)
4976
4977 ///////////////////////////////////////////////////////////////////////////////////////
4978    BUTTON_CIRCLE_STYLES("send", "00_button_send.png", "00_button_send_press.png", 40, 40)
4979
4980 ///////////////////////////////////////////////////////////////////////////////////////
4981    BUTTON_CIRCLE_STYLES("send/extended", "00_button_send.png", "00_button_send_press.png", 60, 70)
4982 ///////////////////////////////////////////////////////////////////////////////////////
4983    group { name: "elm/button/base/circle/empty";
4984       images {
4985          image: "00_btn_circle_bg_normal.png" COMP;
4986          image: "00_btn_circle_bg_press.png" COMP;
4987       }
4988       parts {
4989          part { name: "button_image";
4990             scale: 1;
4991             description { state: "default" 0.0;
4992                min: BUTTON_CIRCLE_STYLE_BG_MIN_MAX_INC;
4993                max: BUTTON_CIRCLE_STYLE_BG_MIN_MAX_INC;
4994                fixed: 1 1;
4995                image.normal: "00_btn_circle_bg_normal.png";
4996                color: 255 255 255 255;
4997             }
4998             description { state: "clicked" 0.0;
4999                inherit: "default" 0.0;
5000                image.normal: "00_btn_circle_bg_press.png";
5001             }
5002             description { state: "disabled" 0.0;
5003                inherit: "default" 0.0;
5004                color: 255 255 255 128;
5005             }
5006          }
5007          part { name: "elm.swallow.content";
5008             type: SWALLOW;
5009             scale: 1;
5010             description { state: "default" 0.0;
5011                min: BUTTON_CIRCLE_STYLE_CONTENT_MIN_MAX_INC;
5012                max: BUTTON_CIRCLE_STYLE_CONTENT_MIN_MAX_INC;
5013                fixed: 1 1;
5014                color: 255 255 255 255;
5015             }
5016             description {
5017                state: "disabled" 0.0;
5018                inherit: "default" 0.0;
5019                color: 255 255 255 128;
5020             }
5021          }
5022          part { name: "over1";
5023             type: RECT;
5024             ignore_flags: ON_HOLD;
5025             description { state: "default" 0.0;
5026                color: 0 0 0 0;
5027             }
5028          }
5029          part { name: "over2";
5030             repeat_events: 1;
5031             description { state: "default" 0.0;
5032                color: 0 0 0 0;
5033             }
5034          }
5035          part { name: "disabler";
5036             type: RECT;
5037             description { state: "default" 0.0;
5038                color: 0 0 0 0;
5039                visible: 0;
5040             }
5041             description { state: "disabled" 0.0;
5042                inherit: "default" 0.0;
5043                visible: 1;
5044             }
5045          }
5046       }
5047       programs {
5048          program { name: "button_click";
5049             signal: "mouse,down,1";
5050             source: "over1";
5051             action: SIGNAL_EMIT "elm,action,press" "";
5052             after: "button_click_anim";
5053          }
5054          program { name: "button_click_anim";
5055             action: STATE_SET "clicked" 0.0;
5056             target: "button_image";
5057          }
5058          program { name: "touch_snd";
5059             signal: "mouse,clicked,1";
5060             source: "over1";
5061             action: PLAY_SAMPLE "touch_sound" 1.0;
5062             after: button_unclick2;
5063          }
5064          program { name: "button_unclick2";
5065             action: SIGNAL_EMIT "elm,action,click" "";
5066          }
5067          program { name: "button_unclick";
5068             signal: "mouse,up,1";
5069             source: "over2";
5070             action: SIGNAL_EMIT "elm,action,unpress" "";
5071             after: "button_unclick_anim";
5072          }
5073          program { name: "button_unclick_anim";
5074             action: STATE_SET "default" 0.0;
5075             target: "button_image";
5076          }
5077          program { name: "disable";
5078             signal: "elm,state,disabled";
5079             source: "elm";
5080             action: STATE_SET "disabled" 0.0;
5081             target: "disabler";
5082             target: "button_image";
5083          }
5084          program { name: "enable";
5085             signal: "elm,state,enabled";
5086             source: "elm";
5087             action: STATE_SET "default" 0.0;
5088             target: "disabler";
5089             target: "button_image";
5090          }
5091          program { name: "icon_show";
5092             signal: "elm,state,icon,visible";
5093             source: "elm";
5094             action: STATE_SET "visible" 0.0;
5095             target: "elm.swallow.content";
5096          }
5097          program { name: "icon_hide";
5098             signal: "elm,state,icon,hidden";
5099             source: "elm";
5100             action: STATE_SET "default" 0.0;
5101             target: "elm.swallow.content";
5102          }
5103       }
5104    }
5105
5106 ///////////////////////////////////////////////////////////////////////////////////////
5107 #define BUTTON_EDIT_STYLES(style_name, image_normal, image_press, min_width, min_height) \
5108    group { name: "elm/button/base/contacts/"style_name; \
5109    alias: "elm/button/base/"style_name; \
5110       images { \
5111          image: image_normal COMP; \
5112          image: image_press COMP; \
5113          image: "00_button_edit.png" COMP; \
5114          image: "00_button_edit_press.png" COMP; \
5115          image: "00_button_edit_dim.png" COMP; \
5116          image: "00_button_edit_focus.png" COMP; \
5117       } \
5118       parts { \
5119          part { name: "button_image"; \
5120             scale: 1; \
5121             description { state: "default" 0.0; \
5122                min: BUTTON_EDIT_STYLE_BG_NORMAL_MIN_MAX_INC; \
5123                max: BUTTON_EDIT_STYLE_BG_NORMAL_MIN_MAX_INC; \
5124                image { \
5125                   normal: "00_button_edit.png"; \
5126                   border: BUTTON_EDIT_STYLE_BORDER_INC; \
5127                   border_scale: 1; \
5128                } \
5129             } \
5130             description { \
5131                state: "clicked" 0.0; \
5132                inherit: "default" 0.0; \
5133                image.normal: "00_button_edit_press.png"; \
5134             } \
5135             description { \
5136                state: "disabled" 0.0; \
5137                inherit: "default" 0.0; \
5138                image.normal: "00_button_edit_dim.png"; \
5139             } \
5140             description { \
5141                state: "focused" 0.0; \
5142                inherit: "default" 0.0; \
5143                image.normal: "00_button_edit_focus.png"; \
5144             } \
5145          } \
5146          part { name: "button_center_part"; \
5147             mouse_events: 0; \
5148             scale: 1; \
5149             description { state: "default" 0.0; \
5150                min: BUTTON_EDIT_STYLE_IMAGE_NORMAL_MIN_MAX_INC; \
5151                max: BUTTON_EDIT_STYLE_IMAGE_NORMAL_MIN_MAX_INC; \
5152                image { \
5153                   normal: image_normal; \
5154                   border: BUTTON_EDIT_STYLE_BORDER_INC; \
5155                   border_scale: 1; \
5156                } \
5157             } \
5158             description { \
5159                state: "clicked" 0.0; \
5160                inherit: "default" 0.0; \
5161                image.normal: image_press; \
5162             } \
5163          } \
5164          part { name: "over1"; \
5165             type: RECT; \
5166             repeat_events: 1; \
5167             ignore_flags: ON_HOLD; \
5168             description { state: "default" 0.0; \
5169                color: 0 0 0 0; \
5170                min: min_width min_height; \
5171             } \
5172          } \
5173          part { name: "over2"; \
5174             repeat_events: 1; \
5175             description { state: "default" 0.0; \
5176                color: 0 0 0 0; \
5177             } \
5178          } \
5179          part { name: "disabler"; \
5180             type: RECT; \
5181             description { state: "default" 0.0; \
5182                color: 0 0 0 0; \
5183                visible: 0; \
5184             } \
5185             description { state: "disabled" 0.0; \
5186                inherit: "default" 0.0; \
5187                visible: 1; \
5188             } \
5189          } \
5190       } \
5191       programs { \
5192          program { name: "button_click"; \
5193             signal: "mouse,down,1"; \
5194             source: "over1"; \
5195             action: SIGNAL_EMIT "elm,action,press" ""; \
5196             after: "button_click_anim"; \
5197          } \
5198          program { name: "button_click_anim"; \
5199             action: STATE_SET "clicked" 0.0; \
5200             target: "button_image"; \
5201             target: "button_center_part"; \
5202          } \
5203          program { name: "button_unclick"; \
5204             signal: "mouse,up,1"; \
5205             source: "over2"; \
5206             action: SIGNAL_EMIT "elm,action,unpress" ""; \
5207             after: "button_unclick_anim"; \
5208          } \
5209          program { name: "button_unclick_anim"; \
5210             action: STATE_SET "default" 0.0; \
5211             target: "button_image"; \
5212             target: "button_center_part"; \
5213          } \
5214          program { name: "touch_snd"; \
5215             signal: "mouse,clicked,1"; \
5216             source: "over1"; \
5217             action: PLAY_SAMPLE "touch_sound" 1.0; \
5218             after: button_unclick3; \
5219          } \
5220          program { name: "button_unclick3"; \
5221             action: SIGNAL_EMIT "elm,action,click" ""; \
5222          } \
5223          program { name: "disable"; \
5224             signal: "elm,state,disabled"; \
5225             source: "elm"; \
5226             action: STATE_SET "disabled" 0.0; \
5227             target: "disabler"; \
5228             target: "button_image"; \
5229          } \
5230          program { name: "enable"; \
5231             signal: "elm,state,enabled"; \
5232             source: "elm"; \
5233             action: STATE_SET "default" 0.0; \
5234             target: "disabler"; \
5235             target: "button_image"; \
5236          } \
5237       } \
5238    }
5239 ///////////////////////////////////////////////////////////////////////////////////////
5240    BUTTON_EDIT_STYLES("icon_plus", "00_button_icon_plus.png", "00_button_icon_plus_press.png", BUTTON_EDIT_NORMAL_MIN_WIDTH_INC, BUTTON_EDIT_NORMAL_MIN_HEIGHT_INC)
5241
5242 ///////////////////////////////////////////////////////////////////////////////////////
5243    BUTTON_EDIT_STYLES("icon_plus/extended", "00_button_icon_plus.png", "00_button_icon_plus_press.png", BUTTON_EDIT_EXTENDED_MIN_WIDTH_INC, BUTTON_EDIT_EXTENDED_MIN_HEIGHT_INC)
5244
5245 ///////////////////////////////////////////////////////////////////////////////////////
5246    BUTTON_EDIT_STYLES("icon_minus", "00_button_icon_minus.png", "00_button_icon_minus_press.png", BUTTON_EDIT_NORMAL_MIN_WIDTH_INC, BUTTON_EDIT_NORMAL_MIN_HEIGHT_INC)
5247
5248 ///////////////////////////////////////////////////////////////////////////////////////
5249    BUTTON_EDIT_STYLES("icon_minus/extended", "00_button_icon_minus.png", "00_button_icon_minus_press.png", BUTTON_EDIT_EXTENDED_MIN_WIDTH_INC, BUTTON_EDIT_EXTENDED_MIN_HEIGHT_INC)
5250
5251 ///////////////////////////////////////////////////////////////////////////////////////
5252    BUTTON_EDIT_STYLES("icon_expand", "00_button_icon_expand.png", "00_button_icon_expand_press.png", BUTTON_EDIT_NORMAL_MIN_WIDTH_INC, BUTTON_EDIT_NORMAL_MIN_HEIGHT_INC)
5253
5254 ///////////////////////////////////////////////////////////////////////////////////////
5255    BUTTON_EDIT_STYLES("icon_expand/extended", "00_button_icon_expand.png", "00_button_icon_expand_press.png", BUTTON_EDIT_EXTENDED_MIN_WIDTH_INC, BUTTON_EDIT_EXTENDED_MIN_HEIGHT_INC)
5256
5257 ///////////////////////////////////////////////////////////////////////////////////////
5258    BUTTON_EDIT_STYLES("icon_expand_closed", "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)
5259
5260 ///////////////////////////////////////////////////////////////////////////////////////
5261    BUTTON_EDIT_STYLES("icon_expand_opened", "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)
5262
5263 ///////////////////////////////////////////////////////////////////////////////////////
5264    group { name: "elm/button/base/contacts/delete";
5265       images {
5266          image: "00_button_edit.png" COMP;
5267          image: "00_button_edit_press.png" COMP;
5268          image: "00_button_edit_dim.png" COMP;
5269          image: "00_button_edit_focus.png" COMP;
5270       }
5271       script {
5272          public button_state = BUTTON_STATE_ENABLED;
5273       }
5274       parts {
5275          part { name: "button_image";
5276             scale: 1;
5277             description { state: "default" 0.0;
5278                min: BUTTON_CONTACT_DELETE_BG_NORMAL_MIN_INC;
5279                image {
5280                   normal: "00_button_edit.png";
5281                   border: BUTTON_CONTACT_DELETE_BG_BORDER_INC;
5282                   border_scale: 1;
5283                }
5284             }
5285             description { state: "clicked" 0.0;
5286                inherit: "default" 0.0;
5287                image.normal: "00_button_edit_press.png";
5288             }
5289             description { state: "disabled" 0.0;
5290                inherit: "default" 0.0;
5291                image.normal: "00_button_edit_dim.png";
5292             }
5293             description { state: "focused" 0.0;
5294                inherit: "default" 0.0;
5295                image.normal: "00_button_edit_focus.png";
5296             }
5297          }
5298          part { name: "padding_left_top";
5299             type: RECT;
5300             scale: 1;
5301             mouse_events: 0;
5302             description { state: "default" 0.0;
5303                align: 0.0 0.0;
5304                rel2.relative: 0.0 0.0;
5305                min: BUTTON_CONTACT_DELETE_PADDING_LEFT_TOP_MIN_INC;
5306                fixed: 1 1;
5307                visible: 0;
5308             }
5309          }
5310          part { name: "padding_right_bottom";
5311             type: RECT;
5312             scale: 1;
5313             mouse_events: 0;
5314             description { state: "default" 0.0;
5315                align: 1.0 1.0;
5316                rel1.relative: 1.0 1.0;
5317                min: BUTTON_CONTACT_DELETE_PADDING_RIGHT_BOTTOM_MIN_INC;
5318                fixed: 1 1;
5319                visible: 0;
5320             }
5321          }
5322          part { name: "padding_icon_text";
5323             type: RECT;
5324             scale: 1;
5325             mouse_events: 0;
5326             description { state: "default" 0.0; //when only icon or no icon is there
5327                align: 0.0 0.0;
5328                rel1 {
5329                   relative: 1.0 0.0;
5330                   to: "elm.swallow.content";
5331                }
5332                rel2.to: "elm.swallow.content";
5333                fixed: 1 0;
5334                min: 0 0;
5335                visible: 0;
5336             }
5337             description { state: "icononly" 0.0;
5338                inherit: "default" 0.0;
5339             }
5340             description { state: "visible" 0.0; //when icon is visible
5341                inherit: "default" 0.0;
5342                min: BUTTON_CONTACT_DELETE_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
5343             }
5344          }
5345          part { name: "elm.swallow.content";
5346             type: SWALLOW;
5347             scale: 1;
5348             clip_to: "clipper";
5349             description { state: "default" 0.0;
5350                visible: 0;
5351                align: 0.0 0.5;
5352                rel1 {
5353                   relative: 1.0 1.0;
5354                   to: "padding_left_top";
5355                }
5356                rel2 {
5357                   relative: 1.0 0.0;
5358                   to_x: "padding_left_top";
5359                   to_y: "padding_right_bottom";
5360                }
5361                fixed: 1 0;
5362             }
5363             description { state: "visible" 0.0;
5364                fixed: 1 0;
5365                align: 0.0 0.5;
5366                rel1 {
5367                   relative: 1.0 1.0;
5368                   to: "padding_left_top";
5369                }
5370                rel2 {
5371                   relative: 1.0 0.0;
5372                   to_x: "padding_left_top";
5373                   to_y: "padding_right_bottom";
5374                }
5375                aspect: 1.0 1.0;
5376                aspect_preference: VERTICAL;
5377             }
5378             description { state: "icononly" 0.0;
5379                min: BUTTON_CONTACT_DELETE_ICON_ICONONLY_MIN_INC;
5380                rel1 {
5381                   relative: 1.0 1.0;
5382                   to: "padding_left_top";
5383                }
5384                rel2 {
5385                   relative: 0.0 0.0;
5386                   to: "padding_right_bottom";
5387                }
5388                aspect: 1.0 1.0;
5389                aspect_preference: VERTICAL;
5390             }
5391          }
5392          part { name: "elm.text";
5393             type: TEXT;
5394             mouse_events: 0;
5395             scale: 1;
5396             clip_to: "clipper";
5397             description { state: "default" 0.0;
5398                rel1 {
5399                   relative: 1.0 1.0;
5400                   to_x: "padding_icon_text";
5401                   to_y: "padding_left_top";
5402                }
5403                rel2 {
5404                   relative: 0.0 0.0;
5405                   to: "padding_right_bottom";
5406                }
5407                color: BUTTON_TEXT_CONTACTS_DELETE_NORMAL_COLOR_INC;
5408                text {
5409                   font: "SLP:style=Medium";
5410                   size: BUTTON_CONTACT_DELETE_FONT_SIZE_INC;
5411                   min: 1 0;
5412                   text: "Delete";
5413                   max: 1 0;
5414                   text_class: "slp_medium";
5415                }
5416             }
5417             description { state: "visible" 0.0;
5418                inherit: "default" 0.0;
5419             }
5420             description { state: "clicked" 0.0;
5421                inherit: "default" 0.0;
5422                color: BUTTON_TEXT_CONTACTS_DELETE_PRESSED_COLOR_INC;
5423             }
5424             description { state: "disabled" 0.0;
5425                inherit: "default" 0.0;
5426                color: 0 0 0 128;
5427             }
5428             description { state: "disabled_visible" 0.0;
5429                inherit: "default" 0.0;
5430                color: BUTTON_TEXT_CONTACTS_DELETE_DISABLED_COLOR_INC;
5431             }
5432             description { state: "focused" 0.0;
5433                inherit: "default" 0.0;
5434                min: 0 0;
5435                color: BUTTON_TEXT_CONTACTS_DELETE_PRESSED_COLOR_INC;
5436             }
5437          }
5438          part { name: "over2";
5439             type: RECT;
5440             repeat_events: 1;
5441             ignore_flags: ON_HOLD;
5442             description { state: "default" 0.0;
5443                color: 0 0 0 0;
5444             }
5445          }
5446          part { name: "over3";
5447             type: RECT;
5448             repeat_events: 1;
5449             description { state: "default" 0.0;
5450                color: 0 0 0 0;
5451             }
5452          }
5453          part { name: "clipper";
5454             type: RECT;
5455             description { state: "default" 0.0;
5456                color: 255 255 255 255;
5457             }
5458          }
5459          part { name: "disabler";
5460             type: RECT;
5461             description { state: "default" 0.0;
5462                color: 0 0 0 0;
5463                visible: 0;
5464             }
5465             description { state: "disabled" 0.0;
5466                inherit: "default" 0.0;
5467                visible: 1;
5468             }
5469          }
5470       }
5471       programs {
5472          program { name: "button_click";
5473             signal: "mouse,down,1";
5474             source: "over2";
5475             action: SIGNAL_EMIT "elm,action,press" "";
5476             after: "button_click_anim";
5477          }
5478          program { name: "button_click_anim";
5479             action: STATE_SET "clicked" 0.0;
5480             target: "button_image";
5481             after: "text_clicked";
5482          }
5483          program { name: "text_clicked";
5484             script {
5485                new st[31];
5486                new Float:vl;
5487                get_state(PART:"elm.text", st, 30, vl);
5488                if (!strcmp(st, "visible"))
5489                  set_state(PART:"elm.text", "clicked", 0.0);
5490             }
5491          }
5492          program { name: "button_unpress";
5493             action: SIGNAL_EMIT "elm,action,unpress" "";
5494          }
5495          program { name: "button_mouseout_clicked";
5496             signal: "mouse,up,1";
5497             source: "over3";
5498             script {
5499                new st[31];
5500                new Float:vl;
5501                get_state(PART:"elm.swallow.content", st, 30, vl);
5502                if (strcmp(st, "icononly"))
5503                  {
5504                     emit("elm,action,default,text,set", "");
5505                     set_state(PART:"elm.text", "visible", 0.0);
5506                  }
5507                if (get_int(button_state) != BUTTON_STATE_DISABLED)
5508                  set_state(PART:"button_image", "default", 0.0);
5509             }
5510             after: button_unpress;
5511          }
5512          program { name: "touch_snd";
5513             signal: "mouse,clicked,1";
5514             source: "over2";
5515             action: PLAY_SAMPLE "touch_sound" 1.0;
5516             after: button_unclick3;
5517          }
5518          program { name: "button_unclick3";
5519             action: SIGNAL_EMIT "elm,action,click" "";
5520          }
5521          program { name: "text_show";
5522             signal: "elm,state,text,visible";
5523             source: "elm";
5524             script {
5525                new st[31];
5526                new Float:vl;
5527                get_state(PART:"elm.swallow.content", st, 30, vl);
5528                if (!strcmp(st, "icononly"))
5529                  {
5530                     set_state(PART:"elm.swallow.content", "visible", 0.0);
5531                     set_state(PART:"padding_icon_text", "visible", 0.0);
5532                  }
5533                if (get_int(button_state) != BUTTON_STATE_DISABLED)
5534                  set_state(PART:"elm.text", "visible", 0.0);
5535                else
5536                  set_state(PART:"elm.text", "disabled_visible", 0.0);
5537             }
5538          }
5539          program { name: "text_hide";
5540             signal: "elm,state,text,hidden";
5541             source: "elm";
5542             script {
5543                new st[31];
5544                new Float:vl;
5545                get_state(PART:"elm.swallow.content", st, 30, vl);
5546                if (!strcmp(st, "visible"))
5547                  {
5548                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
5549                     set_state(PART:"padding_icon_text", "icononly", 0.0);
5550                  }
5551                set_state(PART:"elm.text", "default", 0.0);
5552             }
5553          }
5554          program { name: "icon_show";
5555             signal: "elm,state,icon,visible";
5556             source: "elm";
5557             script {
5558                new st[31];
5559                new Float:vl;
5560                get_state(PART:"elm.text", st, 30, vl);
5561                if (!strcmp(st, "visible"))
5562                  {
5563                     set_state(PART:"elm.swallow.content", "visible", 0.0);
5564                     set_state(PART:"padding_icon_text", "visible", 0.0);
5565                  }
5566                else
5567                  {
5568                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
5569                     set_state(PART:"padding_icon_text", "icononly", 0.0);
5570                  }
5571             }
5572          }
5573          program { name: "icon_hide";
5574             signal: "elm,state,icon,hidden";
5575             source: "elm";
5576             action: STATE_SET "default" 0.0;
5577             target: "elm.swallow.content";
5578             target: "padding_icon_text";
5579          }
5580          program { name: "disable";
5581             signal: "elm,state,disabled";
5582             source: "elm";
5583             action: STATE_SET "disabled" 0.0;
5584             target: "button_image";
5585             target: "disabler";
5586             after: "disable_text";
5587          }
5588          program { name: "disable_text";
5589             script {
5590                new st[31];
5591                new Float:vl;
5592                get_state(PART:"elm.text", st, 30, vl);
5593                if (!strcmp(st, "visible"))
5594                  set_state(PART:"elm.text", "disabled_visible", 0.0);
5595                else
5596                  set_state(PART:"elm.text", "disabled", 0.0);
5597                set_int(button_state, BUTTON_STATE_DISABLED);
5598             }
5599          }
5600          program { name: "enable";
5601             signal: "elm,state,enabled";
5602             source: "elm";
5603             action: STATE_SET "default" 0.0;
5604             target: "button_image";
5605             target: "disabler";
5606             after: "enable_text";
5607          }
5608          program { name: "enable_text";
5609             script {
5610                new st[31];
5611                new Float:vl;
5612                get_state(PART:"elm.text", st, 30, vl);
5613                if (!strcmp(st, "disabled_visible"))
5614                  set_state(PART:"elm.text", "visible", 0.0);
5615                else
5616                  set_state(PART:"elm.text", "default", 0.0);
5617                set_int(button_state, BUTTON_STATE_ENABLED);
5618             }
5619          }
5620          program { name: "focused";
5621             //signal: "elm,action,focus";
5622             //source: "elm";
5623             action: STATE_SET "focused" 0.0;
5624             target: "button_image";
5625             target: "elm.text";
5626          }
5627          program { name: "unfocused";
5628             //signal: "elm,action,unfocus";
5629             //source: "elm";
5630             action: STATE_SET "default" 0.0;
5631             target: "button_image";
5632             after: "unfocus_text";
5633          }
5634          program { name: "unfocus_text";
5635             action: STATE_SET "visible" 0.0;
5636             target: "elm.text";
5637          }
5638       }
5639    }
5640
5641 ///////////////////////////////////////////////////////////////////////////////////////
5642    group { name: "elm/button/base/multiline";
5643       alias: "elm/button/base/text_only/multiline";
5644       images {
5645          image: "00_button_04_normal.png" COMP;
5646          image: "00_button_04_press.png" COMP;
5647          image: "00_button_04_dim.png" COMP;
5648          image: "00_button_04_normal_focus.png" COMP;
5649       }
5650       script {
5651          public button_state = BUTTON_STATE_ENABLED;
5652       }
5653       styles{
5654          style { name: "btn_multiline_style";
5655             base: "font=SLP:style=Medium font_size=18 align=center color=#ffffff wrap=mixed text_class=slp_medium";
5656             tag: "br" "\n";
5657             tag: "ps" "ps";
5658             tag: "tab" "\t";
5659          }
5660       }
5661       parts {
5662          part { name: "button_image";
5663             scale: 1;
5664             description { state: "default" 0.0;
5665                min: 10 46;
5666                image {
5667                   normal: "00_button_04_normal.png";
5668                   border: 4 4 3 3;
5669                   border_scale: 1;
5670                }
5671             }
5672             description { state: "clicked" 0.0;
5673                inherit: "default" 0.0;
5674                image.normal: "00_button_04_press.png";
5675             }
5676             description { state: "disabled" 0.0;
5677                inherit: "default" 0.0;
5678                image.normal: "00_button_04_dim.png";
5679             }
5680             description { state: "focused" 0.0;
5681                inherit: "default" 0.0;
5682                image.normal: "00_button_04_normal_focus.png";
5683             }
5684          }
5685          part { name: "padding_left_top";
5686             type: RECT;
5687             scale: 1;
5688             mouse_events: 0;
5689             description { state: "default" 0.0;
5690                align: 0.0 0.0;
5691                rel2.relative: 0.0 0.0;
5692                min: 2 2;
5693                fixed: 1 1;
5694                visible: 0;
5695             }
5696          }
5697          part { name: "padding_right_bottom";
5698             type: RECT;
5699             scale: 1;
5700             mouse_events: 0;
5701             description { state: "default" 0.0;
5702                align: 1.0 1.0;
5703                rel1.relative: 1.0 1.0;
5704                min: 2 2;
5705                fixed: 1 1;
5706                visible: 0;
5707             }
5708          }
5709          part { name: "icon_rect";
5710             type: RECT;
5711             scale: 1;
5712             mouse_events: 0;
5713             description { state: "default" 0.0;
5714                visible: 1;
5715                min: 0 40;
5716                fixed: 1 0;
5717                rel1 {
5718                   relative: 0.0 1.0;
5719                   to_x: "elm.swallow.content";
5720                   to_y: "padding_left_top";
5721                }
5722                rel2 {
5723                   relative: 1.0 0.0;
5724                   to_x: "elm.swallow.content";
5725                   to_y: "padding_right_bottom";
5726                }
5727                align: 0.0 0.5;
5728                color: 0 0 0 0;
5729             }
5730          }
5731          part { name: "padding_icon_text";
5732             type: RECT;
5733             scale: 1;
5734             mouse_events: 0;
5735             description { state: "default" 0.0; //when only icon or no icon is there
5736                align: 0.0 0.0;
5737                rel1 {
5738                   relative: 1.0 0.0;
5739                   to: "icon_rect";
5740                }
5741                rel2.to: "icon_rect";
5742                fixed: 1 0;
5743                min: 0 0;
5744                color: 0 0 0 0;
5745             }
5746             description { state: "icononly" 0.0;
5747                inherit: "default" 0.0;
5748             }
5749             description { state: "visible" 0.0; //when icon is visible
5750                align: 0.0 0.0;
5751                rel1 {
5752                   relative: 1.0 0.0;
5753                   to: "icon_rect";
5754                }
5755                rel2.to: "icon_rect";
5756                fixed: 1 0;
5757                min: 5 0;
5758                color: 0 0 0 0;
5759             }
5760          }
5761          part { name: "elm.swallow.content";
5762             type: SWALLOW;
5763             scale: 1;
5764             clip_to: "clipper";
5765             description { state: "default" 0.0;
5766                visible: 0;
5767                align: 0.0 0.5;
5768                rel1 {
5769                   relative: 1.0 1.0;
5770                   to: "padding_left_top";
5771                }
5772                rel2 {
5773                   relative: 1.0 0.0;
5774                   to_x: "padding_left_top";
5775                   to_y: "padding_right_bottom";
5776                }
5777                fixed: 1 0;
5778             }
5779             description { state: "visible" 0.0;
5780                fixed: 1 0;
5781                align: 0.0 0.5;
5782                rel1 {
5783                   relative: 1.0 1.0;
5784                   to: "padding_left_top";
5785                }
5786                rel2 {
5787                   relative: 1.0 0.0;
5788                   to_x: "padding_left_top";
5789                   to_y: "padding_right_bottom";
5790                }
5791                aspect: 1.0 1.0;
5792                aspect_preference: VERTICAL;
5793             }
5794             description { state: "icononly" 0.0;
5795                min: 40 40;
5796                rel1 {
5797                   relative: 1.0 1.0;
5798                   to: "padding_left_top";
5799                }
5800                rel2 {
5801                   relative: 0.0 0.0;
5802                   to: "padding_right_bottom";
5803                }
5804                aspect: 1.0 1.0;
5805                aspect_preference: VERTICAL;
5806             }
5807          }
5808          part { name: "elm.text";
5809             type: TEXTBLOCK;
5810             mouse_events: 0;
5811             scale: 1;
5812             clip_to: "clipper";
5813             description { state: "default" 0.0;
5814                visible: 0;
5815                rel1 {
5816                   relative: 1.0 1.0;
5817                   to_x: "padding_icon_text";
5818                   to_y: "padding_left_top";
5819                }
5820                rel2 {
5821                   relative: 0.0 0.0;
5822                   to: "padding_right_bottom";
5823                }
5824                color: BUTTON_TEXT_STYLE1_NORMAL_COLOR_INC;
5825                text {
5826                   style: "btn_multiline_style";
5827                   min: 0 0;
5828                   max: 0 1;
5829                }
5830             }
5831             description { state: "visible" 0.0;
5832                inherit: "default" 0.0;
5833                visible: 1;
5834                min: 80 0;
5835             }
5836             description { state: "clicked" 0.0;
5837                inherit: "default" 0.0;
5838                visible: 1;
5839                min: 0 0;
5840                color: BUTTON_TEXT_STYLE1_PRESSED_COLOR_INC;
5841             }
5842             description { state: "disabled" 0.0;
5843                inherit: "default" 0.0;
5844                color: 0 0 0 128;
5845             }
5846             description { state: "disabled_visible" 0.0;
5847                inherit: "default" 0.0;
5848                color: BUTTON_TEXT_STYLE1_TEXT_DISABLED_COLOR_INC;
5849                visible: 1;
5850                min: 80 0;
5851             }
5852             description { state: "focused" 0.0;
5853                inherit: "default" 0.0;
5854                visible: 1;
5855                min: 0 0;
5856                color: BUTTON_TEXT_STYLE1_DISABLED_COLOR_INC;
5857             }
5858          }
5859          part { name: "over2";
5860             type: RECT;
5861             repeat_events: 1;
5862             ignore_flags: ON_HOLD;
5863             description { state: "default" 0.0;
5864                color: 0 0 0 0;
5865             }
5866          }
5867          part { name: "over3";
5868             type: RECT;
5869             repeat_events: 1;
5870             description { state: "default" 0.0;
5871                color: 0 0 0 0;
5872             }
5873          }
5874          part { name: "clipper";
5875             type: RECT;
5876             description { state: "default" 0.0;
5877                color: 255 255 255 255;
5878             }
5879          }
5880          part { name: "disabler";
5881             type: RECT;
5882             description { state: "default" 0.0;
5883                color: 0 0 0 0;
5884                visible: 0;
5885             }
5886             description { state: "disabled" 0.0;
5887                inherit: "default" 0.0;
5888                visible: 1;
5889             }
5890          }
5891       }
5892       programs {
5893          program { name: "button_click";
5894             signal: "mouse,down,1";
5895             source: "over2";
5896             action: SIGNAL_EMIT "elm,action,press" "";
5897             after: "button_click_anim";
5898          }
5899          program { name: "button_click_anim";
5900             action: STATE_SET "clicked" 0.0;
5901             target: "button_image";
5902             after: "text_clicked";
5903          }
5904          program { name: "text_clicked";
5905             script {
5906                new st[31];
5907                new Float:vl;
5908                get_state(PART:"elm.text", st, 30, vl);
5909                if (!strcmp(st, "visible"))
5910                  set_state(PART:"elm.text", "clicked", 0.0);
5911             }
5912          }
5913          program { name: "button_unpress";
5914             action: SIGNAL_EMIT "elm,action,unpress" "";
5915          }
5916          program { name: "button_mouseout_clicked";
5917             signal: "mouse,up,1";
5918             source: "over3";
5919             script {
5920                new st[31];
5921                new Float:vl;
5922                get_state(PART:"elm.swallow.content", st, 30, vl);
5923                if (strcmp(st, "icononly"))
5924                  {
5925                     emit("elm,action,default,text,set", "");
5926                     set_state(PART:"elm.text", "visible", 0.0);
5927                  }
5928                if (get_int(button_state) != BUTTON_STATE_DISABLED)
5929                  set_state(PART:"button_image", "default", 0.0);
5930             }
5931             after: button_unpress;
5932          }
5933          program { name: "touch_snd";
5934             signal: "mouse,clicked,1";
5935             source: "over2";
5936             action: PLAY_SAMPLE "touch_sound" 1.0;
5937             after: button_unclick3;
5938          }
5939          program { name: "button_unclick3";
5940             action: SIGNAL_EMIT "elm,action,click" "";
5941          }
5942          program { name: "text_show";
5943             signal: "elm,state,text,visible";
5944             source: "elm";
5945             script {
5946                new st[31];
5947                new Float:vl;
5948                get_state(PART:"elm.swallow.content", st, 30, vl);
5949                if (!strcmp(st, "icononly"))
5950                  {
5951                     set_state(PART:"elm.swallow.content", "visible", 0.0);
5952                     set_state(PART:"padding_icon_text", "visible", 0.0);
5953                  }
5954                if (get_int(button_state) != BUTTON_STATE_DISABLED)
5955                  set_state(PART:"elm.text", "visible", 0.0);
5956                else
5957                  set_state(PART:"elm.text", "disabled_visible", 0.0);
5958             }
5959          }
5960          program { name: "text_hide";
5961             signal: "elm,state,text,hidden";
5962             source: "elm";
5963             script {
5964                new st[31];
5965                new Float:vl;
5966                get_state(PART:"elm.swallow.content", st, 30, vl);
5967                if (!strcmp(st, "visible"))
5968                  {
5969                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
5970                     set_state(PART:"padding_icon_text", "icononly", 0.0);
5971                  }
5972                set_state(PART:"elm.text", "default", 0.0);
5973             }
5974          }
5975          program { name: "icon_show";
5976             signal: "elm,state,icon,visible";
5977             source: "elm";
5978             script {
5979                new st[31];
5980                new Float:vl;
5981                get_state(PART:"elm.text", st, 30, vl);
5982                if (!strcmp(st, "visible"))
5983                  {
5984                     set_state(PART:"elm.swallow.content", "visible", 0.0);
5985                     set_state(PART:"padding_icon_text", "visible", 0.0);
5986                  }
5987                else
5988                  {
5989                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
5990                     set_state(PART:"padding_icon_text", "icononly", 0.0);
5991                  }
5992             }
5993          }
5994          program { name: "icon_hide";
5995             signal: "elm,state,icon,hidden";
5996             source: "elm";
5997             action: STATE_SET "default" 0.0;
5998             target: "elm.swallow.content";
5999             target: "padding_icon_text";
6000          }
6001          program { name: "disable";
6002             signal: "elm,state,disabled";
6003             source: "elm";
6004             action: STATE_SET "disabled" 0.0;
6005             target: "button_image";
6006             target: "disabler";
6007             after: "disable_text";
6008          }
6009          program { name: "disable_text";
6010             script {
6011                new st[31];
6012                new Float:vl;
6013                get_state(PART:"elm.text", st, 30, vl);
6014                if (!strcmp(st, "visible"))
6015                  set_state(PART:"elm.text", "disabled_visible", 0.0);
6016                else
6017                  set_state(PART:"elm.text", "disabled", 0.0);
6018                set_int(button_state, BUTTON_STATE_DISABLED);
6019             }
6020          }
6021          program { name: "enable";
6022             signal: "elm,state,enabled";
6023             source: "elm";
6024             action: STATE_SET "default" 0.0;
6025             target: "button_image";
6026             target: "disabler";
6027             after: "enable_text";
6028          }
6029          program { name: "enable_text";
6030             script {
6031                new st[31];
6032                new Float:vl;
6033                get_state(PART:"elm.text", st, 30, vl);
6034                if (!strcmp(st, "disabled_visible"))
6035                  set_state(PART:"elm.text", "visible", 0.0);
6036                else
6037                  set_state(PART:"elm.text", "default", 0.0);
6038                set_int(button_state, BUTTON_STATE_ENABLED);
6039             }
6040          }
6041          program { name: "focused";
6042             //signal: "elm,action,focus";
6043             //source: "elm";
6044             action: STATE_SET "focused" 0.0;
6045             target: "button_image";
6046             target: "elm.text";
6047          }
6048          program { name: "unfocused";
6049             //signal: "elm,action,unfocus";
6050             //source: "elm";
6051             action: STATE_SET "default" 0.0;
6052             target: "button_image";
6053             after: "unfocus_text";
6054          }
6055          program { name: "unfocus_text";
6056             action: STATE_SET "visible" 0.0;
6057             target: "elm.text";
6058          }
6059       }
6060    }
6061
6062 ///////////////////////////////////////////////////////////////////////////////////////
6063    group { name: "elm/button/base/default";
6064       images {
6065          image: "00_button_01_normal.png" COMP;
6066          image: "00_button_01_normal_press.png" COMP;
6067          image: "00_button_01_normal_dim.png" COMP;
6068          image: "00_button_01_normal_Focus.png" COMP;
6069       }
6070       script {
6071          public button_state = BUTTON_STATE_ENABLED;
6072       }
6073       parts {
6074          part { name: "button_image";
6075             scale: 1;
6076             description { state: "default" 0.0;
6077                min: BUTTON_DEFAULT_STYLE_BG_MIN_INC;
6078                image {
6079                   normal: "00_button_01_normal.png";
6080                   border: BUTTON_DEFAULT_STYLE_BG_BORDER_INC;
6081                   border_scale: 1;
6082                }
6083             }
6084             description { state: "clicked" 0.0;
6085                inherit: "default" 0.0;
6086                image.normal: "00_button_01_normal_press.png";
6087             }
6088             description { state: "disabled" 0.0;
6089                inherit: "default" 0.0;
6090                image.normal: "00_button_01_normal_dim.png";
6091             }
6092             description { state: "focused" 0.0;
6093                inherit: "default" 0.0;
6094                image.normal: "00_button_01_normal_Focus.png";
6095             }
6096          }
6097          part { name: "padding_left_top";
6098             type: RECT;
6099             scale: 1;
6100             mouse_events: 0;
6101             description { state: "default" 0.0;
6102                align: 0.0 0.0;
6103                rel2.relative: 0.0 0.0;
6104                min: BUTTON_DEFAULT_STYLE_PADDING_MIN_INC;
6105                fixed: 1 1;
6106                visible: 0;
6107             }
6108          }
6109          part { name: "padding_right_bottom";
6110             type: RECT;
6111             scale: 1;
6112             mouse_events: 0;
6113             description { state: "default" 0.0;
6114                align: 1.0 1.0;
6115                rel1.relative: 1.0 1.0;
6116                min: BUTTON_DEFAULT_STYLE_PADDING_MIN_INC;
6117                fixed: 1 1;
6118                visible: 0;
6119             }
6120          }
6121          part { name: "padding_icon_text";
6122             type: RECT;
6123             scale: 1;
6124             mouse_events: 0;
6125             description { state: "default" 0.0; //when only icon or no icon is there
6126                align: 0.0 0.0;
6127                visible: 0;
6128                rel1 {
6129                   relative: 1.0 0.0;
6130                   to: "elm.swallow.content";
6131                }
6132                rel2.to: "elm.swallow.content";
6133                fixed: 1 0;
6134                min: 0 0;
6135             }
6136             description { state: "icononly" 0.0;
6137                inherit: "default" 0.0;
6138             }
6139             description { state: "visible" 0.0; //when icon is visible
6140                inherit: "default" 0.0;
6141                min: BUTTON_DEFAULT_STYLE_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
6142             }
6143          }
6144          part { name: "elm.swallow.content";
6145             type: SWALLOW;
6146             scale: 1;
6147             clip_to: "clipper";
6148             description { state: "default" 0.0;
6149                visible: 0;
6150                align: 0.0 0.5;
6151                rel1 {
6152                   relative: 1.0 1.0;
6153                   to: "padding_left_top";
6154                }
6155                rel2 {
6156                   relative: 1.0 0.0;
6157                   to_x: "padding_left_top";
6158                   to_y: "padding_right_bottom";
6159                }
6160                fixed: 1 0;
6161             }
6162             description { state: "visible" 0.0;
6163                fixed: 1 0;
6164                align: 0.0 0.5;
6165                rel1 {
6166                   relative: 1.0 1.0;
6167                   to: "padding_left_top";
6168                }
6169                rel2 {
6170                   relative: 1.0 0.0;
6171                   to_x: "padding_left_top";
6172                   to_y: "padding_right_bottom";
6173                }
6174                aspect: 1.0 1.0;
6175                aspect_preference: VERTICAL;
6176             }
6177             description { state: "icononly" 0.0;
6178                min: BUTTON_DEFAULT_STYLE_ICONONLY_ICON_MIN_INC;
6179                rel1 {
6180                   relative: 1.0 0.0;
6181                   to_x: "padding_left_top";
6182                }
6183                rel2 {
6184                   relative: 0.0 1.0;
6185                   to_x: "padding_right_bottom";
6186                }
6187                aspect: 1.0 1.0;
6188                aspect_preference: VERTICAL;
6189             }
6190          }
6191          part { name: "elm.text";
6192             type: TEXT;
6193             mouse_events: 0;
6194             scale: 1;
6195             clip_to: "clipper";
6196             description { state: "default" 0.0;
6197                visible: 0;
6198                align: 0.0 0.5;
6199                rel1 {
6200                   relative: 1.0 1.0;
6201                   to_x: "padding_icon_text";
6202                   to_y: "padding_left_top";
6203                }
6204                rel2 {
6205                   relative: 0.0 0.0;
6206                   to: "padding_right_bottom";
6207                }
6208                color: BUTTON_DEFAULT_STYLE_BUTTON_TEXT_NORMAL_COLOR_INC;
6209                text {
6210                   font: "SLP:style=Medium";
6211                   size: BUTTON_DEFAULT_STYLE_FONT_SIZE_INC;
6212                   min: 0 0;
6213                   text_class: "slp_medium";
6214                }
6215             }
6216             description { state: "visible" 0.0;
6217                inherit: "default" 0.0;
6218                visible: 1;
6219                min: BUTTON_DEFAULT_STYLE_TEXT_MIN_INC;
6220             }
6221             description { state: "clicked" 0.0;
6222                inherit: "default" 0.0;
6223                visible: 1;
6224                min: BUTTON_DEFAULT_STYLE_TEXT_MIN_INC;
6225                color: BUTTON_DEFAULT_STYLE_BUTTON_TEXT_PRESSED_COLOR_INC;
6226             }
6227             description { state: "disabled" 0.0;
6228                inherit: "default" 0.0;
6229             }
6230             description { state: "disabled_visible" 0.0;
6231                inherit: "default" 0.0;
6232                color: BUTTON_DEFAULT_STYLE_BUTTON_TEXT_DISABLED_COLOR_INC;
6233                visible: 1;
6234                min: BUTTON_DEFAULT_STYLE_TEXT_MIN_INC;
6235             }
6236             description { state: "focused" 0.0;
6237                inherit: "default" 0.0;
6238                visible: 1;
6239                min: 0 0;
6240                color: BUTTON_DEFAULT_STYLE_BUTTON_TEXT_FOCUSED_COLOR_INC;
6241             }
6242          }
6243          part { name: "over2";
6244             type: RECT;
6245             repeat_events: 1;
6246             ignore_flags: ON_HOLD;
6247             description { state: "default" 0.0;
6248                color: 0 0 0 0;
6249             }
6250          }
6251          part { name: "over3";
6252             type: RECT;
6253             repeat_events: 1;
6254             description { state: "default" 0.0;
6255                color: 0 0 0 0;
6256             }
6257          }
6258          part { name: "clipper";
6259             type: RECT;
6260             description { state: "default" 0.0;
6261                color: 255 255 255 255;
6262             }
6263          }
6264          part { name: "disabler";
6265             type: RECT;
6266             description { state: "default" 0.0;
6267                color: 0 0 0 0;
6268                visible: 0;
6269             }
6270             description { state: "disabled" 0.0;
6271                inherit: "default" 0.0;
6272                visible: 1;
6273             }
6274          }
6275       }
6276       programs {
6277          program { name: "button_click";
6278             signal: "mouse,down,1";
6279             source: "over2";
6280             action: SIGNAL_EMIT "elm,action,press" "";
6281             after: "button_click_anim";
6282          }
6283          program { name: "button_click_anim";
6284             action: STATE_SET "clicked" 0.0;
6285             target: "button_image";
6286             after: "text_clicked";
6287          }
6288          program { name: "text_clicked";
6289             script {
6290                new st[31];
6291                new Float:vl;
6292                get_state(PART:"elm.text", st, 30, vl);
6293                if (!strcmp(st, "visible"))
6294                  set_state(PART:"elm.text", "clicked", 0.0);
6295             }
6296          }
6297          program { name: "button_unpress";
6298             action: SIGNAL_EMIT "elm,action,unpress" "";
6299          }
6300          program { name: "button_mouseout_clicked";
6301             signal: "mouse,up,1";
6302             source: "over3";
6303             script {
6304                new st[31];
6305                new Float:vl;
6306                get_state(PART:"elm.swallow.content", st, 30, vl);
6307                if (strcmp(st, "icononly"))
6308                  {
6309                     emit("elm,action,default,text,set", "");
6310                     set_state(PART:"elm.text", "visible", 0.0);
6311                  }
6312                if (get_int(button_state) != BUTTON_STATE_DISABLED)
6313                  set_state(PART:"button_image", "default", 0.0);
6314             }
6315             after: button_unpress;
6316          }
6317          program { name: "touch_snd";
6318             signal: "mouse,clicked,1";
6319             source: "over2";
6320             action: PLAY_SAMPLE "touch_sound" 1.0;
6321             after: button_unclick3;
6322          }
6323          program { name: "button_unclick3";
6324             action: SIGNAL_EMIT "elm,action,click" "";
6325          }
6326          program { name: "text_show";
6327             signal: "elm,state,text,visible";
6328             source: "elm";
6329             script {
6330                new st[31];
6331                new Float:vl;
6332                get_state(PART:"elm.swallow.content", st, 30, vl);
6333                if (!strcmp(st, "icononly"))
6334                  {
6335                     set_state(PART:"elm.swallow.content", "visible", 0.0);
6336                     set_state(PART:"padding_icon_text", "visible", 0.0);
6337                  }
6338                if (get_int(button_state) != BUTTON_STATE_DISABLED)
6339                  set_state(PART:"elm.text", "visible", 0.0);
6340                else
6341                  set_state(PART:"elm.text", "disabled_visible", 0.0);
6342             }
6343          }
6344          program { name: "text_hide";
6345             signal: "elm,state,text,hidden";
6346             source: "elm";
6347             script {
6348                new st[31];
6349                new Float:vl;
6350                get_state(PART:"elm.swallow.content", st, 30, vl);
6351                if (!strcmp(st, "visible"))
6352                  {
6353                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
6354                     set_state(PART:"padding_icon_text", "icononly", 0.0);
6355                  }
6356                set_state(PART:"elm.text", "default", 0.0);
6357             }
6358          }
6359          program { name: "icon_show";
6360             signal: "elm,state,icon,visible";
6361             source: "elm";
6362             script {
6363                new st[31];
6364                new Float:vl;
6365                get_state(PART:"elm.text", st, 30, vl);
6366                if (!strcmp(st, "visible"))
6367                  {
6368                     set_state(PART:"elm.swallow.content", "visible", 0.0);
6369                     set_state(PART:"padding_icon_text", "visible", 0.0);
6370                  }
6371                else
6372                  {
6373                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
6374                     set_state(PART:"padding_icon_text", "icononly", 0.0);
6375                  }
6376             }
6377          }
6378          program { name: "icon_hide";
6379             signal: "elm,state,icon,hidden";
6380             source: "elm";
6381             action: STATE_SET "default" 0.0;
6382             target: "elm.swallow.content";
6383             target: "padding_icon_text";
6384          }
6385          program { name: "disable";
6386             signal: "elm,state,disabled";
6387             source: "elm";
6388             action: STATE_SET "disabled" 0.0;
6389             target: "button_image";
6390             target: "disabler";
6391             after: "disable_text";
6392          }
6393          program { name: "disable_text";
6394             script {
6395                new st[31];
6396                new Float:vl;
6397                get_state(PART:"elm.text", st, 30, vl);
6398                if (!strcmp(st, "visible"))
6399                  set_state(PART:"elm.text", "disabled_visible", 0.0);
6400                else
6401                  set_state(PART:"elm.text", "disabled", 0.0);
6402                set_int(button_state, BUTTON_STATE_DISABLED);
6403             }
6404          }
6405          program { name: "enable";
6406             signal: "elm,state,enabled";
6407             source: "elm";
6408             action: STATE_SET "default" 0.0;
6409             target: "button_image";
6410             target: "disabler";
6411             after: "enable_text";
6412          }
6413          program { name: "enable_text";
6414             script {
6415                new st[31];
6416                new Float:vl;
6417                get_state(PART:"elm.text", st, 30, vl);
6418                if (!strcmp(st, "disabled_visible"))
6419                  set_state(PART:"elm.text", "visible", 0.0);
6420                else
6421                  set_state(PART:"elm.text", "default", 0.0);
6422                set_int(button_state, BUTTON_STATE_ENABLED);
6423             }
6424          }
6425          program { name: "focused";
6426             //signal: "elm,action,focus";
6427             //source: "elm";
6428             action: STATE_SET "focused" 0.0;
6429             target: "button_image";
6430             target: "elm.text";
6431          }
6432          program { name: "unfocused";
6433             //signal: "elm,action,unfocus";
6434             //source: "elm";
6435             action: STATE_SET "default" 0.0;
6436             target: "button_image";
6437             after: "unfocus_text";
6438          }
6439          program { name: "unfocus_text";
6440             action: STATE_SET "visible" 0.0;
6441             target: "elm.text";
6442          }
6443       }
6444    }
6445
6446 ///////////////////////////////////////////////////////////////////////////////////////
6447 #define BUTTON_COLORSELECTOR_STYLES(style_name, image_normal, image_press,image_disable) \
6448    group { name: "elm/button/base/"style_name; \
6449       images { \
6450          image: image_normal COMP; \
6451          image: image_press COMP; \
6452          image: image_disable COMP; \
6453          image: "00_button_01_normal.png" COMP; \
6454          image: "00_button_01_normal_press.png" COMP; \
6455          image: "00_button_01_normal_dim.png" COMP; \
6456          image: "00_button_01_normal_Focus.png" COMP; \
6457       } \
6458       parts { \
6459          part { name: "button_image"; \
6460             scale: 1; \
6461             description { state: "default" 0.0; \
6462                min: BUTTON_COLORSELECTOR_BG_DEFAULT_MIN_INC; \
6463                max: BUTTON_COLORSELECTOR_BG_DEFAULT_MIN_INC; \
6464                image { \
6465                   normal: "00_button_01_normal.png"; \
6466                   border: BUTTON_COLORSELECTOR_BG_BORDER_INC; \
6467                   border_scale: 1; \
6468                } \
6469             } \
6470             description { \
6471                state: "clicked" 0.0; \
6472                inherit: "default" 0.0; \
6473                image.normal: "00_button_01_normal_press.png"; \
6474             } \
6475             description { \
6476                state: "disabled" 0.0; \
6477                inherit: "default" 0.0; \
6478                image.normal: "00_button_01_normal_dim.png"; \
6479             } \
6480             description { \
6481                state: "focused" 0.0; \
6482                inherit: "default" 0.0; \
6483                image.normal: "00_button_01_normal_Focus.png"; \
6484             } \
6485          } \
6486          part { name: "button_center_part"; \
6487             scale: 1; \
6488             description { state: "default" 0.0; \
6489                min: BUTTON_COLORSELECTOR_IMAGE_MIN_MAX_INC; \
6490                max: BUTTON_COLORSELECTOR_IMAGE_MIN_MAX_INC; \
6491                image.normal: image_normal; \
6492             } \
6493             description { \
6494                state: "clicked" 0.0; \
6495                inherit: "default" 0.0; \
6496                image.normal: image_press; \
6497             } \
6498             description { \
6499                state: "disabled" 0.0; \
6500                inherit: "default" 0.0; \
6501                image.normal: image_disable; \
6502             } \
6503          } \
6504          part { name: "over1"; \
6505             type: RECT; \
6506             ignore_flags: ON_HOLD; \
6507             description { state: "default" 0.0; \
6508                color: 0 0 0 0; \
6509             } \
6510          } \
6511          part { name: "over2"; \
6512             repeat_events: 1; \
6513             description { state: "default" 0.0; \
6514                color: 0 0 0 0; \
6515             } \
6516          } \
6517          part { name: "disabler"; \
6518             type: RECT; \
6519             description { state: "default" 0.0; \
6520                color: 0 0 0 0; \
6521                visible: 0; \
6522             } \
6523             description { state: "disabled" 0.0; \
6524                inherit: "default" 0.0; \
6525                visible: 1; \
6526             } \
6527          } \
6528       } \
6529       programs { \
6530          program { name: "button_click"; \
6531             signal: "mouse,down,1"; \
6532             source: "over1"; \
6533             action: SIGNAL_EMIT "elm,action,press" ""; \
6534             after: "button_click_anim"; \
6535          } \
6536          program { name: "button_click_anim"; \
6537             action: STATE_SET "clicked" 0.0; \
6538             target: "button_image"; \
6539             target: "button_center_part"; \
6540          } \
6541          program { name: "button_unclick"; \
6542             signal: "mouse,up,1"; \
6543             source: "over2"; \
6544             action: SIGNAL_EMIT "elm,action,unpress" ""; \
6545             after: "button_unclick_anim"; \
6546          } \
6547          program { name: "button_unclick_anim"; \
6548             action: STATE_SET "default" 0.0; \
6549             target: "button_image"; \
6550             target: "button_center_part"; \
6551          } \
6552          program { name: "touch_snd"; \
6553             signal: "mouse,clicked,1"; \
6554             source: "over1"; \
6555             action: PLAY_SAMPLE "touch_sound" 1.0; \
6556             after: button_unclick3; \
6557          } \
6558          program { name: "button_unclick3"; \
6559             action: SIGNAL_EMIT "elm,action,click" ""; \
6560          } \
6561          program { name: "disable"; \
6562             signal: "elm,state,disabled"; \
6563             source: "elm"; \
6564             action: STATE_SET "disabled" 0.0; \
6565             target: "disabler"; \
6566             target: "button_image"; \
6567             target: "button_center_part"; \
6568          } \
6569          program { name: "enable"; \
6570             signal: "elm,state,enabled"; \
6571             source: "elm"; \
6572             action: STATE_SET "default" 0.0; \
6573             target: "disabler"; \
6574             target: "button_image"; \
6575             target: "button_center_part"; \
6576          } \
6577       } \
6578    }
6579 ///////////////////////////////////////////////////////////////////////////////////////
6580    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")
6581 ///////////////////////////////////////////////////////////////////////////////////////
6582    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")
6583 ///////////////////////////////////////////////////////////////////////////////////////
6584    group { name: "elm/button/base/hidden";
6585       images {
6586          image: "00_button_sweep.png" COMP;
6587          image: "00_button_sweep_press.png" COMP;
6588          image: "00_button_sweep_focus.png" COMP;
6589          image: "00_button_sweep_dim.png" COMP;
6590       }
6591       script {
6592          public button_state = BUTTON_STATE_ENABLED;
6593       }
6594       parts {
6595          part { name: "button_image";
6596             scale: 1;
6597             description { state: "default" 0.0;
6598                min: BUTTON_HIDDEN_BG_NORMAL_MIN_INC;
6599                image {
6600                   normal: "00_button_sweep.png";
6601                   border: BUTTON_HIDDEN_BG_BORDER_INC;
6602                   border_scale: 1;
6603                }
6604             }
6605             description { state: "clicked" 0.0;
6606                inherit: "default" 0.0;
6607                image.normal: "00_button_sweep_press.png";
6608             }
6609             description { state: "disabled" 0.0;
6610                inherit: "default" 0.0;
6611                image.normal: "00_button_sweep_dim.png";
6612             }
6613             description { state: "focused" 0.0;
6614                inherit: "default" 0.0;
6615                image.normal: "00_button_sweep_focus.png";
6616             }
6617          }
6618          part { name: "padding_left_top";
6619             type: RECT;
6620             scale: 1;
6621             mouse_events: 0;
6622             description { state: "default" 0.0;
6623                align: 0.0 0.0;
6624                rel2.relative: 0.0 0.0;
6625                min: BUTTON_HIDDEN_PADDING_MIN_INC;
6626                fixed: 1 1;
6627                visible: 0;
6628             }
6629          }
6630          part { name: "padding_right_bottom";
6631             type: RECT;
6632             scale: 1;
6633             mouse_events: 0;
6634             description { state: "default" 0.0;
6635                align: 1.0 1.0;
6636                rel1.relative: 1.0 1.0;
6637                min: BUTTON_HIDDEN_PADDING_MIN_INC;
6638                fixed: 1 1;
6639                visible: 0;
6640             }
6641          }
6642          part { name: "icon_rect";
6643             type: RECT;
6644             scale: 1;
6645             mouse_events: 0;
6646             description { state: "default" 0.0;
6647                min: BUTTON_HIDDEN_ICON_RECT_MIN_INC;
6648                fixed: 1 0;
6649                rel1 {
6650                   relative: 0.0 1.0;
6651                   to_x: "elm.swallow.content";
6652                   to_y: "padding_left_top";
6653                }
6654                rel2 {
6655                   relative: 1.0 0.0;
6656                   to_x: "elm.swallow.content";
6657                   to_y: "padding_right_bottom";
6658                }
6659                align: 0.0 0.5;
6660                color: 0 0 0 0;
6661             }
6662          }
6663          part { name: "padding_icon_text";
6664             type: RECT;
6665             scale: 1;
6666             mouse_events: 0;
6667             description { state: "default" 0.0; //when only icon or no icon is there
6668                align: 0.0 0.0;
6669                rel1 {
6670                   relative: 1.0 0.0;
6671                   to: "icon_rect";
6672                }
6673                rel2.to: "icon_rect";
6674                fixed: 1 0;
6675                min: 0 0;
6676                color: 0 0 0 0;
6677             }
6678             description { state: "icononly" 0.0;
6679                inherit: "default" 0.0;
6680             }
6681             description { state: "visible" 0.0; //when icon is visible
6682                align: 0.0 0.0;
6683                rel1 {
6684                   relative: 1.0 0.0;
6685                   to: "icon_rect";
6686                }
6687                rel2.to: "icon_rect";
6688                fixed: 1 0;
6689                min: BUTTON_HIDDEN_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
6690                color: 0 0 0 0;
6691             }
6692          }
6693          part { name: "elm.swallow.content";
6694             type: SWALLOW;
6695             scale: 1;
6696             clip_to: "clipper";
6697             description { state: "default" 0.0;
6698                visible: 0;
6699                align: 0.0 0.5;
6700                rel1 {
6701                   relative: 1.0 1.0;
6702                   to: "padding_left_top";
6703                }
6704                rel2 {
6705                   relative: 1.0 0.0;
6706                   to_x: "padding_left_top";
6707                   to_y: "padding_right_bottom";
6708                }
6709                fixed: 1 0;
6710             }
6711             description { state: "visible" 0.0;
6712                fixed: 1 0;
6713                align: 0.0 0.5;
6714                rel1 {
6715                   relative: 1.0 1.0;
6716                   to: "padding_left_top";
6717                }
6718                rel2 {
6719                   relative: 1.0 0.0;
6720                   to_x: "padding_left_top";
6721                   to_y: "padding_right_bottom";
6722                }
6723                aspect: 1.0 1.0;
6724                aspect_preference: VERTICAL;
6725             }
6726             description { state: "icononly" 0.0;
6727                min: BUTTON_HIDDEN_ICON_ICONONLY_MIN_INC;
6728                rel1 {
6729                   relative: 1.0 1.0;
6730                   to: "padding_left_top";
6731                }
6732                rel2 {
6733                   relative: 1.0 0.0;
6734                   to_x: "padding_left_top";
6735                   to_y: "padding_right_bottom";
6736                }
6737                aspect: 1.0 1.0;
6738                aspect_preference: VERTICAL;
6739             }
6740          }
6741          part { name: "elm.text";
6742             type: TEXT;
6743             mouse_events: 0;
6744             scale: 1;
6745             clip_to: "clipper";
6746             description { state: "default" 0.0;
6747                visible: 0;
6748                rel1 {
6749                   relative: 1.0 1.0;
6750                   to_x: "padding_icon_text";
6751                   to_y: "padding_left_top";
6752                }
6753                rel2 {
6754                   relative: 0.0 0.0;
6755                   to: "padding_right_bottom";
6756                }
6757                color: BUTTON_HIDDEN_BUTTON_TEXT_NORMAL_COLOR_INC;
6758                text {
6759                   font: "SLP:style=Medium";
6760                   size: BUTTON_HIDDEN_FONT_SIZE_INC;
6761                   min: 0 0;
6762                   text_class: "slp_medium";
6763                }
6764             }
6765             description { state: "visible" 0.0;
6766                inherit: "default" 0.0;
6767                visible: 1;
6768                min: BUTTON_HIDDEN_TEXT_MIN_INC;
6769             }
6770             description { state: "clicked" 0.0;
6771                inherit: "default" 0.0;
6772                visible: 1;
6773                min: 0 0;
6774                color: BUTTON_HIDDEN_BUTTON_TEXT_PRESSED_COLOR_INC;
6775             }
6776             description { state: "disabled" 0.0;
6777                inherit: "default" 0.0;
6778                color: 0 0 0 128;
6779             }
6780             description { state: "disabled_visible" 0.0;
6781                inherit: "default" 0.0;
6782                color: BUTTON_HIDDEN_BUTTON_TEXT_DISABLED_COLOR_INC;
6783                visible: 1;
6784                min: BUTTON_HIDDEN_TEXT_MIN_INC;
6785             }
6786             description { state: "focused" 0.0;
6787                inherit: "default" 0.0;
6788                visible: 1;
6789                min: 0 0;
6790                color: BUTTON_HIDDEN_BUTTON_TEXT_FOCUSED_COLOR_INC;
6791             }
6792          }
6793          part { name: "over2";
6794             type: RECT;
6795             repeat_events: 1;
6796             ignore_flags: ON_HOLD;
6797             description { state: "default" 0.0;
6798                color: 0 0 0 0;
6799             }
6800          }
6801          part { name: "over3";
6802             type: RECT;
6803             repeat_events: 1;
6804             description { state: "default" 0.0;
6805                color: 0 0 0 0;
6806             }
6807          }
6808          part { name: "clipper";
6809             type: RECT;
6810             description { state: "default" 0.0;
6811                color: 255 255 255 255;
6812             }
6813          }
6814          part { name: "disabler";
6815             type: RECT;
6816             description { state: "default" 0.0;
6817                color: 0 0 0 0;
6818                visible: 0;
6819             }
6820             description { state: "disabled" 0.0;
6821                inherit: "default" 0.0;
6822                visible: 1;
6823             }
6824          }
6825       }
6826       programs {
6827          program { name: "button_click";
6828             signal: "mouse,down,1";
6829             source: "over2";
6830             action: SIGNAL_EMIT "elm,action,press" "";
6831             after: "button_click_anim";
6832          }
6833          program { name: "button_click_anim";
6834             action: STATE_SET "clicked" 0.0;
6835             target: "button_image";
6836             after: "text_clicked";
6837          }
6838          program { name: "text_clicked";
6839             script {
6840                new st[31];
6841                new Float:vl;
6842                get_state(PART:"elm.text", st, 30, vl);
6843                if (!strcmp(st, "visible"))
6844                  set_state(PART:"elm.text", "clicked", 0.0);
6845             }
6846          }
6847          program { name: "button_unpress";
6848             action: SIGNAL_EMIT "elm,action,unpress" "";
6849          }
6850          program { name: "button_mouseout_clicked";
6851             signal: "mouse,up,1";
6852             source: "over3";
6853             script {
6854                new st[31];
6855                new Float:vl;
6856                get_state(PART:"elm.swallow.content", st, 30, vl);
6857                if (strcmp(st, "icononly"))
6858                  {
6859                     emit("elm,action,default,text,set", "");
6860                     set_state(PART:"elm.text", "visible", 0.0);
6861                  }
6862                if (get_int(button_state) != BUTTON_STATE_DISABLED)
6863                  set_state(PART:"button_image", "default", 0.0);
6864             }
6865             after: button_unpress;
6866          }
6867          program { name: "touch_snd";
6868             signal: "mouse,clicked,1";
6869             source: "over2";
6870             action: PLAY_SAMPLE "touch_sound" 1.0;
6871             after: button_unclick3;
6872          }
6873          program { name: "button_unclick3";
6874             action: SIGNAL_EMIT "elm,action,click" "";
6875          }
6876          program { name: "text_show";
6877             signal: "elm,state,text,visible";
6878             source: "elm";
6879             script {
6880                new st[31];
6881                new Float:vl;
6882                get_state(PART:"elm.swallow.content", st, 30, vl);
6883                if (!strcmp(st, "icononly"))
6884                  {
6885                     set_state(PART:"elm.swallow.content", "visible", 0.0);
6886                     set_state(PART:"padding_icon_text", "visible", 0.0);
6887                  }
6888                if (get_int(button_state) != BUTTON_STATE_DISABLED)
6889                  set_state(PART:"elm.text", "visible", 0.0);
6890                else
6891                  set_state(PART:"elm.text", "disabled_visible", 0.0);
6892             }
6893          }
6894          program { name: "text_hide";
6895             signal: "elm,state,text,hidden";
6896             source: "elm";
6897             script {
6898                new st[31];
6899                new Float:vl;
6900                get_state(PART:"elm.swallow.content", st, 30, vl);
6901                if (!strcmp(st, "visible"))
6902                  {
6903                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
6904                     set_state(PART:"padding_icon_text", "icononly", 0.0);
6905                  }
6906                set_state(PART:"elm.text", "default", 0.0);
6907             }
6908          }
6909          program { name: "icon_show";
6910             signal: "elm,state,icon,visible";
6911             source: "elm";
6912             script {
6913                new st[31];
6914                new Float:vl;
6915                get_state(PART:"elm.text", st, 30, vl);
6916                if (!strcmp(st, "visible"))
6917                  {
6918                     set_state(PART:"elm.swallow.content", "visible", 0.0);
6919                     set_state(PART:"padding_icon_text", "visible", 0.0);
6920                  }
6921                else
6922                  {
6923                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
6924                     set_state(PART:"padding_icon_text", "icononly", 0.0);
6925                  }
6926             }
6927          }
6928          program { name: "icon_hide";
6929             signal: "elm,state,icon,hidden";
6930             source: "elm";
6931             action: STATE_SET "default" 0.0;
6932             target: "elm.swallow.content";
6933             target: "padding_icon_text";
6934          }
6935          program { name: "disable";
6936             signal: "elm,state,disabled";
6937             source: "elm";
6938             action: STATE_SET "disabled" 0.0;
6939             target: "button_image";
6940             target: "disabler";
6941             after: "disable_text";
6942          }
6943          program { name: "disable_text";
6944             script {
6945                new st[31];
6946                new Float:vl;
6947                get_state(PART:"elm.text", st, 30, vl);
6948                if (!strcmp(st, "visible"))
6949                  set_state(PART:"elm.text", "disabled_visible", 0.0);
6950                else
6951                  set_state(PART:"elm.text", "disabled", 0.0);
6952                set_int(button_state, BUTTON_STATE_DISABLED);
6953             }
6954          }
6955          program { name: "enable";
6956             signal: "elm,state,enabled";
6957             source: "elm";
6958             action: STATE_SET "default" 0.0;
6959             target: "button_image";
6960             target: "disabler";
6961             after: "enable_text";
6962          }
6963          program { name: "enable_text";
6964             script {
6965                new st[31];
6966                new Float:vl;
6967                get_state(PART:"elm.text", st, 30, vl);
6968                if (!strcmp(st, "disabled_visible"))
6969                  set_state(PART:"elm.text", "visible", 0.0);
6970                else
6971                  set_state(PART:"elm.text", "default", 0.0);
6972                set_int(button_state, BUTTON_STATE_ENABLED);
6973             }
6974          }
6975          program { name: "focused";
6976             //signal: "elm,action,focus";
6977             //source: "elm";
6978             action: STATE_SET "focused" 0.0;
6979             target: "button_image";
6980             target: "elm.text";
6981          }
6982          program { name: "unfocused";
6983             //signal: "elm,action,unfocus";
6984             //source: "elm";
6985             action: STATE_SET "default" 0.0;
6986             target: "button_image";
6987             after: "unfocus_text";
6988          }
6989          program { name: "unfocus_text";
6990             action: STATE_SET "visible" 0.0;
6991             target: "elm.text";
6992          }
6993       }
6994    }
6995
6996 ///////////////////////////////////////////////////////////////////////////////////////
6997    group { name: "elm/button/base/picker/bar/default";
6998       images {
6999          image: "00_picker_btn_normal.png" COMP;
7000          image: "00_picker_btn_press.png" COMP;
7001          image: "00_picker_btn_normal_focus.png" COMP;
7002       }
7003       script {
7004          public button_state = BUTTON_STATE_ENABLED;
7005       }
7006       parts {
7007          part { name: "button_image";
7008             scale: 1;
7009             description { state: "default" 0.0;
7010                min: BUTTON_PICKER_BAR_DEFAULT_BG_DEFAULT_MIN_INC;
7011                image {
7012                   normal: "00_picker_btn_normal.png";
7013                   border: BUTTON_PICKER_BAR_DEFAULT_BG_DEFAULT_IMAGE_BORDER_INC;
7014                   border_scale: 1;
7015                }
7016             }
7017             description { state: "clicked" 0.0;
7018                inherit: "default" 0.0;
7019                image.normal: "00_picker_btn_press.png";
7020             }
7021             description { state: "disabled" 0.0;
7022                inherit: "default" 0.0;
7023             }
7024             description { state: "focused" 0.0;
7025                inherit: "default" 0.0;
7026                image.normal: "00_picker_btn_normal_focus.png";
7027             }
7028          }
7029          part { name: "padding_left_top";
7030             type: RECT;
7031             scale: 1;
7032             mouse_events: 0;
7033             description { state: "default" 0.0;
7034                align: 0.0 0.0;
7035                rel2.relative: 0.0 0.0;
7036                min: BUTTON_PICKER_BAR_DEFAULT_PADDING_MIN_INC;
7037                fixed: 1 1;
7038                visible: 0;
7039             }
7040          }
7041          part { name: "padding_right_bottom";
7042             type: RECT;
7043             scale: 1;
7044             mouse_events: 0;
7045             description { state: "default" 0.0;
7046                align: 1.0 1.0;
7047                rel1.relative: 1.0 1.0;
7048                min: BUTTON_PICKER_BAR_DEFAULT_PADDING_MIN_INC;
7049                fixed: 1 1;
7050                visible: 0;
7051             }
7052          }
7053          part { name: "icon_rect";
7054             type: RECT;
7055             scale: 1;
7056             mouse_events: 0;
7057             description { state: "default" 0.0;
7058                min: BUTTON_PICKER_BAR_DEFAULT_ICON_RECT_DEFAULT_MIN_INC;
7059                fixed: 1 0;
7060                rel1 {
7061                   relative: 0.0 1.0;
7062                   to_x: "elm.swallow.content";
7063                   to_y: "padding_left_top";
7064                }
7065                rel2 {
7066                   relative: 1.0 0.0;
7067                   to_x: "elm.swallow.content";
7068                   to_y: "padding_right_bottom";
7069                }
7070                align: 0.0 0.5;
7071                color: 0 0 0 0;
7072             }
7073          }
7074          part { name: "padding_icon_text";
7075             type: RECT;
7076             scale: 1;
7077             mouse_events: 0;
7078             description { state: "default" 0.0; //when only icon or no icon is there
7079                align: 0.0 0.0;
7080                rel1 {
7081                   relative: 1.0 0.0;
7082                   to: "icon_rect";
7083                }
7084                rel2.to: "icon_rect";
7085                fixed: 1 0;
7086                min: 0 0;
7087                color: 0 0 0 0;
7088             }
7089             description { state: "icononly" 0.0;
7090                inherit: "default" 0.0;
7091             }
7092             description { state: "visible" 0.0; //when icon is visible
7093                align: 0.0 0.0;
7094                rel1 {
7095                   relative: 1.0 0.0;
7096                   to: "icon_rect";
7097                }
7098                rel2.to: "icon_rect";
7099                fixed: 1 0;
7100                min: BUTTON_PICKER_BAR_DEFAULT_PADDING_ICON_RECT_TEXT_MIN_INC;
7101                color: 0 0 0 0;
7102             }
7103          }
7104          part { name: "elm.swallow.content";
7105             type: SWALLOW;
7106             scale: 1;
7107             clip_to: "clipper";
7108             description { state: "default" 0.0;
7109                visible: 0;
7110                align: 0.0 0.5;
7111                rel1 {
7112                   relative: 1.0 1.0;
7113                   to: "padding_left_top";
7114                }
7115                rel2 {
7116                   relative: 1.0 0.0;
7117                   to_x: "padding_left_top";
7118                   to_y: "padding_right_bottom";
7119                }
7120                fixed: 1 0;
7121             }
7122             description { state: "visible" 0.0;
7123                fixed: 1 0;
7124                align: 0.0 0.5;
7125                rel1 {
7126                   relative: 1.0 1.0;
7127                   to: "padding_left_top";
7128                }
7129                rel2 {
7130                   relative: 1.0 0.0;
7131                   to_x: "padding_left_top";
7132                   to_y: "padding_right_bottom";
7133                }
7134                aspect: 1.0 1.0;
7135                aspect_preference: VERTICAL;
7136             }
7137             description { state: "icononly" 0.0;
7138                min: BUTTON_PICKER_BAR_DEFAULT_CONTENT_ICONONLY_MIN_INC;
7139                rel1 {
7140                   relative: 1.0 1.0;
7141                   to: "padding_left_top";
7142                }
7143                rel2 {
7144                   relative: 1.0 0.0;
7145                   to_x: "padding_left_top";
7146                   to_y: "padding_right_bottom";
7147                }
7148                aspect: 1.0 1.0;
7149                aspect_preference: VERTICAL;
7150             }
7151          }
7152          part { name: "elm.text";
7153             type: TEXT;
7154             mouse_events: 0;
7155             scale: 1;
7156             clip_to: "clipper";
7157             description { state: "default" 0.0;
7158                visible: 0;
7159                rel1 {
7160                   relative: 1.0 1.0;
7161                   to_x: "padding_icon_text";
7162                   to_y: "padding_left_top";
7163                }
7164                rel2 {
7165                   relative: 0.0 0.0;
7166                   to: "padding_right_bottom";
7167                }
7168                color: BUTTON_PICKER_TEXT_DEFAULT_COLOR_INC;
7169                text {
7170                   font: "SLP:style=Medium";
7171                   size: BUTTON_PICKER_BAR_DEFAULT_TEXT_FONT_SIZE_INC;
7172                   min: 1 0;
7173                   max: 0 0;
7174                   text_class: "slp_medium";
7175                }
7176             }
7177             description { state: "visible" 0.0;
7178                inherit: "default" 0.0;
7179                visible: 1;
7180                min: BUTTON_PICKER_BAR_DEFAULT_TEXT_VISIBLE_MIN_INC;
7181             }
7182             description { state: "clicked" 0.0;
7183                inherit: "default" 0.0;
7184                visible: 1;
7185                min: 0 0;
7186                color: BUTTON_PICKER_TEXT_CLICKED_COLOR_INC;
7187             }
7188             description { state: "disabled" 0.0;
7189                inherit: "default" 0.0;
7190                color: BUTTON_PICKER_TEXT_DISABLED_COLOR_INC;
7191             }
7192             description { state: "disabled_visible" 0.0;
7193                inherit: "default" 0.0;
7194                color: BUTTON_PICKER_TEXT_DISABLED_COLOR_INC;
7195                visible: 1;
7196                min: BUTTON_PICKER_BAR_DEFAULT_TEXT_VISIBLE_MIN_INC;
7197             }
7198             description { state: "focused" 0.0;
7199                inherit: "default" 0.0;
7200                visible: 1;
7201                min: 0 0;
7202                color: BUTTON_PICKER_TEXT_FOCUSED_COLOR_INC;
7203             }
7204          }
7205          part { name: "over2";
7206             type: RECT;
7207             repeat_events: 1;
7208             ignore_flags: ON_HOLD;
7209             description { state: "default" 0.0;
7210                color: 0 0 0 0;
7211             }
7212          }
7213          part { name: "over3";
7214             type: RECT;
7215             repeat_events: 1;
7216             description { state: "default" 0.0;
7217                color: 0 0 0 0;
7218             }
7219          }
7220          part { name: "clipper";
7221             type: RECT;
7222             description { state: "default" 0.0;
7223                color: 255 255 255 255;
7224             }
7225          }
7226          part { name: "disabler";
7227             type: RECT;
7228             description { state: "default" 0.0;
7229                color: 0 0 0 0;
7230                visible: 0;
7231             }
7232             description { state: "disabled" 0.0;
7233                inherit: "default" 0.0;
7234                visible: 1;
7235             }
7236          }
7237       }
7238       programs {
7239          program { name: "button_click";
7240             signal: "mouse,down,1";
7241             source: "over2";
7242             action: SIGNAL_EMIT "elm,action,press" "";
7243             after: "button_click_anim";
7244          }
7245          program { name: "button_click_anim";
7246             action: STATE_SET "clicked" 0.0;
7247             target: "button_image";
7248             after: "text_clicked";
7249          }
7250          program { name: "text_clicked";
7251             script {
7252                new st[31];
7253                new Float:vl;
7254                get_state(PART:"elm.text", st, 30, vl);
7255                if (!strcmp(st, "visible"))
7256                  set_state(PART:"elm.text", "clicked", 0.0);
7257             }
7258          }
7259          program { name: "button_unpress";
7260             action: SIGNAL_EMIT "elm,action,unpress" "";
7261          }
7262          program { name: "button_mouseout_clicked";
7263             signal: "mouse,up,1";
7264             source: "over3";
7265             script {
7266                new st[31];
7267                new Float:vl;
7268                get_state(PART:"elm.swallow.content", st, 30, vl);
7269                if (strcmp(st, "icononly"))
7270                  {
7271                     emit("elm,action,default,text,set", "");
7272                     set_state(PART:"elm.text", "visible", 0.0);
7273                  }
7274                if (get_int(button_state) != BUTTON_STATE_DISABLED)
7275                  set_state(PART:"button_image", "default", 0.0);
7276             }
7277             after: button_unpress;
7278          }
7279          program { name: "touch_snd";
7280             signal: "mouse,clicked,1";
7281             source: "over2";
7282             action: PLAY_SAMPLE "touch_sound" 1.0;
7283             after: button_unclick3;
7284          }
7285          program { name: "button_unclick3";
7286             action: SIGNAL_EMIT "elm,action,click" "";
7287          }
7288          program { name: "text_show";
7289             signal: "elm,state,text,visible";
7290             source: "elm";
7291             script {
7292                new st[31];
7293                new Float:vl;
7294                get_state(PART:"elm.swallow.content", st, 30, vl);
7295                if (!strcmp(st, "icononly"))
7296                  {
7297                     set_state(PART:"elm.swallow.content", "visible", 0.0);
7298                     set_state(PART:"padding_icon_text", "visible", 0.0);
7299                  }
7300                if (get_int(button_state) != BUTTON_STATE_DISABLED)
7301                  set_state(PART:"elm.text", "visible", 0.0);
7302                else
7303                  set_state(PART:"elm.text", "disabled_visible", 0.0);
7304             }
7305          }
7306          program { name: "text_hide";
7307             signal: "elm,state,text,hidden";
7308             source: "elm";
7309             script {
7310                new st[31];
7311                new Float:vl;
7312                get_state(PART:"elm.swallow.content", st, 30, vl);
7313                if (!strcmp(st, "visible"))
7314                  {
7315                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
7316                     set_state(PART:"padding_icon_text", "icononly", 0.0);
7317                  }
7318                set_state(PART:"elm.text", "default", 0.0);
7319             }
7320          }
7321          program { name: "icon_show";
7322             signal: "elm,state,icon,visible";
7323             source: "elm";
7324             script {
7325                new st[31];
7326                new Float:vl;
7327                get_state(PART:"elm.text", st, 30, vl);
7328                if (!strcmp(st, "visible"))
7329                  {
7330                     set_state(PART:"elm.swallow.content", "visible", 0.0);
7331                     set_state(PART:"padding_icon_text", "visible", 0.0);
7332                  }
7333                else
7334                  {
7335                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
7336                     set_state(PART:"padding_icon_text", "icononly", 0.0);
7337                  }
7338             }
7339          }
7340          program { name: "icon_hide";
7341             signal: "elm,state,icon,hidden";
7342             source: "elm";
7343             action: STATE_SET "default" 0.0;
7344             target: "elm.swallow.content";
7345             target: "padding_icon_text";
7346          }
7347          program { name: "disable";
7348             signal: "elm,state,disabled";
7349             source: "elm";
7350             action: STATE_SET "disabled" 0.0;
7351             target: "button_image";
7352             target: "disabler";
7353             after: "disable_text";
7354          }
7355          program { name: "disable_text";
7356             script {
7357                new st[31];
7358                new Float:vl;
7359                get_state(PART:"elm.text", st, 30, vl);
7360                if (!strcmp(st, "visible"))
7361                  set_state(PART:"elm.text", "disabled_visible", 0.0);
7362                else
7363                  set_state(PART:"elm.text", "disabled", 0.0);
7364                set_int(button_state, BUTTON_STATE_DISABLED);
7365             }
7366          }
7367          program { name: "enable";
7368             signal: "elm,state,enabled";
7369             source: "elm";
7370             action: STATE_SET "default" 0.0;
7371             target: "button_image";
7372             target: "disabler";
7373             after: "enable_text";
7374          }
7375          program { name: "enable_text";
7376             script {
7377                new st[31];
7378                new Float:vl;
7379                get_state(PART:"elm.text", st, 30, vl);
7380                if (!strcmp(st, "disabled_visible"))
7381                  set_state(PART:"elm.text", "visible", 0.0);
7382                else
7383                  set_state(PART:"elm.text", "default", 0.0);
7384                set_int(button_state, BUTTON_STATE_ENABLED);
7385             }
7386          }
7387          program { name: "focused";
7388             //signal: "elm,action,focus";
7389             //source: "elm";
7390             action: STATE_SET "focused" 0.0;
7391             target: "button_image";
7392             target: "elm.text";
7393          }
7394          program { name: "unfocused";
7395             //signal: "elm,action,unfocus";
7396             //source: "elm";
7397             action: STATE_SET "default" 0.0;
7398             target: "button_image";
7399             after: "unfocus_text";
7400          }
7401          program { name: "unfocus_text";
7402             action: STATE_SET "visible" 0.0;
7403             target: "elm.text";
7404          }
7405       }
7406    }
7407
7408 ///////////////////////////////////////////////////////////////////////////////////////
7409    group { name: "elm/button/base/picker/prev/text/default";
7410       alias: "elm/button/base/picker/next/text/default";
7411       images {
7412          image: "00_picker_btn_normal.png" COMP;
7413          image: "00_picker_btn_press.png" COMP;
7414          image: "00_picker_btn_normal_focus.png" COMP;
7415       }
7416       script {
7417          public button_state = BUTTON_STATE_ENABLED;
7418       }
7419       parts {
7420          part { name: "button_image";
7421             scale: 1;
7422             description { state: "default" 0.0;
7423                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_BG_DEFAULT_MIN_INC;
7424                image {
7425                   normal: "00_picker_btn_normal.png";
7426                   border: BUTTON_PICKER_PREV_TEXT_DEFAULT_BG_DEFAULT_BORDER_INC;
7427                   border_scale: 1;
7428                }
7429             }
7430             description { state: "clicked" 0.0;
7431                inherit: "default" 0.0;
7432                image.normal: "00_picker_btn_press.png";
7433             }
7434             description { state: "disabled" 0.0;
7435                inherit: "default" 0.0;
7436                color: 0 0 0 128;
7437             }
7438             description { state: "focused" 0.0;
7439                inherit: "default" 0.0;
7440                image.normal: "00_picker_btn_normal_focus.png";
7441             }
7442          }
7443          part { name: "padding_left_top";
7444             type: RECT;
7445             scale: 1;
7446             mouse_events: 0;
7447             description { state: "default" 0.0;
7448                align: 0.0 0.0;
7449                rel2.relative: 0.0 0.0;
7450                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_PADDING_MIN_INC;
7451                fixed: 1 1;
7452                visible: 0;
7453             }
7454          }
7455          part { name: "padding_right_bottom";
7456             type: RECT;
7457             scale: 1;
7458             mouse_events: 0;
7459             description { state: "default" 0.0;
7460                align: 1.0 1.0;
7461                rel1.relative: 1.0 1.0;
7462                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_PADDING_MIN_INC;
7463                fixed: 1 1;
7464                visible: 0;
7465             }
7466          }
7467          part { name: "icon_rect";
7468             type: RECT;
7469             scale: 1;
7470             mouse_events: 0;
7471             description { state: "default" 0.0;
7472                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_ICON_RECT_MIN_INC;
7473                fixed: 1 0;
7474                rel1 {
7475                   relative: 0.0 1.0;
7476                   to_x: "elm.swallow.content";
7477                   to_y: "padding_left_top";
7478                }
7479                rel2 {
7480                   relative: 1.0 0.0;
7481                   to_x: "elm.swallow.content";
7482                   to_y: "padding_right_bottom";
7483                }
7484                align: 0.0 0.5;
7485                color: 0 0 0 0;
7486             }
7487          }
7488          part { name: "padding_icon_text";
7489             type: RECT;
7490             scale: 1;
7491             mouse_events: 0;
7492             description { state: "default" 0.0; //when only icon or no icon is there
7493                align: 0.0 0.0;
7494                rel1 {
7495                   relative: 1.0 0.0;
7496                   to: "icon_rect";
7497                }
7498                rel2.to: "icon_rect";
7499                fixed: 1 0;
7500                min: 0 0;
7501                color: 0 0 0 0;
7502             }
7503             description { state: "icononly" 0.0;
7504                inherit: "default" 0.0;
7505             }
7506             description { state: "visible" 0.0; //when icon is visible
7507                align: 0.0 0.0;
7508                rel1 {
7509                   relative: 1.0 0.0;
7510                   to: "icon_rect";
7511                }
7512                rel2.to: "icon_rect";
7513                fixed: 1 0;
7514                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_PADDING_ICON_RECT_TEXT_MIN_INC;
7515                color: 0 0 0 0;
7516             }
7517          }
7518          part { name: "elm.swallow.content";
7519             type: SWALLOW;
7520             scale: 1;
7521             clip_to: "clipper";
7522             description { state: "default" 0.0;
7523                visible: 0;
7524                align: 0.0 0.5;
7525                rel1 {
7526                   relative: 1.0 1.0;
7527                   to: "padding_left_top";
7528                }
7529                rel2 {
7530                   relative: 1.0 0.0;
7531                   to_x: "padding_left_top";
7532                   to_y: "padding_right_bottom";
7533                }
7534                fixed: 1 0;
7535             }
7536             description { state: "visible" 0.0;
7537                fixed: 1 0;
7538                align: 0.0 0.5;
7539                rel1 {
7540                   relative: 1.0 1.0;
7541                   to: "padding_left_top";
7542                }
7543                rel2 {
7544                   relative: 1.0 0.0;
7545                   to_x: "padding_left_top";
7546                   to_y: "padding_right_bottom";
7547                }
7548                aspect: 1.0 1.0;
7549                aspect_preference: VERTICAL;
7550             }
7551             description { state: "icononly" 0.0;
7552                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_CONTENT_ICON_ONLY_MIN_INC;
7553                rel1 {
7554                   relative: 1.0 1.0;
7555                   to: "padding_left_top";
7556                }
7557                rel2 {
7558                   relative: 1.0 0.0;
7559                   to_x: "padding_left_top";
7560                   to_y: "padding_right_bottom";
7561                }
7562                aspect: 1.0 1.0;
7563                aspect_preference: VERTICAL;
7564             }
7565          }
7566          part { name: "elm.text";
7567             type: TEXT;
7568             mouse_events: 0;
7569             scale: 1;
7570             clip_to: "clipper";
7571             description { state: "default" 0.0;
7572                visible: 0;
7573                rel1 {
7574                   relative: 1.0 1.0;
7575                   to_x: "padding_icon_text";
7576                   to_y: "padding_left_top";
7577                }
7578                rel2 {
7579                   relative: 0.0 0.0;
7580                   to: "padding_right_bottom";
7581                }
7582                color: BUTTON_PICKER_TEXT_DEFAULT_COLOR_INC;
7583                text {
7584                   font: "SLP:style=Medium";
7585                   size: BUTTON_PICKER_PREV_TEXT_DEFAULT_TEXT_FONT_SIZE_INC;
7586                   min: 1 0;
7587                   max: 1 0;
7588                   text_class: "slp_medium";
7589                }
7590             }
7591             description { state: "visible" 0.0;
7592                inherit: "default" 0.0;
7593                visible: 1;
7594                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_TEXT_VISIBLE_MIN_INC;
7595             }
7596             description { state: "clicked" 0.0;
7597                inherit: "default" 0.0;
7598                visible: 1;
7599                min: 0 0;
7600                color: BUTTON_PICKER_TEXT_CLICKED_COLOR_INC;
7601             }
7602             description { state: "disabled" 0.0;
7603                inherit: "default" 0.0;
7604                color: BUTTON_PICKER_TEXT_DISABLED_COLOR_INC;
7605             }
7606             description { state: "disabled_visible" 0.0;
7607                inherit: "default" 0.0;
7608                color: BUTTON_PICKER_TEXT_DISABLED_COLOR_INC;
7609                visible: 1;
7610                min: BUTTON_PICKER_PREV_TEXT_DEFAULT_TEXT_VISIBLE_MIN_INC;
7611             }
7612             description { state: "focused" 0.0;
7613                inherit: "default" 0.0;
7614                visible: 1;
7615                min: 0 0;
7616                color: BUTTON_PICKER_TEXT_FOCUSED_COLOR_INC;
7617             }
7618          }
7619          part { name: "over2";
7620             type: RECT;
7621             repeat_events: 1;
7622             ignore_flags: ON_HOLD;
7623             description { state: "default" 0.0;
7624                color: 0 0 0 0;
7625             }
7626          }
7627          part { name: "over3";
7628             type: RECT;
7629             repeat_events: 1;
7630             description { state: "default" 0.0;
7631                color: 0 0 0 0;
7632             }
7633          }
7634          part { name: "clipper";
7635             type: RECT;
7636             description { state: "default" 0.0;
7637                color: 255 255 255 255;
7638             }
7639          }
7640          part { name: "disabler";
7641             type: RECT;
7642             description { state: "default" 0.0;
7643                color: 0 0 0 0;
7644                visible: 0;
7645             }
7646             description { state: "disabled" 0.0;
7647                inherit: "default" 0.0;
7648                visible: 1;
7649             }
7650          }
7651       }
7652       programs {
7653          program { name: "button_click";
7654             signal: "mouse,down,1";
7655             source: "over2";
7656             action: SIGNAL_EMIT "elm,action,press" "";
7657             after: "button_click_anim";
7658          }
7659          program { name: "button_click_anim";
7660             action: STATE_SET "clicked" 0.0;
7661             target: "button_image";
7662             after: "text_clicked";
7663          }
7664          program { name: "text_clicked";
7665             script {
7666                new st[31];
7667                new Float:vl;
7668                get_state(PART:"elm.text", st, 30, vl);
7669                if (!strcmp(st, "visible"))
7670                  set_state(PART:"elm.text", "clicked", 0.0);
7671             }
7672          }
7673          program { name: "button_unpress";
7674             action: SIGNAL_EMIT "elm,action,unpress" "";
7675          }
7676          program { name: "button_mouseout_clicked";
7677             signal: "mouse,up,1";
7678             source: "over3";
7679             script {
7680                new st[31];
7681                new Float:vl;
7682                get_state(PART:"elm.swallow.content", st, 30, vl);
7683                if (strcmp(st, "icononly"))
7684                  {
7685                     emit("elm,action,default,text,set", "");
7686                     set_state(PART:"elm.text", "visible", 0.0);
7687                  }
7688                if (get_int(button_state) != BUTTON_STATE_DISABLED)
7689                  set_state(PART:"button_image", "default", 0.0);
7690             }
7691             after: button_unpress;
7692          }
7693          program { name: "touch_snd";
7694             signal: "mouse,clicked,1";
7695             source: "over2";
7696             action: PLAY_SAMPLE "touch_sound" 1.0;
7697             after: button_unclick3;
7698          }
7699          program { name: "button_unclick3";
7700             action: SIGNAL_EMIT "elm,action,click" "";
7701          }
7702          program { name: "text_show";
7703             signal: "elm,state,text,visible";
7704             source: "elm";
7705             script {
7706                new st[31];
7707                new Float:vl;
7708                get_state(PART:"elm.swallow.content", st, 30, vl);
7709                if (!strcmp(st, "icononly"))
7710                  {
7711                     set_state(PART:"elm.swallow.content", "visible", 0.0);
7712                     set_state(PART:"padding_icon_text", "visible", 0.0);
7713                  }
7714                if (get_int(button_state) != BUTTON_STATE_DISABLED)
7715                  set_state(PART:"elm.text", "visible", 0.0);
7716                else
7717                  set_state(PART:"elm.text", "disabled_visible", 0.0);
7718             }
7719          }
7720          program { name: "text_hide";
7721             signal: "elm,state,text,hidden";
7722             source: "elm";
7723             script {
7724                new st[31];
7725                new Float:vl;
7726                get_state(PART:"elm.swallow.content", st, 30, vl);
7727                if (!strcmp(st, "visible"))
7728                  {
7729                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
7730                     set_state(PART:"padding_icon_text", "icononly", 0.0);
7731                  }
7732                set_state(PART:"elm.text", "default", 0.0);
7733             }
7734          }
7735          program { name: "icon_show";
7736             signal: "elm,state,icon,visible";
7737             source: "elm";
7738             script {
7739                new st[31];
7740                new Float:vl;
7741                get_state(PART:"elm.text", st, 30, vl);
7742                if (!strcmp(st, "visible"))
7743                  {
7744                     set_state(PART:"elm.swallow.content", "visible", 0.0);
7745                     set_state(PART:"padding_icon_text", "visible", 0.0);
7746                  }
7747                else
7748                  {
7749                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
7750                     set_state(PART:"padding_icon_text", "icononly", 0.0);
7751                  }
7752             }
7753          }
7754          program { name: "icon_hide";
7755             signal: "elm,state,icon,hidden";
7756             source: "elm";
7757             action: STATE_SET "default" 0.0;
7758             target: "elm.swallow.content";
7759             target: "padding_icon_text";
7760          }
7761          program { name: "disable";
7762             signal: "elm,state,disabled";
7763             source: "elm";
7764             action: STATE_SET "disabled" 0.0;
7765             target: "button_image";
7766             target: "disabler";
7767             after: "disable_text";
7768          }
7769          program { name: "disable_text";
7770             script {
7771                new st[31];
7772                new Float:vl;
7773                get_state(PART:"elm.text", st, 30, vl);
7774                if (!strcmp(st, "visible"))
7775                  set_state(PART:"elm.text", "disabled_visible", 0.0);
7776                else
7777                  set_state(PART:"elm.text", "disabled", 0.0);
7778                set_int(button_state, BUTTON_STATE_DISABLED);
7779             }
7780          }
7781          program { name: "enable";
7782             signal: "elm,state,enabled";
7783             source: "elm";
7784             action: STATE_SET "default" 0.0;
7785             target: "button_image";
7786             target: "disabler";
7787             after: "enable_text";
7788          }
7789          program { name: "enable_text";
7790             script {
7791                new st[31];
7792                new Float:vl;
7793                get_state(PART:"elm.text", st, 30, vl);
7794                if (!strcmp(st, "disabled_visible"))
7795                  set_state(PART:"elm.text", "visible", 0.0);
7796                else
7797                  set_state(PART:"elm.text", "default", 0.0);
7798                set_int(button_state, BUTTON_STATE_ENABLED);
7799             }
7800          }
7801          program { name: "focused";
7802             //signal: "elm,action,focus";
7803             //source: "elm";
7804             action: STATE_SET "focused" 0.0;
7805             target: "button_image";
7806             target: "elm.text";
7807          }
7808          program { name: "unfocused";
7809             //signal: "elm,action,unfocus";
7810             //source: "elm";
7811             action: STATE_SET "default" 0.0;
7812             target: "button_image";
7813             after: "unfocus_text";
7814          }
7815          program { name: "unfocus_text";
7816             action: STATE_SET "visible" 0.0;
7817             target: "elm.text";
7818          }
7819       }
7820    }
7821
7822 ///////////////////////////////////////////////////////////////////////////////////////
7823 #define BUTTON_CONTACT_STYLES(style_name, image_normal, image_press) \
7824    group { name: "elm/button/base/contact/"style_name; \
7825       images { \
7826          image: "00_contacts_circle_bg.png" COMP; \
7827          image: image_normal COMP; \
7828          image: image_press COMP; \
7829       } \
7830       parts { \
7831          part { name: "button_image"; \
7832             scale: 1; \
7833             description { state: "default" 0.0; \
7834                min: BUTTON_CONTACT_STYLE_BG_MIN_MAX_INC; \
7835                max: BUTTON_CONTACT_STYLE_BG_MIN_MAX_INC; \
7836                image.normal: "00_contacts_circle_bg.png"; \
7837                color: 255 255 255 255; \
7838             } \
7839             description { \
7840                state: "clicked" 0.0; \
7841                inherit: "default" 0.0; \
7842                image.normal: "00_contacts_circle_bg.png"; \
7843             } \
7844             description { \
7845                state: "disabled" 0.0; \
7846                inherit: "default" 0.0; \
7847                color: 255 255 255 128; \
7848             } \
7849          } \
7850          part { name: "button_center_part"; \
7851             scale: 1; \
7852             description { state: "default" 0.0; \
7853                min: BUTTON_CONTACT_STYLE_IMAGE_MIN_MAX_INC; \
7854                max: BUTTON_CONTACT_STYLE_IMAGE_MIN_MAX_INC; \
7855                image.normal: image_normal; \
7856                color: 255 255 255 255; \
7857             } \
7858             description { \
7859                state: "clicked" 0.0; \
7860                inherit: "default" 0.0; \
7861                image.normal: image_press; \
7862             } \
7863             description { \
7864                state: "disabled" 0.0; \
7865                inherit: "default" 0.0; \
7866                color: 255 255 255 128; \
7867             } \
7868          } \
7869          part { name: "over1"; \
7870             type: RECT; \
7871             ignore_flags: ON_HOLD; \
7872             description { state: "default" 0.0; \
7873                color: 0 0 0 0; \
7874             } \
7875          } \
7876          part { name: "over2"; \
7877             repeat_events: 1; \
7878             description { state: "default" 0.0; \
7879                color: 0 0 0 0; \
7880             } \
7881          } \
7882          part { name: "disabler"; \
7883             type: RECT; \
7884             description { state: "default" 0.0; \
7885                color: 0 0 0 0; \
7886                visible: 0; \
7887             } \
7888             description { state: "disabled" 0.0; \
7889                inherit: "default" 0.0; \
7890                visible: 1; \
7891             } \
7892          } \
7893       } \
7894       programs { \
7895          program { name: "button_click"; \
7896             signal: "mouse,down,1"; \
7897             source: "over1"; \
7898             action: SIGNAL_EMIT "elm,action,press" ""; \
7899             after: "button_click_anim"; \
7900          } \
7901          program { name: "button_click_anim"; \
7902             action: STATE_SET "clicked" 0.0; \
7903             target: "button_image"; \
7904             target: "button_center_part"; \
7905          } \
7906          program { name: "button_unclick"; \
7907             signal: "mouse,up,1"; \
7908             source: "over2"; \
7909             action: SIGNAL_EMIT "elm,action,unpress" ""; \
7910             after: "button_unclick_anim"; \
7911          } \
7912          program { name: "button_unclick_anim"; \
7913             action: STATE_SET "default" 0.0; \
7914             target: "button_image"; \
7915             target: "button_center_part"; \
7916          } \
7917          program { name: "touch_snd"; \
7918             signal: "mouse,clicked,1"; \
7919             source: "over1"; \
7920             action: PLAY_SAMPLE "touch_sound" 1.0; \
7921             after: button_unclick3; \
7922          } \
7923          program { name: "button_unclick3"; \
7924             action: SIGNAL_EMIT "elm,action,click" ""; \
7925          } \
7926          program { name: "disable"; \
7927             signal: "elm,state,disabled"; \
7928             source: "elm"; \
7929             action: STATE_SET "disabled" 0.0; \
7930             target: "disabler"; \
7931             target: "button_image"; \
7932             target: "button_center_part"; \
7933          } \
7934          program { name: "enable"; \
7935             signal: "elm,state,enabled"; \
7936             source: "elm"; \
7937             action: STATE_SET "default" 0.0; \
7938             target: "disabler"; \
7939             target: "button_image"; \
7940             target: "button_center_part"; \
7941          } \
7942       } \
7943    }
7944
7945 ///////////////////////////////////////////////////////////////////////////////////////
7946    BUTTON_CONTACT_STYLES("expand_closed", "00_button_expand_closed.png", "00_button_expand_closed_press.png")
7947
7948    BUTTON_CONTACT_STYLES("expand_opened", "00_button_expand_opened.png", "00_button_expand_opened_press.png")
7949
7950    BUTTON_CONTACT_STYLES("plus", "00_button_plus.png", "00_button_plus_press.png")
7951
7952 ///////////////////////////////////////////////////////////////////////////////////////
7953    group { name: "elm/button/base/contact";
7954       alias: "elm/button/base/text_only/contact";
7955       images {
7956          image: "00_contacts_button_bg.png" COMP;
7957          image: "00_contacts_button_bg_press.png" COMP;
7958       }
7959       script {
7960          public button_state = BUTTON_STATE_ENABLED;
7961       }
7962       parts {
7963          part { name: "button_image";
7964             scale: 1;
7965             description { state: "default" 0.0;
7966                rel1 {
7967                   to_x: "padding.left";
7968                   to_y: "elm.text";
7969                }
7970                rel2 {
7971                   to_x: "padding.right";
7972                   to_y: "elm.text";
7973                }
7974                min: BUTTON_CONTACT_BG_MIN_INC;
7975                image {
7976                   normal: "00_contacts_button_bg.png";
7977                   border: BUTTON_CONTACT_BG_BORDER_INC;
7978                   border_scale: 1;
7979                }
7980             }
7981             description { state: "clicked" 0.0;
7982                inherit: "default" 0.0;
7983                image.normal: "00_contacts_button_bg_press.png";
7984             }
7985             description { state: "disabled" 0.0;
7986                inherit: "default" 0.0;
7987                color: 0 0 0 128;
7988             }
7989             description { state: "focused" 0.0;
7990                inherit: "default" 0.0;
7991             }
7992          }
7993          part { name: "padding.left";
7994             type: RECT;
7995             scale: 1;
7996             description { state: "default" 0.0;
7997                visible: 0;
7998                min: BUTTON_CONTACT_PADDING_MIN_INC;
7999                fixed: 1 0;
8000                color: 0 0 0 0;
8001                rel2 {
8002                   relative: 0.0 1.0;
8003                   to_x: "elm.text";
8004                }
8005                align: 1.0 0.0;
8006             }
8007          }
8008          part { name: "padding.right";
8009             type: RECT;
8010             scale: 1;
8011             description { state: "default" 0.0;
8012                visible: 0;
8013                min: BUTTON_CONTACT_PADDING_MIN_INC;
8014                fixed: 1 0;
8015                color: 0 0 0 0;
8016                rel1 {
8017                   relative: 1.0 0.0;
8018                   to_x: "elm.text";
8019                }
8020                align: 0.0 0.0;
8021             }
8022          }
8023          part {   name: "elm.text";
8024             type: TEXT;
8025             mouse_events: 0;
8026             scale: 1;
8027             description { state: "default" 0.0;
8028                visible: 0;
8029                fixed: 1 1;
8030                color: BUTTON_CONTACT_BUTTON_TEXT_NORMAL_COLOR_INC;
8031                text {
8032                   font: "SLP:style=Medium";
8033                   size: BUTTON_CONTACT_FONT_SIZE_INC;
8034                   min: 1 1;
8035                   text_class: "slp_medium";
8036                }
8037             }
8038             description { state: "visible" 0.0;
8039                inherit: "default" 0.0;
8040                visible: 1;
8041                min: 1 1;
8042             }
8043             description { state: "clicked" 0.0;
8044                inherit: "default" 0.0;
8045                visible: 1;
8046                min: 1 1;
8047                color: BUTTON_CONTACT_BUTTON_TEXT_PRESSED_COLOR_INC;
8048             }
8049             description { state: "disabled" 0.0;
8050                inherit: "default" 0.0;
8051                color: 0 0 0 128;
8052             }
8053             description { state: "disabled_visible" 0.0;
8054                inherit: "default" 0.0;
8055                color: BUTTON_CONTACT_BUTTON_TEXT_DISABLED_COLOR_INC;
8056                visible: 1;
8057                min: 1 1;
8058             }
8059             description { state: "focused" 0.0;
8060                inherit: "default" 0.0;
8061                visible: 1;
8062                min: 1 1;
8063                color: BUTTON_CONTACT_BUTTON_TEXT_FOCUSED_COLOR_INC;
8064             }
8065          }
8066          part { name: "over1";
8067             mouse_events: 0;
8068             description { state: "default" 0.0;
8069                rel2.relative: 1.0 0.5;
8070             }
8071          }
8072          part { name: "over2";
8073             repeat_events: 1;
8074             ignore_flags: ON_HOLD;
8075             description { state: "default" 0.0;
8076                rel1.to: "button_image";
8077                rel2.to: "button_image";
8078             }
8079          }
8080          part { name: "over3";
8081             repeat_events: 1;
8082             description { state: "default" 0.0;
8083                rel1.to: "button_image";
8084                rel2.to: "button_image";
8085                color: 0 0 0 0;
8086             }
8087          }
8088          part { name: "disabler";
8089             type: RECT;
8090             description { state: "default" 0.0;
8091                rel1.to: "button_image";
8092                rel2.to: "button_image";
8093                color: 0 0 0 0;
8094                visible: 0;
8095             }
8096             description { state: "disabled" 0.0;
8097                inherit: "default" 0.0;
8098                visible: 1;
8099             }
8100          }
8101       }
8102       programs {
8103          program { name: "button_click";
8104             signal: "mouse,down,1";
8105             source: "over2";
8106             action: SIGNAL_EMIT "elm,action,press" "";
8107             after: "button_click_anim";
8108          }
8109          program { name: "button_click_anim";
8110             action: STATE_SET "clicked" 0.0;
8111             target: "button_image";
8112             target: "elm.text";
8113          }
8114          program { name: "button_unpress";
8115             action: SIGNAL_EMIT "elm,action,unpress" "";
8116          }
8117          program { name: "button_mouseout_clicked";
8118             signal: "mouse,up,1";
8119             source: "over3";
8120             script {
8121                new st[31];
8122                new Float:vl;
8123                get_state(PART:"elm.text", st, 30, vl);
8124                if (!strcmp(st, "clicked") || !strcmp(st, "focused"))
8125                  {
8126                     emit("elm,action,default,text,set", "");
8127                     set_state(PART:"elm.text", "visible", 0.0);
8128                  }
8129                if (get_int(button_state) != BUTTON_STATE_DISABLED)
8130                  set_state(PART:"button_image", "default", 0.0);
8131             }
8132             after: button_unpress;
8133          }
8134          program { name: "touch_snd";
8135             signal: "mouse,clicked,1";
8136             source: "over2";
8137             action: PLAY_SAMPLE "touch_sound" 1.0;
8138             after: button_unclick3;
8139          }
8140          program { name: "button_unclick3";
8141             action: SIGNAL_EMIT "elm,action,click" "";
8142          }
8143          program { name: "text_show";
8144             signal: "elm,state,text,visible";
8145             source: "elm";
8146             script {
8147                if (get_int(button_state) != BUTTON_STATE_DISABLED)
8148                  set_state(PART:"elm.text", "visible", 0.0);
8149                else
8150                  set_state(PART:"elm.text", "disabled_visible", 0.0);
8151             }
8152          }
8153          program { name: "text_hide";
8154             signal: "elm,state,text,hidden";
8155             source: "elm";
8156             action: STATE_SET "default" 0.0;
8157             target: "elm.text";
8158          }
8159          program { name: "disable";
8160             signal: "elm,state,disabled";
8161             source: "elm";
8162             action: STATE_SET "disabled" 0.0;
8163             target: "button_image";
8164             target: "disabler";
8165             after: "disable_text";
8166          }
8167          program { name: "disable_text";
8168             script {
8169                new st[31];
8170                new Float:vl;
8171                get_state(PART:"elm.text", st, 30, vl);
8172                if (!strcmp(st, "visible"))
8173                  set_state(PART:"elm.text", "disabled_visible", 0.0);
8174                else
8175                  set_state(PART:"elm.text", "disabled", 0.0);
8176                set_int(button_state, BUTTON_STATE_DISABLED);
8177             }
8178          }
8179          program { name: "enable";
8180             signal: "elm,state,enabled";
8181             source: "elm";
8182             action: STATE_SET "default" 0.0;
8183             target: "button_image";
8184             target: "disabler";
8185             after: "enable_text";
8186          }
8187          program { name: "enable_text";
8188             script {
8189                new st[31];
8190                new Float:vl;
8191                get_state(PART:"elm.text", st, 30, vl);
8192                if (!strcmp(st, "disabled_visible"))
8193                  set_state(PART:"elm.text", "visible", 0.0);
8194                else
8195                  set_state(PART:"elm.text", "default", 0.0);
8196                set_int(button_state, BUTTON_STATE_ENABLED);
8197             }
8198          }
8199          program { name: "focused";
8200             //signal: "elm,action,focus";
8201             //source: "elm";
8202             action: STATE_SET "focused" 0.0;
8203             target: "button_image";
8204             target: "elm.text";
8205          }
8206          program { name: "unfocused";
8207             //signal: "elm,action,unfocus";
8208             //source: "elm";
8209             action: STATE_SET "default" 0.0;
8210             target: "button_image";
8211             action: STATE_SET "visible" 0.0;
8212             target: "elm.text";
8213          }
8214       }
8215    }
8216
8217 ///////////////////////////////////////////////////////////////////////////////////////
8218    group { name: "elm/button/base/naviframe/back_btn/default";
8219       alias: "elm/button/base/naviframe/prev_btn/default";
8220       alias: "elm/button/base/naviframe/end_btn/default";
8221       images {
8222          image: "00_winset_Back_btn_normal.png" COMP;
8223          image: "00_winset_Back_btn_press.png" COMP;
8224          image: "00_winset_Back_btn_normal_focus.png" COMP;
8225          image: "00_winset_Back.png" COMP;
8226       }
8227       script {
8228          public button_state = BUTTON_STATE_ENABLED;
8229       }
8230       parts {
8231          part { name: "button_image";
8232             scale: 1;
8233             description { state: "default" 0.0;
8234                min: BUTTON_NAVIFRAME_BACK_BUTTON_BG_MIN_MAX_INC;
8235                max: BUTTON_NAVIFRAME_BACK_BUTTON_BG_MIN_MAX_INC;
8236                image {
8237                   normal: "00_winset_Back_btn_normal.png";
8238                   border: BUTTON_NAVIFRAME_BACK_BUTTON_BG_BORDER_INC;
8239                   border_scale: 1;
8240                }
8241             }
8242             description { state: "clicked" 0.0;
8243                inherit: "default" 0.0;
8244                image.normal: "00_winset_Back_btn_press.png";
8245             }
8246             description { state: "disabled" 0.0;
8247                inherit: "default" 0.0;
8248             }
8249             description { state: "focused" 0.0;
8250                inherit: "default" 0.0;
8251                image.normal: "00_winset_Back_btn_normal_focus.png";
8252             }
8253          }
8254          part { name: "back_button";
8255             scale: 1;
8256             mouse_events: 0;
8257             description { state: "default" 0.0;
8258                min: BUTTON_NAVIFRAME_BACK_BUTTON_MIN_MAX_INC;
8259                max: BUTTON_NAVIFRAME_BACK_BUTTON_MIN_MAX_INC;
8260                rel1.to: "button_image";
8261                rel2.to: "button_image";
8262                image.normal: "00_winset_Back.png";
8263             }
8264             description { state: "clicked" 0.0;
8265                inherit: "default" 0.0;
8266             }
8267             description { state: "disabled" 0.0;
8268                inherit: "default" 0.0;
8269                color: 127 127 127 127;
8270             }
8271          }
8272          part { name: "over2";
8273             type: RECT;
8274             repeat_events: 1;
8275             ignore_flags: ON_HOLD;
8276             description { state: "default" 0.0;
8277                color: 0 0 0 0;
8278             }
8279          }
8280          part { name: "over3";
8281             type: RECT;
8282             repeat_events: 1;
8283             description { state: "default" 0.0;
8284                color: 0 0 0 0;
8285             }
8286          }
8287          part { name: "disabler";
8288             type: RECT;
8289             description { state: "default" 0.0;
8290                color: 0 0 0 0;
8291                visible: 0;
8292             }
8293             description { state: "disabled" 0.0;
8294                inherit: "default" 0.0;
8295                visible: 1;
8296             }
8297          }
8298       }
8299       programs {
8300          program { name: "button_click";
8301             signal: "mouse,down,1";
8302             source: "over2";
8303             action: SIGNAL_EMIT "elm,action,press" "";
8304             after: "button_click_anim";
8305          }
8306          program { name: "button_click_anim";
8307             action: STATE_SET "clicked" 0.0;
8308             target: "button_image";
8309          }
8310          program { name: "button_unpress";
8311             action: SIGNAL_EMIT "elm,action,unpress" "";
8312          }
8313          program { name: "button_mouseout_clicked";
8314             signal: "mouse,up,1";
8315             source: "over3";
8316             script {
8317                if (get_int(button_state) != BUTTON_STATE_DISABLED)
8318                  set_state(PART:"button_image", "default", 0.0);
8319             }
8320             after: button_unpress;
8321          }
8322          program { name: "touch_snd";
8323             signal: "mouse,clicked,1";
8324             source: "over2";
8325             action: PLAY_SAMPLE "touch_sound" 1.0;
8326             after: button_unclick3;
8327          }
8328          program { name: "button_unclick3";
8329             action: SIGNAL_EMIT "elm,action,click" "";
8330          }
8331          program { name: "disable";
8332             signal: "elm,state,disabled";
8333             source: "elm";
8334             action: STATE_SET "disabled" 0.0;
8335             target: "button_image";
8336             target: "disabler";
8337             target: "back_button";
8338             after: "disable_button";
8339          }
8340          program { name: "disable_button";
8341             script {
8342                set_int(button_state, BUTTON_STATE_DISABLED);
8343             }
8344          }
8345          program { name: "enable";
8346             signal: "elm,state,enabled";
8347             source: "elm";
8348             action: STATE_SET "default" 0.0;
8349             target: "button_image";
8350             target: "disabler";
8351             target: "back_button";
8352             after: "enable_button";
8353          }
8354          program { name: "enable_button";
8355             script {
8356                set_int(button_state, BUTTON_STATE_ENABLED);
8357             }
8358          }
8359          program { name: "focused";
8360             //signal: "elm,action,focus";
8361             //source: "elm";
8362             action: STATE_SET "focused" 0.0;
8363             target: "button_image";
8364          }
8365          program { name: "unfocused";
8366             //signal: "elm,action,unfocus";
8367             //source: "elm";
8368             action: STATE_SET "default" 0.0;
8369             target: "button_image";
8370          }
8371       }
8372    }
8373
8374 ///////////////////////////////////////////////////////////////////////////////////////
8375    group { name: "elm/button/base/picker/prev/icon/default";
8376       images {
8377          image: "00_picker_btn_normal.png" COMP;
8378          image: "00_picker_btn_press.png" COMP;
8379          image: "00_picker_btn_normal_focus.png" COMP;
8380          image: "00_picker_arrow_left.png" COMP;
8381          image: "00_picker_arrow_left_press.png" COMP;
8382       }
8383       script {
8384          public button_state = BUTTON_STATE_ENABLED;
8385       }
8386       parts {
8387          part { name: "button_image";
8388             scale: 1;
8389             description { state: "default" 0.0;
8390                min: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_MIN_MAX_INC;
8391                max: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_MIN_MAX_INC;
8392                image {
8393                   normal: "00_picker_btn_normal.png";
8394                   border: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_BORDER_INC;
8395                   border_scale: 1;
8396                }
8397             }
8398             description { state: "clicked" 0.0;
8399                inherit: "default" 0.0;
8400                image.normal: "00_picker_btn_press.png";
8401             }
8402             description { state: "disabled" 0.0;
8403                inherit: "default" 0.0;
8404             }
8405             description { state: "focused" 0.0;
8406                inherit: "default" 0.0;
8407                image.normal: "00_picker_btn_normal_focus.png";
8408             }
8409          }
8410          part { name: "padding_left_top";
8411             type: RECT;
8412             scale: 1;
8413             mouse_events: 0;
8414             description { state: "default" 0.0;
8415                align: 0.0 0.0;
8416                rel2.relative: 0.0 0.0;
8417                min: BUTTON_PICKER_PREV_ICON_DEFAULT_PADDING_MIN_INC;
8418                fixed: 1 1;
8419                visible: 0;
8420             }
8421          }
8422          part { name: "padding_right_bottom";
8423             type: RECT;
8424             scale: 1;
8425             mouse_events: 0;
8426             description { state: "default" 0.0;
8427                align: 1.0 1.0;
8428                rel1.relative: 1.0 1.0;
8429                min: BUTTON_PICKER_PREV_ICON_DEFAULT_PADDING_MIN_INC;
8430                fixed: 1 1;
8431                visible: 0;
8432             }
8433          }
8434          part { name: "left_arrow";
8435             scale: 1;
8436             mouse_events: 0;
8437             description { state: "default" 0.0;
8438                min: BUTTON_PICKER_PREV_ICON_DEFAULT_IMAGE_MIN_MAX_INC;
8439                max: BUTTON_PICKER_PREV_ICON_DEFAULT_IMAGE_MIN_MAX_INC;
8440                rel1 {
8441                   relative: 1.0 1.0;
8442                   to: "padding_left_top";
8443                }
8444                rel2 {
8445                   relative: 0.0 0.0;
8446                   to: "padding_right_bottom";
8447                }
8448                image.normal: "00_picker_arrow_left.png";
8449             }
8450             description { state: "clicked" 0.0;
8451                inherit: "default" 0.0;
8452                image.normal: "00_picker_arrow_left_press.png";
8453             }
8454          }
8455          part { name: "over2";
8456             type: RECT;
8457             repeat_events: 1;
8458             ignore_flags: ON_HOLD;
8459             description { state: "default" 0.0;
8460                color: 0 0 0 0;
8461             }
8462          }
8463          part { name: "over3";
8464             type: RECT;
8465             repeat_events: 1;
8466             description { state: "default" 0.0;
8467                color: 0 0 0 0;
8468             }
8469          }
8470          part { name: "disabler";
8471             type: RECT;
8472             description { state: "default" 0.0;
8473                color: 0 0 0 0;
8474                visible: 0;
8475             }
8476             description { state: "disabled" 0.0;
8477                inherit: "default" 0.0;
8478                visible: 1;
8479             }
8480          }
8481       }
8482       programs {
8483          program { name: "button_click";
8484             signal: "mouse,down,1";
8485             source: "over2";
8486             action: SIGNAL_EMIT "elm,action,press" "";
8487             after: "button_click_anim";
8488          }
8489          program { name: "button_click_anim";
8490             action: STATE_SET "clicked" 0.0;
8491             target: "button_image";
8492          }
8493          program { name: "button_unpress";
8494             action: SIGNAL_EMIT "elm,action,unpress" "";
8495          }
8496          program { name: "button_mouseout_clicked";
8497             signal: "mouse,up,1";
8498             source: "over3";
8499             script {
8500                if (get_int(button_state) != BUTTON_STATE_DISABLED)
8501                  set_state(PART:"button_image", "default", 0.0);
8502             }
8503             after: button_unpress;
8504          }
8505          program { name: "touch_snd";
8506             signal: "mouse,clicked,1";
8507             source: "over2";
8508             action: PLAY_SAMPLE "touch_sound" 1.0;
8509             after: button_unclick3;
8510          }
8511          program { name: "button_unclick3";
8512             action: SIGNAL_EMIT "elm,action,click" "";
8513          }
8514          program { name: "disable";
8515             signal: "elm,state,disabled";
8516             source: "elm";
8517             action: STATE_SET "disabled" 0.0;
8518             target: "button_image";
8519             target: "disabler";
8520             after: "disable_button";
8521          }
8522          program { name: "disable_button";
8523             script {
8524                set_int(button_state, BUTTON_STATE_DISABLED);
8525             }
8526          }
8527          program { name: "enable";
8528             signal: "elm,state,enabled";
8529             source: "elm";
8530             action: STATE_SET "default" 0.0;
8531             target: "button_image";
8532             target: "disabler";
8533             after: "enable_button";
8534          }
8535          program { name: "enable_button";
8536             script {
8537                set_int(button_state, BUTTON_STATE_ENABLED);
8538             }
8539          }
8540          program { name: "focused";
8541             //signal: "elm,action,focus";
8542             //source: "elm";
8543             action: STATE_SET "focused" 0.0;
8544             target: "button_image";
8545          }
8546          program { name: "unfocused";
8547             //signal: "elm,action,unfocus";
8548             //source: "elm";
8549             action: STATE_SET "default" 0.0;
8550             target: "button_image";
8551          }
8552       }
8553    }
8554
8555 ///////////////////////////////////////////////////////////////////////////////////////
8556    group { name: "elm/button/base/picker/next/icon/default";
8557       images {
8558          image: "00_picker_btn_normal.png" COMP;
8559          image: "00_picker_btn_press.png" COMP;
8560          image: "00_picker_btn_normal_focus.png" COMP;
8561          image: "00_picker_arrow_right.png" COMP;
8562          image: "00_picker_arrow_right_press.png" COMP;
8563       }
8564       script {
8565          public button_state = BUTTON_STATE_ENABLED;
8566       }
8567       parts {
8568          part { name: "button_image";
8569             scale: 1;
8570             description { state: "default" 0.0;
8571                min: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_MIN_MAX_INC;
8572                max: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_MIN_MAX_INC;
8573                image {
8574                   normal: "00_picker_btn_normal.png";
8575                   border: BUTTON_PICKER_PREV_ICON_DEFAULT_BG_DEFAULT_BORDER_INC;
8576                   border_scale: 1;
8577                }
8578             }
8579             description { state: "clicked" 0.0;
8580                inherit: "default" 0.0;
8581                image.normal: "00_picker_btn_press.png";
8582             }
8583             description { state: "disabled" 0.0;
8584                inherit: "default" 0.0;
8585             }
8586             description { state: "focused" 0.0;
8587                inherit: "default" 0.0;
8588                image.normal: "00_picker_btn_normal_focus.png";
8589             }
8590          }
8591          part { name: "padding_left_top";
8592             type: RECT;
8593             scale: 1;
8594             mouse_events: 0;
8595             description { state: "default" 0.0;
8596                align: 0.0 0.0;
8597                rel2.relative: 0.0 0.0;
8598                min: BUTTON_PICKER_PREV_ICON_DEFAULT_PADDING_MIN_INC;
8599                fixed: 1 1;
8600                visible: 0;
8601             }
8602          }
8603          part { name: "padding_right_bottom";
8604             type: RECT;
8605             scale: 1;
8606             mouse_events: 0;
8607             description { state: "default" 0.0;
8608                align: 1.0 1.0;
8609                rel1.relative: 1.0 1.0;
8610                min: BUTTON_PICKER_PREV_ICON_DEFAULT_PADDING_MIN_INC;
8611                fixed: 1 1;
8612                visible: 0;
8613             }
8614          }
8615          part { name: "right_arrow";
8616             scale: 1;
8617             mouse_events: 0;
8618             description { state: "default" 0.0;
8619                min: BUTTON_PICKER_PREV_ICON_DEFAULT_IMAGE_MIN_MAX_INC;
8620                max: BUTTON_PICKER_PREV_ICON_DEFAULT_IMAGE_MIN_MAX_INC;
8621                rel1 {
8622                   relative: 1.0 1.0;
8623                   to: "padding_left_top";
8624                }
8625                rel2 {
8626                   relative: 0.0 0.0;
8627                   to: "padding_right_bottom";
8628                }
8629                image.normal: "00_picker_arrow_right.png";
8630             }
8631             description { state: "clicked" 0.0;
8632                inherit: "default" 0.0;
8633                image.normal: "00_picker_arrow_right_press.png";
8634             }
8635          }
8636          part { name: "over2";
8637             type: RECT;
8638             repeat_events: 1;
8639             ignore_flags: ON_HOLD;
8640             description { state: "default" 0.0;
8641                color: 0 0 0 0;
8642             }
8643          }
8644          part { name: "over3";
8645             type: RECT;
8646             repeat_events: 1;
8647             description { state: "default" 0.0;
8648                color: 0 0 0 0;
8649             }
8650          }
8651          part { name: "disabler";
8652             type: RECT;
8653             description { state: "default" 0.0;
8654                color: 0 0 0 0;
8655                visible: 0;
8656             }
8657             description { state: "disabled" 0.0;
8658                inherit: "default" 0.0;
8659                visible: 1;
8660             }
8661          }
8662       }
8663       programs {
8664          program { name: "button_click";
8665             signal: "mouse,down,1";
8666             source: "over2";
8667             action: SIGNAL_EMIT "elm,action,press" "";
8668             after: "button_click_anim";
8669          }
8670          program { name: "button_click_anim";
8671             action: STATE_SET "clicked" 0.0;
8672             target: "button_image";
8673          }
8674          program { name: "button_unpress";
8675             action: SIGNAL_EMIT "elm,action,unpress" "";
8676          }
8677          program { name: "button_mouseout_clicked";
8678             signal: "mouse,up,1";
8679             source: "over3";
8680             script {
8681                if (get_int(button_state) != BUTTON_STATE_DISABLED)
8682                  set_state(PART:"button_image", "default", 0.0);
8683             }
8684             after: button_unpress;
8685          }
8686          program { name: "touch_snd";
8687             signal: "mouse,clicked,1";
8688             source: "over2";
8689             action: PLAY_SAMPLE "touch_sound" 1.0;
8690             after: button_unclick3;
8691          }
8692          program { name: "button_unclick3";
8693             action: SIGNAL_EMIT "elm,action,click" "";
8694          }
8695          program { name: "disable";
8696             signal: "elm,state,disabled";
8697             source: "elm";
8698             action: STATE_SET "disabled" 0.0;
8699             target: "button_image";
8700             target: "disabler";
8701             after: "disable_button";
8702          }
8703          program { name: "disable_button";
8704             script {
8705                set_int(button_state, BUTTON_STATE_DISABLED);
8706             }
8707          }
8708          program { name: "enable";
8709             signal: "elm,state,enabled";
8710             source: "elm";
8711             action: STATE_SET "default" 0.0;
8712             target: "button_image";
8713             target: "disabler";
8714             after: "enable_button";
8715          }
8716          program { name: "enable_button";
8717             script {
8718                set_int(button_state, BUTTON_STATE_ENABLED);
8719             }
8720          }
8721          program { name: "focused";
8722             //signal: "elm,action,focus";
8723             //source: "elm";
8724             action: STATE_SET "focused" 0.0;
8725             target: "button_image";
8726          }
8727          program { name: "unfocused";
8728             //signal: "elm,action,unfocus";
8729             //source: "elm";
8730             action: STATE_SET "default" 0.0;
8731             target: "button_image";
8732          }
8733       }
8734    }
8735
8736 ///////////////////////////////////////////////////////////////////////////////////////
8737    group { name: "elm/button/base/naviframe_control/default";
8738       alias: "elm/button/base/naviframe_control/center";
8739       script {
8740          public button_state = BUTTON_STATE_ENABLED;
8741       }
8742       images {
8743          image: "00_Option_header_bt.png" COMP;
8744          image: "00_Option_header_bt_dim.png" COMP;
8745          image: "00_Option_header_bt_press.png" COMP;
8746          image: "00_Option_header_bt_focus.png" COMP;
8747       }
8748       parts {
8749          part { name: "button_image";
8750             scale: 1;
8751             description { state: "default" 0.0;
8752                min: BUTTON_NAVIFRAME_CENTER_BG_NORMAL_MIN_INC;
8753                color: 0 0 0 0;
8754                rel1.offset: 0 0;
8755                rel2.offset: -1 -1;
8756                image {
8757                   normal: "00_Option_header_bt.png";
8758                   border: BUTTON_NAVIFRAME_CENTER_BG_NORMAL_BORDER_INC;
8759                }
8760                color: 255 255 255 255;
8761             }
8762             description { state: "disabled" 0.0;
8763                inherit: "default" 0.0;
8764                image.normal: "00_Option_header_bt_dim.png";
8765             }
8766             description { state: "clicked" 0.0;
8767                inherit: "default" 0.0;
8768                image.normal: "00_Option_header_bt_press.png";
8769             }
8770             description { state: "focused" 0.0;
8771                inherit: "default" 0.0;
8772                image.normal: "00_Option_header_bt_focus.png";
8773             }
8774          }
8775          part { name: "padding_left_top";
8776             type: RECT;
8777             scale: 1;
8778             mouse_events: 0;
8779             description { state: "default" 0.0;
8780                align: 0.0 0.0;
8781                rel2.relative: 0.0 0.0;
8782                min: BUTTON_NAVIFRAME_CENTER_PADDING_MIN_MAX_INC;
8783                fixed: 1 1;
8784                visible: 0;
8785             }
8786          }
8787          part { name: "padding_right_bottom";
8788             type: RECT;
8789             scale: 1;
8790             mouse_events: 0;
8791             description { state: "default" 0.0;
8792                align: 1.0 1.0;
8793                rel1.relative: 1.0 1.0;
8794                min: BUTTON_NAVIFRAME_CENTER_PADDING_MIN_MAX_INC;
8795                fixed: 1 1;
8796                visible: 0;
8797             }
8798          }
8799          part { name: "icon_rect";
8800             type: RECT;
8801             scale: 1;
8802             mouse_events: 0;
8803             description { state: "default" 0.0;
8804                min: 0 0;
8805                fixed: 1 0;
8806                rel1 {
8807                   relative: 1.0 1.0;
8808                   to: "padding_left_top";
8809                }
8810                rel2 {
8811                   relative: 1.0 0.0;
8812                   to_x: "padding_left_top";
8813                   to_y: "padding_right_bottom";
8814                }
8815                align: 0.0 0.5;
8816                color: 0 0 0 0;
8817             }
8818             description { state: "visible" 0.0;
8819                min: BUTTON_NAVIFRAME_CENTER_ICON_RECT_VISIBLE_MIN_SIZE;
8820                fixed: 1 0;
8821                rel1 {
8822                   relative: 1.0 1.0;
8823                   to: "padding_left_top";
8824                }
8825                rel2 {
8826                   relative: 1.0 0.0;
8827                   to_x: "padding_left_top";
8828                   to_y: "padding_right_bottom";
8829                }
8830                align: 0.0 0.5;
8831                color: 0 0 0 0;
8832             }
8833             description { state: "icononly" 0.0;
8834                inherit: "default" 0.0;
8835             }
8836          }
8837          part { name: "padding_after_icon";
8838             type: RECT;
8839             scale: 1;
8840             mouse_events: 0;
8841             description { state: "default" 0.0; //when only icon or no icon is there
8842                align: 0.0 0.0;
8843                rel1 {
8844                   relative: 1.0 0.0;
8845                   to: "icon_rect";
8846                }
8847                rel2.to: "icon_rect";
8848                fixed: 1 0;
8849                min: 0 0;
8850                color: 0 0 0 0;
8851             }
8852             description { state: "visible" 0.0;
8853                align: 0.0 0.0;
8854                rel1 {
8855                   relative: 1.0 0.0;
8856                   to: "icon_rect";
8857                }
8858                rel2.to: "icon_rect";
8859                fixed: 1 0;
8860                min: BUTTON_NAVIFRAME_CENTER_PADDING_AFTER_ICON_VISIBLE_MIN_INC;
8861                color: 0 0 0 0;
8862             }
8863             description { state: "icononly" 0.0;
8864                inherit: "default" 0.0;
8865             }
8866          }
8867          part { name: "padding_before_text";
8868             type: RECT;
8869             scale: 1;
8870             mouse_events: 0;
8871             description { state: "default" 0.0; //when only icon or no icon is there
8872                align: 1.0 0.5;
8873                rel1 {
8874                   relative: 0.0 1.0;
8875                   to_x: "elm.text";
8876                   to_y: "padding_left_top";
8877                }
8878                rel2 {
8879                   relative: 0.0 0.0;
8880                   to_x: "elm.text";
8881                   to_y: "padding_right_bottom";
8882                }
8883                fixed: 1 0;
8884                min: BUTTON_NAVIFRAME_CENTER_PADDING_BEFORE_TEXT_DEFAULT_MIN_INC;
8885                color: 0 0 0 0;
8886             }
8887          }
8888          part { name: "elm.swallow.content";
8889             type: SWALLOW;
8890             scale: 1;
8891             clip_to: "clipper";
8892             description { state: "default" 0.0;
8893                visible: 0;
8894                align: 0.0 0.5;
8895                rel1 {
8896                   relative: 1.0 1.0;
8897                   to: "padding_left_top";
8898                }
8899                rel2 {
8900                   relative: 1.0 0.0;
8901                   to_x: "padding_left_top";
8902                   to_y: "padding_right_bottom";
8903                }
8904                fixed: 1 0;
8905             }
8906             description { state: "visible" 0.0;
8907                fixed: 1 0;
8908                min: BUTTON_NAVIFRAME_CENTER_SWALLOW_VISIBLE_MIN_MAX_INC;
8909                max: BUTTON_NAVIFRAME_CENTER_SWALLOW_VISIBLE_MIN_MAX_INC;
8910                align: 1.0 0.5;
8911                rel1 {
8912                   relative: 0.0 1.0;
8913                   to_x: "padding_before_text";
8914                   to_y: "padding_left_top";
8915                }
8916                rel2 {
8917                   relative: 0.0 0.0;
8918                   to_x: "padding_before_text";
8919                   to_y: "padding_right_bottom";
8920                }
8921                aspect: 1.0 1.0;
8922                aspect_preference: VERTICAL;
8923             }
8924             description { state: "icononly" 0.0;
8925                min: BUTTON_NAVIFRAME_CENTER_SWALLOW_ICONONLY_MIN_MAX_INC;
8926                max: BUTTON_NAVIFRAME_CENTER_SWALLOW_ICONONLY_MIN_MAX_INC;
8927                rel1 {
8928                   relative: 1.0 1.0;
8929                   to: "padding_left_top";
8930                }
8931                rel2 {
8932                   relative: 0.0 0.0;
8933                   to: "padding_right_bottom";
8934                }
8935                aspect: 1.0 1.0;
8936                aspect_preference: VERTICAL;
8937             }
8938          }
8939          part { name: "elm.text";
8940             type: TEXT;
8941             mouse_events: 0;
8942             scale: 1;
8943             clip_to: "clipper";
8944             description { state: "default" 0.0;
8945                visible: 0;
8946                rel1 {
8947                   relative: 1.0 1.0;
8948                   to_x: "padding_after_icon";
8949                   to_y: "padding_left_top";
8950                }
8951                rel2 {
8952                   relative: 0.0 0.0;
8953                   to: "padding_right_bottom";
8954                }
8955                color: BUTTON_NAVIFRAME_DEFAULT_TEXT_COLOR_INC;
8956                text {
8957                   font: "SLP:style=Medium";
8958                   size: BUTTON_NAVIFRAME_CENTER_TEXT_FONT_SIZE_INC;
8959                   min: 0 0;
8960                   max: 1 0;
8961                   text_class: "slp_medium";
8962                }
8963             }
8964             description { state: "visible" 0.0;
8965                inherit: "default" 0.0;
8966                visible: 1;
8967             }
8968             description { state: "clicked" 0.0;
8969                inherit: "default" 0.0;
8970                visible: 1;
8971                min: 0 0;
8972             }
8973             description { state: "focused" 0.0;
8974                inherit: "default" 0.0;
8975                visible: 1;
8976                min: 0 0;
8977                color: BUTTON_NAVIFRAME_FOCUSED_TEXT_COLOR_INC;
8978             }
8979          }
8980          part { name: "over2";
8981             type: RECT;
8982             repeat_events: 1;
8983             ignore_flags: ON_HOLD;
8984             description { state: "default" 0.0;
8985                color: 0 0 0 0;
8986             }
8987          }
8988          part { name: "over3";
8989             type: RECT;
8990             repeat_events: 1;
8991             description { state: "default" 0.0;
8992                color: 0 0 0 0;
8993             }
8994          }
8995          part { name: "clipper";
8996             type: RECT;
8997             description { state: "default" 0.0;
8998                color: 255 255 255 255;
8999             }
9000             description { state: "disabled" 0.0;
9001                color: 255 255 255 127;
9002             }
9003          }
9004          part { name: "disabler";
9005             type: RECT;
9006             description { state: "default" 0.0;
9007                color: 0 0 0 0;
9008                visible: 0;
9009             }
9010             description { state: "disabled" 0.0;
9011                inherit: "default" 0.0;
9012                visible: 1;
9013             }
9014          }
9015       }
9016       programs {
9017          program { name: "button_click";
9018             signal: "mouse,down,1";
9019             source: "over2";
9020             action: SIGNAL_EMIT "elm,action,press" "";
9021             after: "button_click_anim";
9022          }
9023          program { name: "button_click_anim";
9024             action: STATE_SET "clicked" 0.0;
9025             target: "button_image";
9026             after: "text_clicked";
9027          }
9028          program { name: "text_clicked";
9029             script {
9030                new st[31];
9031                new Float:vl;
9032                get_state(PART:"elm.text", st, 30, vl);
9033                if (!strcmp(st, "visible"))
9034                  set_state(PART:"elm.text", "clicked", 0.0);
9035             }
9036          }
9037          program { name: "button_unpress";
9038             action: SIGNAL_EMIT "elm,action,unpress" "";
9039          }
9040          program { name: "button_mouseout_clicked";
9041             signal: "mouse,up,1";
9042             source: "over3";
9043             script {
9044                new st[31];
9045                new Float:vl;
9046                get_state(PART:"elm.swallow.content", st, 30, vl);
9047                if (strcmp(st, "icononly"))
9048                  {
9049                     emit("elm,action,default,text,set", "");
9050                     set_state(PART:"elm.text", "visible", 0.0);
9051                  }
9052                if (get_int(button_state) != BUTTON_STATE_DISABLED)
9053                  set_state(PART:"button_image", "default", 0.0);
9054             }
9055             after: button_unpress;
9056          }
9057          program { name: "touch_snd";
9058             signal: "mouse,clicked,1";
9059             source: "over2";
9060             action: PLAY_SAMPLE "touch_sound" 1.0;
9061             after: button_unclick3;
9062          }
9063          program { name: "button_unclick3";
9064             action: SIGNAL_EMIT "elm,action,click" "";
9065          }
9066          program { name: "text_show";
9067             signal: "elm,state,text,visible";
9068             source: "elm";
9069             script {
9070                new st[31];
9071                new Float:vl;
9072                get_state(PART:"elm.swallow.content", st, 30, vl);
9073                if (!strcmp(st, "icononly"))
9074                  {
9075                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9076                     set_state(PART:"icon_rect", "visible", 0.0);
9077                     set_state(PART:"padding_after_icon", "visible", 0.0);
9078                  }
9079                set_state(PART:"elm.text", "visible", 0.0);
9080             }
9081          }
9082          program { name: "text_hide";
9083             signal: "elm,state,text,hidden";
9084             source: "elm";
9085             script {
9086                new st[31];
9087                new Float:vl;
9088                get_state(PART:"elm.swallow.content", st, 30, vl);
9089                if (!strcmp(st, "visible"))
9090                  {
9091                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9092                     set_state(PART:"icon_rect", "icononly", 0.0);
9093                     set_state(PART:"padding_after_icon", "icononly", 0.0);
9094                  }
9095                set_state(PART:"elm.text", "default", 0.0);
9096             }
9097          }
9098          program { name: "icon_show";
9099             signal: "elm,state,icon,visible";
9100             source: "elm";
9101             script {
9102                new st[31];
9103                new Float:vl;
9104                get_state(PART:"elm.text", st, 30, vl);
9105                if (!strcmp(st, "visible"))
9106                  {
9107                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9108                     set_state(PART:"icon_rect", "visible", 0.0);
9109                     set_state(PART:"padding_after_icon", "visible", 0.0);
9110                  }
9111                else
9112                  {
9113                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9114                     set_state(PART:"icon_rect", "icononly", 0.0);
9115                     set_state(PART:"padding_after_icon", "icononly", 0.0);
9116                  }
9117             }
9118          }
9119          program { name: "icon_hide";
9120             signal: "elm,state,icon,hidden";
9121             source: "elm";
9122             action: STATE_SET "default" 0.0;
9123             target: "elm.swallow.content";
9124             target: "icon_rect";
9125             target: "padding_after_icon";
9126          }
9127          program { name: "disable";
9128             signal: "elm,state,disabled";
9129             source: "elm";
9130             action: STATE_SET "disabled" 0.0;
9131             target: "button_image";
9132             target: "clipper";
9133             target: "disabler";
9134             after: "disable_text";
9135          }
9136          program { name: "disable_text";
9137             script {
9138                new st[31];
9139                new Float:vl;
9140                set_int(button_state, BUTTON_STATE_DISABLED);
9141                get_state(PART:"elm.text", st, 30, vl);
9142                if (!strcmp(st, "clicked") || !strcmp(st, "focused"))
9143                  set_state(PART:"elm.text", "visible", 0.0);
9144             }
9145          }
9146          program { name: "enable";
9147             signal: "elm,state,enabled";
9148             source: "elm";
9149             action: STATE_SET "default" 0.0;
9150             target: "button_image";
9151             target: "clipper";
9152             target: "disabler";
9153             after: "enable_text";
9154          }
9155          program { name: "enable_text";
9156             script {
9157                new st[31];
9158                new Float:vl;
9159                set_int(button_state, BUTTON_STATE_ENABLED);
9160                get_state(PART:"elm.text", st, 30, vl);
9161                if (!strcmp(st, "clicked") || !strcmp(st, "focused"))
9162                  set_state(PART:"elm.text", "visible", 0.0);
9163             }
9164          }
9165          program { name: "focused";
9166             //signal: "elm,action,focus";
9167             //source: "elm";
9168             action: STATE_SET "focused" 0.0;
9169             target: "button_image";
9170             target: "elm.text";
9171          }
9172          program { name: "unfocused";
9173             //signal: "elm,action,unfocus";
9174             //source: "elm";
9175             action: STATE_SET "default" 0.0;
9176             target: "button_image";
9177             after: "unfocus_text";
9178          }
9179          program { name: "unfocus_text";
9180             action: STATE_SET "visible" 0.0;
9181             target: "elm.text";
9182          }
9183       }
9184    }
9185
9186 ///////////////////////////////////////////////////////////////////////////////////////
9187    group { name: "elm/button/base/naviframe_control/multiline";
9188       script {
9189          public button_state = BUTTON_STATE_ENABLED;
9190       }
9191       images {
9192          image: "00_Option_header_bt.png" COMP;
9193          image: "00_Option_header_bt_dim.png" COMP;
9194          image: "00_Option_header_bt_press.png" COMP;
9195          image: "00_Option_header_bt_focus.png" COMP;
9196       }
9197       styles{
9198          style { name: "btn_multiline_naviframe_controlbar_style";
9199             base: "font=SLP:style=Medium font_size="BUTTON_NAVIFRAME_MULTILINE_TEXT_FONT_SIZE_INC" align=center color=#ffffff wrap=mixed text_class=slp_medium";
9200             tag: "br" "\n";
9201             tag: "ps" "ps";
9202             tag: "tab" "\t";
9203          }
9204       }
9205       parts {
9206          part { name: "button_image";
9207             scale: 1;
9208             description { state: "default" 0.0;
9209                min: BUTTON_NAVIFRAME_CENTER_BG_NORMAL_MIN_INC;
9210                rel1.offset: 0 0;
9211                rel2.offset: -1 -1;
9212                image {
9213                   normal: "00_Option_header_bt.png";
9214                   border: BUTTON_NAVIFRAME_CENTER_BG_NORMAL_BORDER_INC;
9215                }
9216                color: 255 255 255 255;
9217             }
9218             description { state: "disabled" 0.0;
9219                inherit: "default" 0.0;
9220                image.normal: "00_Option_header_bt_dim.png";
9221             }
9222             description { state: "clicked" 0.0;
9223                inherit: "default" 0.0;
9224                image.normal: "00_Option_header_bt_press.png";
9225             }
9226             description { state: "focused" 0.0;
9227                inherit: "default" 0.0;
9228                image.normal: "00_Option_header_bt_focus.png";
9229             }
9230          }
9231          part { name: "padding_left_top";
9232             type: RECT;
9233             scale: 1;
9234             mouse_events: 0;
9235             description { state: "default" 0.0;
9236                align: 0.0 0.0;
9237                rel2.relative: 0.0 0.0;
9238                min: BUTTON_NAVIFRAME_CENTER_PADDING_MIN_MAX_INC;
9239                fixed: 1 1;
9240                visible: 0;
9241             }
9242          }
9243          part { name: "padding_right_bottom";
9244             type: RECT;
9245             scale: 1;
9246             mouse_events: 0;
9247             description { state: "default" 0.0;
9248                align: 1.0 1.0;
9249                rel1.relative: 1.0 1.0;
9250                min: BUTTON_NAVIFRAME_CENTER_PADDING_MIN_MAX_INC;
9251                fixed: 1 1;
9252                visible: 0;
9253             }
9254          }
9255          part { name: "icon_rect";
9256             type: RECT;
9257             scale: 1;
9258             mouse_events: 0;
9259             description { state: "default" 0.0;
9260                visible: 0;
9261                min: 0 0;
9262                fixed: 1 0;
9263                rel1 {
9264                   relative: 0.0 1.0;
9265                   to_x: "elm.swallow.content";
9266                   to_y: "padding_left_top";
9267                }
9268                rel2 {
9269                   relative: 1.0 0.0;
9270                   to_x: "elm.swallow.content";
9271                   to_y: "padding_right_bottom";
9272                }
9273                align: 0.0 0.5;
9274             }
9275          }
9276          part { name: "padding_icon_text";
9277             type: RECT;
9278             scale: 1;
9279             mouse_events: 0;
9280             description { state: "default" 0.0; //when only icon or no icon is there
9281                visible: 0;
9282                align: 0.0 0.0;
9283                rel1 {
9284                   relative: 1.0 0.0;
9285                   to: "icon_rect";
9286                }
9287                rel2 {
9288                   relative: 1.0 1.0;
9289                   to: "icon_rect";
9290                }
9291                fixed: 1 0;
9292                min: 0 0;
9293             }
9294             description { state: "visible" 0.0;
9295                inherit: "default" 0.0;
9296                min: BUTTON_NAVIFRAME_CENTER_PADDING_AFTER_ICON_VISIBLE_MIN_INC;
9297                rel1 {
9298                   relative: 1.0 0.0;
9299                   to: "icon_rect";
9300                }
9301                rel2 {
9302                   relative: 1.0 1.0;
9303                   to: "icon_rect";
9304                }
9305            }
9306             description { state: "icononly" 0.0;
9307                inherit: "default" 0.0;
9308             }
9309          }
9310          part { name: "elm.swallow.content";
9311             type: SWALLOW;
9312             scale: 1;
9313             clip_to: "clipper";
9314             description { state: "default" 0.0;
9315                visible: 0;
9316                align: 0.0 0.5;
9317                rel1 {
9318                   relative: 1.0 1.0;
9319                   to: "padding_left_top";
9320                }
9321                rel2 {
9322                   relative: 1.0 0.0;
9323                   to_x: "padding_left_top";
9324                   to_y: "padding_right_bottom";
9325                }
9326                fixed: 1 0;
9327             }
9328             description { state: "visible" 0.0;
9329                fixed: 1 0;
9330                min: BUTTON_NAVIFRAME_CENTER_SWALLOW_VISIBLE_MIN_MAX_INC;
9331                max: BUTTON_NAVIFRAME_CENTER_SWALLOW_VISIBLE_MIN_MAX_INC;
9332                align: 0.0 0.5;
9333                rel1 {
9334                   relative: 1.0 1.0;
9335                   to: "padding_left_top";
9336                }
9337                rel2 {
9338                   relative: 0.0 0.0;
9339                   to_x: "padding_left_top";
9340                   to_y: "padding_right_bottom";
9341                }
9342             }
9343             description { state: "icononly" 0.0;
9344                min: BUTTON_NAVIFRAME_CENTER_SWALLOW_ICONONLY_MIN_MAX_INC;
9345                max: BUTTON_NAVIFRAME_CENTER_SWALLOW_ICONONLY_MIN_MAX_INC;
9346                rel1 {
9347                   relative: 1.0 1.0;
9348                   to: "padding_left_top";
9349                }
9350                rel2 {
9351                   relative: 0.0 0.0;
9352                   to: "padding_right_bottom";
9353                }
9354             }
9355          }
9356          part { name: "elm.text";
9357             type: TEXTBLOCK;
9358             mouse_events: 0;
9359             scale: 1;
9360             clip_to: "clipper";
9361             description { state: "default" 0.0;
9362                visible: 0;
9363                rel1 {
9364                   relative: 1.0 1.0;
9365                   to_x: "padding_icon_text";
9366                   to_y: "padding_left_top";
9367                }
9368                rel2 {
9369                    relative: 0.0 0.0;
9370                    to: "padding_right_bottom";
9371                }
9372                color: BUTTON_NAVIFRAME_DEFAULT_TEXT_COLOR_INC;
9373                text {
9374                   style: "btn_multiline_naviframe_controlbar_style";
9375                   min: 0 0;
9376                   max: 0 1;
9377                }
9378             }
9379             description { state: "visible" 0.0;
9380                inherit: "default" 0.0;
9381                visible: 1;
9382                min: 80 0;
9383             }
9384             description { state: "clicked" 0.0;
9385                inherit: "default" 0.0;
9386                visible: 1;
9387                min: 0 0;
9388             }
9389             description { state: "focused" 0.0;
9390                inherit: "default" 0.0;
9391                visible: 1;
9392                min: 0 0;
9393                color: BUTTON_NAVIFRAME_FOCUSED_TEXT_COLOR_INC;
9394             }
9395          }
9396          part { name: "over2";
9397             type: RECT;
9398             repeat_events: 1;
9399             ignore_flags: ON_HOLD;
9400             description { state: "default" 0.0;
9401                color: 0 0 0 0;
9402             }
9403          }
9404          part { name: "over3";
9405             type: RECT;
9406             repeat_events: 1;
9407             description { state: "default" 0.0;
9408                color: 0 0 0 0;
9409             }
9410          }
9411          part { name: "clipper";
9412             type: RECT;
9413             description { state: "default" 0.0;
9414                color: 255 255 255 255;
9415             }
9416             description { state: "disabled" 0.0;
9417                color: 255 255 255 127;
9418             }
9419          }
9420          part { name: "disabler";
9421             type: RECT;
9422             description { state: "default" 0.0;
9423                color: 0 0 0 0;
9424                visible: 0;
9425             }
9426             description { state: "disabled" 0.0;
9427                inherit: "default" 0.0;
9428                visible: 1;
9429             }
9430          }
9431       }
9432       programs {
9433          program { name: "button_click";
9434             signal: "mouse,down,1";
9435             source: "over2";
9436             action: SIGNAL_EMIT "elm,action,press" "";
9437             after: "button_click_anim";
9438          }
9439          program { name: "button_click_anim";
9440             action: STATE_SET "clicked" 0.0;
9441             target: "button_image";
9442             after: "text_clicked";
9443          }
9444          program { name: "text_clicked";
9445             script {
9446                new st[31];
9447                new Float:vl;
9448                get_state(PART:"elm.text", st, 30, vl);
9449                if (!strcmp(st, "visible"))
9450                  set_state(PART:"elm.text", "clicked", 0.0);
9451             }
9452          }
9453          program { name: "button_unpress";
9454             action: SIGNAL_EMIT "elm,action,unpress" "";
9455          }
9456          program { name: "button_mouseout_clicked";
9457             signal: "mouse,up,1";
9458             source: "over3";
9459             script {
9460                new st[31];
9461                new Float:vl;
9462                get_state(PART:"elm.swallow.content", st, 30, vl);
9463                if (strcmp(st, "icononly"))
9464                  {
9465                     emit("elm,action,default,text,set", "");
9466                     set_state(PART:"elm.text", "visible", 0.0);
9467                  }
9468                if (get_int(button_state) != BUTTON_STATE_DISABLED)
9469                  set_state(PART:"button_image", "default", 0.0);
9470             }
9471             after: button_unpress;
9472          }
9473          program { name: "touch_snd";
9474             signal: "mouse,clicked,1";
9475             source: "over2";
9476             action: PLAY_SAMPLE "touch_sound" 1.0;
9477             after: button_unclick3;
9478          }
9479          program { name: "button_unclick3";
9480             action: SIGNAL_EMIT "elm,action,click" "";
9481          }
9482          program { name: "text_show";
9483             signal: "elm,state,text,visible";
9484             source: "elm";
9485             script {
9486                new st[31];
9487                new Float:vl;
9488                get_state(PART:"elm.swallow.content", st, 30, vl);
9489                if (!strcmp(st, "icononly"))
9490                  {
9491                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9492                     set_state(PART:"padding_icon_text", "visible", 0.0);
9493                  }
9494                set_state(PART:"elm.text", "visible", 0.0);
9495             }
9496          }
9497          program { name: "text_hide";
9498             signal: "elm,state,text,hidden";
9499             source: "elm";
9500             script {
9501                new st[31];
9502                new Float:vl;
9503                get_state(PART:"elm.swallow.content", st, 30, vl);
9504                if (!strcmp(st, "visible"))
9505                  {
9506                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9507                     set_state(PART:"padding_icon_text", "icononly", 0.0);
9508                  }
9509                set_state(PART:"elm.text", "default", 0.0);
9510             }
9511          }
9512          program { name: "icon_show";
9513             signal: "elm,state,icon,visible";
9514             source: "elm";
9515             script {
9516                new st[31];
9517                new Float:vl;
9518                get_state(PART:"elm.text", st, 30, vl);
9519                if (!strcmp(st, "visible"))
9520                  {
9521                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9522                     set_state(PART:"padding_icon_text", "visible", 0.0);
9523                  }
9524                else
9525                  {
9526                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9527                     set_state(PART:"padding_icon_text", "icononly", 0.0);
9528                  }
9529             }
9530          }
9531          program { name: "icon_hide";
9532             signal: "elm,state,icon,hidden";
9533             source: "elm";
9534             action: STATE_SET "default" 0.0;
9535             target: "elm.swallow.content";
9536             target: "padding_icon_text";
9537          }
9538          program { name: "disable";
9539             signal: "elm,state,disabled";
9540             source: "elm";
9541             action: STATE_SET "disabled" 0.0;
9542             target: "button_image";
9543             target: "clipper";
9544             target: "disabler";
9545             after: "disable_text";
9546          }
9547          program { name: "disable_text";
9548             script {
9549                new st[31];
9550                new Float:vl;
9551                set_int(button_state, BUTTON_STATE_DISABLED);
9552                get_state(PART:"elm.text", st, 30, vl);
9553                if (!strcmp(st, "clicked") || !strcmp(st, "focused"))
9554                  set_state(PART:"elm.text", "visible", 0.0);
9555             }
9556          }
9557          program { name: "enable";
9558             signal: "elm,state,enabled";
9559             source: "elm";
9560             action: STATE_SET "default" 0.0;
9561             target: "button_image";
9562             target: "clipper";
9563             target: "disabler";
9564             after: "enable_text";
9565          }
9566          program { name: "enable_text";
9567             script {
9568                new st[31];
9569                new Float:vl;
9570                set_int(button_state, BUTTON_STATE_ENABLED);
9571                get_state(PART:"elm.text", st, 30, vl);
9572                if (!strcmp(st, "clicked") || !strcmp(st, "focused"))
9573                  set_state(PART:"elm.text", "visible", 0.0);
9574             }
9575          }
9576          program { name: "focused";
9577             //signal: "elm,action,focus";
9578             //source: "elm";
9579             action: STATE_SET "focused" 0.0;
9580             target: "button_image";
9581             target: "elm.text";
9582          }
9583          program { name: "unfocused";
9584             //signal: "elm,action,unfocus";
9585             //source: "elm";
9586             action: STATE_SET "default" 0.0;
9587             target: "button_image";
9588             after: "unfocus_text";
9589          }
9590          program { name: "unfocus_text";
9591             action: STATE_SET "visible" 0.0;
9592             target: "elm.text";
9593          }
9594       }
9595    }
9596
9597 /////////////////////////////////////////////////////////////
9598    group { name: "elm/button/base/naviframe/title1/default";
9599       images {
9600          image: "00_winset_Back_btn_normal.png" COMP;
9601          image: "00_winset_Back_btn_press.png" COMP;
9602          image: "00_winset_Back_btn_normal_focus.png" COMP;
9603       }
9604       script {
9605          public button_state = BUTTON_STATE_ENABLED;
9606       }
9607       parts {
9608          part { name: "button_image";
9609             scale: 1;
9610             description { state: "default" 0.0;
9611                min: BUTTON_NAVIFRAME_TITLE1_BG_MIN_INC;
9612                image {
9613                   normal: "00_winset_Back_btn_normal.png";
9614                   border: BUTTON_NAVIFRAME_TITLE1_BG_BORDER_INC;
9615                   border_scale: 1;
9616                }
9617             }
9618             description { state: "clicked" 0.0;
9619                inherit: "default" 0.0;
9620                image.normal: "00_winset_Back_btn_press.png";
9621             }
9622             description { state: "disabled" 0.0;
9623                inherit: "default" 0.0;
9624                color: 127 127 127 127;
9625             }
9626             description { state: "focused" 0.0;
9627                inherit: "default" 0.0;
9628                image.normal: "00_winset_Back_btn_normal_focus.png";
9629             }
9630          }
9631          part { name: "padding_left_top";
9632             type: RECT;
9633             scale: 1;
9634             mouse_events: 0;
9635             description { state: "default" 0.0;
9636                align: 0.0 0.0;
9637                rel2.relative: 0.0 0.0;
9638                min: BUTTON_NAVIFRAME_TITLE1_PADDING_MIN_INC;
9639                fixed: 1 1;
9640                visible: 0;
9641             }
9642          }
9643          part { name: "bg";
9644             type: RECT;
9645             scale: 1;
9646             mouse_events: 0;
9647             description { state: "default" 0.0;
9648                min: BUTTON_NAVIFRAME_TITLE1_BG_MIN_INC;
9649                visible: 0;
9650             }
9651             description { state: "visible" 0.0;
9652                inherit: "default" 0.0;
9653                min: BUTTON_NAVIFRAME_TITLE1_BG_MIN_INC;
9654             }
9655             description { state: "icononly" 0.0;
9656                inherit: "default" 0.0;
9657                min: BUTTON_NAVIFRAME_TITLE1_BG_MIN_INC;
9658             }
9659          }
9660          part { name: "padding_right_bottom";
9661             type: RECT;
9662             scale: 1;
9663             mouse_events: 0;
9664             description { state: "default" 0.0;
9665                align: 1.0 1.0;
9666                rel1.relative: 1.0 1.0;
9667                min: BUTTON_NAVIFRAME_TITLE1_PADDING_MIN_INC;
9668                fixed: 1 1;
9669                visible: 0;
9670             }
9671          }
9672          part { name: "icon_rect";
9673             type: RECT;
9674             scale: 1;
9675             mouse_events: 0;
9676             description { state: "default" 0.0;
9677                visible: 0;
9678                min: 0 0;
9679                fixed: 1 0;
9680                rel1 {
9681                   relative: 1.0 1.0;
9682                   to: "padding_left_top";
9683                }
9684                rel2 {
9685                   relative: 1.0 0.0;
9686                   to_x: "padding_left_top";
9687                   to_y: "padding_right_bottom";
9688                }
9689                align: 0.0 0.5;
9690             }
9691             description { state: "visible" 0.0;
9692                visible: 0;
9693                min: BUTTON_NAVIFRAME_TITLE1_VISIBLE_ICON_RECT_MIN_MAX_INC;
9694                max: BUTTON_NAVIFRAME_TITLE1_VISIBLE_ICON_RECT_MIN_MAX_INC;
9695                fixed: 1 0;
9696                rel1 {
9697                   relative: 1.0 1.0;
9698                   to: "padding_left_top";
9699                }
9700                rel2 {
9701                   relative: 1.0 0.0;
9702                   to_x: "padding_left_top";
9703                   to_y: "padding_right_bottom";
9704                }
9705                align: 0.0 0.5;
9706             }
9707             description { state: "icononly" 0.0;
9708                inherit: "default" 0.0;
9709             }
9710          }
9711          part { name: "padding_after_icon";
9712             type: RECT;
9713             scale: 1;
9714             mouse_events: 0;
9715             description { state: "default" 0.0; //when only icon or no icon is there
9716                align: 0.0 0.0;
9717                rel1 {
9718                   relative: 1.0 0.0;
9719                   to: "icon_rect";
9720                }
9721                rel2.to: "icon_rect";
9722                fixed: 1 0;
9723                min: 0 0;
9724                visible: 0;
9725             }
9726             description { state: "visible" 0.0;
9727                visible: 0;
9728                align: 0.0 0.0;
9729                rel1 {
9730                   relative: 1.0 0.0;
9731                   to: "icon_rect";
9732                }
9733                rel2.to: "icon_rect";
9734                fixed: 1 0;
9735                min: BUTTON_NAVIFRAME_TITLE1_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
9736             }
9737             description { state: "icononly" 0.0;
9738                inherit: "default" 0.0;
9739             }
9740          }
9741          part { name: "padding_before_text";
9742             type: RECT;
9743             scale: 1;
9744             mouse_events: 0;
9745             description { state: "default" 0.0; //when only icon or no icon is there
9746                align: 1.0 0.5;
9747                rel1 {
9748                   relative: 0.0 1.0;
9749                   to_x: "elm.text";
9750                   to_y: "padding_left_top";
9751                }
9752                rel2 {
9753                   relative: 0.0 0.0;
9754                   to_x: "elm.text";
9755                   to_y: "padding_right_bottom";
9756                }
9757                fixed: 1 0;
9758                min: BUTTON_NAVIFRAME_TITLE1_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
9759                visible: 0;
9760             }
9761          }
9762          part { name: "elm.swallow.content";
9763             type: SWALLOW;
9764             scale: 1;
9765             clip_to: "clipper";
9766             description { state: "default" 0.0;
9767                visible: 0;
9768                align: 0.0 0.5;
9769                rel1 {
9770                   relative: 1.0 1.0;
9771                   to: "padding_left_top";
9772                }
9773                rel2 {
9774                   relative: 1.0 0.0;
9775                   to_x: "padding_left_top";
9776                   to_y: "padding_right_bottom";
9777                }
9778                fixed: 1 0;
9779             }
9780             description { state: "visible" 0.0;
9781                fixed: 1 0;
9782                min: BUTTON_NAVIFRAME_TITLE1_VISIBLE_ICON_MIN_MAX_INC;
9783                max: BUTTON_NAVIFRAME_TITLE1_VISIBLE_ICON_MIN_MAX_INC;
9784                align: 1.0 0.5;
9785                rel1 {
9786                   relative: 0.0 1.0;
9787                   to_x: "padding_before_text";
9788                   to_y: "padding_left_top";
9789                }
9790                rel2 {
9791                   relative: 0.0 0.0;
9792                   to_x: "padding_before_text";
9793                   to_y: "padding_right_bottom";
9794                }
9795             }
9796             description { state: "icononly" 0.0;
9797                min: BUTTON_NAVIFRAME_TITLE1_ICONONLY_ICON_MIN_MAX_INC;
9798                max: BUTTON_NAVIFRAME_TITLE1_ICONONLY_ICON_MIN_MAX_INC;
9799             }
9800          }
9801          part { name: "elm.text";
9802             type: TEXT;
9803             mouse_events: 0;
9804             scale: 1;
9805             clip_to: "clipper";
9806             description { state: "default" 0.0;
9807                visible: 0;
9808                rel1 {
9809                   relative: 1.0 1.0;
9810                   to_x: "padding_after_icon";
9811                   to_y: "padding_left_top";
9812                }
9813                rel2 {
9814                   relative: 0.0 0.0;
9815                   to: "padding_right_bottom";
9816                }
9817                color: BUTTON_NAVIFRAME_TITLE1_NORMAL_COLOR_INC;
9818                text {
9819                   font: "SLP:style=Medium";
9820                   size: BUTTON_NAVIFRAME_TITLE1_FONT_SIZE_INC;
9821                   min: 1 0;
9822                   max: 1 0;
9823                   text_class: "slp_medium";
9824                }
9825             }
9826             description { state: "visible" 0.0;
9827                inherit: "default" 0.0;
9828                visible: 1;
9829             }
9830             description { state: "clicked" 0.0;
9831                inherit: "default" 0.0;
9832                visible: 1;
9833                color: BUTTON_NAVIFRAME_TITLE1_PRESSED_COLOR_INC;
9834             }
9835             description { state: "disabled" 0.0;
9836                inherit: "default" 0.0;
9837                color: 0 0 0 128;
9838             }
9839             description { state: "disabled_visible" 0.0;
9840                inherit: "default" 0.0;
9841                color: BUTTON_NAVIFRAME_TITLE1_DISABLED_COLOR_INC;
9842                visible: 1;
9843             }
9844             description { state: "focused" 0.0;
9845                inherit: "default" 0.0;
9846                visible: 1;
9847                color: BUTTON_NAVIFRAME_TITLE1_FOCUSED_COLOR_INC;
9848             }
9849          }
9850          part { name: "over2";
9851             type: RECT;
9852             repeat_events: 1;
9853             ignore_flags: ON_HOLD;
9854             description { state: "default" 0.0;
9855                color: 0 0 0 0;
9856             }
9857          }
9858          part { name: "over3";
9859             type: RECT;
9860             repeat_events: 1;
9861             description { state: "default" 0.0;
9862                color: 0 0 0 0;
9863             }
9864          }
9865          part { name: "clipper";
9866             type: RECT;
9867             description { state: "default" 0.0;
9868                color: 255 255 255 255;
9869             }
9870          }
9871          part { name: "disabler";
9872             type: RECT;
9873             description { state: "default" 0.0;
9874                color: 0 0 0 0;
9875                visible: 0;
9876             }
9877             description { state: "disabled" 0.0;
9878                inherit: "default" 0.0;
9879                visible: 1;
9880             }
9881          }
9882       }
9883       programs {
9884          program { name: "button_click";
9885             signal: "mouse,down,1";
9886             source: "over2";
9887             action: SIGNAL_EMIT "elm,action,press" "";
9888             after: "button_click_anim";
9889          }
9890          program { name: "button_click_anim";
9891             action: STATE_SET "clicked" 0.0;
9892             target: "button_image";
9893             after: "text_clicked";
9894          }
9895          program { name: "text_clicked";
9896             script {
9897                new st[31];
9898                new Float:vl;
9899                get_state(PART:"elm.text", st, 30, vl);
9900                if (!strcmp(st, "visible"))
9901                  set_state(PART:"elm.text", "clicked", 0.0);
9902             }
9903          }
9904          program { name: "button_unpress";
9905             action: SIGNAL_EMIT "elm,action,unpress" "";
9906          }
9907          program { name: "button_mouseout_clicked";
9908             signal: "mouse,up,1";
9909             source: "over3";
9910             script {
9911                new st[31];
9912                new Float:vl;
9913                get_state(PART:"elm.swallow.content", st, 30, vl);
9914                if (strcmp(st, "icononly"))
9915                  {
9916                     emit("elm,action,default,text,set", "");
9917                     set_state(PART:"elm.text", "visible", 0.0);
9918                  }
9919                if (get_int(button_state) != BUTTON_STATE_DISABLED)
9920                  set_state(PART:"button_image", "default", 0.0);
9921             }
9922             after: button_unpress;
9923          }
9924          program { name: "touch_snd";
9925             signal: "mouse,clicked,1";
9926             source: "over2";
9927             action: PLAY_SAMPLE "touch_sound" 1.0;
9928             after: button_unclick3;
9929          }
9930          program { name: "button_unclick3";
9931             action: SIGNAL_EMIT "elm,action,click" "";
9932          }
9933          program { name: "text_show";
9934             signal: "elm,state,text,visible";
9935             source: "elm";
9936             script {
9937                new st[31];
9938                new Float:vl;
9939                get_state(PART:"elm.swallow.content", st, 30, vl);
9940                if (!strcmp(st, "icononly"))
9941                  {
9942                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9943                     set_state(PART:"icon_rect", "visible", 0.0);
9944                     set_state(PART:"padding_after_icon", "visible", 0.0);
9945                     set_state(PART:"bg", "visible", 0.0);
9946                  }
9947                if (get_int(button_state) != BUTTON_STATE_DISABLED)
9948                  set_state(PART:"elm.text", "visible", 0.0);
9949                else
9950                  set_state(PART:"elm.text", "disabled_visible", 0.0);
9951             }
9952          }
9953          program { name: "text_hide";
9954             signal: "elm,state,text,hidden";
9955             source: "elm";
9956             script {
9957                new st[31];
9958                new Float:vl;
9959                get_state(PART:"elm.swallow.content", st, 30, vl);
9960                if (!strcmp(st, "visible"))
9961                  {
9962                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9963                     set_state(PART:"icon_rect", "icononly", 0.0);
9964                     set_state(PART:"padding_after_icon", "icononly", 0.0);
9965                     set_state(PART:"bg", "icononly", 0.0);
9966                  }
9967                set_state(PART:"elm.text", "default", 0.0);
9968             }
9969          }
9970          program { name: "icon_show";
9971             signal: "elm,state,icon,visible";
9972             source: "elm";
9973             script {
9974                new st[31];
9975                new Float:vl;
9976                get_state(PART:"elm.text", st, 30, vl);
9977                if (!strcmp(st, "visible"))
9978                  {
9979                     set_state(PART:"elm.swallow.content", "visible", 0.0);
9980                     set_state(PART:"icon_rect", "visible", 0.0);
9981                     set_state(PART:"padding_after_icon", "visible", 0.0);
9982                     set_state(PART:"bg", "visible", 0.0);
9983                  }
9984                else
9985                  {
9986                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
9987                     set_state(PART:"icon_rect", "icononly", 0.0);
9988                     set_state(PART:"padding_after_icon", "icononly", 0.0);
9989                     set_state(PART:"bg", "icononly", 0.0);
9990                  }
9991             }
9992          }
9993          program { name: "icon_hide";
9994             signal: "elm,state,icon,hidden";
9995             source: "elm";
9996             action: STATE_SET "default" 0.0;
9997             target: "elm.swallow.content";
9998             target: "padding_after_icon";
9999             target: "icon_rect";
10000             target: "bg";
10001          }
10002          program { name: "disable";
10003             signal: "elm,state,disabled";
10004             source: "elm";
10005             action: STATE_SET "disabled" 0.0;
10006             target: "button_image";
10007             target: "disabler";
10008             after: "disable_text";
10009          }
10010          program { name: "disable_text";
10011             script {
10012                new st[31];
10013                new Float:vl;
10014                get_state(PART:"elm.text", st, 30, vl);
10015                if (!strcmp(st, "visible"))
10016                  set_state(PART:"elm.text", "disabled_visible", 0.0);
10017                else
10018                  set_state(PART:"elm.text", "disabled", 0.0);
10019                set_int(button_state, BUTTON_STATE_DISABLED);
10020             }
10021          }
10022          program { name: "enable";
10023             signal: "elm,state,enabled";
10024             source: "elm";
10025             action: STATE_SET "default" 0.0;
10026             target: "button_image";
10027             target: "disabler";
10028             after: "enable_text";
10029          }
10030          program { name: "enable_text";
10031             script {
10032                new st[31];
10033                new Float:vl;
10034                get_state(PART:"elm.text", st, 30, vl);
10035                if (!strcmp(st, "disabled_visible"))
10036                  set_state(PART:"elm.text", "visible", 0.0);
10037                else
10038                  set_state(PART:"elm.text", "default", 0.0);
10039                set_int(button_state, BUTTON_STATE_ENABLED);
10040             }
10041          }
10042          program { name: "focused";
10043             //signal: "elm,action,focus";
10044             //source: "elm";
10045             action: STATE_SET "focused" 0.0;
10046             target: "button_image";
10047             target: "elm.text";
10048          }
10049          program { name: "unfocused";
10050             //signal: "elm,action,unfocus";
10051             //source: "elm";
10052             action: STATE_SET "default" 0.0;
10053             target: "button_image";
10054             after: "unfocus_text";
10055          }
10056          program { name: "unfocus_text";
10057             action: STATE_SET "visible" 0.0;
10058             target: "elm.text";
10059          }
10060       }
10061    }
10062
10063 //////////////////////////////////////////////////////////////
10064    group { name: "elm/button/base/naviframe/title/default";
10065       script {
10066          public button_state = BUTTON_STATE_ENABLED;
10067       }
10068       images {
10069          image: "00_title_btn_bg_press.png" COMP;
10070       }
10071       styles{
10072          style { name: "btn_naviframe_style";
10073             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";
10074             tag: "br" "\n";
10075             tag: "ps" "ps";
10076             tag: "tab" "\t";
10077          }
10078       }
10079       parts {
10080          part { name: "button_image";
10081             scale: 1;
10082             description { state: "default" 0.0;
10083                min: BUTTON_NAVIFRAME_TITLE_TEXT_BG_NORMAL_MIN_INC;
10084                max: BUTTON_NAVIFRAME_TITLE_TEXT_BG_NORMAL_MIN_INC;
10085                color: 0 0 0 0;
10086             }
10087             description { state: "clicked" 0.0;
10088                min: BUTTON_NAVIFRAME_TITLE_TEXT_BG_PRESSED_MIN_INC;
10089                max: BUTTON_NAVIFRAME_TITLE_TEXT_BG_PRESSED_MIN_INC;
10090                image {
10091                   normal: "00_title_btn_bg_press.png";
10092                   border: BUTTON_NAVIFRAME_TITLE_TEXT_BG_PRESSED_BORDER_INC;
10093                   border_scale: 1;
10094                }
10095             }
10096             description { state: "disabled" 0.0;
10097                inherit: "default" 0.0;
10098             }
10099             description { state: "focused" 0.0;
10100                inherit: "default" 0.0;
10101             }
10102          }
10103          part { name: "padding_left_top";
10104             type: RECT;
10105             scale: 1;
10106             mouse_events: 0;
10107             description { state: "default" 0.0;
10108                align: 0.0 0.0;
10109                rel2.relative: 0.0 0.0;
10110                min: BUTTON_NAVIFRAME_TITLE_TEXT_PADDING_MIN_INC;
10111                fixed: 1 1;
10112                visible: 0;
10113             }
10114          }
10115          part { name: "padding_right_bottom";
10116             type: RECT;
10117             scale: 1;
10118             mouse_events: 0;
10119             description { state: "default" 0.0;
10120                align: 1.0 1.0;
10121                rel1.relative: 1.0 1.0;
10122                min: BUTTON_NAVIFRAME_TITLE_TEXT_PADDING_MIN_INC;
10123                fixed: 1 1;
10124                visible: 0;
10125             }
10126          }
10127          part { name: "icon_rect";
10128             type: RECT;
10129             scale: 1;
10130             mouse_events: 0;
10131             description { state: "default" 0.0;
10132                visible: 0;
10133                min: 0 0;
10134                fixed: 1 0;
10135                rel1 {
10136                   relative: 1.0 1.0;
10137                   to: "padding_left_top";
10138                }
10139                rel2 {
10140                   relative: 1.0 0.0;
10141                   to_x: "padding_left_top";
10142                   to_y: "padding_right_bottom";
10143                }
10144                align: 0.0 0.5;
10145             }
10146             description { state: "visible" 0.0;
10147                visible: 0;
10148                min: BUTTON_NAVIFRAME_TITLE_VISIBLE_ICON_RECT_MIN_MAX_INC;
10149                max: BUTTON_NAVIFRAME_TITLE_VISIBLE_ICON_RECT_MIN_MAX_INC;
10150                fixed: 1 0;
10151                rel1 {
10152                   relative: 1.0 1.0;
10153                   to: "padding_left_top";
10154                }
10155                rel2 {
10156                   relative: 1.0 0.0;
10157                   to_x: "padding_left_top";
10158                   to_y: "padding_right_bottom";
10159                }
10160                align: 0.0 0.5;
10161             }
10162             description { state: "icononly" 0.0;
10163                inherit: "default" 0.0;
10164             }
10165          }
10166          part { name: "padding_after_icon";
10167             type: RECT;
10168             scale: 1;
10169             mouse_events: 0;
10170             description { state: "default" 0.0; //when only icon or no icon is there
10171                align: 0.0 0.0;
10172                rel1 {
10173                   relative: 1.0 0.0;
10174                   to: "icon_rect";
10175                }
10176                rel2.to: "icon_rect";
10177                fixed: 1 0;
10178                min: 0 0;
10179                visible: 0;
10180             }
10181             description { state: "visible" 0.0;
10182                visible: 0;
10183                align: 0.0 0.0;
10184                rel1 {
10185                   relative: 1.0 0.0;
10186                   to: "icon_rect";
10187                }
10188                rel2.to: "icon_rect";
10189                fixed: 1 0;
10190                min: BUTTON_NAVIFRAME_TITLE_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
10191             }
10192             description { state: "icononly" 0.0;
10193                inherit: "default" 0.0;
10194             }
10195          }
10196          part { name: "padding_before_text";
10197             type: RECT;
10198             scale: 1;
10199             mouse_events: 0;
10200             description { state: "default" 0.0; //when only icon or no icon is there
10201                align: 1.0 0.5;
10202                rel1 {
10203                   relative: 0.0 1.0;
10204                   to_x: "elm.text";
10205                   to_y: "padding_left_top";
10206                }
10207                rel2 {
10208                   relative: 0.0 0.0;
10209                   to_x: "elm.text";
10210                   to_y: "padding_right_bottom";
10211                }
10212                fixed: 1 0;
10213                min: BUTTON_NAVIFRAME_TITLE_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
10214                visible: 0;
10215             }
10216          }
10217          part { name: "elm.swallow.content";
10218             type: SWALLOW;
10219             scale: 1;
10220             clip_to: "clipper";
10221             description { state: "default" 0.0;
10222                visible: 0;
10223                align: 0.0 0.5;
10224                rel1 {
10225                   relative: 1.0 1.0;
10226                   to: "padding_left_top";
10227                }
10228                rel2 {
10229                   relative: 1.0 0.0;
10230                   to_x: "padding_left_top";
10231                   to_y: "padding_right_bottom";
10232                }
10233                fixed: 1 0;
10234             }
10235             description { state: "visible" 0.0;
10236                fixed: 1 0;
10237                min: BUTTON_NAVIFRAME_TITLE_VISIBLE_ICON_RECT_MIN_MAX_INC;
10238                max: BUTTON_NAVIFRAME_TITLE_VISIBLE_ICON_RECT_MIN_MAX_INC;
10239                align: 1.0 0.5;
10240                rel1 {
10241                   relative: 0.0 1.0;
10242                   to_x: "padding_before_text";
10243                   to_y: "padding_left_top";
10244                }
10245                rel2 {
10246                   relative: 0.0 0.0;
10247                   to_x: "padding_before_text";
10248                   to_y: "padding_right_bottom";
10249                }
10250             }
10251             description { state: "icononly" 0.0;
10252                min: BUTTON_NAVIFRAME_TITLE_ICONONLY_ICON_MIN_MAX_INC;
10253                max: BUTTON_NAVIFRAME_TITLE_ICONONLY_ICON_MIN_MAX_INC;
10254             }
10255          }
10256          part { name: "elm.text";
10257             type: TEXTBLOCK;
10258             mouse_events: 0;
10259             scale: 1;
10260             clip_to: "clipper";
10261             description { state: "default" 0.0;
10262                visible: 0;
10263                rel1 {
10264                   relative: 1.0 1.0;
10265                   to_x: "padding_after_icon";
10266                   to_y: "padding_left_top";
10267                }
10268                rel2 {
10269                   relative: 0.0 0.0;
10270                   to: "padding_right_bottom";
10271                }
10272                color: BUTTON_NAVIFRAME_TITLE_TEXT_NORMAL_COLOR_INC;
10273                text {
10274                    style: "btn_naviframe_style";
10275                    min: 0 0;
10276                    max: 0 1;
10277                }
10278             }
10279             description { state: "visible" 0.0;
10280                inherit: "default" 0.0;
10281                visible: 1;
10282             }
10283             description { state: "clicked" 0.0;
10284                inherit: "default" 0.0;
10285                visible: 1;
10286                color: BUTTON_NAVIFRAME_TITLE_TEXT_PRESSED_COLOR_INC;
10287             }
10288             description { state: "disabled" 0.0;
10289                inherit: "default" 0.0;
10290                color: 0 0 0 128;
10291             }
10292             description { state: "disabled_visible" 0.0;
10293                inherit: "default" 0.0;
10294                color: BUTTON_NAVIFRAME_TITLE_TEXT_DISABLED_COLOR_INC;
10295                visible: 1;
10296             }
10297             description { state: "focused" 0.0;
10298                inherit: "default" 0.0;
10299                visible: 1;
10300                color: BUTTON_NAVIFRAME_TITLE_TEXT_FOCUSED_COLOR_INC;
10301             }
10302          }
10303          part { name: "over2";
10304             type: RECT;
10305             repeat_events: 1;
10306             ignore_flags: ON_HOLD;
10307             description { state: "default" 0.0;
10308                color: 0 0 0 0;
10309             }
10310          }
10311          part { name: "over3";
10312             type: RECT;
10313             repeat_events: 1;
10314             description { state: "default" 0.0;
10315                color: 0 0 0 0;
10316             }
10317          }
10318          part { name: "clipper";
10319             type: RECT;
10320             description { state: "default" 0.0;
10321                color: 255 255 255 255;
10322             }
10323          }
10324          part { name: "disabler";
10325             type: RECT;
10326             description { state: "default" 0.0;
10327                color: 0 0 0 0;
10328                visible: 0;
10329             }
10330             description { state: "disabled" 0.0;
10331                inherit: "default" 0.0;
10332                visible: 1;
10333             }
10334          }
10335       }
10336       programs {
10337          program { name: "button_click";
10338             signal: "mouse,down,1";
10339             source: "over2";
10340             action: SIGNAL_EMIT "elm,action,press" "";
10341             after: "button_click_anim";
10342          }
10343          program { name: "button_click_anim";
10344             action: STATE_SET "clicked" 0.0;
10345             target: "button_image";
10346             after: "text_clicked";
10347          }
10348          program { name: "text_clicked";
10349             script {
10350                new st[31];
10351                new Float:vl;
10352                get_state(PART:"elm.text", st, 30, vl);
10353                if (!strcmp(st, "visible"))
10354                  set_state(PART:"elm.text", "clicked", 0.0);
10355             }
10356          }
10357          program { name: "button_unpress";
10358             action: SIGNAL_EMIT "elm,action,unpress" "";
10359          }
10360          program { name: "button_mouseout_clicked";
10361             signal: "mouse,up,1";
10362             source: "over3";
10363             script {
10364                new st[31];
10365                new Float:vl;
10366                get_state(PART:"elm.swallow.content", st, 30, vl);
10367                if (strcmp(st, "icononly"))
10368                  {
10369                     emit("elm,action,default,text,set", "");
10370                     set_state(PART:"elm.text", "visible", 0.0);
10371                  }
10372                if (get_int(button_state) != BUTTON_STATE_DISABLED)
10373                  set_state(PART:"button_image", "default", 0.0);
10374             }
10375             after: button_unpress;
10376          }
10377          program { name: "touch_snd";
10378             signal: "mouse,clicked,1";
10379             source: "over2";
10380             action: PLAY_SAMPLE "touch_sound" 1.0;
10381             after: button_unclick3;
10382          }
10383          program { name: "button_unclick3";
10384             action: SIGNAL_EMIT "elm,action,click" "";
10385          }
10386          program { name: "text_show";
10387             signal: "elm,state,text,visible";
10388             source: "elm";
10389             script {
10390                new st[31];
10391                new Float:vl;
10392                get_state(PART:"elm.swallow.content", st, 30, vl);
10393                if (!strcmp(st, "icononly"))
10394                  {
10395                     set_state(PART:"elm.swallow.content", "visible", 0.0);
10396                     set_state(PART:"icon_rect", "visible", 0.0);
10397                     set_state(PART:"padding_after_icon", "visible", 0.0);
10398                  }
10399                if (get_int(button_state) != BUTTON_STATE_DISABLED)
10400                  set_state(PART:"elm.text", "visible", 0.0);
10401                else
10402                  set_state(PART:"elm.text", "disabled_visible", 0.0);
10403             }
10404          }
10405          program { name: "text_hide";
10406             signal: "elm,state,text,hidden";
10407             source: "elm";
10408             script {
10409                new st[31];
10410                new Float:vl;
10411                get_state(PART:"elm.swallow.content", st, 30, vl);
10412                if (!strcmp(st, "visible"))
10413                  {
10414                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
10415                     set_state(PART:"icon_rect", "icononly", 0.0);
10416                     set_state(PART:"padding_after_icon", "icononly", 0.0);
10417                  }
10418                set_state(PART:"elm.text", "default", 0.0);
10419             }
10420          }
10421          program { name: "icon_show";
10422             signal: "elm,state,icon,visible";
10423             source: "elm";
10424             script {
10425                new st[31];
10426                new Float:vl;
10427                get_state(PART:"elm.text", st, 30, vl);
10428                if (!strcmp(st, "visible"))
10429                  {
10430                     set_state(PART:"elm.swallow.content", "visible", 0.0);
10431                     set_state(PART:"icon_rect", "visible", 0.0);
10432                     set_state(PART:"padding_after_icon", "visible", 0.0);
10433                  }
10434                else
10435                  {
10436                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
10437                     set_state(PART:"icon_rect", "icononly", 0.0);
10438                     set_state(PART:"padding_after_icon", "icononly", 0.0);
10439                  }
10440             }
10441          }
10442          program { name: "icon_hide";
10443             signal: "elm,state,icon,hidden";
10444             source: "elm";
10445             action: STATE_SET "default" 0.0;
10446             target: "elm.swallow.content";
10447             target: "padding_after_icon";
10448             target: "icon_rect";
10449          }
10450          program { name: "disable";
10451             signal: "elm,state,disabled";
10452             source: "elm";
10453             action: STATE_SET "disabled" 0.0;
10454             target: "button_image";
10455             target: "disabler";
10456             after: "disable_text";
10457          }
10458          program { name: "disable_text";
10459             script {
10460                new st[31];
10461                new Float:vl;
10462                get_state(PART:"elm.text", st, 30, vl);
10463                if (!strcmp(st, "visible"))
10464                  set_state(PART:"elm.text", "disabled_visible", 0.0);
10465                else
10466                  set_state(PART:"elm.text", "disabled", 0.0);
10467                set_int(button_state, BUTTON_STATE_DISABLED);
10468             }
10469          }
10470          program { name: "enable";
10471             signal: "elm,state,enabled";
10472             source: "elm";
10473             action: STATE_SET "default" 0.0;
10474             target: "button_image";
10475             target: "disabler";
10476             after: "enable_text";
10477          }
10478          program { name: "enable_text";
10479             script {
10480                new st[31];
10481                new Float:vl;
10482                get_state(PART:"elm.text", st, 30, vl);
10483                if (!strcmp(st, "disabled_visible"))
10484                  set_state(PART:"elm.text", "visible", 0.0);
10485                else
10486                  set_state(PART:"elm.text", "default", 0.0);
10487                set_int(button_state, BUTTON_STATE_ENABLED);
10488             }
10489          }
10490          program { name: "focused";
10491             //signal: "elm,action,focus";
10492             //source: "elm";
10493             action: STATE_SET "focused" 0.0;
10494             target: "button_image";
10495             target: "elm.text";
10496          }
10497          program { name: "unfocused";
10498             //signal: "elm,action,unfocus";
10499             //source: "elm";
10500             action: STATE_SET "default" 0.0;
10501             target: "button_image";
10502             after: "unfocus_text";
10503          }
10504          program { name: "unfocus_text";
10505             action: STATE_SET "visible" 0.0;
10506             target: "elm.text";
10507          }
10508       }
10509    }
10510
10511 ///////////////////////////////////////////////////////////////////////////////////////
10512 #define BUTTON_NAVIFRAME_TITLE_ICON_STYLES(style_name, image_normal, image_press, min_width, min_height) \
10513    group { name: "elm/button/base/naviframe/title/icon/"style_name; \
10514       images { \
10515          image: image_normal COMP; \
10516          image: image_press COMP; \
10517          image: "00_title_btn_bg_press.png" COMP; \
10518       } \
10519       parts { \
10520          part { name: "button_image"; \
10521             scale: 1; \
10522             description { state: "default" 0.0; \
10523                min: BUTTON_NAVIFRAME_TITLE_ICON_BG_NORMAL_MIN_INC; \
10524                max: BUTTON_NAVIFRAME_TITLE_ICON_BG_NORMAL_MIN_INC; \
10525                color: 0 0 0 0; \
10526             } \
10527             description { \
10528                state: "clicked" 0.0; \
10529                min: BUTTON_NAVIFRAME_TITLE_ICON_BG_PRESSED_MIN_INC; \
10530                max: BUTTON_NAVIFRAME_TITLE_ICON_BG_PRESSED_MIN_INC; \
10531                image { \
10532                   normal: "00_title_btn_bg_press.png"; \
10533                   border: BUTTON_NAVIFRAME_TITLE_ICON_BG_PRESSED_BORDER_INC; \
10534                   border_scale: 1; \
10535                } \
10536             } \
10537             description { \
10538                state: "disabled" 0.0; \
10539                inherit: "default" 0.0; \
10540             } \
10541             description { state: "focused" 0.0; \
10542                inherit: "default" 0.0;\
10543             } \
10544          } \
10545          part { name: "icon_part"; \
10546             scale: 1; \
10547             description { state: "default" 0.0; \
10548                min: min_width min_height; \
10549                max: min_width min_height; \
10550                rel1.to: "button_image"; \
10551                rel2.to: "button_image"; \
10552                image.normal: image_normal; \
10553             } \
10554             description { \
10555                state: "clicked" 0.0; \
10556                inherit: "default" 0.0; \
10557                image.normal: image_press; \
10558             } \
10559             description { \
10560                state: "disabled" 0.0; \
10561                inherit: "default" 0.0; \
10562                color: 127 127 127 127; \
10563             } \
10564          } \
10565          part { name: "over1"; \
10566             type: RECT; \
10567             ignore_flags: ON_HOLD; \
10568             description { state: "default" 0.0; \
10569                color: 0 0 0 0; \
10570             } \
10571          } \
10572          part { name: "over2"; \
10573             repeat_events: 1; \
10574             description { state: "default" 0.0; \
10575                color: 0 0 0 0; \
10576             } \
10577          } \
10578          part { name: "disabler"; \
10579             type: RECT; \
10580             description { state: "default" 0.0; \
10581                color: 0 0 0 0; \
10582                visible: 0; \
10583             } \
10584             description { state: "disabled" 0.0; \
10585                inherit: "default" 0.0; \
10586                visible: 1; \
10587             } \
10588          } \
10589       } \
10590       programs { \
10591          program { name: "button_click"; \
10592             signal: "mouse,down,1"; \
10593             source: "over1"; \
10594             action: SIGNAL_EMIT "elm,action,press" ""; \
10595             after: "button_click_anim"; \
10596          } \
10597          program { name: "button_click_anim"; \
10598             action: STATE_SET "clicked" 0.0; \
10599             target: "button_image"; \
10600             target: "icon_part"; \
10601          } \
10602          program { name: "button_unclick"; \
10603             signal: "mouse,up,1"; \
10604             source: "over2"; \
10605             action: SIGNAL_EMIT "elm,action,unpress" ""; \
10606             after: "button_unclick_anim"; \
10607          } \
10608          program { name: "button_unclick_anim"; \
10609             action: STATE_SET "default" 0.0; \
10610             target: "button_image"; \
10611             target: "icon_part"; \
10612          } \
10613          program { name: "touch_snd"; \
10614             signal: "mouse,clicked,1"; \
10615             source: "over1"; \
10616             action: PLAY_SAMPLE "touch_sound" 1.0; \
10617             after: button_unclick3; \
10618          } \
10619          program { name: "button_unclick3"; \
10620             action: SIGNAL_EMIT "elm,action,click" ""; \
10621          } \
10622          program { name: "disable"; \
10623             signal: "elm,state,disabled"; \
10624             source: "elm"; \
10625             action: STATE_SET "disabled" 0.0; \
10626             target: "disabler"; \
10627             target: "button_image"; \
10628             target: "icon_part"; \
10629          } \
10630          program { name: "enable"; \
10631             signal: "elm,state,enabled"; \
10632             source: "elm"; \
10633             action: STATE_SET "default" 0.0; \
10634             target: "disabler"; \
10635             target: "button_image"; \
10636             target: "icon_part"; \
10637          } \
10638       } \
10639    }
10640 ///////////////////////////////////////////////////////////////////////////////////////
10641    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)
10642
10643    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)
10644
10645    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)
10646
10647    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)
10648
10649    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)
10650
10651 /////////////////////////////////////////////////////////////////////////////////////////
10652    group { name: "elm/button/base/naviframe/more/default";
10653       images {
10654          image: "00_winset_more.png" COMP;
10655          image: "00_winset_more_press.png" COMP;
10656          image: "00_title_btn_bg_press.png" COMP;
10657       }
10658       parts {
10659          part { name: "button_image";
10660             scale: 1;
10661             description { state: "default" 0.0;
10662                min: BUTTON_NAVIFRAME_MORE_BG_MIN_MAX_INC;
10663                max: BUTTON_NAVIFRAME_MORE_BG_MIN_MAX_INC;
10664                color: 0 0 0 0;
10665             }
10666             description { state: "clicked" 0.0;
10667                min: BUTTON_NAVIFRAME_MORE_BG_PRESSED_MIN_MAX_INC;
10668                max: BUTTON_NAVIFRAME_MORE_BG_PRESSED_MIN_MAX_INC;
10669                image {
10670                   normal: "00_title_btn_bg_press.png";
10671                   border: BUTTON_NAVIFRAME_MORE_BG_PRESSED_BORDER_INC;
10672                   border_scale: 1;
10673                }
10674             }
10675             description { state: "disabled" 0.0;
10676                inherit: "default" 0.0;
10677             }
10678             description { state: "focused" 0.0;
10679                inherit: "default" 0.0;
10680             }
10681          }
10682          part { name: "more_image";
10683             scale: 1;
10684             mouse_events: 0;
10685             description { state: "default" 0.0;
10686                min: BUTTON_NAVIFRAME_MORE_DEFAULT_IMAGE_MIN_MAX_INC;
10687                max: BUTTON_NAVIFRAME_MORE_DEFAULT_IMAGE_MIN_MAX_INC;
10688                rel1.to: "button_image";
10689                rel2.to: "button_image";
10690                image.normal: "00_winset_more.png";
10691             }
10692             description { state: "clicked" 0.0;
10693                inherit: "default" 0.0;
10694                image.normal: "00_winset_more_press.png";
10695             }
10696             description { state: "disabled" 0.0;
10697                inherit: "default" 0.0;
10698                color: 255 255 255 127;
10699             }
10700          }
10701          part { name: "over2";
10702             type: RECT;
10703             repeat_events: 1;
10704             ignore_flags: ON_HOLD;
10705             description { state: "default" 0.0;
10706                color: 0 0 0 0;
10707             }
10708          }
10709          part { name: "over3";
10710             type: RECT;
10711             repeat_events: 1;
10712             description { state: "default" 0.0;
10713                color: 0 0 0 0;
10714             }
10715          }
10716          part { name: "disabler";
10717             type: RECT;
10718             description { state: "default" 0.0;
10719                color: 0 0 0 0;
10720                visible: 0;
10721             }
10722             description { state: "disabled" 0.0;
10723                inherit: "default" 0.0;
10724                visible: 1;
10725             }
10726          }
10727       }
10728       programs {
10729          program { name: "button_click";
10730             signal: "mouse,down,1";
10731             source: "over2";
10732             action: SIGNAL_EMIT "elm,action,press" "";
10733             after: "button_click_anim";
10734          }
10735          program { name: "button_click_anim";
10736             action: STATE_SET "clicked" 0.0;
10737             target: "button_image";
10738             target: "more_image";
10739          }
10740          program { name: "button_unclick";
10741             signal: "mouse,up,1";
10742             source: "over3";
10743             action: SIGNAL_EMIT "elm,action,unpress" "";
10744             after: "button_unclick_anim";
10745          }
10746          program { name: "button_unclick_anim";
10747             action: STATE_SET "default" 0.0;
10748             target: "button_image";
10749             target: "more_image";
10750          }
10751          program { name: "touch_snd";
10752             signal: "mouse,clicked,1";
10753             source: "over2";
10754             action: PLAY_SAMPLE "touch_sound" 1.0;
10755             after: button_unclick3;
10756          }
10757          program { name: "button_unclick3";
10758             action: SIGNAL_EMIT "elm,action,click" "";
10759          }
10760          program { name: "disable";
10761             signal: "elm,state,disabled";
10762             source: "elm";
10763             action: STATE_SET "disabled" 0.0;
10764             target: "disabler";
10765             target: "button_image";
10766             target: "more_image";
10767          }
10768          program { name: "enable";
10769             signal: "elm,state,enabled";
10770             source: "elm";
10771             action: STATE_SET "default" 0.0;
10772             target: "disabler";
10773             target: "button_image";
10774             target: "more_image";
10775          }
10776       }
10777    }
10778
10779 ///////////////////////////////////////////////////////////////////////////////////////
10780    group { name: "elm/button/base/tickernoti";
10781       images {
10782          image: "00_button_06_normal.png" COMP;
10783          image: "00_button_06_press.png" COMP;
10784          image: "00_button_06_dim.png" COMP;
10785          image: "00_button_06_normal_focus.png" COMP;
10786       }
10787       script {
10788          public button_state = BUTTON_STATE_ENABLED;
10789       }
10790       parts {
10791          part { name: "button_image";
10792             scale: 1;
10793             description { state: "default" 0.0;
10794                image {
10795                   normal: "00_button_06_normal.png";
10796                   border: BUTTON_TICKERNOTI_BG_BORDER_INC;
10797                   border_scale: 1;
10798                }
10799             }
10800             description { state: "clicked" 0.0;
10801                inherit: "default" 0.0;
10802                image.normal: "00_button_06_press.png";
10803             }
10804             description { state: "disabled" 0.0;
10805                inherit: "default" 0.0;
10806                image.normal: "00_button_06_dim.png";
10807             }
10808             description { state: "focused" 0.0;
10809                inherit: "default" 0.0;
10810                image.normal: "00_button_06_normal_focus.png";
10811             }
10812          }
10813          part { name: "padding_left_top";
10814             type: RECT;
10815             scale: 1;
10816             mouse_events: 0;
10817             description { state: "default" 0.0;
10818                align: 0.0 0.0;
10819                rel2.relative: 0.0 0.0;
10820                min: BUTTON_TICKERNOTI_PADDING_MIN_INC;
10821                fixed: 1 1;
10822                visible: 0;
10823             }
10824          }
10825          part { name: "bg";
10826             type: RECT;
10827             scale: 1;
10828             mouse_events: 0;
10829             description { state: "default" 0.0;
10830                min: BUTTON_TICKERNOTI_BG_MIN_INC;
10831                visible: 0;
10832             }
10833             description { state: "visible" 0.0;
10834                inherit: "default" 0.0;
10835                min: BUTTON_TICKERNOTI_VISIBLE_BG_MIN_INC;
10836             }
10837             description { state: "icononly" 0.0;
10838                inherit: "default" 0.0;
10839                min: BUTTON_TICKERNOTI_ICONONLY_BG_MIN_INC;
10840             }
10841          }
10842          part { name: "padding_right_bottom";
10843             type: RECT;
10844             scale: 1;
10845             mouse_events: 0;
10846             description { state: "default" 0.0;
10847                align: 1.0 1.0;
10848                rel1.relative: 1.0 1.0;
10849                min: BUTTON_TICKERNOTI_PADDING_MIN_INC;
10850                fixed: 1 1;
10851                visible: 0;
10852             }
10853          }
10854          part { name: "icon_rect";
10855             type: RECT;
10856             scale: 1;
10857             mouse_events: 0;
10858             description { state: "default" 0.0;
10859                visible: 0;
10860                min: 0 0;
10861                fixed: 1 0;
10862                rel1 {
10863                   relative: 1.0 1.0;
10864                   to: "padding_left_top";
10865                }
10866                rel2 {
10867                   relative: 1.0 0.0;
10868                   to_x: "padding_left_top";
10869                   to_y: "padding_right_bottom";
10870                }
10871                align: 0.0 0.5;
10872             }
10873             description { state: "visible" 0.0;
10874                visible: 0;
10875                min: BUTTON_TICKERNOTI_VISIBLE_ICON_RECT_MIN_MAX_INC;
10876                max: BUTTON_TICKERNOTI_VISIBLE_ICON_RECT_MIN_MAX_INC;
10877                fixed: 1 0;
10878                rel1 {
10879                   relative: 1.0 1.0;
10880                   to: "padding_left_top";
10881                }
10882                rel2 {
10883                   relative: 1.0 0.0;
10884                   to_x: "padding_left_top";
10885                   to_y: "padding_right_bottom";
10886                }
10887                align: 0.0 0.5;
10888             }
10889             description { state: "icononly" 0.0;
10890                inherit: "default" 0.0;
10891             }
10892          }
10893          part { name: "padding_after_icon";
10894             type: RECT;
10895             scale: 1;
10896             mouse_events: 0;
10897             description { state: "default" 0.0; //when only icon or no icon is there
10898                align: 0.0 0.0;
10899                rel1 {
10900                   relative: 1.0 0.0;
10901                   to: "icon_rect";
10902                }
10903                rel2.to: "icon_rect";
10904                fixed: 1 0;
10905                min: 0 0;
10906                visible: 0;
10907             }
10908             description { state: "visible" 0.0;
10909                visible: 0;
10910                align: 0.0 0.0;
10911                rel1 {
10912                   relative: 1.0 0.0;
10913                   to: "icon_rect";
10914                }
10915                rel2.to: "icon_rect";
10916                fixed: 1 0;
10917                min: BUTTON_TICKERNOTI_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
10918             }
10919             description { state: "icononly" 0.0;
10920                inherit: "default" 0.0;
10921             }
10922          }
10923          part { name: "padding_before_text";
10924             type: RECT;
10925             scale: 1;
10926             mouse_events: 0;
10927             description { state: "default" 0.0; //when only icon or no icon is there
10928                align: 1.0 0.5;
10929                rel1 {
10930                   relative: 0.0 1.0;
10931                   to_x: "elm.text";
10932                   to_y: "padding_left_top";
10933                }
10934                rel2 {
10935                   relative: 0.0 0.0;
10936                   to_x: "elm.text";
10937                   to_y: "padding_right_bottom";
10938                }
10939                fixed: 1 0;
10940                min: BUTTON_TICKERNOTI_VISIBLE_PADDING_ICON_TEXT_MIN_INC;
10941                visible: 0;
10942             }
10943          }
10944          part { name: "elm.swallow.content";
10945             type: SWALLOW;
10946             scale: 1;
10947             clip_to: "clipper";
10948             description { state: "default" 0.0;
10949                visible: 0;
10950                align: 0.0 0.5;
10951                rel1 {
10952                   relative: 1.0 1.0;
10953                   to: "padding_left_top";
10954                }
10955                rel2 {
10956                   relative: 1.0 0.0;
10957                   to_x: "padding_left_top";
10958                   to_y: "padding_right_bottom";
10959                }
10960                fixed: 1 0;
10961             }
10962             description { state: "visible" 0.0;
10963                fixed: 1 0;
10964                min: BUTTON_TICKERNOTI_VISIBLE_ICON_MIN_MAX_INC;
10965                max: BUTTON_TICKERNOTI_VISIBLE_ICON_MIN_MAX_INC;
10966                align: 1.0 0.5;
10967                rel1 {
10968                   relative: 0.0 1.0;
10969                   to_x: "padding_before_text";
10970                   to_y: "padding_left_top";
10971                }
10972                rel2 {
10973                   relative: 0.0 0.0;
10974                   to_x: "padding_before_text";
10975                   to_y: "padding_right_bottom";
10976                }
10977             }
10978             description { state: "icononly" 0.0;
10979                min: BUTTON_TICKERNOTI_ICONONLY_ICON_MIN_MAX_INC;
10980                max: BUTTON_TICKERNOTI_ICONONLY_ICON_MIN_MAX_INC;
10981             }
10982          }
10983          part { name: "elm.text";
10984             type: TEXT;
10985             mouse_events: 0;
10986             scale: 1;
10987             clip_to: "clipper";
10988             description { state: "default" 0.0;
10989                visible: 0;
10990                rel1 {
10991                   relative: 1.0 1.0;
10992                   to_x: "padding_after_icon";
10993                   to_y: "padding_left_top";
10994                }
10995                rel2 {
10996                   relative: 0.0 0.0;
10997                   to: "padding_right_bottom";
10998                }
10999                color: BUTTON_TICKERNOTI_NORMAL_COLOR_INC;
11000                text {
11001                   font: "SLP:style=Medium";
11002                   size: BUTTON_TICKERNOTI_FONT_SIZE_INC;
11003                   min: 1 0;
11004                   max: 1 0;
11005                   text_class: "slp_medium";
11006                }
11007             }
11008             description { state: "visible" 0.0;
11009                inherit: "default" 0.0;
11010                visible: 1;
11011             }
11012             description { state: "clicked" 0.0;
11013                inherit: "default" 0.0;
11014                visible: 1;
11015                color: BUTTON_TICKERNOTI_PRESSED_COLOR_INC;
11016             }
11017             description { state: "disabled" 0.0;
11018                inherit: "default" 0.0;
11019                color: 0 0 0 128;
11020             }
11021             description { state: "disabled_visible" 0.0;
11022                inherit: "default" 0.0;
11023                color: BUTTON_TICKERNOTI_DISABLED_COLOR_INC;
11024                visible: 1;
11025             }
11026             description { state: "focused" 0.0;
11027                inherit: "default" 0.0;
11028                visible: 1;
11029                color: BUTTON_TICKERNOTI_PRESSED_COLOR_INC;
11030             }
11031          }
11032          part { name: "over2";
11033             type: RECT;
11034             repeat_events: 1;
11035             ignore_flags: ON_HOLD;
11036             description { state: "default" 0.0;
11037                color: 0 0 0 0;
11038             }
11039          }
11040          part { name: "over3";
11041             type: RECT;
11042             repeat_events: 1;
11043             description { state: "default" 0.0;
11044                color: 0 0 0 0;
11045             }
11046          }
11047          part { name: "clipper";
11048             type: RECT;
11049             description { state: "default" 0.0;
11050                color: 255 255 255 255;
11051             }
11052          }
11053          part { name: "disabler";
11054             type: RECT;
11055             description { state: "default" 0.0;
11056                color: 0 0 0 0;
11057                visible: 0;
11058             }
11059             description { state: "disabled" 0.0;
11060                inherit: "default" 0.0;
11061                visible: 1;
11062             }
11063          }
11064       }
11065       programs {
11066          program { name: "button_click";
11067             signal: "mouse,down,1";
11068             source: "over2";
11069             action: SIGNAL_EMIT "elm,action,press" "";
11070             after: "button_click_anim";
11071          }
11072          program { name: "button_click_anim";
11073             action: STATE_SET "clicked" 0.0;
11074             target: "button_image";
11075             after: "text_clicked";
11076          }
11077          program { name: "text_clicked";
11078             script {
11079                new st[31];
11080                new Float:vl;
11081                get_state(PART:"elm.text", st, 30, vl);
11082                if (!strcmp(st, "visible"))
11083                  set_state(PART:"elm.text", "clicked", 0.0);
11084             }
11085          }
11086          program { name: "button_unpress";
11087             action: SIGNAL_EMIT "elm,action,unpress" "";
11088          }
11089          program { name: "button_mouseout_clicked";
11090             signal: "mouse,up,1";
11091             source: "over3";
11092             script {
11093                new st[31];
11094                new Float:vl;
11095                get_state(PART:"elm.swallow.content", st, 30, vl);
11096                if (strcmp(st, "icononly"))
11097                  {
11098                     emit("elm,action,default,text,set", "");
11099                     set_state(PART:"elm.text", "visible", 0.0);
11100                  }
11101                if (get_int(button_state) != BUTTON_STATE_DISABLED)
11102                  set_state(PART:"button_image", "default", 0.0);
11103             }
11104             after: button_unpress;
11105          }
11106          program { name: "touch_snd";
11107             signal: "mouse,clicked,1";
11108             source: "over2";
11109             action: PLAY_SAMPLE "touch_sound" 1.0;
11110             after: button_unclick3;
11111          }
11112          program { name: "button_unclick3";
11113             action: SIGNAL_EMIT "elm,action,click" "";
11114          }
11115          program { name: "text_show";
11116             signal: "elm,state,text,visible";
11117             source: "elm";
11118             script {
11119                new st[31];
11120                new Float:vl;
11121                get_state(PART:"elm.swallow.content", st, 30, vl);
11122                if (!strcmp(st, "icononly"))
11123                  {
11124                     set_state(PART:"elm.swallow.content", "visible", 0.0);
11125                     set_state(PART:"icon_rect", "visible", 0.0);
11126                     set_state(PART:"padding_after_icon", "visible", 0.0);
11127                     set_state(PART:"bg", "visible", 0.0);
11128                  }
11129                if (get_int(button_state) != BUTTON_STATE_DISABLED)
11130                  set_state(PART:"elm.text", "visible", 0.0);
11131                else
11132                  set_state(PART:"elm.text", "disabled_visible", 0.0);
11133             }
11134          }
11135          program { name: "text_hide";
11136             signal: "elm,state,text,hidden";
11137             source: "elm";
11138             script {
11139                new st[31];
11140                new Float:vl;
11141                get_state(PART:"elm.swallow.content", st, 30, vl);
11142                if (!strcmp(st, "visible"))
11143                  {
11144                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
11145                     set_state(PART:"icon_rect", "icononly", 0.0);
11146                     set_state(PART:"padding_after_icon", "icononly", 0.0);
11147                     set_state(PART:"bg", "icononly", 0.0);
11148                  }
11149                set_state(PART:"elm.text", "default", 0.0);
11150             }
11151          }
11152          program { name: "icon_show";
11153             signal: "elm,state,icon,visible";
11154             source: "elm";
11155             script {
11156                new st[31];
11157                new Float:vl;
11158                get_state(PART:"elm.text", st, 30, vl);
11159                if (!strcmp(st, "visible"))
11160                  {
11161                     set_state(PART:"elm.swallow.content", "visible", 0.0);
11162                     set_state(PART:"icon_rect", "visible", 0.0);
11163                     set_state(PART:"padding_after_icon", "visible", 0.0);
11164                     set_state(PART:"bg", "visible", 0.0);
11165                  }
11166                else
11167                  {
11168                     set_state(PART:"elm.swallow.content", "icononly", 0.0);
11169                     set_state(PART:"icon_rect", "icononly", 0.0);
11170                     set_state(PART:"padding_after_icon", "icononly", 0.0);
11171                     set_state(PART:"bg", "icononly", 0.0);
11172                  }
11173             }
11174          }
11175          program { name: "icon_hide";
11176             signal: "elm,state,icon,hidden";
11177             source: "elm";
11178             action: STATE_SET "default" 0.0;
11179             target: "elm.swallow.content";
11180             target: "padding_after_icon";
11181             target: "icon_rect";
11182             target: "bg";
11183          }
11184          program { name: "disable";
11185             signal: "elm,state,disabled";
11186             source: "elm";
11187             action: STATE_SET "disabled" 0.0;
11188             target: "button_image";
11189             target: "disabler";
11190             after: "disable_text";
11191          }
11192          program { name: "disable_text";
11193             script {
11194                new st[31];
11195                new Float:vl;
11196                get_state(PART:"elm.text", st, 30, vl);
11197                if (!strcmp(st, "visible"))
11198                  set_state(PART:"elm.text", "disabled_visible", 0.0);
11199                else
11200                  set_state(PART:"elm.text", "disabled", 0.0);
11201                set_int(button_state, BUTTON_STATE_DISABLED);
11202             }
11203          }
11204          program { name: "enable";
11205             signal: "elm,state,enabled";
11206             source: "elm";
11207             action: STATE_SET "default" 0.0;
11208             target: "button_image";
11209             target: "disabler";
11210             after: "enable_text";
11211          }
11212          program { name: "enable_text";
11213             script {
11214                new st[31];
11215                new Float:vl;
11216                get_state(PART:"elm.text", st, 30, vl);
11217                if (!strcmp(st, "disabled_visible"))
11218                  set_state(PART:"elm.text", "visible", 0.0);
11219                else
11220                  set_state(PART:"elm.text", "default", 0.0);
11221                set_int(button_state, BUTTON_STATE_ENABLED);
11222             }
11223          }
11224          program { name: "focused";
11225             //signal: "elm,action,focus";
11226             //source: "elm";
11227             action: STATE_SET "focused" 0.0;
11228             target: "button_image";
11229             target: "elm.text";
11230          }
11231          program { name: "unfocused";
11232             //signal: "elm,action,unfocus";
11233             //source: "elm";
11234             action: STATE_SET "default" 0.0;
11235             target: "button_image";
11236             after: "unfocus_text";
11237          }
11238          program { name: "unfocus_text";
11239             action: STATE_SET "visible" 0.0;
11240             target: "elm.text";
11241          }
11242       }
11243    }
11244
11245 ///////////////////////////////////////////////////////////////////////////////////////
11246    group { name: "elm/button/base/expandable_number";
11247       alias: "elm/button/base/text_only/expandable_number";
11248       images {
11249          image: "00_button_05_normal.png" COMP;
11250          image: "00_button_05_press.png" COMP;
11251          image: "00_button_05_dim.png" COMP;
11252          image: "00_button_05_normal_focus.png" COMP;
11253          image: "00_arrow_expand.png" COMP;
11254          image: "00_arrow_expand_press.png" COMP;
11255          image: "00_arrow_expand_dim.png" COMP;
11256       }
11257       script {
11258          public button_state = BUTTON_STATE_ENABLED;
11259       }
11260       parts {
11261          part { name: "button_image";
11262             scale: 1;
11263             description { state: "default" 0.0;
11264                min: BUTTON_EXPANDABLE_NUMBER_BG_NORMAL_MIN_MAX_INC;
11265                max: BUTTON_EXPANDABLE_NUMBER_BG_NORMAL_MIN_MAX_INC;
11266                image {
11267                   normal: "00_button_05_normal.png";
11268                   border: BUTTON_EXPANDABLE_NUMBER_BG_BORDER_INC;
11269                   border_scale: 1;
11270                }
11271             }
11272             description { state: "clicked" 0.0;
11273                inherit: "default" 0.0;
11274                image.normal: "00_button_05_press.png";
11275             }
11276             description { state: "disabled" 0.0;
11277                inherit: "default" 0.0;
11278                image.normal: "00_button_05_dim.png";
11279             }
11280             description { state: "focused" 0.0;
11281                inherit: "default" 0.0;
11282                image.normal: "00_button_05_normal_focus.png";
11283             }
11284          }
11285          part { name: "padding_left_top";
11286             type: RECT;
11287             scale: 1;
11288             mouse_events: 0;
11289             description { state: "default" 0.0;
11290                align: 0.0 0.0;
11291                rel2.relative: 0.0 0.0;
11292                min: BUTTON_EXPANDABLE_NUMBER_PADDING_MIN_INC;
11293                fixed: 1 1;
11294                visible: 0;
11295             }
11296          }
11297          part { name: "padding_right_bottom";
11298             type: RECT;
11299             scale: 1;
11300             mouse_events: 0;
11301             description { state: "default" 0.0;
11302                align: 1.0 1.0;
11303                rel1.relative: 1.0 1.0;
11304                min: BUTTON_EXPANDABLE_NUMBER_PADDING_MIN_INC;
11305                fixed: 1 1;
11306                visible: 0;
11307             }
11308          }
11309          part { name: "icon_rect";
11310             type: RECT;
11311             scale: 1;
11312             mouse_events: 0;
11313             description { state: "default" 0.0;
11314                visible: 0;
11315                min: BUTTON_EXPANDABLE_NUMBER_ICON_RECT_EXPAND__MIN_MAX_INC;
11316                max: BUTTON_EXPANDABLE_NUMBER_ICON_RECT_EXPAND__MIN_MAX_INC;
11317                fixed: 1 0;
11318                rel1 {
11319                   relative: 0.0 1.0;
11320                   to_x: "padding_right_bottom";
11321                   to_y: "padding_left_top";
11322                }
11323                rel2 {
11324                   relative: 0.0 0.0;
11325                   to: "padding_right_bottom";
11326                }
11327                align: 1.0 0.5;
11328                color: 0 0 0 0;
11329             }
11330          }
11331          part { name: "arrow_expand";
11332             scale: 1;
11333             mouse_events: 0;
11334             description { state: "default" 0.0;
11335                align: 0.0 0.5;
11336                min: BUTTON_EXPANDABLE_NUMBER_ICON_RECT_EXPAND__MIN_MAX_INC;
11337                max: BUTTON_EXPANDABLE_NUMBER_ICON_RECT_EXPAND__MIN_MAX_INC;
11338                fixed: 0 0;
11339                rel1.to: "icon_rect";
11340                rel2.to: "icon_rect";
11341                image.normal:"00_arrow_expand.png";
11342             }
11343             description { state: "clicked" 0.0;
11344                inherit: "default" 0.0;
11345                image.normal:"00_arrow_expand_press.png";
11346             }
11347             description { state: "disabled" 0.0;
11348                inherit: "default" 0.0;
11349                image.normal:"00_arrow_expand_dim.png";
11350             }
11351          }
11352          part { name: "elm.text";
11353             type: TEXT;
11354             mouse_events: 0;
11355             scale: 1;
11356             description { state: "default" 0.0;
11357                min: BUTTON_EXPANDABLE_NUMBER_TEXT_MIN_MAX_INC;
11358                max: BUTTON_EXPANDABLE_NUMBER_TEXT_MIN_MAX_INC;
11359                fixed:1 0;
11360                rel1 {
11361                   relative: 1.0 1.0;
11362                   to: "padding_left_top";
11363                }
11364                rel2 {
11365                   relative: 1.0 1.0;
11366                   to_x:"padding_left_top";
11367                   to_y:"padding_right_bottom";
11368                }
11369                align: 0.0 0.5;
11370                color: BUTTON_TEXT_STYLE1_NORMAL_COLOR_INC;
11371                text {
11372                   font: "SLP:style=Medium";
11373                   size: BUTTON_EXPANDABLE_NUMBER_FONT_SIZE_INC;
11374                   min: 0 0;
11375                   fit: 1 1;
11376                   size_range: 14 20;
11377                   text_class: "slp_medium";
11378                }
11379             }
11380             description { state: "visible" 0.0;
11381                inherit: "default" 0.0;
11382             }
11383             description { state: "clicked" 0.0;
11384                inherit: "default" 0.0;
11385                color: BUTTON_TEXT_STYLE1_PRESSED_COLOR_INC;
11386             }
11387             description { state: "disabled" 0.0;
11388                inherit: "default" 0.0;
11389                color: 0 0 0 128;
11390             }
11391             description { state: "disabled_visible" 0.0;
11392                inherit: "default" 0.0;
11393                color: BUTTON_TEXT_STYLE1_DISABLED_COLOR_INC;
11394             }
11395             description { state: "focused" 0.0;
11396                inherit: "default" 0.0;
11397                color: BUTTON_TEXT_STYLE1_FOCUSED_COLOR_INC;
11398             }
11399          }
11400          part { name: "over2";
11401             type: RECT;
11402             repeat_events: 1;
11403             ignore_flags: ON_HOLD;
11404             description { state: "default" 0.0;
11405                color: 0 0 0 0;
11406             }
11407          }
11408          part { name: "over3";
11409             type: RECT;
11410             repeat_events: 1;
11411             description { state: "default" 0.0;
11412                color: 0 0 0 0;
11413             }
11414          }
11415          part { name: "disabler";
11416             type: RECT;
11417             description { state: "default" 0.0;
11418                color: 0 0 0 0;
11419                visible: 0;
11420             }
11421             description { state: "disabled" 0.0;
11422                inherit: "default" 0.0;
11423                visible: 1;
11424             }
11425          }
11426       }
11427       programs {
11428          program { name: "button_click";
11429             signal: "mouse,down,1";
11430             source: "over2";
11431             action: SIGNAL_EMIT "elm,action,press" "";
11432             after: "button_click_anim";
11433          }
11434          program { name: "button_click_anim";
11435             action: STATE_SET "clicked" 0.0;
11436             target: "button_image";
11437             target: "arrow_expand";
11438             after: "text_clicked";
11439          }
11440          program { name: "text_clicked";
11441             script {
11442                new st[31];
11443                new Float:vl;
11444                get_state(PART:"elm.text", st, 30, vl);
11445                if (!strcmp(st, "visible"))
11446                  set_state(PART:"elm.text", "clicked", 0.0);
11447             }
11448          }
11449          program { name: "button_unpress";
11450             action: SIGNAL_EMIT "elm,action,unpress" "";
11451          }
11452          program { name: "button_mouseout_clicked";
11453             signal: "mouse,up,1";
11454             source: "over3";
11455             script {
11456                if (get_int(button_state) != BUTTON_STATE_DISABLED)
11457                  {
11458                     set_state(PART:"button_image", "default", 0.0);
11459                     set_state(PART:"elm.text", "visible", 0.0);
11460                     set_state(PART:"arrow_expand", "default", 0.0);
11461                  }
11462             }
11463             after: button_unpress;
11464          }
11465          program { name: "touch_snd";
11466             signal: "mouse,clicked,1";
11467             source: "over2";
11468             action: PLAY_SAMPLE "touch_sound" 1.0;
11469             after: button_unclick3;
11470          }
11471          program { name: "button_unclick3";
11472             action: SIGNAL_EMIT "elm,action,click" "";
11473          }
11474          program { name: "text_show";
11475             signal: "elm,state,text,visible";
11476             source: "elm";
11477             script {
11478                if (get_int(button_state) != BUTTON_STATE_DISABLED)
11479                  set_state(PART:"elm.text", "visible", 0.0);
11480                else
11481                  set_state(PART:"elm.text", "disabled_visible", 0.0);
11482             }
11483          }
11484          program { name: "text_hide";
11485             signal: "elm,state,text,hidden";
11486             source: "elm";
11487             script {
11488                set_state(PART:"elm.text", "default", 0.0);
11489             }
11490          }
11491          program { name: "disable";
11492             signal: "elm,state,disabled";
11493             source: "elm";
11494             action: STATE_SET "disabled" 0.0;
11495             target: "button_image";
11496             target: "disabler";
11497             after: "disable_text";
11498          }
11499          program { name: "disable_text";
11500             script {
11501                new st[31];
11502                new Float:vl;
11503                get_state(PART:"elm.text", st, 30, vl);
11504                if (!strcmp(st, "visible"))
11505                  set_state(PART:"elm.text", "disabled_visible", 0.0);
11506                else
11507                  set_state(PART:"elm.text", "disabled", 0.0);
11508                set_int(button_state, BUTTON_STATE_DISABLED);
11509             }
11510          }
11511          program { name: "enable";
11512             signal: "elm,state,enabled";
11513             source: "elm";
11514             action: STATE_SET "default" 0.0;
11515             target: "button_image";
11516             target: "disabler";
11517             after: "enable_text";
11518          }
11519          program { name: "enable_text";
11520             script {
11521                new st[31];
11522                new Float:vl;
11523                get_state(PART:"elm.text", st, 30, vl);
11524                if (!strcmp(st, "disabled_visible"))
11525                  set_state(PART:"elm.text", "visible", 0.0);
11526                else
11527                  set_state(PART:"elm.text", "default", 0.0);
11528                set_int(button_state, BUTTON_STATE_ENABLED);
11529             }
11530          }
11531          program { name: "focused";
11532             //signal: "elm,action,focus";
11533             //source: "elm";
11534             action: STATE_SET "focused" 0.0;
11535             target: "button_image";
11536             target: "elm.text";
11537          }
11538          program { name: "unfocused";
11539             //signal: "elm,action,unfocus";
11540             //source: "elm";
11541             action: STATE_SET "default" 0.0;
11542             target: "button_image";
11543             after: "unfocus_text";
11544          }
11545          program { name: "unfocus_text";
11546             action: STATE_SET "visible" 0.0;
11547             target: "elm.text";
11548          }
11549       }
11550    }
11551
11552 #undef BUTTON_STATE_ENABLED
11553 #undef BUTTON_STATE_DISABLED