/* * Copyright 2012 Samsung Electronics Co., Ltd * * Licensed under the Flora License, Version 1.1 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://floralicense.org/license/ * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #include "cam_funcs.edc" #include "../include/edc_image_name.h" collections { group { name: "main_layout"; parts { part { name: "transparent_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "guideline_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "shot_guide_popup_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "indicator_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "recording_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "mouse_event_layer"; type: RECT; mouse_events: 1; description { state: "default" 0.0; rel1 { relative: 0.0 0.0; offset: 0 0; } rel2 { relative: 1.0 1.0; offset: -1 -1; } color : 0 0 0 0; } } part { name: "timer_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "best_photo_thumbnail_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "progressbar_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "progress_popup_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "tip_popup_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "pinch_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "zoom_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "ev_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } part { name: "toolbar_layout"; type: SWALLOW; scale: 1; description { state: "default" 0.0; } } } } #include "cam_guideline_edje.edc" group { name: "progressbar"; min: MAIN_W MAIN_H; parts { #define PROGRESS_BAR_X 320 #define PROGRESS_BAR_Y 657 #define PROGRESS_BAR_W 639 #define PROGRESS_BAR_H 20 part { name: "progressbar"; type: SWALLOW; description { state: "default" 0.0; fixed:1 1; visible: 0; rel1 { relative: PROGRESS_BAR_X/MAIN_W PROGRESS_BAR_Y/MAIN_H; } rel2 { relative: (PROGRESS_BAR_X+PROGRESS_BAR_W)/MAIN_W (PROGRESS_BAR_Y+PROGRESS_BAR_H)/MAIN_H; } } description { state: "landscape" 0.0; fixed:1 1; visible: 1; rel1 { relative: PROGRESS_BAR_X/MAIN_W PROGRESS_BAR_Y/MAIN_H; } rel2 { relative: (PROGRESS_BAR_X+PROGRESS_BAR_W)/MAIN_W (PROGRESS_BAR_Y+PROGRESS_BAR_H)/MAIN_H; } } description { state: "vertical" 0.0; fixed:1 1; visible: 1; rel1 { relative: PROGRESS_BAR_X/MAIN_W (PROGRESS_BAR_Y - 60)/MAIN_H; } rel2 { relative: (PROGRESS_BAR_X+PROGRESS_BAR_W)/MAIN_W (PROGRESS_BAR_Y+PROGRESS_BAR_H - 60)/MAIN_H; } } } part { name: "progressbar_text"; type: TEXT; scale: 1; description { state: "default" 0.0; rel1 { relative: 1.0 (-20)/PROGRESS_BAR_H; to: "progressbar"; } rel2 { relative: (1.0+90/PROGRESS_BAR_W) (1.0+20/PROGRESS_BAR_H); to: "progressbar"; } color: FONT_COLOR; text { font : FONT_NAME; size : 28; align: 0.5 0.5; } } description { state: "vertical" 0.0; rel1 { relative: 1.0 (-20)/PROGRESS_BAR_H; to: "progressbar"; } rel2 { relative: (1.0+90/PROGRESS_BAR_W*MAIN_W/MAIN_H) (1.0+20/PROGRESS_BAR_H); to: "progressbar"; } color: FONT_COLOR; text { font : FONT_NAME; size : 28; align: 0.5 0.5; } } } } programs { program { name: "progressbar,default"; source: "prog"; signal: "progressbar,default"; script: { set_state(PART:"progressbar", "landscape", 0.0); set_state(PART:"progressbar_text", "default", 0.0); } } program { name: "progressbar,vertical"; source: "prog"; signal: "progressbar,vertical"; script: { set_state(PART:"progressbar", "vertical", 0.0); set_state(PART:"progressbar_text", "vertical", 0.0); } } } } group { name: "shutter_image"; min: MAIN_W MAIN_H; parts { part { name: "camera_image_bg"; type: RECT; description { state: "default" 0.0; rel1 { relative: 0.0 0.0; offset: 0 0; } rel2 { relative: 1.0 1.0; offset: -1 -1; } color : 0 0 0 0; } description { state: "gray" 0.0; rel1 { relative: 0.0 0.0; offset: 0 0; } rel2 { relative: 1.0 1.0; offset: -1 -1; } color : 0 0 0 180; } } part { name: "up_part"; type: RECT; description { state: "default" 0.0; rel1 { relative: 0.0 0.0; offset: 0 0; to : "camera_image_bg"; } rel2 { relative: 1.0 0.0; offset: -1 0; to : "camera_image_bg"; } color : 0 0 0 255; // visible: 1; } description { state: "middle" 0.0; rel1 { relative: 0.0 0.0; offset: 0 0; to : "camera_image_bg"; } rel2 { relative: 1.0 0.5; offset: -1 -1; to : "camera_image_bg"; } color : 0 0 0 255; // visible: 0; } } part { name: "down_part"; type: RECT; description { state: "default" 0.0; rel1 { relative: 0.0 1.0; offset: 0 -1; to : "camera_image_bg"; } rel2 { relative: 1.0 1.0; offset: -1 -1; to : "camera_image_bg"; } color : 0 0 0 255; // visible: 1; } description { state: "middle" 0.0; rel1 { relative: 0.0 0.5; offset: 0 -1; to : "camera_image_bg"; } rel2 { relative: 1.0 1.0; offset: -1 -1; to : "camera_image_bg"; } color : 0 0 0 255; // visible: 0; } } } programs { program { name: "close"; signal: "start_animation"; source: "*"; action: STATE_SET "middle" 0.0; target: "up_part" ; target: "down_part" ; transition: ACCELERATE 0.25; after: "open"; } program { name: "open"; signal: "open"; source: "*"; action: STATE_SET "default" 0.0; target: "up_part" ; target: "down_part" ; transition: DECELERATE 0.25; } program { name: "dim"; signal: "dim"; source: "*"; action: STATE_SET "gray" 0.0; target: "camera_image_bg" ; } program { name: "bright"; signal: "bright"; source: "*"; action: STATE_SET "default" 0.0; target: "camera_image_bg" ; transition: DECELERATE 0.2; after: "animation_finish"; } program { name: "animation_finish"; signal: "animation_finish"; source: "*"; action: SIGNAL_EMIT "animation_finish" "*"; } } } group { name: "shutter_rect"; min: MAIN_W MAIN_H; parts { part { name: "shutter_rect_bg"; type: RECT; scale: 1; description { state: "default" 0.0; rel1 { relative: 0.0 0.0;} rel2 { relative: 1.0 1.0;} color : 0 0 0 0; } description { state: "gray" 0.0; rel1 { relative: 0.0 0.0;} rel2 { relative: 1.0 1.0;} color : 0 0 0 180; } } part { name: "point_0"; type: RECT; scale: 1; description { state: "default" 0.0; min: 1 1; max: 1 1; fixed: 1 1; align: 0.0 0.0; rel1 { relative: 0.0 0.0; to : "shutter_rect_bg"; } rel2 { relative: 0.0 0.0; to : "shutter_rect_bg"; } color : 255 255 255 0; visible: 0; } description { state: "end" 0.0; inherit: "default" 0.0; min: 15 15; max: 15 15; fixed: 1 1; } } part { name: "point_1"; type: RECT; scale: 1; description { state: "default" 0.0; min: 1 1; max: 1 1; fixed: 1 1; align: 1.0 0.0; rel1 { relative: 1.0 0.0; to : "shutter_rect_bg"; } rel2 { relative: 1.0 0.0; to : "shutter_rect_bg"; } color : 255 255 255 0; visible: 0; } description { state: "end" 0.0; inherit: "default" 0.0; min: 15 15; max: 15 15; fixed: 1 1; } } part { name: "point_2"; type: RECT; scale: 1; description { state: "default" 0.0; min: 1 1; max: 1 1; fixed: 1 1; align: 1.0 1.0; rel1 { relative: 1.0 1.0; to : "shutter_rect_bg"; } rel2 { relative: 1.0 1.0; to : "shutter_rect_bg"; } color : 255 255 255 0; visible: 0; } description { state: "end" 0.0; inherit: "default" 0.0; min: 15 15; max: 15 15; fixed: 1 1; } } part { name: "point_3"; type: RECT; scale: 1; description { state: "default" 0.0; min: 1 1; max: 1 1; fixed: 1 1; align: 0.0 1.0; rel1 { relative: 0.0 1.0; to : "shutter_rect_bg"; } rel2 { relative: 0.0 1.0; to : "shutter_rect_bg"; } color : 255 255 255 0; visible: 0; } description { state: "end" 0.0; inherit: "default" 0.0; min: 15 15; max: 15 15; fixed: 1 1; } } part { name: "top"; type: RECT; scale: 1; description { state: "default" 0.0; rel1 { relative: 0.0 0.0; offset: 0 0; to_x : "point_0"; to_y : "point_0";} rel2 { relative: 0.0 1.0; offset: 0 0; to_x : "point_1"; to_y : "point_1";} color : 255 255 255 200; visible: 1; } } part { name: "right"; type: RECT; scale: 1; description { state: "default" 0.0; rel1 { relative: 0.0 0.0; offset: 1 0; to_x : "point_1"; to_y : "point_1";} rel2 { relative: 1.0 1.0; offset: 0 0; to_x : "point_2"; to_y : "point_2";} color : 255 255 255 200; visible: 1; } } part { name: "bottom"; type: RECT; scale: 1; description { state: "default" 0.0; rel1 { relative: 0.0 0.0; offset: 0 0; to_x : "point_3"; to_y : "point_3";} rel2 { relative: 0.0 1.0; offset: 0 0; to_x : "point_2"; to_y : "point_2";} color : 255 255 255 200; visible: 1; } } part { name: "left"; type: RECT; scale: 1; description { state: "default" 0.0; rel1 { relative: 0.0 1.0; offset: 0 1; to_x : "point_0"; to_y : "point_0";} rel2 { relative: 1.0 0.0; offset: 0 -1; to_x : "point_3"; to_y : "point_3";} color : 255 255 255 200; visible: 1; } } } programs { program { name: "shutter_rect,start"; signal: "shutter_rect,start"; source: "prog"; action: STATE_SET "end" 0.0; target: "point_0"; target: "point_1"; target: "point_2"; target: "point_3"; transition: DECELERATE 0.20; after: "shutter_rect,finish"; } program { name: "shutter_rect,finish"; signal: "shutter_rect,finish"; source: "*"; action: SIGNAL_EMIT "shutter_rect,finish" "*"; } } } }