a94b2021745c583e8e8cc6c0fe8014331933103b
[apps/core/preloaded/calendar.git] / data / edc / layout / inc.main.month.weekly.edc
1 // 720 x 855
2 #ifndef _RATIO_
3 #define _RATIO_
4 #define R_X (480.0/720.0)
5 #define R_Y (800.0/1280.0)
6 #endif
7
8 //for month view
9 #define W (720.0*R_X)
10 #define H (855.0*R_Y)
11 #define H_WEEK (105.0*R_Y)
12 #define H_GAP (2.0*R_Y)
13 #define H_LINE (3.0*R_Y)
14
15 #define HEIGHT_OF_LIST_INDEX (48.0)
16 #define WIDTH_OF_LIST_INDEX (720.0)
17 #define WIDTH_OF_LIST_ICON (24.0)
18 #define HEIGHT_OF_LIST_ICON (24.0)
19 #define LIST_ICON_RIGHT_OFFSET (14.0)
20 #define HEIGHT_OF_CONTENT (915)
21 #define WIDTH_OF_LIST_INDEX_AREA (52)
22
23 group { name, "main/month/weekly";
24         images {
25                 image: CALENDAR_LIST_INDEX_OPEN COMP;
26                 image: CALENDAR_LIST_INDEX_OPEN_PRESS COMP;
27                 image: CALENDAR_LIST_INDEX_CLOSE COMP;
28                 image: CALENDAR_LIST_INDEX_CLOSE_PRESS COMP;
29                 image: CALENDAR_LIST_INDEX_BG COMP;
30         }
31
32         parts {
33                 part { name, "base";
34                         type, RECT;
35                         description {
36                                 state, "default" 0.0;
37                                 color, 0 0 0 0;
38                         }
39                 }
40
41                 part { name, "cal/sw";
42                         type, SWALLOW;
43                         clip_to, "cal/clip";
44                         description {
45                                 state, "default" 0.0;
46                                 rel1 { relative, 0.0 0.0; offset, 0 0; to, "base"; }
47                                 rel2 { relative, 1.0 ((HEIGHT_OF_CONTENT-HEIGHT_OF_LIST_INDEX)/HEIGHT_OF_CONTENT); offset, 0 0; to, "base"; }
48                         }
49                 }
50
51                 part { name, "cal/sw/left";
52                         type, SWALLOW;
53                         clip_to, "cal/clip";
54                         description {
55                                 state, "default" 0.0;
56                                 rel1 { relative, -1.0 0.0; to_x, "base"; to_y, "cal/sw"; }
57                                 rel2 { relative, 0.0 1.0; to_x, "base"; to_y, "cal/sw";}
58                         }
59                 }
60
61                 part { name, "cal/sw/right";
62                         type, SWALLOW;
63                         clip_to, "cal/clip";
64                         description {
65                                 state, "default" 0.0;
66                                 rel1 { relative, 1.0 0.0; to_x, "base"; to_y, "cal/sw"; }
67                                 rel2 { relative, 2.0 1.0; to_x, "base"; to_y, "cal/sw";}
68                         }
69                 }
70
71                 part { name, "cal/clip";
72                         type, RECT;
73                         description {
74                                 state, "default" 0.0;
75                                 rel1.to, "cal/sw";
76                                 rel2 { relative, 1.0 1.0; offset, 0 0; to, "cal/sw"; }
77                         }
78                         description {
79                                 state, "default" 1.0;
80                                 rel1.to, "cal/sw";
81                                 rel2 { relative, 1.0 ((H-H_WEEK-H_GAP)/H); offset: 0 0; to, "cal/sw"; }
82                         }
83                         description {
84                                 state, "default" 0.5;
85                                 rel1.to, "cal/sw";
86                                 rel2 { relative, 1.0 ((H-2*H_WEEK-2*H_GAP)/H); offset: 0 0; to, "cal/sw"; }
87                         }
88                 }
89
90                 part { name, "list/base";
91                         type, SWALLOW;
92                         description {
93                                 state, "default" 0.0;
94                                 rel1 {
95                                         relative, 0.0 1.0;
96                                         to_x, "base"; to_y, "cal/clip";
97                                 }
98                                 rel2.to, "base";
99                                 color, 0 0 0 0;
100                         }
101                 }
102
103                 part { name, "list/line";
104                         type, RECT;
105                         description {
106                                 state, "default" 0.0;
107                                 rel1 { to, "list/base"; }
108                                 rel2 { relative, 1.0 0.0; offset, 0 HEIGHT_OF_BOTTOM_LINE; to, "list/base"; }
109                                 color, COLOR_OF_LIST_LINE_FOR_MONTH;
110                         }
111                 }
112
113                 part { name, "list/index";
114                         scale, 1;
115                         mouse_events, 0;
116                         description {
117                                 state, "default" 0.0;
118                                 rel1{ relative, 0.0 0.0; offset, 0 2; to, "list/base"; }
119                                 rel2{ relative, 1.0 1.0; offset, 0 0; to, "list/base"; }
120                                 image {
121                                         border_scale, 1;
122                                         normal, CALENDAR_LIST_INDEX_BG;
123                                 }
124
125                         }
126                 }
127
128                 part { name, "list/icon/rect";
129                         type, RECT;
130                         mouse_events, 1;
131                         description {
132                                 state, "default" 0.0;
133                                 rel1{ relative, ((WIDTH_OF_LIST_INDEX-WIDTH_OF_LIST_INDEX_AREA)/WIDTH_OF_LIST_INDEX) 0.0; to, "list/index"; }
134                                 rel2{ relative,1.0 1.0; to, "list/index"; }
135                                 color, 0 0 0 0;
136                         }
137                 }
138
139                 part { name, "list/icon";
140                         scale, 1;
141                         mouse_events, 0;
142                         description {
143                                 state, "default" 0.0;
144                                 rel1{ relative, ((WIDTH_OF_LIST_INDEX-LIST_ICON_RIGHT_OFFSET-WIDTH_OF_LIST_ICON)/WIDTH_OF_LIST_INDEX) ((HEIGHT_OF_LIST_INDEX-HEIGHT_OF_LIST_ICON)/2/HEIGHT_OF_LIST_INDEX); to, "list/index"; }
145                                 rel2{ relative, ((WIDTH_OF_LIST_INDEX-LIST_ICON_RIGHT_OFFSET)/WIDTH_OF_LIST_INDEX) (1-((HEIGHT_OF_LIST_INDEX-HEIGHT_OF_LIST_ICON)/2/HEIGHT_OF_LIST_INDEX)); to, "list/index"; }
146                                 image.normal: CALENDAR_LIST_INDEX_CLOSE;
147                         }
148                         description { state: "down" 0.0;
149                                 inherit: "default" 0.0;
150                                 image.normal: CALENDAR_LIST_INDEX_CLOSE_PRESS;
151                         }
152                 }
153
154         }
155
156         programs {
157                 program { name, "cal/line5";
158                         signal, "go,line5";
159                         source, "prog";
160                         action, STATE_SET "default" 1.0;
161                         target, "cal/clip";
162                         transition, SINUSOIDAL 0.0;
163                 }
164                 program { name, "cal/line6";
165                         signal, "go,line6";
166                         source, "prog";
167                         action, STATE_SET "default" 0.0;
168                         target, "cal/clip";
169                         transition, SINUSOIDAL 0.0;
170                 }
171                 program { name, "cal/line4";
172                         signal, "go,line4";
173                         source, "prog";
174                         action, STATE_SET "default" 0.5;
175                         target, "cal/clip";
176                         transition, SINUSOIDAL 0.0;
177                 }
178                 program { name, "icon/down";
179                         signal, "mouse,down,1";
180                         source, "list/icon/rect";
181                         action, STATE_SET "down" 0.0;
182                         target, "list/icon";
183                 }
184                 program { name, "icon/up";
185                         signal, "mouse,up,1";
186                         source, "list/icon/rect";
187                         action, STATE_SET "default" 0.0;
188                         target, "list/icon";
189                 }
190                 program { name, "icon/clicked";
191                         signal, "mouse,clicked,1";
192                         source, "list/icon/rect";
193                         action, SIGNAL_EMIT "close" "cal";
194                 }
195         }
196 }
197
198 group { name, "main/month/weekly/l";
199
200         parts {
201                 part { name, "base";
202                         type, RECT;
203                         description {
204                                 state, "default" 0.0;
205                                 color, 0 0 0 0;
206                         }
207                 }
208
209                 part { name, "cal/sw";
210                         type, SWALLOW;
211                         clip_to, "cal/clip";
212                         description {
213                                 state, "default" 0.0;
214                                 rel1 { relative, 0.0 0.0; offset, 0 0; to, "base"; }
215                                 rel2 { relative, 1.0 1.0; offset, 0 0; to, "base"; }
216                         }
217                 }
218
219                 part { name, "cal/sw/left";
220                         type, SWALLOW;
221                         clip_to, "cal/clip";
222                         description {
223                                 state, "default" 0.0;
224                                 rel1 { relative, -1.0 0.0; to_x, "base"; to_y, "cal/sw"; }
225                                 rel2 { relative, 0.0 1.0; to_x, "base"; to_y, "cal/sw";}
226                         }
227                 }
228
229                 part { name, "cal/sw/right";
230                         type, SWALLOW;
231                         clip_to, "cal/clip";
232                         description {
233                                 state, "default" 0.0;
234                                 rel1 { relative, 1.0 0.0; to_x, "base"; to_y, "cal/sw"; }
235                                 rel2 { relative, 2.0 1.0; to_x, "base"; to_y, "cal/sw";}
236                         }
237                 }
238
239                 part { name, "cal/clip";
240                         type, RECT;
241                         description {
242                                 state, "default" 0.0;
243                                 rel1.to, "cal/sw";
244                                 rel2 { relative, 1.0 1.0; offset, 0 0; to, "cal/sw"; }
245                         }
246                 }
247         }
248 }
249