04a6ce9b262dceb56287fa9e2be2c284bc0c7c87
[platform/core/uifw/efl-theme-tizen.git] / themes / widgets / datetime.edc
1 /*
2  * efl-theme-tizen
3  * Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
4  *
5  * Licensed under the Apache License, Version 2.0 (the License);
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  *     http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an AS IS BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  */
17
18
19 ///////////////////////////////////////////////////////////////////////////////
20 // datetime
21 ///////////////////////////////////////////////////////////////////////////////
22
23 #define DATETIME_FIELD(_pos, prev_part) \
24    part {\
25       name: "picker.padding"#_pos; \
26       type: RECT; \
27       scale: 1;\
28       clip_to: "clipper";\
29       description { state: "default" 0.0; \
30          color: 0 0 0 0;\
31          min: 0 0;\
32          align: 0.0 0.5;\
33          fixed: 1 0;\
34          rel1 {\
35             relative: 1.0 0.0;\
36             to: prev_part;\
37          }\
38          rel2 {\
39             relative: 1.0 1.0;\
40             to: prev_part;\
41          }\
42       }\
43       description { state: "enable" 0.0;\
44          inherit: "default" 0.0;\
45          min: DATETIME_FIELD_PICKER_PADDING_SIZE_INC;\
46       }\
47    }\
48    part {\
49       name: "field"#_pos".bg"; \
50       type: RECT; \
51       scale: 1;\
52       clip_to: "clipper";\
53       description { state: "default" 0.0; \
54          visible: 0;\
55          align: 0.0 0.5;\
56          fixed: 1 0;\
57          rel1 {\
58             relative: 0.0 0.0;\
59             to: "left.padding"#_pos;\
60          }\
61          rel2 {\
62             relative: 1.0 1.0;\
63             to: "right.padding"#_pos;\
64          }\
65          color: DATETIME_PICKER_BG_COLOR_INC;\
66       }\
67       description { state: "enable" 0.0;\
68          inherit: "default" 0.0;\
69          visible: 1;\
70       }\
71    }\
72    part {\
73       name: "left.padding"#_pos; \
74       type: RECT; \
75       scale: 1;\
76       clip_to: "clipper";\
77       description { state: "default" 0.0; \
78          color: 0 0 0 0;\
79          min: 0 0;\
80          align: 0.0 0.5;\
81          fixed: 1 0;\
82          rel1 {\
83             relative: 1.0 0.0;\
84             to: "picker.padding"#_pos;\
85          }\
86          rel2 {\
87             relative: 1.0 1.0;\
88             to: "picker.padding"#_pos;\
89          }\
90       }\
91       description { state: "enable" 0.0;\
92          inherit: "default" 0.0;\
93          min: DATETIME_FIELD_LEFT_PADDING_SIZE_INC;\
94       }\
95    }\
96    part {\
97       name: "field"#_pos; \
98       type: SWALLOW; \
99       scale: 1;\
100       clip_to: "clipper";\
101       repeat_events: 1;\
102       description { state: "default" 0.0; \
103          visible: 0;\
104          min: 0 0;\
105          align: 0.0 0.5;\
106          fixed: 1 0;\
107          rel1 {\
108             relative: 1.0 0.0;\
109             to: "left.padding"#_pos;\
110          }\
111          rel2 {\
112             relative: 1.0 1.0;\
113             to: "left.padding"#_pos;\
114          }\
115       }\
116       description { state: "enable" 0.0;\
117          inherit: "default" 0.0;\
118          visible: 1;\
119          min: DATETIME_FIELD_MIN_SIZE_INC;\
120       }\
121    }\
122    part {\
123       name: "separator"#_pos; \
124       type: TEXT;\
125       scale: 1;\
126       clip_to: "clipper";\
127       description {\
128          state: "default" 0.0;\
129          visible: 0;\
130          min: 0 0;\
131          align: 0.0 0.5;\
132          fixed: 1 0;\
133          rel1 {\
134             relative: 1.0 0.0;\
135             to: "field"#_pos;\
136          }\
137          rel2 {\
138             relative: 1.0 1.0;\
139             to: "field"#_pos;\
140          }\
141          color: DATETIME_SEPARATOR_TEXT_COLOR_INC;\
142          text {\
143             font: "Tizen:style=Regular";\
144             size: DATETIME_SEPARATOR_TEXT_FONT_SIZE_INC;\
145             min: 1 0; \
146             text_class: "tizen";\
147          }\
148       }\
149       description { state: "enable" 0.0;\
150          inherit: "default" 0.0;\
151          visible: 1;\
152          min: DATETIME_SEPARATOR_MIN_SIZE_INC;\
153       }\
154    }\
155    part {\
156       name: "right.padding"#_pos; \
157       type: RECT;\
158       scale: 1;\
159       clip_to: "clipper";\
160       description {\
161          state: "default" 0.0;\
162          color: 0 0 0 0;\
163          min: 0 0;\
164          align: 0.0 0.5;\
165          fixed: 1 0;\
166          rel1 {\
167             relative: 1.0 0.0;\
168             to: "separator"#_pos;\
169          }\
170          rel2 {\
171             relative: 1.0 1.0;\
172             to: "separator"#_pos;\
173          }\
174       }\
175       description { state: "enable" 0.0;\
176          inherit: "default" 0.0;\
177          visible: 1;\
178          min: DATETIME_FIELD_RIGHT_PADDING_SIZE_INC;\
179       }\
180    }\
181    programs{\
182       program {\
183          name: "field_"#_pos"enabled";\
184          signal: "field"#_pos",enable";\
185          source: "elm";\
186          action: STATE_SET "enable" 0.0;\
187          target: "field"#_pos;\
188          target: "left.padding"#_pos;\
189          target: "right.padding"#_pos;\
190          target: "field"#_pos".bg";\
191       }\
192       program {\
193          name: "field_"#_pos"disabled";\
194          signal: "field"#_pos",disable";\
195          source: "elm";\
196          action: STATE_SET "default" 0.0;\
197          target: "field"#_pos;\
198          target: "left.padding"#_pos;\
199          target: "right.padding"#_pos;\
200          target: "field"#_pos".bg";\
201       }\
202       program {\
203          name: "separator"#_pos",enabled";\
204          signal: "field"#_pos",separator,enable";\
205          source: "elm";\
206          action: STATE_SET "enable" 0.0;\
207          target: "separator"#_pos;\
208       }\
209       program {\
210          name: "separator"#_pos",disabled";\
211          signal: "field"#_pos",separator,disable";\
212          source: "elm";\
213          action: STATE_SET "default" 0.0;\
214          target: "separator"#_pos;\
215       }\
216    }
217
218 #define DATETIME_DATEPICKER_BG \
219    part {\
220       name: "date.picker.bg"; \
221       scale: 1;\
222       clip_to: "clipper";\
223       description { state: "default" 0.0; \
224          min: 0 0;\
225          visible: 0;\
226          fixed: 1 0;\
227          image {\
228             normal: "00_button_01.png";\
229             border: DATETIME_BG_IMAGE_BORDER_INC;\
230             border_scale: 1;\
231          }\
232          rel1 {\
233             relative: 0.0 0.0;\
234             to: "left.padding0";\
235          }\
236          rel2 {\
237             relative: 1.0 1.0;\
238             to: "right.padding2";\
239          }\
240       }\
241       description { state: "datefirst" 0.0;\
242          inherit: "default" 0.0;\
243          visible: 1;\
244       }\
245       description { state: "timefirst" 0.0;\
246          inherit: "default" 0.0;\
247          visible: 1;\
248          rel1 {\
249             relative: 0.0 0.0;\
250             to: "left.padding3";\
251          }\
252          rel2 {\
253             relative: 1.0 1.0;\
254             to: "right.padding5";\
255          }\
256       }\
257       description { state: "timefirst24hr" 0.0;\
258          inherit: "default" 0.0;\
259          visible: 1;\
260          rel1 {\
261             relative: 0.0 0.0;\
262             to: "left.padding2";\
263          }\
264          rel2 {\
265             relative: 1.0 1.0;\
266             to: "right.padding4";\
267          }\
268       }\
269    }\
270    programs{\
271       program {\
272          name: "datepicker_starting_field0";\
273          signal: "datepicker,starting,field0";\
274          source: "elm";\
275          action: STATE_SET "datefirst" 0.0;\
276          target: "date.picker.bg";\
277       }\
278       program {\
279          name: "datepicker_starting_field3";\
280          signal: "datepicker,starting,field3";\
281          source: "elm";\
282          action: STATE_SET "timefirst" 0.0;\
283          target: "date.picker.bg";\
284       }\
285       program {\
286          name: "datepicker_starting_field2";\
287          signal: "datepicker,starting,field3";\
288          source: "elm";\
289          action: STATE_SET "timefirst24hr" 0.0;\
290          target: "date.picker.bg";\
291       }\
292       program {\
293          name: "datepicker_starting_field1";\
294          signal: "datepicker,starting,field1";\
295          source: "elm";\
296          action: STATE_SET "default" 0.0;\
297          target: "date.picker.bg";\
298       }\
299       program {\
300          name: "datepicker_starting_field4";\
301          signal: "datepicker,starting,field4";\
302          source: "elm";\
303          action: STATE_SET "default" 0.0;\
304          target: "date.picker.bg";\
305       }\
306       program {\
307          name: "datepicker_starting_field5";\
308          signal: "datepicker,starting,field5";\
309          source: "elm";\
310          action: STATE_SET "default" 0.0;\
311          target: "date.picker.bg";\
312       }\
313    }
314
315 #define DATETIME_TIMEPICKER_BG \
316    part {\
317       name: "time.picker.bg"; \
318       scale: 1;\
319       clip_to: "clipper";\
320       description { state: "default" 0.0; \
321          min: 0 0;\
322          visible: 0;\
323          fixed: 1 0;\
324          image {\
325             normal: "00_button_01.png";\
326             border: DATETIME_BG_IMAGE_BORDER_INC;\
327             border_scale: 1;\
328          }\
329          rel1 {\
330             relative: 0.0 0.0;\
331             to: "left.padding3";\
332          }\
333          rel2 {\
334             relative: 1.0 1.0;\
335             to: "right.padding5";\
336          }\
337       }\
338       description { state: "datefirst" 0.0;\
339          inherit: "default" 0.0;\
340          visible: 1;\
341       }\
342       description { state: "timefirst" 0.0;\
343          inherit: "default" 0.0;\
344          visible: 1;\
345          rel1 {\
346             relative: 0.0 0.0;\
347             to: "left.padding0";\
348          }\
349          rel2 {\
350             relative: 1.0 1.0;\
351             to: "right.padding2";\
352          }\
353       }\
354       description { state: "timefirst24hr" 0.0;\
355          inherit: "default" 0.0;\
356          visible: 1;\
357          rel1 {\
358             relative: 0.0 0.0;\
359             to: "left.padding0";\
360          }\
361          rel2 {\
362             relative: 1.0 1.0;\
363             to: "right.padding1";\
364          }\
365       }\
366    }\
367    programs{\
368       program {\
369          name: "timepicker_starting_field3";\
370          signal: "timepicker,starting,field3";\
371          source: "elm";\
372          action: STATE_SET "datefirst" 0.0;\
373          target: "time.picker.bg";\
374       }\
375       program {\
376          name: "timepicker_starting_field0";\
377          signal: "timepicker,starting,field0";\
378          source: "elm";\
379          script {\
380             new st[31];\
381             new Float:vl;\
382             get_state(PART:"date.picker.bg", st, 30, vl);\
383             if (!strcmp(st, "timefirst24hr"))\
384               set_state(PART:"time.picker.bg", "timefirst24hr", 0.0);\
385             else\
386               set_state(PART:"time.picker.bg", "timefirst", 0.0);\
387          }\
388       }\
389       program {\
390          name: "timepicker_starting_field1";\
391          signal: "timepicker,starting,field1";\
392          source: "elm";\
393          action: STATE_SET "default" 0.0;\
394          target: "time.picker.bg";\
395       }\
396       program {\
397          name: "timepicker_starting_field2";\
398          signal: "timepicker,starting,field2";\
399          source: "elm";\
400          action: STATE_SET "default" 0.0;\
401          target: "time.picker.bg";\
402       }\
403       program {\
404          name: "timepicker_starting_field4";\
405          signal: "timepicker,starting,field4";\
406          source: "elm";\
407          action: STATE_SET "default" 0.0;\
408          target: "time.picker.bg";\
409       }\
410       program {\
411          name: "timepicker_starting_field5";\
412          signal: "timepicker,starting,field5";\
413          source: "elm";\
414          action: STATE_SET "default" 0.0;\
415          target: "time.picker.bg";\
416       }\
417    }
418
419 #define DATETIME_PICKER_BG_PROGRAMS \
420       program {\
421          name: "datepicker_starting_field2_bg";\
422          signal: "datepicker,starting,field2";\
423          source: "elm";\
424          script {\
425             set_state(PART:"picker.padding2", "enable", 0.0);\
426             set_state(PART:"picker.padding3", "default", 0.0);\
427          }\
428       }\
429       program {\
430          name: "datepicker_starting_field3_bg";\
431          signal: "datepicker,starting,field3";\
432          source: "elm";\
433          script {\
434             set_state(PART:"picker.padding3", "enable", 0.0);\
435             set_state(PART:"picker.padding2", "default", 0.0);\
436          }\
437       }\
438       program {\
439          name: "timepicker_starting_field3_bg";\
440          signal: "timepicker,starting,field3";\
441          source: "elm";\
442          script {\
443             set_state(PART:"picker.padding3", "enable", 0.0);\
444             set_state(PART:"picker.padding2", "default", 0.0);\
445          }\
446       }\
447       program {\
448          name: "timepicker_starting_field0_bg";\
449          signal: "timepicker,starting,field0";\
450          source: "elm";\
451          action: STATE_SET "default" 0.0;\
452          target: "picker.padding0";\
453       }\
454       program {\
455          name: "datepicker_starting_field1_bg";\
456          signal: "datepicker,starting,field1";\
457          source: "elm";\
458          action: STATE_SET "default" 0.0;\
459          target: "picker.padding0";\
460          target: "picker.padding2";\
461          target: "picker.padding3";\
462       }\
463       program {\
464          name: "datepicker_starting_field4_bg";\
465          signal: "datepicker,starting,field4";\
466          source: "elm";\
467          action: STATE_SET "default" 0.0;\
468          target: "picker.padding0";\
469          target: "picker.padding2";\
470          target: "picker.padding3";\
471       }
472
473 group { name: "elm/datetime/base/default";
474    images {
475       image: "00_button_01.png" COMP;
476       image: "00_button_01_press.png" COMP;
477    }
478    parts {
479       part {
480          name: "bg";
481          type: RECT;
482          scale: 1;
483          description {
484             state: "default" 0.0;
485             color: 0 0 0 0;
486             min: 0 DATETIME_WIDGET_HEIGHT;
487             max: -1 DATETIME_WIDGET_HEIGHT;
488          }
489       }
490       part {
491          name: "left.padding";
492          type: RECT;
493          scale: 1;
494          clip_to: "clipper";
495          mouse_events: 0;
496          description {
497             state: "default" 0.0;
498             visible: 0;
499             min: DATETIME_WIDGET_PADDING_SIZE_INC;
500             align: 0.0 0.5;
501             fixed: 1 1;
502             rel1.to: "bg";
503             rel2 {
504                relative: 0.0 1.0;
505                to: "bg";
506             }
507          }
508       }
509       part {
510          name: "right.padding";
511          type: RECT;
512          scale: 1;
513          clip_to: "clipper";
514          mouse_events: 0;
515          description {
516             state: "default" 0.0;
517             visible: 0;
518             min: DATETIME_WIDGET_PADDING_SIZE_INC;
519             align: 1.0 0.5;
520             fixed: 1 1;
521             rel2 {
522                relative: 1.0 0.0;
523                to: "bg";
524             }
525             rel2.to: "bg";
526          }
527       }
528
529       //DATETIME_DATEPICKER_BG
530       //DATETIME_TIMEPICKER_BG
531
532       DATETIME_FIELD(0, "left.padding")
533       DATETIME_FIELD(1, "right.padding0")
534       DATETIME_FIELD(2, "right.padding1")
535       DATETIME_FIELD(3, "right.padding2")
536       DATETIME_FIELD(4, "right.padding3")
537       DATETIME_FIELD(5, "right.padding4")
538
539       part {
540          name: "clipper";
541          type: RECT;
542          description { state: "default" 0.0;
543             color: 255 255 255 255;
544          }
545          description { state: "visible" 0.0;
546             inherit: "default" 0.0;
547             color: 255 255 255 102;
548          }
549       }
550       part {
551          name: "disabler";
552          type: RECT;
553          description { state: "default" 0.0;
554             color: 0 0 0 0;
555             visible: 0;
556          }
557          description { state: "visible" 0.0;
558             inherit: "default" 0.0;
559             visible: 1;
560          }
561       }
562    }
563    programs {
564       program {
565          name: "disble_datetime";
566          signal: "elm,state,disabled";
567          source: "elm";
568          action: STATE_SET "visible" 0.0;
569          target: "disabler";
570          target: "clipper";
571       }
572       program {
573          name: "enable_datetime";
574          signal: "elm,state,enabled";
575          source: "elm";
576          action: STATE_SET "default" 0.0;
577          target: "disabler";
578          target: "clipper";
579       }
580       DATETIME_PICKER_BG_PROGRAMS
581    }
582 }
583
584 #define DATETIME_FIELD_STYLE1(_pos, _after) \
585    part {\
586       name: "field"#_pos; \
587       type: SWALLOW; \
588       scale: 1;\
589       clip_to: "clipper";\
590       repeat_events: 1;\
591       description { state: "default" 0.0; \
592          visible: 0;\
593          min: 0 0;\
594          align: 0.0 0.5;\
595          fixed: 1 1;\
596          rel1 {\
597             relative: 1.0 0.0;\
598             to: "separator"#_after;\
599          }\
600          rel2 {\
601             relative: 1.0 1.0;\
602             to: "separator"#_after;\
603          }\
604       }\
605       description { state: "enable" 0.0;\
606          inherit: "default" 0.0;\
607          visible: 1;\
608          min: DATETIME_FIELD_MIN_SIZE_INC;\
609       }\
610    }\
611    programs{\
612       program {\
613          name: "field_"#_pos"enabled";\
614          signal: "field"#_pos",enable";\
615          source: "elm";\
616          action: STATE_SET "enable" 0.0;\
617          target: "field"#_pos;\
618       }\
619       program {\
620          name: "field_"#_pos"disabled";\
621          signal: "field"#_pos",disable";\
622          source: "elm";\
623          action: STATE_SET "default" 0.0;\
624          target: "field"#_pos;\
625       }\
626     }
627
628 #define DATETIME_SEPARATOR_STYLE1(_pos) \
629    part {\
630       name: "separator"#_pos; \
631       type: TEXT;\
632       scale: 1;\
633       clip_to: "clipper";\
634       repeat_events: 1;\
635       description {\
636          state: "default" 0.0;\
637          visible: 0;\
638          min: DATETIME_SEPARATOR_MIN_SIZE_INC;\
639          max: DATETIME_SEPARATOR_MIN_SIZE_INC;\
640          align: 0.0 0.5;\
641          fixed: 1 1;\
642          rel1 {\
643             relative: 1.0 0.0;\
644             to: "field"#_pos;\
645          }\
646          rel2 {\
647             relative: 1.0 1.0;\
648             to: "field"#_pos;\
649          }\
650          color: DATETIME_SEPARATOR_TEXT_COLOR_INC;\
651          text {\
652             font: "Tizen:style=Regular";\
653             size: DATETIME_SEPARATOR_TEXT_FONT_SIZE_INC;\
654             min: 1 0; \
655             text_class: "tizen";\
656          }\
657       }\
658       description { state: "enable" 0.0;\
659          inherit: "default" 0.0;\
660          visible: 1;\
661       }\
662       description { state: "hide" 0.0;\
663          inherit: "default" 0.0;\
664          min: 0 0;\
665          max: 0 0;\
666       }\
667    }\
668    programs {\
669       program {\
670          name: "separator"#_pos",enabled";\
671          signal: "field"#_pos",separator,enable";\
672          source: "elm";\
673          action: STATE_SET "enable" 0.0;\
674          target: "separator"#_pos;\
675       }\
676       program {\
677          name: "separator"#_pos",disabled";\
678          signal: "field"#_pos",separator,disable";\
679          source: "elm";\
680          script {\
681             new st[31];\
682             new Float:vl;\
683             get_state(PART:"separator"#_pos, st, 30, vl);\
684             if (strcmp(st, "hide")) \
685             {\
686                set_state(PART:"separator"#_pos, "default", 0.0);\
687             }\
688          }\
689       }\
690       program {\
691          name: "separator"#_pos",hide";\
692          signal: "field"#_pos",disable";\
693          source: "elm";\
694          action: STATE_SET "hide" 0.0;\
695          target: "separator"#_pos;\
696       }\
697    }
698
699
700 group { name: "elm/datetime/base/style1";
701    parts {
702       part {
703          name: "bg";
704          type: RECT;
705          scale: 1;
706          description {
707             state: "default" 0.0;
708             color: 0 0 0 0;
709          }
710       }
711       part {
712          name: "left.padding";
713          type: RECT;
714          scale: 1;
715          clip_to: "clipper";
716          mouse_events: 0;
717          description {
718             state: "default" 0.0;
719             visible: 0;
720             min: DATETIME_LEFT_PADDING_SIZE_INC;
721             max: DATETIME_LEFT_PADDING_SIZE_INC;
722             align: 0.0 0.5;
723             fixed: 1 1;
724             rel1.to: "bg";
725             rel2 {
726                relative: 0.0 1.0;
727                to: "bg";
728             }
729          }
730       }
731       part {
732          name: "field0";
733          type: SWALLOW;
734          scale: 1;
735          clip_to: "clipper";
736          repeat_events: 1;
737          description {
738             state: "default" 0.0;
739             visible: 0;
740             min: 0 0;
741             align: 0.0 0.5;
742             fixed: 1 0;
743             rel1 {
744                relative: 0.5 0.0;
745                to_x: "left.padding";
746             }
747             rel2 {
748                relative: 0.5 1.0;
749                to_x: "left.padding";
750             }
751          }
752          description { state: "enable" 0.0;
753             inherit: "default" 0.0;
754             visible: 1;
755             min: DATETIME_FIELD_MIN_SIZE_INC;
756          }
757       }
758       DATETIME_SEPARATOR_STYLE1(0)
759       DATETIME_FIELD_STYLE1(1, 0)
760       DATETIME_SEPARATOR_STYLE1(1)
761       DATETIME_FIELD_STYLE1(2, 1)
762       DATETIME_SEPARATOR_STYLE1(2)
763       DATETIME_FIELD_STYLE1(3, 2)
764       DATETIME_SEPARATOR_STYLE1(3)
765       DATETIME_FIELD_STYLE1(4, 3)
766       DATETIME_SEPARATOR_STYLE1(4)
767       DATETIME_FIELD_STYLE1(5, 4)
768       DATETIME_SEPARATOR_STYLE1(5)
769       part {
770          name: "right.padding";
771          type: RECT;
772          scale: 1;
773          clip_to: "clipper";
774          mouse_events: 0;
775          description {
776             state: "default" 0.0;
777             visible: 0;
778             min: DATETIME_LEFT_PADDING_SIZE_INC;
779             max: DATETIME_LEFT_PADDING_SIZE_INC;
780             align: 1.0 0.5;
781             fixed: 1 1;
782             rel2 {
783                relative: 1.0 0.0;
784                to: "bg";
785             }
786             rel2.to: "bg";
787          }
788       }
789       part {
790          name: "clipper";
791          type: RECT;
792          description { state: "default" 0.0;
793             color: 255 255 255 255;
794          }
795          description { state: "visible" 0.0;
796             inherit: "default" 0.0;
797             color: 255 255 255 102;
798          }
799       }
800       part {
801          name: "disabler";
802          type: RECT;
803          description { state: "default" 0.0;
804             color: 0 0 0 0;
805             visible: 0;
806          }
807          description { state: "visible" 0.0;
808             inherit: "default" 0.0;
809             visible: 1;
810          }
811       }
812    }
813    programs {
814       program {
815          name: "disble_datetime";
816          signal: "elm,state,disabled";
817          source: "elm";
818          action: STATE_SET "visible" 0.0;
819          target: "disabler";
820          target: "clipper";
821       }
822       program {
823          name: "enable_datetime";
824          signal: "elm,state,enabled";
825          source: "elm";
826          action: STATE_SET "default" 0.0;
827          target: "disabler";
828          target: "clipper";
829       }
830       program {
831          name: "field0,enabled";
832          signal: "field0,enable";
833          source: "elm";
834          action: STATE_SET "enable" 0.0;
835          target: "field0";
836       }
837       program {
838          name: "field0,disabled";
839          signal: "field0,disable";
840          source: "elm";
841          action: STATE_SET "default" 0.0;
842          target: "field0";
843       }
844    }
845 }
846 group { name: "elm/spinner/base/default";
847    alias: "elm/spinner/base/datetime_popup";
848    alias: "elm/spinner/base/datetime_popup/year";
849    alias: "elm/spinner/base/datetime_popup/month";
850    alias: "elm/spinner/base/datetime_popup/date";
851    alias: "elm/spinner/base/datetime_popup/hour";
852    alias: "elm/spinner/base/datetime_popup/minute";
853    images {
854       image: "00_picker_arrow_down.png" COMP;
855       image: "00_picker_arrow_up.png" COMP;
856       image: "00_button_01.png" COMP;
857       image: "00_button_01_press.png" COMP;
858    }
859    parts {
860       part { name: "bg";
861          type: RECT;
862          scale: 1;
863          description { state: "default" 0.0;
864             color: 0 0 0 0;
865          }
866       }
867       part { name: "up.image";
868          scale: 1;
869          description { state: "default" 0.0;
870             align: 0.5 0.0;
871             min: SPINNER_UP_DOWN_IMAGE_SIZE_INC;
872             max: SPINNER_UP_DOWN_IMAGE_SIZE_INC;
873             image {
874                normal: "00_button_01.png";
875                border: SPINNER_UP_DOWN_IMAGE_BORDER_SIZE_INC;
876                border_scale: 1;
877             }
878          }
879          description { state: "pressed" 0.0;
880             inherit: "default" 0.0;
881             image.normal: "00_button_01_press.png";
882          }
883       }
884       part { name: "up.image.arrow";
885          scale: 1;
886          description { state: "default" 0.0;
887             rel1.to: "up.image";
888             rel2.to: "up.image";
889             min: SPINNER_UP_DOWN_ARROW_IMAGE_SIZE_INC;
890             max: SPINNER_UP_DOWN_ARROW_IMAGE_SIZE_INC;
891             image.normal: "00_picker_arrow_up.png";
892          }
893          description { state: "pressed" 0.0;
894             inherit: "default" 0.0;
895             image.normal: "00_picker_arrow_up.png";
896          }
897       }
898       part { name: "down.image";
899          scale: 1;
900          description { state: "default" 0.0;
901             align: 0.5 1.0;
902             min: SPINNER_UP_DOWN_IMAGE_SIZE_INC;
903             max: SPINNER_UP_DOWN_IMAGE_SIZE_INC;
904             image {
905                normal: "00_button_01.png";
906                border: SPINNER_UP_DOWN_IMAGE_BORDER_SIZE_INC;
907                border_scale: 1;
908             }
909          }
910          description { state: "pressed" 0.0;
911             inherit: "default" 0.0;
912             image.normal: "00_button_01_press.png";
913          }
914       }
915       part { name: "down.image.arrow";
916          scale: 1;
917          description { state: "default" 0.0;
918             rel1.to: "down.image";
919             rel2.to: "down.image";
920             min: SPINNER_UP_DOWN_ARROW_IMAGE_SIZE_INC;
921             max: SPINNER_UP_DOWN_ARROW_IMAGE_SIZE_INC;
922             image.normal: "00_picker_arrow_down.png";
923          }
924          description { state: "pressed" 0.0;
925             inherit: "default" 0.0;
926             image.normal: "00_picker_arrow_down.png";
927          }
928       }
929       part { name: "elm.text";
930          type: TEXT;
931          scale: 1;
932          description { state: "default" 0.0;
933             visible: 1;
934             color: SPINNER_ENTRY_TEXT_COLOR_INC;
935             min: 0 SPINNER_TEXT_HEIGHT_INC;
936             max: -1 SPINNER_TEXT_HEIGHT_INC;
937             text {
938                font: "Tizen:style=Regular";
939                size: SPINNER_ENTRY_TEXT_SIZE_INC;
940                min: 0 0;
941                max: 1 0;
942                text_class: "tizen";
943             }
944          }
945          description { state: "active" 0.0;
946             inherit: "default" 0.0;
947             visible: 0;
948          }
949       }
950       part { name: "button.events";
951          type: RECT;
952          mouse_events: 1;
953          description { state: "default" 0.0;
954             rel1.to: "elm.text";
955             rel2.to: "elm.text";
956             fixed: 1 1;
957             color: 0 0 0 0;
958          }
959       }
960       part { name: "elm.swallow.entry";
961          type: SWALLOW;
962          description { state: "default" 0.0;
963             visible: 0;
964             rel1.to: "elm.text";
965             rel2.to: "elm.text";
966             fixed: 1 1;
967          }
968          description { state: "active" 0.0;
969             inherit: "default" 0.0;
970             visible: 1;
971          }
972       }
973       part { name: "up.btn";
974          type: RECT;
975          repeat_events: 1;
976          scale: 1;
977          description { state: "default" 0.0;
978            rel1.to: "up.image";
979            rel2.to: "up.image";
980            color: 0 0 0 0;
981          }
982       }
983       part { name: "down.btn";
984          type: RECT;
985          repeat_events: 1;
986          scale: 1;
987          description { state: "default" 0.0;
988            rel1.to: "down.image";
989            rel2.to: "down.image";
990            color: 0 0 0 0;
991          }
992       }
993       part { name: "disabler";
994          type: RECT;
995          description { state: "default" 0.0;
996             color: 0 0 0 0;
997             visible: 0;
998          }
999          description { state: "disabled" 0.0;
1000             inherit: "default" 0.0;
1001             visible: 1;
1002          }
1003       }
1004    }
1005    programs {
1006       program { name: "text_show";
1007          signal: "elm,state,text,visible";
1008          source: "elm";
1009          action:  STATE_SET "visible" 0.0;
1010          target: "elm.text";
1011       }
1012       program { name: "text_hide";
1013          signal: "elm,state,text,hidden";
1014          source: "elm";
1015          action:  STATE_SET "default" 0.0;
1016          target: "elm.text";
1017       }
1018       program { name: "dec_start_signal_emit";
1019          action: SIGNAL_EMIT "elm,action,decrement,start" "";
1020       }
1021       program { name: "dec_stop_signal_emit";
1022          action: SIGNAL_EMIT "elm,action,decrement,stop" "";
1023       }
1024       program { name: "inc_start_signal_emit";
1025          action: SIGNAL_EMIT "elm,action,increment,start" "";
1026       }
1027       program { name: "inc_stop_signal_emit";
1028          action: SIGNAL_EMIT "elm,action,increment,stop" "";
1029       }
1030       program { name: "dec";
1031          signal: "mouse,down,1*";
1032          source: "down.btn";
1033          action:  STATE_SET "pressed" 0.0;
1034          target: "down.image";
1035          target: "down.image.arrow";
1036          after: "dec_start_signal_emit";
1037       }
1038       program { name: "dec2";
1039          signal: "mouse,up,1";
1040          source: "down.btn";
1041          action:  STATE_SET "default" 0.0;
1042          target: "down.image";
1043          target: "down.image.arrow";
1044          after: "dec_stop_signal_emit";
1045       }
1046       program { name: "inc";
1047          signal: "mouse,down,1*";
1048          source: "up.btn";
1049          action:  STATE_SET "pressed" 0.0;
1050          target: "up.image";
1051          target: "up.image.arrow";
1052          after: "inc_start_signal_emit";
1053       }
1054       program { name: "inc2";
1055          signal: "mouse,up,1";
1056          source: "up.btn";
1057          action:  STATE_SET "default" 0.0;
1058          target: "up.image";
1059          target: "up.image.arrow";
1060          after: "inc_stop_signal_emit";
1061       }
1062       program { name: "disable";
1063          signal: "elm,state,disabled";
1064          source: "elm";
1065          action: STATE_SET "disabled" 0.0;
1066          target: "disabler";
1067       }
1068       program { name: "enable";
1069          signal: "elm,state,enabled";
1070          source: "elm";
1071          action: STATE_SET "default" 0.0;
1072          target: "disabler";
1073       }
1074       program { name: "active";
1075          signal: "elm,state,active";
1076          source: "elm";
1077          action: STATE_SET "active" 0.0;
1078          target: "elm.text";
1079          target: "elm.swallow.entry";
1080       }
1081       program { name: "inactive";
1082          signal: "elm,state,inactive";
1083          source: "elm";
1084          action: STATE_SET "default" 0.0;
1085          target: "elm.text";
1086          target: "elm.swallow.entry";
1087       }
1088       program { name: "toggle_text";
1089          signal: "mouse,up,1";
1090          source: "button.events";
1091          action: SIGNAL_EMIT "elm,action,entry,toggle" "";
1092       }
1093    }
1094 }
1095
1096 group { name: "elm/spinner/base/datetime_popup/ampm";
1097    inherit: "elm/spinner/base/default";
1098
1099    parts {
1100       part { name: "block.events";
1101          type: RECT;
1102          description { state: "default" 0.0;
1103             color: 0 0 0 0;
1104             rel1.to: "elm.text";
1105             rel2.to: "elm.text";
1106          }
1107       }
1108    }
1109 }
1110
1111 group { name: "elm/layout/datetime_popup/date_layout";
1112
1113    parts {
1114       part { name: "bg";
1115          type: RECT;
1116          scale: 1;
1117          description { state: "default" 0.0;
1118             color: 0 0 0 0;
1119             min: DATETIME_POPUP_CONTENT_SIZE_INC;
1120             max: DATETIME_POPUP_CONTENT_SIZE_INC;
1121          }
1122       }
1123       part { name: "top.padding";
1124          type: RECT;
1125          scale: 1;
1126          description { state: "default" 0.0;
1127             color: 0 0 0 0;
1128             min: 0 0;
1129             max: -1 0;
1130             rel1.to: "bg";
1131             rel2 {
1132                relative: 1.0 0.0;
1133                to: "bg";
1134             }
1135             align: 0.5 0.0;
1136          }
1137       }
1138       part { name: "bottom.padding";
1139          type: RECT;
1140          scale: 1;
1141          description { state: "default" 0.0;
1142             color: 0 0 0 0;
1143             min: 0 0;
1144             max: -1 0;
1145             rel1 {
1146                relative: 0.0 1.0;
1147                to: "bg";
1148             }
1149             rel2.to: "bg";
1150             align: 0.5 1.0;
1151          }
1152       }
1153       part { name: "left.padding";
1154          type: RECT;
1155          scale: 1;
1156          description { state: "default" 0.0;
1157             color: 0 0 0 0;
1158             min: DATETIME_POPUP_CONTENT_LEFT_PADDING_WIDTH_INC 0;
1159             max: DATETIME_POPUP_CONTENT_LEFT_PADDING_WIDTH_INC -1;
1160             rel1 {
1161                relative: 0.0 1.0;
1162                to_x: "bg";
1163                to_y: "top.padding";
1164             }
1165             rel2 {
1166                relative: 0.0 0.0;
1167                to_x: "bg";
1168                to_y: "bottom.padding";
1169             }
1170             align: 0.0 0.5;
1171          }
1172       }
1173       part { name: "right.padding";
1174          type: RECT;
1175          scale: 1;
1176          description { state: "default" 0.0;
1177             color: 0 0 0 0;
1178             min: DATETIME_POPUP_CONTENT_RIGHT_PADDING_WIDTH_INC 0;
1179             max: DATETIME_POPUP_CONTENT_RIGHT_PADDING_WIDTH_INC -1;
1180             rel2.to: "bg";
1181             rel1 {
1182                relative: 1.0 1.0;
1183                to_x: "bg";
1184                to_y: "top.padding";
1185             }
1186             rel2 {
1187                relative: 1.0 0.0;
1188                to_x: "bg";
1189                to_y: "bottom.padding";
1190             }
1191             align: 1.0 0.5;
1192          }
1193       }
1194       part { name: "field0";
1195          type: SWALLOW;
1196          scale: 1;
1197          description { state: "default" 0.0;
1198             min: DATETIME_POPUP_CONTENT_FIELD_WIDTH_INC 0;
1199             rel1 {
1200                relative: 1.0 0.0;
1201                to: "left.padding";
1202             }
1203             rel2.to: "left.padding";
1204             align: 0.0 0.5;
1205          }
1206       }
1207       part { name: "center.padding1";
1208          type: RECT;
1209          scale: 1;
1210          description { state: "default" 0.0;
1211             color: 0 0 0 0;
1212             min: DATETIME_POPUP_CONTENT_CENTER_PADDING_WIDTH_INC 0;
1213             max: DATETIME_POPUP_CONTENT_CENTER_PADDING_WIDTH_INC -1;
1214             rel1 {
1215                relative: 1.0 0.0;
1216                to: "field0";
1217             }
1218             rel2.to: "field0";
1219             align: 0.0 0.5;
1220          }
1221       }
1222       part { name: "field1";
1223          type: SWALLOW;
1224          scale: 1;
1225          description { state: "default" 0.0;
1226             min: DATETIME_POPUP_CONTENT_FIELD_WIDTH_INC 0;
1227             rel1 {
1228                relative: 1.0 0.0;
1229                to: "center.padding1";
1230             }
1231             rel2 {
1232                relative: 0.0 1.0;
1233                to: "center.padding2";
1234             }
1235          }
1236       }
1237       part { name: "center.padding2";
1238          type: RECT;
1239          scale: 1;
1240          description { state: "default" 0.0;
1241             color: 0 0 0 0;
1242             min: DATETIME_POPUP_CONTENT_CENTER_PADDING_WIDTH_INC 0;
1243             max: DATETIME_POPUP_CONTENT_CENTER_PADDING_WIDTH_INC -1;
1244             rel1.to: "field2";
1245             rel2 {
1246                relative: 0.0 1.0;
1247                to: "field2";
1248             }
1249             align: 1.0 0.5;
1250          }
1251       }
1252       part { name: "field2";
1253          type: SWALLOW;
1254          scale: 1;
1255          description { state: "default" 0.0;
1256             min: DATETIME_POPUP_CONTENT_FIELD_WIDTH_INC 0;
1257             rel1.to: "right.padding";
1258             rel2 {
1259                relative: 0.0 1.0;
1260                to: "right.padding";
1261             }
1262             align: 1.0 0.5;
1263          }
1264       }
1265       part {
1266          name: "event_area";
1267          type: RECT;
1268          description { state: "default" 0.0;
1269             color: 0 0 0 0;
1270             visible: 0;
1271          }
1272          description { state: "visible" 0.0;
1273             inherit: "default" 0.0;
1274             visible: 1;
1275          }
1276       }
1277    }
1278 }
1279
1280 group { name: "elm/layout/datetime_popup/time_layout";
1281    inherit: "elm/layout/datetime_popup/date_layout";
1282
1283    parts {
1284       part { name: "hour.minute.color";
1285          type: TEXT;
1286          scale: 1;
1287          description { state: "default" 0.0;
1288             rel1.to: "center.padding1";
1289             rel2.to: "center.padding1";
1290             color: DATETIME_POPUP_CONTENT_FIELD_TEXT_COLOR_INC;
1291             text {
1292                font: "Tizen:style=Regular";
1293                size: DATETIME_POPUP_CONTENT_FIELD_TEXT_SIZE_INC;
1294                min: 0 0;
1295                text_class: "tizen";
1296                text: ":";
1297             }
1298          }
1299       }
1300    }
1301 }