tizen_2.0_build
[apps/home/draglock.git] / res / edje / draglock-slide.edc
1 /*
2  * Copyright 2012  Samsung Electronics Co., Ltd
3  *
4  * Licensed under the Flora License, Version 1.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *  http://www.tizenopensource.org/license
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 #define DRAGLOCK_ARROW_RECT(pname, rel1x, rel2x)\
18         part {\
19                 name: "rect."#pname;\
20                 type: RECT;\
21                 scale: 1;\
22                 description {\
23                         state: "default" 0.0;\
24                         rel1 {\
25                                 relative: rel1x 0.0;\
26                                 to: "rect.arrow";\
27                         }\
28                         rel2 {\
29                                 relative: rel2x 1.0;\
30                                 to: "rect.arrow";\
31                         }\
32                         visible: 0;\
33                 }\
34         }\
35
36 #define DRAGLOCK_ARROW_IMAGE(pname, rname)\
37         part {\
38                 name: "arrow."#pname;\
39                 type: IMAGE;\
40                 scale: 1;\
41                 description {\
42                         state: "default" 0.0;\
43                         min: 23 29;\
44                         align: 0.5 0.5;\
45                         rel1 {\
46                                 relative: 0.5 0.5;\
47                                 to: "rect."#rname;\
48                         }\
49                         rel2 {\
50                                 relative: 0.5 0.5;\
51                                 to: "rect."#rname;\
52                         }\
53                         image.normal: "RB07_icon_Unlock_arrow.png";\
54                         visible: 0;\
55                 }\
56                 description {\
57                         state: "press" 0.0;\
58                         inherit: "default" 0.0;\
59                         image.normal: "RB07_icon_Unlock_arrow_press.png";\
60                         visible: 1;\
61                 }\
62         }\
63
64 #define DRAGLOCK_LOCK_PRESS_DESC(pstate, file)\
65         description {\
66                 state: #pstate 0.0;\
67                 inherit: "default" 0.0;\
68                 image.normal: #file;\
69                 visible: 1;\
70         }\
71
72 #define DRAGLOCK_LOCK_PRESS_PROC(pname)\
73         program{\
74                 name: #pname".lock.r";\
75                 signal: #pname;\
76                 source: "lock.image.r";\
77                 action: STATE_SET #pname 0.0;\
78                 target: "lock.image.r";\
79         }\
80
81 group {
82         name: "draglock-slide";
83
84         images {
85                 image: "RB07_Unlock_bg.png" COMP;
86                 image: "RB07_Unlock_bg_press.png" COMP;
87                 image: "RB07_icon_Unlock_01.png" COMP;
88                 image: "RB07_icon_Unlock_02.png" COMP;
89                 image: "RB07_icon_Unlock_arrow.png" COMP;
90                 image: "RB07_icon_Unlock_arrow_press.png" COMP;
91                 image: "RB07_icon_Unlock_press_01.png" COMP;
92                 image: "RB07_icon_Unlock_press_02.png" COMP;
93                 image: "RB07_icon_Unlock_press_03.png" COMP;
94                 image: "RB07_icon_Unlock_press_04.png" COMP;
95                 image: "RB07_icon_Unlock_press_05.png" COMP;
96                 image: "RB07_icon_Unlock_press_06.png" COMP;
97                 image: "RB07_icon_Unlock_press_07.png" COMP;
98                 image: "RB07_icon_Unlock_press_08.png" COMP;
99                 image: "RB07_icon_Unlock_press_09.png" COMP;
100                 image: "RB07_icon_Unlock_press_10.png" COMP;
101                 image: "RB07_icon_Unlock_press_11.png" COMP;
102                 image: "RB07_icon_Unlock_press_12.png" COMP;
103                 image: "RB07_icon_Unlock_press_13.png" COMP;
104                 image: "RB07_icon_Unlock_press_14.png" COMP;
105                 image: "RB07_icon_Unlock_press_15.png" COMP;
106         }
107
108         parts {
109                 part {
110                         name: "bg";
111                         type: RECT;
112                         scale: 1;
113
114                         description {
115                                 state: "default" 0.0;
116                                 min: 0 114;
117                                 color: 0 0 0 0;
118                         }
119                 }
120
121                 part {
122                         name: "image.bg";
123                         type: IMAGE;
124                         scale: 1;
125
126                         description {
127                                 state: "default" 0.0;
128
129                                 rel1 {
130                                         to: "bg";
131                                 }
132                                 rel2 {
133                                         to: "bg";
134                                 }
135                                 image.normal: "RB07_Unlock_bg.png";
136                                 visible: 0;
137                         }
138                         description {
139                                 state: "press" 0.0;
140                                 inherit: "default" 0.0;
141                                 image.normal: "RB07_Unlock_bg_press.png";
142                                 visible: 1;
143                         }
144                 }
145
146                 part {
147                         name: "lock.padding.l";
148                         type: RECT;
149                         scale: 1;
150
151                         description {
152                                 state: "default" 0.0;
153                                 min: 47 0;
154                                 align: 0.0 0.0;
155
156                                 rel1 {
157                                         to: "bg";
158                                 }
159                                 rel2 {
160                                         relative: 0.0 1.0;
161                                         to: "bg";
162                                 }
163                                 visible: 0;
164                         }
165                 }
166
167                 part {
168                         name: "lock.padding.r";
169                         type: RECT;
170                         scale: 1;
171
172                         description {
173                                 state: "default" 0.0;
174                                 min: 46 0;
175                                 align: 1.0 0.0;
176
177                                 rel1 {
178                                         relative: 1.0 0.0;
179                                         to: "bg";
180                                 }
181                                 rel2 {
182                                         to: "bg";
183                                 }
184                                 visible: 0;
185                         }
186                 }
187
188                 part {
189                         name: "lock.wrapper.image.l";
190                         type: RECT;
191                         scale: 1;
192
193                         description {
194                                 state: "default" 0.0;
195                                 min: 119 119;
196                                 align: 0.5 0.5;
197
198                                 rel1 {
199                                         relative: 0.5 0.5;
200                                         to: "lock.image.l";
201                                 }
202                                 rel2 {
203                                         relative: 0.5 0.5;
204                                         to: "lock.image.l";
205                                 }
206                                 color: 0 0 0 0;
207                         }
208                 }
209
210                 part {
211                         name: "lock.image.l";
212                         type: IMAGE;
213                         scale: 1;
214
215                         description {
216                                 state: "default" 0.0;
217                                 min: 76 76;
218                                 align: 0.0 0.5;
219
220                                 rel1 {
221                                         relative: 1.0 0.5;
222                                         to_x: "lock.padding.l";
223                                         to_y: "bg";
224                                 }
225                                 rel2 {
226                                         relative: 1.0 0.5;
227                                         to_x: "lock.padding.l";
228                                         to_y: "bg";
229                                 }
230                                 image.normal: "RB07_icon_Unlock_01.png";
231                         }
232                         description {
233                                 state: "press" 0.0;
234                                 inherit: "default" 0.0;
235                                 image.normal: "RB07_icon_Unlock_press_01.png";
236                         }
237                 }
238
239                 part {
240                         name: "lock.image.r";
241                         type: IMAGE;
242                         scale: 1;
243
244                         description {
245                                 state: "default" 0.0;
246                                 min: 76 76;
247                                 align: 1.0 0.5;
248
249                                 rel1 {
250                                         relative: 0.0 0.5;
251                                         to_x: "lock.padding.r";
252                                         to_y: "bg";
253                                 }
254                                 rel2 {
255                                         relative: 0.0 0.5;
256                                         to_x: "lock.padding.r";
257                                         to_y: "bg";
258                                 }
259                                 image.normal: "RB07_icon_Unlock_02.png";
260                                 visible: 0;
261                         }
262                         DRAGLOCK_LOCK_PRESS_DESC(press02, RB07_icon_Unlock_press_02.png);
263                         DRAGLOCK_LOCK_PRESS_DESC(press03, RB07_icon_Unlock_press_03.png);
264                         DRAGLOCK_LOCK_PRESS_DESC(press04, RB07_icon_Unlock_press_04.png);
265                         DRAGLOCK_LOCK_PRESS_DESC(press05, RB07_icon_Unlock_press_05.png);
266                         DRAGLOCK_LOCK_PRESS_DESC(press06, RB07_icon_Unlock_press_06.png);
267                         DRAGLOCK_LOCK_PRESS_DESC(press07, RB07_icon_Unlock_press_07.png);
268                         DRAGLOCK_LOCK_PRESS_DESC(press08, RB07_icon_Unlock_press_08.png);
269                         DRAGLOCK_LOCK_PRESS_DESC(press09, RB07_icon_Unlock_press_09.png);
270                         DRAGLOCK_LOCK_PRESS_DESC(press10, RB07_icon_Unlock_press_10.png);
271                         DRAGLOCK_LOCK_PRESS_DESC(press11, RB07_icon_Unlock_press_11.png);
272                         DRAGLOCK_LOCK_PRESS_DESC(press12, RB07_icon_Unlock_press_12.png);
273                         DRAGLOCK_LOCK_PRESS_DESC(press13, RB07_icon_Unlock_press_13.png);
274                         DRAGLOCK_LOCK_PRESS_DESC(press14, RB07_icon_Unlock_press_14.png);
275                         DRAGLOCK_LOCK_PRESS_DESC(press15, RB07_icon_Unlock_press_15.png);
276                 }
277
278                 part {
279                         name: "lock.wrapper.image.r";
280                         type: RECT;
281                         scale: 1;
282
283                         description {
284                                 state: "default" 0.0;
285                                 min: 122 114;
286                                 align: 1.0 0.0;
287
288                                 rel1 {
289                                         relative: 1.0 0.0;
290                                         to: "bg";
291                                 }
292                                 rel2 {
293                                         to: "bg";
294                                 }
295                                 color: 0 0 0 0;
296                         }
297                 }
298
299                 part {
300                         name: "arrow.padding.l";
301                         type: RECT;
302                         scale: 1;
303
304                         description {
305                                 state: "default" 0.0;
306                                 min: 126 0;
307                                 align: 0.0 0.0;
308                                 fixed: 1.0 1.0;
309
310                                 rel1 {
311                                         to: "bg";
312                                 }
313                                 rel2 {
314                                         relative: 0.0 1.0;
315                                         to: "bg";
316                                 }
317                                 visible: 0;
318                         }
319                 }
320
321                 part {
322                         name: "arrow.padding.r";
323                         type: RECT;
324                         scale: 1;
325
326                         description {
327                                 state: "default" 0.0;
328                                 min: 126 0;
329                                 align: 1.0 0.0;
330                                 fixed: 1.0 1.0;
331
332                                 rel1 {
333                                         relative: 1.0 0.0;
334                                         to: "bg";
335                                 }
336                                 rel2 {
337                                         to: "bg";
338                                 }
339                                 visible: 0;
340                         }
341                 }
342
343                 part {
344                         name: "rect.arrow";
345                         type: RECT;
346                         scale: 1;
347
348                         description {
349                                 state: "default" 0.0;
350
351                                 rel1 {
352                                         relative: 1.0 0.0;
353                                         to: "arrow.padding.l";
354                                 }
355                                 rel2 {
356                                         relative: 0.0 1.0;
357                                         to: "arrow.padding.r";
358                                 }
359                                 visible: 0;
360                         }
361                 }
362
363                 DRAGLOCK_ARROW_RECT(arrow1, 0.0, 1/6);
364                 DRAGLOCK_ARROW_RECT(arrow2, 1/6, 2/6);
365                 DRAGLOCK_ARROW_RECT(arrow3, 2/6, 3/6);
366                 DRAGLOCK_ARROW_RECT(arrow4, 3/6, 4/6);
367                 DRAGLOCK_ARROW_RECT(arrow5, 4/6, 5/6);
368                 DRAGLOCK_ARROW_RECT(arrow6, 5/6, 6/6);
369
370                 DRAGLOCK_ARROW_IMAGE(image1, arrow1);
371                 DRAGLOCK_ARROW_IMAGE(image2, arrow2);
372                 DRAGLOCK_ARROW_IMAGE(image3, arrow3);
373                 DRAGLOCK_ARROW_IMAGE(image4, arrow4);
374                 DRAGLOCK_ARROW_IMAGE(image5, arrow5);
375                 DRAGLOCK_ARROW_IMAGE(image6, arrow6);
376         }
377
378         programs {
379                 program{
380                         name: "press.lock.l";
381                         signal: "press";
382                         source: "lock.image.l";
383                         action: STATE_SET "press" 0.0;
384                         target: "lock.image.l";
385                         target: "arrow.image1";
386                         target: "arrow.image2";
387                         target: "arrow.image3";
388                         target: "arrow.image4";
389                         target: "arrow.image5";
390                         target: "arrow.image6";
391                         target: "image.bg";
392                 }
393
394                 program{
395                         name: "release.lock.l";
396                         signal: "release";
397                         source: "lock.image.l";
398                         action: STATE_SET "default" 0.0;
399                         target: "lock.image.l";
400                         target: "arrow.image1";
401                         target: "arrow.image2";
402                         target: "arrow.image3";
403                         target: "arrow.image4";
404                         target: "arrow.image5";
405                         target: "arrow.image6";
406                         target: "image.bg";
407                 }
408
409                 DRAGLOCK_LOCK_PRESS_PROC(press02);
410                 DRAGLOCK_LOCK_PRESS_PROC(press03);
411                 DRAGLOCK_LOCK_PRESS_PROC(press04);
412                 DRAGLOCK_LOCK_PRESS_PROC(press05);
413                 DRAGLOCK_LOCK_PRESS_PROC(press06);
414                 DRAGLOCK_LOCK_PRESS_PROC(press07);
415                 DRAGLOCK_LOCK_PRESS_PROC(press08);
416                 DRAGLOCK_LOCK_PRESS_PROC(press09);
417                 DRAGLOCK_LOCK_PRESS_PROC(press10);
418                 DRAGLOCK_LOCK_PRESS_PROC(press11);
419                 DRAGLOCK_LOCK_PRESS_PROC(press12);
420                 DRAGLOCK_LOCK_PRESS_PROC(press13);
421                 DRAGLOCK_LOCK_PRESS_PROC(press14);
422                 DRAGLOCK_LOCK_PRESS_PROC(press15);
423
424                 program{
425                         name: "release.lock.r";
426                         signal: "release";
427                         source: "lock.image.r";
428                         action: STATE_SET "default" 0.0;
429                         target: "lock.image.r";
430                 }
431         }
432 }