Making changes to make gstreamer calls work correctly on IVI
[profile/ivi/camera.git] / edc / cam_recording_edje_vertical.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
19 #include "cam_recording_edje_vertical_inc.edc"
20
21
22 collections {
23         group {
24                 name: "recording_layout";
25                 min: MAIN_H MAIN_W;
26
27                 parts {
28                         part {
29                                 name: RECORDING_IMAGE;
30                                 type: IMAGE;
31                                 description {
32                                         state: "default" 0.0;
33                                         rel1 { relative: RECORDING_IMAGE_X/VER_MAIN_W RECORDING_IMAGE_Y/VER_MAIN_H; }
34                                         rel2 { relative: (RECORDING_IMAGE_X+RECORDING_IMAGE_W)/VER_MAIN_W (RECORDING_IMAGE_Y+RECORDING_IMAGE_H)/VER_MAIN_H; }
35                                 }
36                                 description {
37                                         state: "rec" 0.0;
38                                         inherit: "default" 0.0;
39                                         image { normal: RECORDING_IMAGE_REC_IMAGE; }
40                                 }
41                                 description {
42                                         state: "rec1" 0.0;
43                                         inherit: "default" 0.0;
44                                         image { normal: RECORDING_IMAGE_REC_IMAGE; }
45                                 }
46                                 description {
47                                         state: "invisible" 0.0;
48                                         inherit: "default" 0.0;
49                                         visible: 0;
50                                 }
51                         }
52
53                         part {
54                                 name: RECORDING_TEXT;
55                                 type: TEXT;
56                                 scale: 1;
57                                 description {
58                                         state: "default" 0.0;
59                                         rel1 { relative: RECORDING_TEXT_X/VER_MAIN_W RECORDING_TEXT_Y/VER_MAIN_H; }
60                                         rel2 { relative: 1.0 1.0; offset: -1 -1; }
61                                         color: FONT_COLOR;
62                                         text {
63                                                 font : FONT_NAME;
64                                                 size : 35;
65                                                 align: 0.0 0.0;
66                                         }
67                                 }
68                                 description {
69                                         state: "invisible" 0.0;
70                                         inherit: "default" 0.0;
71                                         visible: 0;
72                                 }
73                         }
74
75                         part {
76                                 name: RECORDING_LEFT_TEXT;
77                                 type: TEXT;
78                                 scale: 1;
79                                 description {
80                                         state: "default" 0.0;
81                                         rel1 { relative: RECORDING_LEFT_TEXT_X/VER_MAIN_W RECORDING_LEFT_TEXT_Y/VER_MAIN_H; }
82                                         rel2 { relative: 1.0 1.0; offset: -1 -1; }
83                                         color: FONT_COLOR;
84                                         text {
85                                                 font : FONT_NAME;
86                                                 size : 35;
87                                                 align: 0.0 0.0;
88                                         }
89                                 }
90                                 description {
91                                         state: "invisible" 0.0;
92                                         inherit:  "default" 0.0;
93                                         visible : 0;
94                                 }
95                         }
96
97                         part { name: RECORDING_STOP_BUTTON;
98                                 type: IMAGE;
99                                 mouse_events: 1;
100                                 description {
101                                         state: "default" 0.0;
102                                         rel1 { relative: (RECBTN_X)/(VER_MAIN_W) (RECBTN_Y)/(VER_MAIN_H); offset: 0 0; }
103                                         rel2 { relative: (RECBTN_X+RECBTN_W)/(VER_MAIN_W) (RECBTN_Y+RECBTN_H)/(VER_MAIN_H); offset: -1 -1; }
104                                         image { normal: SHUTTER_REC_NORMAL_VERTICAL_IMAGE; }
105                                 }
106                                 description {
107                                         state: "rec" 0.0;
108                                         inherit:  "default" 0.0;
109                                         image { normal: SHUTTER_REC_NORMAL_VERTICAL_IMAGE; }
110                                 }
111                                 description {
112                                         state: "rec1" 0.0;
113                                         inherit:  "default" 0.0;
114                                         image { normal: RECORDING_PRESS_IMAGE_ANI_VER ; }
115                                 }
116                                 description {
117                                         state: "press" 0.0;
118                                         inherit:  "default" 0.0;
119                                         image { normal: SHUTTER_REC_PRESS_VERTICAL_IMAGE ; }
120                                 }
121                         }
122
123                         part { name: "progressbar";
124                                 type: SWALLOW;
125                                 description {
126                                         state: "default" 0.0;
127                                         fixed:1 1;
128                                         rel1 { relative: PROGRESS_BAR_X/VER_MAIN_W PROGRESS_BAR_Y/VER_MAIN_H; }
129                                         rel2 { relative: (PROGRESS_BAR_X+PROGRESS_BAR_W)/VER_MAIN_W (PROGRESS_BAR_Y+PROGRESS_BAR_H)/VER_MAIN_H; }
130                                 }
131                         }
132
133                         part {
134                                 name: "progressbar_text";
135                                 type: TEXT;
136                                 scale: 1;
137                                 description {
138                                          state: "default" 0.0;
139                                         rel1 { relative: 1.0 (-20)/PROGRESS_BAR_H; to: "progressbar"; }
140                                          rel2 { relative: (1.0+90/PROGRESS_BAR_W) (1.0+20/PROGRESS_BAR_H); to: "progressbar"; }
141                                          color: FONT_COLOR;
142                                         text {
143                                                   font : FONT_NAME;
144                                                   size : 28;
145                                                   align: 0.5 0.5;
146                                         }
147                                 }
148                         }
149
150                         part{
151                                 name: "file_size_text";
152                                 type: TEXT;
153                                 scale: 1;
154                                 description{
155                                         state: "default" 0.0;
156                                          rel1 { relative: (0.0-100/PROGRESS_BAR_W) (-20)/PROGRESS_BAR_H; to: "progressbar"; }
157                                          rel2 { relative: (0.0-10/PROGRESS_BAR_W) (1.0+20/PROGRESS_BAR_H); to: "progressbar"; }
158                                         color: FONT_COLOR;
159                                         text {
160                                                 font : FONT_NAME;
161                                                 size : 28;
162                                                 align : 1.0 0.5;
163                                         }
164                                 }
165                         }
166                 }
167
168                 programs {
169
170                         program {
171                                 name: "recording_stop_button,clicked";
172                                 signal: "mouse,clicked,1";
173                                 source: "recording_stop_button";
174                                 script {
175                                         emit( REC_STOP_SIG, REC_SIG_SRC );
176                                 }
177                         }
178
179 #ifdef NEW_RECORDING_LAYOUT
180
181                         program { name: "set_rec_state";
182                                 source: "program";
183                                 signal: "state,rec";
184                                 script {
185                                         set_state(PART:RECORDING_IMAGE, "rec", 0.0);
186                                         set_state(PART:RECORDING_TEXT, "default", 0.0);
187                                         //set_state(PART:REC_REC, "invisible", 0.0);
188                                         //set_state(PART:REC_STOP, "default", 0.0);
189                                         //set_state(PART:REC_PAUSE, "default", 0.0);
190                                 }
191                         }
192                         program { name: "set_rec_state1";
193                                 source: "program";
194                                 signal: "state,rec1";
195                                 script {
196                                         set_state(PART:RECORDING_IMAGE, "rec1", 0.0);
197                                         set_state(PART:RECORDING_TEXT, "default", 0.0);
198                                         //set_state(PART:REC_REC, "invisible", 0.0);
199                                         //set_state(PART:REC_STOP, "default", 0.0);
200                                         //set_state(PART:REC_PAUSE, "default", 0.0);
201                                 }
202                         }
203                         program { name: "set_pause_state";
204                                 source: "program";
205                                 signal: "state,pause";
206                                 script {
207                                         set_state(PART:RECORDING_IMAGE, "pause", 0.0);
208                                         set_state(PART:RECORDING_TEXT, "default", 0.0);
209                                         //set_state(PART:REC_REC, "default", 0.0);
210                                         //set_state(PART:REC_STOP, "invisible", 0.0);
211                                         //set_state(PART:REC_PAUSE, "dim", 0.0);
212                                 }
213                         }
214
215 #else
216
217                         program { name: "set_rec_state";
218                                 source: "program";
219                                 signal: "state,rec";
220                                 script {
221                                         set_state(PART:RECORDING_IMAGE, "rec", 0.0);
222                                         set_state(PART:RECORDING_STOP_BUTTON, "rec",0.0);
223                                         set_state(PART:RECORDING_TEXT, "default", 0.0);
224                                         //set_state(PART:REC_PAUSE, "default", 0.0);
225                                         //set_state(PART:REC_REC, "invisible", 0.0);
226                                 }
227                         }
228                         program { name: "set_rec_state1";
229                                 source: "program";
230                                 signal: "state,rec1";
231                                 script {
232                                         set_state(PART:RECORDING_IMAGE, "rec1", 0.0);
233                                         set_state(PART:RECORDING_STOP_BUTTON, "rec1",0.0);
234                                         set_state(PART:RECORDING_TEXT, "default", 0.0);
235                                         //set_state(PART:REC_PAUSE, "default", 0.0);
236                                         //set_state(PART:REC_REC, "invisible", 0.0);
237                                 }
238                         }
239                         program { name: "set_pause_state";
240                                 source: "program";
241                                 signal: "state,pause";
242                                 script {
243                                         set_state(PART:RECORDING_IMAGE, "pause", 0.0);
244                                         set_state(PART:RECORDING_TEXT, "default", 0.0);
245                                         //set_state(PART:REC_PAUSE, "invisible", 0.0);
246                                         //set_state(PART:REC_REC, "default", 0.0);
247                                 }
248                         }
249                         program{ name : "set_press";
250                                 signal : "mouse,down,1";
251                                 source: RECORDING_STOP_BUTTON;
252                                 action: STATE_SET "press" 0.0;
253                                 target: RECORDING_STOP_BUTTON;
254                         }
255 #endif
256
257                         program { name: "hide_indicator";
258                                 source: "program";
259                                 signal: "indicator,hide";
260                                 script {
261                                         set_state(PART:RECORDING_IMAGE, "invisible", 0.0);
262                                         set_state(PART:RECORDING_TEXT, "invisible", 0.0);
263                                 }
264                         }
265                         program { name: "show_indicator";
266                                 source: "program";
267                                 signal: "indicator,show";
268                                 script {
269                                         set_state(PART:RECORDING_IMAGE, "pause", 0.0);
270                                         set_state(PART:RECORDING_TEXT, "default", 0.0);
271                                 }
272                         }
273                 }
274         }
275 }
276 //endfile