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