From: seolheui,kim Date: Wed, 16 Nov 2016 08:51:45 +0000 (+0900) Subject: Modify setup-wizard and keyguard UI X-Git-Tag: accepted/tizen/3.0/common/20161122.195113 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=17f50602a3e02251da0447f043fb93f9696a43b7;p=platform%2Fcore%2Fsecurity%2Fkrate.git Modify setup-wizard and keyguard UI Change-Id: Ia33b51304234deca39f32d7aeebd123be7ce8f45 Signed-off-by: seolheui,kim --- diff --git a/tools/apps/keyguard/res/edje/keyguard.edc b/tools/apps/keyguard/res/edje/keyguard.edc index 4fd6bf4..08ae41e 100644 --- a/tools/apps/keyguard/res/edje/keyguard.edc +++ b/tools/apps/keyguard/res/edje/keyguard.edc @@ -16,28 +16,54 @@ * limitations under the License. * */ -group { name: "base_layout"; + +group { name: "keyguard_layout"; images { - image: "../images/theme_bg.png" COMP; image: "../images/icon.png" COMP; } parts { part { name: "bg"; - type: IMAGE; + type: RECT; scale: 1; description { state: "default" 0.0; + color: 55 166 184 255; rel1 { relative : 0.0 0.0;} rel2 { relative : 1.0 1.0;} - image.normal: "../images/theme_bg.png"; + } + } + part { name: "bg1"; + type: RECT; + scale: 1; + description { state: "default" 0.0; + color: 0 0 0 25; + rel1 { relative: 0.0 0.0;} + rel2 { relative: 1.0 1.0;} + } + } + part { name: "top_padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 0.0;} + rel2 { relative: 1.0 0.0; offset: 0 160;} + } + } + part { name: "icon_area"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative : 0.0 1.0; to: "top_padding";} + rel2 { relative : 1.0 1.0; to: "top_padding"; offset: 0 110;} } } part { name: "icon"; type:IMAGE; scale: 1; description { state: "default" 0.0; - rel1 { relative : 0.0 0.0; to: "bg"; offset: 0 50;} - rel2 { relative : 1.0 0.2; to: "bg"; offset: 0 0;} max: 110 110; + min: 110 110; + rel1 { relative : 0.0 0.0; to: "icon_area";} + rel2 { relative : 1.0 1.0; to: "icon_area";} align: 0.5 0.5; image.normal: "../images/icon.png"; } @@ -49,18 +75,26 @@ group { name: "base_layout"; description { state: "default" 0.0; color: 255 255 255 255; color3: 85 88 88 255; - rel1 { relative: 0.0 1.0; to_x: "bg"; to_y: "icon"; offset: 22 22;} - rel2 { relative: 1.0 1.0; to_x: "bg"; to_y: "icon"; offset: -22 72;} + rel1 { relative: 0.0 1.0; to: "icon_area"; offset: 22 0;} + rel2 { relative: 1.0 1.0; to: "icon_area"; offset: -22 150;} text { font: "Tizen:style=Regular"; size: "40"; align: 0.5 0.5; text: "Krate";} } } + part { name: "title_bottom_padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "title";} + rel2 { relative: 1.0 1.0; to: "title"; offset: 0 20;} + } + } part { name: "entry_info_text"; type: TEXT; scale: 1; description { state: "default" 0.0; color: 255 255 255 255; - rel1 { relative: 0.0 1.0; to: "title"; offset: 0 80;} - rel2 { relative: 1.0 1.0; to: "title"; offset: 0 120;} + rel1 { relative: 0.0 1.0; to: "title_bottom_padding";} + rel2 { relative: 1.0 1.0; to: "title_bottom_padding"; offset: 0 40;} text { font: "Tizen:style=Regular"; size: "24"; align: 0.0 0.5; text: "Enter password";} } } @@ -81,12 +115,28 @@ group { name: "base_layout"; rel2 { relative: 1.0 1.0; to: "entry_bg";} } } + part { name: "check_top_padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "entry_bg";} + rel2 { relative: 1.0 1.0; to: "entry_bg"; offset: 0 22;} + } + } + part { name: "check_area"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "check_top_padding"; offset: 0 0;} + rel2 { relative: 1.0 1.0; to: "check_top_padding"; offset: 0 60;} + } + } part { name: "check_box"; type: SWALLOW; scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 0.4; to: "bg"; offset: 22 22;} - rel2 { relative: 0.1 0.4; to: "bg"; offset: 0 82;} + rel1 { relative: 0.0 0.0; to: "check_area";} + rel2 { relative: 0.0 1.0; to: "check_area"; offset: 50 0;} } } part { name: "check_text"; @@ -94,8 +144,9 @@ group { name: "base_layout"; scale: 1; description { state: "default" 0.0; rel1 { relative: 1.0 0.0; to: "check_box"; offset: 22 0;} - rel2 { relative: 1.0 1.0; to_x: "bg"; to_y: "check_box"; offset: -22 0;} + rel2 { relative: 1.0 1.0; to: "check_area"; offset: 0 0;} text { font: "Tizen:style=Regular"; size: "24"; align: 0.0 0.5; text: "Show password";} + align: 0.0 0.5; } } part { name: "bottom_text"; @@ -103,8 +154,8 @@ group { name: "base_layout"; scale: 1; description { state: "default" 0.0; color: 255 255 255 255; - rel1 { relative: 0.0 0.6; to: "bg"; offset: 22 0;} - rel2 { relative: 1.0 0.6; to: "bg"; offset: -22 40;} + rel1 { relative: 0.0 1.0; to: "bg"; offset: 22 -160;} + rel2 { relative: 1.0 1.0; to: "bg"; offset: -22 0;} text { font: "Tizen:style=Regular"; size: "24"; align: 0.0 0.5; text: "Forgot your Krate unlock method?";} } } diff --git a/tools/apps/keyguard/res/images/icon.png b/tools/apps/keyguard/res/images/icon.png index bea2daf..9765b1b 100644 Binary files a/tools/apps/keyguard/res/images/icon.png and b/tools/apps/keyguard/res/images/icon.png differ diff --git a/tools/apps/keyguard/res/images/theme_bg.png b/tools/apps/keyguard/res/images/theme_bg.png deleted file mode 100644 index feb089a..0000000 Binary files a/tools/apps/keyguard/res/images/theme_bg.png and /dev/null differ diff --git a/tools/apps/keyguard/src/ui.c b/tools/apps/keyguard/src/ui.c index 45a649c..edd7734 100644 --- a/tools/apps/keyguard/src/ui.c +++ b/tools/apps/keyguard/src/ui.c @@ -81,6 +81,7 @@ static void __text_clicked_cb(void *data, Evas_Object *obj, const char *emission void _create_keyguard_window(void) { Evas_Object *conform; + Evas_Object *base_layout; Evas_Object *entry; Evas_Object *checkbox; @@ -101,10 +102,15 @@ void _create_keyguard_window(void) /* Create main UI widget */ ud.win = _create_win(PACKAGE); conform = _create_conformant(ud.win); - ud.layout = _create_layout(conform, ud.edj_path, "base_layout"); + + base_layout = _create_layout(conform, NULL, NULL); + elm_object_content_set(conform, base_layout); + + ud.layout = _create_layout(base_layout, ud.edj_path, "keyguard_layout"); entry = _create_entry(ud.layout); elm_object_part_content_set(ud.layout, "entry", entry); + elm_object_focus_set(entry, EINA_TRUE); evas_object_smart_callback_add(entry, "activated", __entry_activate_cb, NULL); evas_object_smart_callback_add(entry, "press", __entry_change_cb, NULL); @@ -115,8 +121,7 @@ void _create_keyguard_window(void) elm_object_signal_callback_add(ud.layout, "text_clicked", "layout", __text_clicked_cb, NULL); - elm_object_content_set(conform, ud.layout); - + elm_object_part_content_set(base_layout, "elm.swallow.content", ud.layout); evas_object_show(ud.win); return; } diff --git a/tools/apps/keyguard/src/widget.c b/tools/apps/keyguard/src/widget.c index c92b902..0bc0c09 100644 --- a/tools/apps/keyguard/src/widget.c +++ b/tools/apps/keyguard/src/widget.c @@ -33,12 +33,14 @@ Evas_Object *_create_win(const char *package) efl_util_set_notification_window_level(win, EFL_UTIL_NOTIFICATION_LEVEL_DEFAULT); /* [TBD] enable : eext_win_keygrab_set(win, "XF86Home"); */ - elm_win_conformant_set(win, EINA_FALSE); + elm_win_indicator_mode_set(win, ELM_WIN_INDICATOR_SHOW); + elm_win_indicator_opacity_set(win, ELM_WIN_INDICATOR_BG_TRANSPARENT); + + elm_win_alpha_set(win, EINA_TRUE); + elm_win_conformant_set(win, EINA_TRUE); evas_object_smart_callback_add(win, "delete,request", __win_delete_request_cb, NULL); - elm_win_indicator_mode_set(win, ELM_WIN_INDICATOR_SHOW); - elm_win_indicator_opacity_set(win, ELM_WIN_INDICATOR_TRANSPARENT); eext_object_event_callback_add(win, EEXT_CALLBACK_BACK, __win_delete_request_cb, NULL); return win; } @@ -49,6 +51,7 @@ Evas_Object *_create_conformant(Evas_Object *parent) evas_object_size_hint_weight_set(conform, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); elm_win_resize_object_add(parent, conform); + elm_object_signal_emit(conform, "elm,state,indicator,overlap", "elm"); evas_object_show(conform); @@ -83,6 +86,7 @@ Evas_Object *_create_entry(Evas_Object *parent) elm_entry_password_set(entry, EINA_TRUE); elm_entry_single_line_set(entry, EINA_TRUE); elm_entry_markup_filter_append(entry, elm_entry_filter_limit_size, &limit_size); + elm_entry_input_panel_return_key_type_set(entry, ELM_INPUT_PANEL_RETURN_KEY_TYPE_DONE); evas_object_show(entry); return entry; diff --git a/tools/apps/setup-wizard/include/setup-text.h b/tools/apps/setup-wizard/include/setup-text.h index ca4a792..602c6db 100644 --- a/tools/apps/setup-wizard/include/setup-text.h +++ b/tools/apps/setup-wizard/include/setup-text.h @@ -20,23 +20,26 @@ #ifndef __SETUP_TEXT_H__ #define __SETUP_TEXT_H__ -#define SUB_TITLE_STYLE_B "DEFAULT='font=Tizen:style=Regular font_size=40 color=#ffffff wrap=mixed align=center'" -#define SUB_CONTENT_STYLE_B "DEFAULT='font=Tizen:style=Regular font_size=34 color=#ffffff wrap=mixed align=center'" +#define SUB_TITLE_STYLE_B "DEFAULT='font=Tizen:style=Regular font_size=50 color=#000000 wrap=mixed align=center'" +#define SUB_CONTENT_STYLE_B "DEFAULT='font=Tizen:style=Regular font_size=36 color=#000000 wrap=mixed align=center'" -#define SUB_TITLE_STYLE_W "DEFAULT='font=Tizen:style=Regular font_size=40 color=#000000 wrap=mixed align=center'" -#define SUB_CONTENT_STYLE_W "DEFAULT='font=Tizen:style=Regular font_size=34 color=#000000 wrap=mixed align=center'" +#define SUB_TITLE_STYLE_W "DEFAULT='font=Tizen:style=Regular font_size=50 color=#ffffff wrap=mixed align=center'" +#define SUB_CONTENT_STYLE_W "DEFAULT='font=Tizen:style=Regular font_size=36 color=#ffffff wrap=mixed align=center'" -#define WELCOME_MESSAGE_TITLE "Welcome" -#define WELCOME_MESSAGE_CONTENT "Use your applications separately
with SZ.
The folder will be created on your
personal home screen." +#define ENTRY_TITLE_STYLE_B "DEFAULT='font=Tizen:style=Regular font_size=36 color=#000000 wrap=mixed'" +#define ENTRY_INFO_STYLE_G "DEFAULT='font=Tizen:style=Regular font_size=32 color=#A9A9A9 wrap=mixed'" -#define DELETE_MESSAGE_TITLE "Deletion" -#define DELETE_MESSAGE_CONTENT "The folder will be removed from
your personal home screen." +#define WELCOME_MESSAGE_TITLE "Welcome!" +#define WELCOME_MESSAGE_CONTENT "Save your apps in %s to have separate
versions for different purposes.
The %s folder will be created on your
home screen." -#define SETUP_MESSAGE_TITLE "Creating Folder instance..." -#define SETUP_MESSAGE_CONTENT "The folder will be created on your
presonal home screen." +#define DELETE_MESSAGE_TITLE "Delete %s" +#define DELETE_MESSAGE_CONTENT "The folder and all the files stored
in it will be deleted, and all the
apps in it will be unistalled." -#define DELETE_ONGOING_TITLE "Deleting a folder..." -#define DELETE_ONGOING_CONTENT "The folder will be removed from
your personal home screen." +#define SETUP_MESSAGE_TITLE "Creating Folder..." +#define SETUP_MESSAGE_CONTENT "The folder will be created on your home
screen. The preloaded apps will be
added to this folder automatically. You
can also add other apps." + +#define DELETE_ONGOING_TITLE "Deleting Folder..." +#define DELETE_ONGOING_CONTENT "The folder and all the files stored in it will be deleted,
and all the apps in it will be uninstalled." #define NOTI_CREATE_KRATE "Separated krate creation" #define NOTI_BODY_CREATE_KRATE "Tap heare to create Separated Krate." diff --git a/tools/apps/setup-wizard/res/edje/layout.edc b/tools/apps/setup-wizard/res/edje/layout.edc index 8b521cf..5fb5aac 100644 --- a/tools/apps/setup-wizard/res/edje/layout.edc +++ b/tools/apps/setup-wizard/res/edje/layout.edc @@ -20,7 +20,7 @@ group { name: "base_layout"; parts { part { name: "base"; type: RECT; - scale: 0; + scale: 1; repeat_events: 0; description { state: "default" 0.0; rel1 { relative : 0.0 0.0;} @@ -29,7 +29,7 @@ group { name: "base_layout"; } part { name: "content_layout"; type: SWALLOW; - scale: 0; + scale: 1; description { state: "default" 0.0; rel1 { relative: 0.0 0.0; to: "base";} rel2 { relative: 1.0 0.0; to: "bottom_layout";} @@ -37,9 +37,9 @@ group { name: "base_layout"; } part { name: "bottom_layout"; type: SWALLOW; - scale: 0; + scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 1.0; to: "base"; offset: 0 -162;} + rel1 { relative: 0.0 1.0; to: "base"; offset: 0 -172;} rel2 { relative: 1.0 1.0; to: "base";} } } @@ -50,16 +50,25 @@ group { name: "two_button_layout"; parts { part { name: "base"; type: RECT; - scale: 0; + scale: 1; description { state: "default" 0.0; rel1 { relative: 0.0 0.0; } rel2 { relative: 1.0 1.0; } - color: 255 255 255 255; + color: 55 166 184 255; + } + } + part { name: "base2"; + type: RECT; + scale: 1; + description { state: "default" 0.0; + rel1 {relative: 0.0 0.0; to: "base";} + rel2 {relative: 1.0 1.0; to: "base";} + color: 0 0 0 25; } } part { name: "prev_button"; type: SWALLOW; - scale: 0; + scale: 1; description { state: "default" 0.0; rel1 { relative: 0.0 0.0; to: "base"; offset: 22 22;} rel2 { relative: 0.5 1.0; to: "base"; offset: -22 -22;} @@ -67,7 +76,7 @@ group { name: "two_button_layout"; } part { name: "next_button"; type: SWALLOW; - scale: 0; + scale: 1; description { state: "default" 0.0; rel1 { relative: 1.0 0.0; to_x: "prev_button"; to_y: "base"; offset: 22 22;} rel2 { relative: 1.0 1.0; to: "base"; offset: -22 -22;} diff --git a/tools/apps/setup-wizard/res/edje/security.edc b/tools/apps/setup-wizard/res/edje/security.edc index 3cdb12d..afe9d4f 100644 --- a/tools/apps/setup-wizard/res/edje/security.edc +++ b/tools/apps/setup-wizard/res/edje/security.edc @@ -2,60 +2,77 @@ group { name: "security_layout"; parts { part { name: "bg"; type: RECT; - scale: 0; + scale: 1; repeat_events: 0; description { state: "default" 0.0; + color: 255 255 255 255; rel1 { relative: 0.0 0.0;} rel2 { relative: 1.0 1.0;} - min: 720 600; - max: 720 800; - visible: 0; + } + } + part { name: "title_top_padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 0.0; to: "bg"; offset: 45 0;} + rel2 { relative: 1.0 0.0; to: "bg"; offset: -45 45;} } } part { name: "title"; - type: TEXT; - scale: 0; + type: SWALLOW; + scale: 1; description { state: "default" 0.0; - color: 0 0 0 255; - rel1 { relative: 0.0 0.1; to: "bg"; offset: 45 0;} - rel2 { relative: 1.0 0.1; to: "bg"; offset: -45 40;} - text { font: "Tizen:style=Regular"; size: "32"; align: 0.0 0.5; } + rel1 { relative: 0.0 1.0; to: "title_top_padding";} + rel2 { relative: 1.0 1.0; to: "title_top_padding"; offset: 0 40;} } } - part { name: "entry_bg"; - type: RECT; - scale: 0; + part { name: "title_bottom_padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "title";} + rel2 { relative: 1.0 1.0; to: "title"; offset: 0 20;} + } + } + part { name: "entry_area"; + type: SPACER; + scale: 1; description { state: "default" 0.0; - color: 255 255 255 0; - rel1 { relative: 0.0 0.2; to: "bg"; offset: 45 0;} - rel2 { relative: 1.0 0.2; to: "bg"; offset: -45 60;} + rel1 { relative: 0.0 1.0; to: "title_bottom_padding";} + rel2 { relative: 1.0 1.0; to: "title_bottom_padding"; offset: 0 60;} } } part { name: "entry"; type: SWALLOW; - scale: 0; + scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 0.0; to: "entry_bg";} - rel2 { relative: 1.0 1.0; to: "entry_bg";} + rel1 { relative: 0.0 0.0; to: "entry_area";} + rel2 { relative: 1.0 1.0; to: "entry_area";} } } - part { name: "entry_separator"; + part { name: "entry_separator"; type: RECT; - scale: 0; + scale: 1; description { state: "default" 0.0; color: 7 180 211 250; - rel1 { relative: 0.0 1.0; to: "entry";} - rel2 { relative: 1.0 1.0; to: "entry"; offset: 0 2;} + rel1 { relative: 0.0 1.0; to: "entry_area";} + rel2 { relative: 1.0 1.0; to: "entry_area"; offset: 0 2;} + } + } + part { name: "entry_bottom_padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "entry_area";} + rel2 { relative: 1.0 1.0; to: "entry_area"; offset: 0 24;} } } part { name: "entry_info"; - type: TEXT; - scale: 0; + type: SWALLOW; + scale: 1; description { state: "default" 0.0; - color: 140 140 140 255; - rel1 { relative: 0.0 0.3; to: "bg"; offset: 45 22;} - rel2 { relative: 1.0 0.3; to: "bg"; offset: -45 62;} - text { font: "Tizen:style=Regular"; size: "32"; align: 0.0 0.5; } + rel1 { relative: 0.0 1.0; to: "entry_bottom_padding";} + rel2 { relative: 1.0 1.0; to: "entry_bottom_padding"; offset: 0 60;} } } } diff --git a/tools/apps/setup-wizard/res/edje/setup.edc b/tools/apps/setup-wizard/res/edje/setup.edc index 6262019..2e986e3 100644 --- a/tools/apps/setup-wizard/res/edje/setup.edc +++ b/tools/apps/setup-wizard/res/edje/setup.edc @@ -1,76 +1,172 @@ +/* + * Tizen Krate Setup-Wizard Layout + * + * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * 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. + * + */ group { name: "setup_layout"; images { image: "../images/icon.png" COMP; } parts { - part { name: "bg"; + part { name: "bg1"; type: RECT; scale: 1; description { state: "default" 0.0; - color: 228 228 228 255; + color: 55 166 184 255; rel1 { relative: 0.0 0.0; } rel2 { relative: 1.0 1.0; } } } + part { name: "bg2"; + type: RECT; + scale: 1; + description { state: "default" 0.0; + color: 0 0 0 25; + rel1 { relative: 0.0 0.0; to: "bg1";} + rel2 { relative: 1.0 1.0; to: "bg1";} + } + } + part { name: "bg_top_padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 {relative: 0.0 0.0; to: "bg1";} + rel2 {relative: 1.0 0.0; to: "bg1"; offset: 0 40;} + } + } + part { name: "title_area"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "bg_top_padding";} + rel2 { relative: 1.0 1.0; to: "bg_top_padding"; offset: 0 150;} + } + } part { name: "title"; type: TEXT; scale: 1; + effect: SHADOW; description { state: "default" 0.0; - color: 0 0 0 255; - rel1 { relative: 0.0 0.0; to: "bg"; offset: 22 150;} - rel2 { relative: 1.0 0.0; to: "bg"; offset: -22 300;} - text { font: "Tizen:style=Regular"; size: "48"; align: 0.5 0.5; text: "Separated Krate";} + color: 255 255 255 255; + color3: 85 88 88 255; + rel1 { relative: 0.0 0.0; to: "title_area"; } + rel2 { relative: 1.0 1.0; to: "title_area"; } + text { font: "Tizen:style=Regular"; size: "36"; align: 0.5 0.5; text: "Separated Krate";} } } - part { name: "icon_base"; - type: RECT; + part { name: "top_padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "title_area";} + rel2 { relative: 1.0 1.0; to: "title_area"; offset: 0 162;} + } + } + part { name: "contents_area"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "top_padding";} + rel2 { relative: 1.0 1.0; to: "top_padding"; offset: 0 493;} + } + } + part { name: "app_icon_area"; + type: SPACER; scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 1.0; to_x: "bg"; to_y: "title"; offset: 0 80;} - rel2 { relative: 1.0 1.0; to_x: "bg"; to_y: "title"; offset: 0 350;} - visible: 0; + rel1 { relative: 0.0 0.0; to: "contents_area";} + rel2 { relative: 1.0 0.0; to: "contents_area"; offset: 0 160;} } } - part { name: "icon"; + part { name: "app_icon"; type: IMAGE; scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 0.0; to: "icon_base";} - rel2 { relative: 1.0 1.0; to: "icon_base";} - align: 0.5 0.0; - max: 170 170; + min: 118 118; + max: 118 118; + rel1 { relative: 0.0 0.0; to: "app_icon_area";} + rel2 { relative: 1.0 1.0; to: "app_icon_area";} + align: 0.5 0.5; image.normal: "../images/icon.png"; } } - part { name: "progressbar_msg"; + part { name: "message_title"; type: SWALLOW; scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 1.0; to_x: "bg"; to_y: "icon_base"; offset: 22 50;} - rel2 { relative: 1.0 1.0; to_x: "bg"; to_y: "icon_base"; offset: -22 150;} + rel1 { relative: 0.0 1.0; to: "app_icon_area"; offset: 32 0;} + rel2 { relative: 1.0 1.0; to: "app_icon_area"; offset: -32 67;} } } - part { name: "progressbar"; - type: SWALLOW; + part { name: "message_top_padding"; + type: SPACER; scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 1.0; to_x: "bg"; to_y: "progressbar_msg"; offset: 22 22;} - rel2 { relative: 1.0 1.0; to_x: "bg"; to_y: "progressbar_msg"; offset: -22 52;} + rel1 { relative: 0.0 1.0; to: "message_title";} + rel2 { relative: 1.0 1.0; to: "message_title"; offset: 0 42;} } } - part { name: "content_text"; + part { name: "progress_area"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "message_top_padding";} + rel2 { relative: 1.0 1.0; to: "message_top_padding"; offset: 0 114;} + } + } +#if 0 + part { name: "progress_percentage"; + type: TEXT; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 0.0; to: "progress_area";} + rel2 { relative: 1.0 0.0; to: "progress_area"; offset: 0 54;} + } + } +#endif + part { name: "progress_top_padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 0.0; to: "progress_area";} + rel2 { relative: 1.0 0.0; to: "progress_area"; offset: 0 66;} + } + } + part { name: "progress_indicator"; type: SWALLOW; scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 1.0; to_x: "bg"; to_y: "progressbar"; offset: 22 0;} - rel2 { relative: 1.0 1.0; to: "bg"; offset: -22 0;} + rel1 { relative: 0.0 1.0; to: "progress_top_padding";} + rel2 { relative: 1.0 1.0; to: "progress_top_padding"; offset: 0 48;} } } - part { name: "bottom_pending"; + part { name: "progress_bottom_padding"; type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "progress_area";} + rel2 { relative: 1.0 1.0; to: "progress_area"; offset: 0 49;} + } + } + part { name: "message_content"; + type: SWALLOW; + scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 1.0; to: "bg"; offset: 0 -162;} - rel2 { relative: 1.0 1.0; to: "bg";} + rel1 { relative: 0.0 1.0; to: "progress_bottom_padding";} + rel2 { relative: 1.0 1.0; to: "progress_bottom_padding"; offset: 0 208;} } } } diff --git a/tools/apps/setup-wizard/res/edje/welcome.edc b/tools/apps/setup-wizard/res/edje/welcome.edc index 382e402..d1dc64e 100644 --- a/tools/apps/setup-wizard/res/edje/welcome.edc +++ b/tools/apps/setup-wizard/res/edje/welcome.edc @@ -22,13 +22,38 @@ group { name: "welcome_layout"; image: "../images/theme_bg.png" COMP; } parts { - part { name: "bg"; - type: IMAGE; + part { name: "bg1"; + type: RECT; scale: 1; description { state: "default" 0.0; + color: 55 166 184 255; rel1 { relative: 0.0 0.0; } rel2 { relative: 1.0 1.0; } - image.normal: "../images/theme_bg.png"; + } + } + part { name: "bg2"; + type: RECT; + scale: 1; + description { state: "default" 0.0; + color: 0 0 0 25; + rel1 { relative: 0.0 0.0; to: "bg1";} + rel2 { relative: 1.0 1.0; to: "bg1";} + } + } + part { name: "bg_top_padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 {relative: 0.0 0.0; to: "bg1";} + rel2 {relative: 1.0 0.0; to: "bg1"; offset: 0 40;} + } + } + part { name: "title_area"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "bg_top_padding";} + rel2 { relative: 1.0 1.0; to: "bg_top_padding"; offset: 0 150;} } } part { name: "title"; @@ -38,54 +63,70 @@ group { name: "welcome_layout"; description { state: "default" 0.0; color: 255 255 255 255; color3: 85 88 88 255; - rel1 { relative: 0.0 0.0; to: "bg"; offset: 22 150;} - rel2 { relative: 1.0 0.0; to: "bg"; offset: -22 300;} - text { font: "Tizen:style=Regular"; size: "48"; align: 0.5 0.5; text: "Separated Krate";} + rel1 { relative: 0.0 0.0; to: "title_area"; } + rel2 { relative: 1.0 1.0; to: "title_area"; } + text { font: "Tizen:style=Regular"; size: "36"; align: 0.5 0.5; text: "Separated Krate";} } } - part { name: "icon_base"; - type: RECT; + part { name: "top_padding"; + type: SPACER; scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 1.0; to_x: "bg"; to_y: "title"; offset: 0 80;} - rel2 { relative: 1.0 1.0; to_x: "bg"; to_y: "title"; offset: 0 350;} - visible: 0; + rel1 { relative: 0.0 1.0; to: "title_area";} + rel2 { relative: 1.0 1.0; to: "title_area"; offset: 0 162;} } } - part { name: "icon"; - type: IMAGE; + part { name: "contents_area"; + type: SPACER; scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 0.0; to: "icon_base";} - rel2 { relative: 1.0 1.0; to: "icon_base";} - align: 0.5 0.0; - max: 170 170; - image.normal: "../images/icon.png"; + rel1 { relative: 0.0 1.0; to: "top_padding";} + rel2 { relative: 1.0 1.0; to: "top_padding"; offset: 0 493;} } } - part { name: "top_padding"; - type: RECT; + part { name: "app_icon_area"; + type: SPACER; scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 1.0; to: "icon_base"; } - rel2 { relative: 1.0 1.0; to: "icon_base"; offset: 0 80;} - visible: 0; + rel1 { relative: 0.0 0.0; to: "contents_area";} + rel2 { relative: 1.0 0.0; to: "contents_area"; offset: 0 160;} + } + } + part { name: "app_icon"; + type: IMAGE; + scale: 1; + description { state: "default" 0.0; + min: 118 118; + max: 118 118; + rel1 { relative: 0.0 0.0; to: "app_icon_area";} + rel2 { relative: 1.0 1.0; to: "app_icon_area";} + align: 0.5 0.5; + image.normal: "../images/icon.png"; } } part { name: "message_title"; type: SWALLOW; scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 1.0; to: "top_padding";} - rel2 { relative: 1.0 1.0; to: "top_padding"; offset: 0 50;} + color: 255 255 255 255; + rel1 { relative: 0.0 1.0; to: "app_icon_area"; offset: 32 0;} + rel2 { relative: 1.0 1.0; to: "app_icon_area"; offset: -32 67;} + } + } + part { name: "message_top_padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + rel1 { relative: 0.0 1.0; to: "message_title";} + rel2 { relative: 1.0 1.0; to: "message_title"; offset: 0 58;} } } part { name: "message_content"; type: SWALLOW; scale: 1; description { state: "default" 0.0; - rel1 { relative: 0.0 1.0; to: "message_title"; offset: 0 22;} - rel2 { relative: 1.0 1.0; to: "bg";} + rel1 { relative: 0.0 1.0; to: "message_top_padding";} + rel2 { relative: 1.0 1.0; to: "message_top_padding"; offset: 0 208;} } } } diff --git a/tools/apps/setup-wizard/src/security.c b/tools/apps/setup-wizard/src/security.c index 05f472d..bf711ad 100644 --- a/tools/apps/setup-wizard/src/security.c +++ b/tools/apps/setup-wizard/src/security.c @@ -140,6 +140,7 @@ static void security_lock_type_select_cb(void *data, Evas_Object *obj, void *eve static Eina_Bool security_view_pop_cb(void *data, Elm_Object_Item *it) { + elm_win_indicator_opacity_set(ud.win, ELM_WIN_INDICATOR_BG_TRANSPARENT); elm_object_signal_emit(ud.conform, "elm,state,indicator,overlap", "elm"); return EINA_TRUE; @@ -171,7 +172,8 @@ static void security_previous_view_cb(void *data, Evas_Object *obj, void *event_ static void security_password_setup_cb(void *data, Evas_Object *obj, void *event_info) { appdata_s *ad = (appdata_s *)data; - Evas_Object *entry; + Evas_Object *entry, *entry_text; + if (security_passphrase_mode < PASSPHRASE_STATE_VERIFY) { security_passphrase_mode++; entry = (Evas_Object *)evas_object_data_get(ud.nf, "setup_entry"); @@ -186,7 +188,8 @@ static void security_password_setup_cb(void *data, Evas_Object *obj, void *event elm_entry_input_panel_hide(entry); Evas_Object *layout = (Evas_Object *)evas_object_data_get(ud.nf, "layout"); - elm_object_part_text_set(layout, "entry_info", "Password do not matched."); + entry_text = _create_textblock(layout, "Password do not matched.", ENTRY_INFO_STYLE_G); + elm_object_part_content_set(layout, "entry_info", entry_text); dlog_print(DLOG_ERROR, LOG_TAG, "Password not matched"); return; } @@ -198,6 +201,7 @@ static void security_password_setup_cb(void *data, Evas_Object *obj, void *event ui_app_exit(); } + elm_win_indicator_opacity_set(ud.win, ELM_WIN_INDICATOR_BG_TRANSPARENT); elm_object_signal_emit(ud.conform, "elm,state,indicator,overlap", "elm"); _create_setup_view(ad); } @@ -227,46 +231,15 @@ static void security_password_entry_changed_cb(void *data, Evas_Object *obj, voi elm_object_disabled_set(button, EINA_TRUE); } -static Evas_Object *security_password_setup_content_get(void *data, Evas_Object *obj, const char *part) -{ - if (!strcmp(part, "elm.swallow.content")) { - Evas_Object *layout, *entry; - - layout = _create_layout(obj, ud.edj_path, "security_layout"); - - entry = _create_entry(obj); - elm_object_part_text_set(layout, "title", "Enter password"); - elm_object_part_content_set(layout, "entry", entry); - evas_object_smart_callback_add(entry, "unfocused", security_password_entry_unfocused_cb, data); - evas_object_smart_callback_add(entry, "changed", security_password_entry_changed_cb, NULL); - elm_entry_input_panel_return_key_disabled_set(entry, EINA_TRUE); - - if (security_passphrase_mode < PASSPHRASE_STATE_VERIFY) - evas_object_data_set(ud.nf, "setup_entry", entry); - else - evas_object_data_set(ud.nf, "verify_entry", entry); - - evas_object_data_set(ud.nf, "layout", layout); - - return layout; - } - - return NULL; -} - static void create_password_setup_view(appdata_s *ad) { - char** entry; + char** entry_data; const char* title; Elm_Object_Item *item; - Elm_Genlist_Item_Class *itc; - Evas_Object *genlist, *layout, *left_button, *right_button; + Evas_Object *layout, *left_button, *right_button; + Evas_Object *security_layout, *entry, *entry_title; layout = _create_layout(ud.nf, ud.edj_path, "base_layout"); - genlist = elm_genlist_add(layout); - elm_layout_content_set(layout, "content_layout", genlist); - elm_object_style_set(genlist, "solid/default"); - elm_genlist_mode_set(genlist, ELM_LIST_COMPRESS); left_button = _create_button(layout, PREV_BUTTON, security_previous_view_cb, NULL); right_button = _create_button(layout, NEXT_BUTTON, security_password_setup_cb, ad); @@ -275,17 +248,35 @@ static void create_password_setup_view(appdata_s *ad) _create_two_button_layout(layout, left_button, right_button); if (security_passphrase_mode == 1) { - entry = &security_password_setup_data; + entry_data = &security_password_setup_data; title = "Setup Password"; evas_object_data_set(ud.nf, "setup_button", right_button); } else { - entry = &security_password_verify_data; + entry_data = &security_password_verify_data; title = "Verify Password"; evas_object_data_set(ud.nf, "verify_button", right_button); } - itc = _create_genlist_item_class("full", NULL, security_password_setup_content_get); - item = _append_genlist_item(genlist, itc, ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY, (void **)entry); + security_layout = _create_layout(layout, ud.edj_path, "security_layout"); + + entry = _create_entry(security_layout); + entry_title = _create_textblock(security_layout, "Enter Password", ENTRY_TITLE_STYLE_B); + elm_object_part_content_set(security_layout, "title", entry_title); + elm_object_part_content_set(security_layout, "entry", entry); + evas_object_smart_callback_add(entry, "unfocused", security_password_entry_unfocused_cb, entry_data); + evas_object_smart_callback_add(entry, "changed", security_password_entry_changed_cb, NULL); + + elm_entry_input_panel_return_key_disabled_set(entry, EINA_TRUE); + elm_object_focus_set(entry, EINA_TRUE); + + if (security_passphrase_mode < PASSPHRASE_STATE_VERIFY) + evas_object_data_set(ud.nf, "setup_entry", entry); + else + evas_object_data_set(ud.nf, "verify_entry", entry); + + evas_object_data_set(ud.nf, "layout", security_layout); + + elm_object_part_content_set(layout, "content_layout", security_layout); item = elm_naviframe_item_push(ud.nf, title, NULL, NULL, layout, NULL); elm_naviframe_item_title_enabled_set(item, EINA_TRUE, EINA_TRUE); @@ -299,6 +290,7 @@ void _create_security_view(appdata_s *ad) Elm_Genlist_Item_Class *itc; Evas_Object *genlist, *layout, *left_button, *right_button; + elm_win_indicator_opacity_set(ud.win, ELM_WIN_INDICATOR_OPAQUE); elm_object_signal_emit(ud.conform, "elm,state,indicator,nooverlap", "elm"); layout = _create_layout(ud.nf, ud.edj_path, "base_layout"); diff --git a/tools/apps/setup-wizard/src/ui.c b/tools/apps/setup-wizard/src/ui.c index 30be539..1db8b33 100644 --- a/tools/apps/setup-wizard/src/ui.c +++ b/tools/apps/setup-wizard/src/ui.c @@ -161,6 +161,8 @@ static void __create_welcome_view(appdata_s *ad) Evas_Object *layout, *welcome_layout; Evas_Object *title, *content; Evas_Object *left_button, *right_button; + char title_text[PATH_MAX]; + char content_text[PATH_MAX]; char *welcome_text[2][4] = { {WELCOME_MESSAGE_TITLE, WELCOME_MESSAGE_CONTENT, CANCEL_BUTTON, NEXT_BUTTON}, @@ -168,18 +170,23 @@ static void __create_welcome_view(appdata_s *ad) }; char **text = NULL; - if (!strcmp(ad->mode, "create")) + if (!strcmp(ad->mode, "create")) { text = welcome_text[0]; - else + snprintf(title_text, PATH_MAX, "%s", text[0]); + snprintf(content_text, PATH_MAX, text[1], ad->krate_name, ad->krate_name); + } else { text = welcome_text[1]; + snprintf(title_text, PATH_MAX, text[0], ad->krate_name); + snprintf(content_text, PATH_MAX, "%s", text[1]); + } elm_object_signal_emit(ud.conform, "elm,state,indicator,overlap", "elm"); layout = _create_layout(ud.nf, ud.edj_path, "base_layout"); welcome_layout = _create_layout(layout, ud.edj_path, "welcome_layout"); - title = _create_textblock(welcome_layout, text[0], SUB_TITLE_STYLE_B); - content = _create_textblock(welcome_layout, text[1], SUB_CONTENT_STYLE_B); + title = _create_textblock(welcome_layout, title_text, SUB_TITLE_STYLE_W); + content = _create_textblock(welcome_layout, content_text, SUB_CONTENT_STYLE_W); elm_object_part_content_set(welcome_layout, "message_title", title); elm_object_part_content_set(welcome_layout, "message_content", content); @@ -223,12 +230,12 @@ void _create_setup_view(appdata_s *ad) title = _create_textblock(setup_layout, text[0], SUB_TITLE_STYLE_W); content = _create_textblock(setup_layout, text[1], SUB_CONTENT_STYLE_W); - elm_object_part_content_set(setup_layout, "progressbar_msg", title); + elm_object_part_content_set(setup_layout, "message_title", title); progressbar = _create_progressbar(setup_layout, "pending"); - elm_object_part_content_set(setup_layout, "progressbar", progressbar); + elm_object_part_content_set(setup_layout, "progress_indicator", progressbar); - elm_object_part_content_set(setup_layout, "content_text", content); + elm_object_part_content_set(setup_layout, "message_content", content); nf_it = elm_naviframe_item_push(ud.nf, NULL, NULL, NULL, setup_layout, NULL); elm_naviframe_item_title_enabled_set(nf_it, EINA_FALSE, EINA_TRUE); diff --git a/tools/apps/setup-wizard/src/widget.c b/tools/apps/setup-wizard/src/widget.c index 6a94dc4..61e466a 100644 --- a/tools/apps/setup-wizard/src/widget.c +++ b/tools/apps/setup-wizard/src/widget.c @@ -31,6 +31,7 @@ Evas_Object *_create_win(const char *package) win = elm_win_add(NULL, package, ELM_WIN_BASIC); elm_win_indicator_mode_set(win, ELM_WIN_INDICATOR_SHOW); + elm_win_indicator_opacity_set(win, ELM_WIN_INDICATOR_BG_TRANSPARENT); elm_win_conformant_set(win, EINA_TRUE); elm_win_autodel_set(win, EINA_TRUE);