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