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