Name: wifi-efl-ug
Summary: Wi-Fi UI Gadget for TIZEN
-Version: 1.0.248
+Version: 1.0.249
Release: 1
Group: App/Network
License: Flora-1.1
if (index == I18N_TYPE_WPS_PIN)
elm_object_item_signal_emit(event_info, "elm,state,bottomline,hide", "");
+
+ if (common_util_get_ug_type() == UG_VIEW_IOT_COMMON)
+ elm_object_item_signal_emit(event_info, "elm,state,bottomline,hide", "elm");
}
void create_wps_options_popup(Evas_Object *win_main,
elm_object_focus_set(obj, EINA_FALSE);
}
+static void _chk_changed_cb(void *data, Evas_Object *obj, void *ei)
+{
+ if (!data || !obj)
+ return;
+
+ Eina_Bool state = elm_check_state_get(obj);
+ pswd_popup_t *pswd_popup_data = (pswd_popup_t *)data;
+
+ if (state)
+ elm_entry_password_set(pswd_popup_data->entry, EINA_FALSE);
+ else
+ elm_entry_password_set(pswd_popup_data->entry, EINA_TRUE);
+
+ elm_entry_cursor_end_set(pswd_popup_data->entry);
+}
+
+// IOT only
+static void __pswd_entry_set_show_password_check(Evas_Object *parent, pswd_popup_t *data)
+{
+ Evas_Object *check = elm_check_add(parent);
+
+ elm_object_style_set(check, "show_password");
+ elm_check_state_set(check, EINA_FALSE);
+ elm_object_part_content_set(parent, "elm.swallow.end", check);
+
+ evas_object_propagate_events_set(check, EINA_FALSE);
+ evas_object_size_hint_align_set(check, EVAS_HINT_FILL, EVAS_HINT_FILL);
+ evas_object_size_hint_weight_set(check, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_smart_callback_add(check, "changed", _chk_changed_cb, data);
+
+ evas_object_show(check);
+}
+
static Evas_Object* _gl_pswd_entry_item_content_get(void *data,
Evas_Object *obj, const char *part)
{
if (!g_strcmp0(part, g_genlist_info[WIFI_GENLIST_FULL_STYLE].content_part)) {
editfield = elm_layout_add(obj);
- elm_layout_theme_set(editfield, "layout", "editfield", "singleline");
+
+ if (common_util_get_ug_type() == UG_VIEW_IOT_COMMON) {
+ elm_layout_file_set(editfield, CUSTOM_EDITFIELD_PATH, "password");
+ __pswd_entry_set_show_password_check(editfield, pswd_popup_data);
+ } else {
+ elm_layout_theme_set(editfield, "layout", "editfield", "singleline");
+ }
+
evas_object_size_hint_align_set(editfield, EVAS_HINT_FILL, 0.0);
evas_object_size_hint_weight_set(editfield, EVAS_HINT_EXPAND, 0.0);
entry = elm_entry_add(editfield);
return NULL;
}
-static void _chk_changed_cb(void *data, Evas_Object *obj, void *ei)
-{
- if (obj == NULL)
- return;
-
- Eina_Bool state = elm_check_state_get(obj);
- pswd_popup_t *pswd_popup_data = (pswd_popup_t *)data;
-
- if (state)
- elm_entry_password_set(pswd_popup_data->entry, EINA_FALSE);
- else
- elm_entry_password_set(pswd_popup_data->entry, EINA_TRUE);
-
- elm_entry_cursor_end_set((Evas_Object *)data);
-}
static char *_gl_pswd_check_box_item_text_get(void *data, Evas_Object *obj,
const char *part)
{
EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
evas_object_size_hint_align_set(genlist, EVAS_HINT_FILL, EVAS_HINT_FILL);
- /* Entry genlist item */
+ /* Entry genlist item for password entry */
g_pswd_entry_itc.item_style = g_genlist_info[WIFI_GENLIST_FULL_STYLE].style_name;
g_pswd_entry_itc.func.text_get = NULL;
g_pswd_entry_itc.func.content_get = _gl_pswd_entry_item_content_get;
- g_check_box_itc.func.state_get = NULL;
- g_check_box_itc.func.del = NULL;
+ g_pswd_entry_itc.func.state_get = NULL;
+ g_pswd_entry_itc.func.del = NULL;
Elm_Object_Item * entry_item = elm_genlist_item_append(genlist,
&g_pswd_entry_itc, pswd_popup_data,
NULL, ELM_GENLIST_ITEM_NONE, NULL, NULL);
- /* Checkbox genlist item */
- g_check_box_itc.item_style = g_genlist_info[WIFI_GENLIST_1LINE_STYLE].style_name;
- g_check_box_itc.func.text_get = _gl_pswd_check_box_item_text_get;
- g_check_box_itc.func.content_get = _gl_pswd_check_box_item_content_get;
- g_check_box_itc.func.state_get = NULL;
- g_check_box_itc.func.del = NULL;
-
- elm_genlist_item_append(genlist, &g_check_box_itc, pswd_popup_data,
- NULL, ELM_GENLIST_ITEM_NONE,
- _gl_pswd_check_box_sel, pswd_popup_data);
+ if (common_util_get_ug_type() != UG_VIEW_IOT_COMMON) {
+ /* Checkbox genlist item for showing passsword */
+ g_check_box_itc.item_style = g_genlist_info[WIFI_GENLIST_1LINE_STYLE].style_name;
+ g_check_box_itc.func.text_get = _gl_pswd_check_box_item_text_get;
+ g_check_box_itc.func.content_get = _gl_pswd_check_box_item_content_get;
+ g_check_box_itc.func.state_get = NULL;
+ g_check_box_itc.func.del = NULL;
+
+ elm_genlist_item_append(genlist, &g_check_box_itc, pswd_popup_data,
+ NULL, ELM_GENLIST_ITEM_NONE,
+ _gl_pswd_check_box_sel, pswd_popup_data);
+ }
if (popup_info->show_wps_btn) {
/* WPS options genlist item */
elm_object_content_set(passpopup, genlist);
+ evas_object_smart_callback_add(genlist, "realized", _gl_realized, NULL);
evas_object_smart_callback_add(passpopup, "show,finished",
popup_animation_finish_cb, entry_item);
evas_object_show(passpopup);
--- /dev/null
+#define SHOW_PASSWORD_CHECKED_BG "wifi_icon_eye_pw_visible.png"
+#define SHOW_PASSWORD_UNCHECKED_BG "wifi_icon_eye_pw_invisible.png"
+
+#define CUSTOM_CHECK_TRANSITION_TIME 0
+#define CUSTOM_CHECK_TRANSITION_TYPE LINEAR CUSTOM_CHECK_TRANSITION_TIME
+#define CUSTOM_CHECK_SIZE 32 22
+
+#define COLOR_TRANSPARENT 0 0 0 0
+
+group { "elm/check/event/default";
+ inherit_only: 1;
+ parts {
+ rect { "event";
+ desc { "default";
+ color: COLOR_TRANSPARENT;
+ vis;
+ }
+ desc { "disabled";
+ inherit: "default";
+ hid;
+ }
+ desc { "checked";
+ inherit: "default";
+ }
+ }
+ }
+ programs {
+ program { "clicked";
+ signal: "mouse,clicked,1";
+ source: "event";
+ sequence {
+ action: SIGNAL_EMIT "elm,action,click" "";
+ action: SIGNAL_EMIT "elm,action,check,toggle" "";
+ }
+ after: "on_clicked";
+ }
+ program { "pressed";
+ signal: "mouse,down,1*";
+ source: "event";
+ action: SIGNAL_EMIT "elm,action,press" "";
+ after: "on_pressed";
+ }
+ program { "unpressed";
+ signal: "mouse,up,1";
+ source: "event";
+ action: SIGNAL_EMIT "elm,action,unpress" "";
+ after: "on_unpressed";
+ }
+ program { "set_check";
+ signal: "elm,state,check,on";
+ source: "elm";
+ after: "on_set_check";
+ }
+ program { "unset_check";
+ signal: "elm,state,check,off";
+ source: "elm";
+ after: "on_unset_check";
+ }
+ program { "disabled";
+ signal: "elm,state,disabled";
+ source: "elm";
+ after: "on_disabled";
+ }
+ program { "enabled";
+ signal: "elm,state,enabled";
+ source: "elm";
+ after: "on_enabled";
+ }
+ }
+}
+
+group { "elm/check/base/template";
+ inherit: "elm/check/event/default";
+ nomouse;
+ parts {
+ spacer { "base";
+ desc { "default";
+ }
+ }
+ }
+ programs {
+ program { name: "on_set_check";
+ //Can be overriden in inheriting class
+ }
+ program { name: "on_unset_check";
+ //Can be overriden in inheriting class
+ }
+ program { name: "on_pressed";
+ //Can be overriden in inheriting class
+ }
+ program { name: "on_unpressed";
+ //Can be overriden in inheriting class
+ }
+ program { name: "on_clicked";
+ //Can be overriden in inheriting class
+ }
+ program { name: "on_disabled";
+ //Can be overriden in inheriting class
+ }
+ program { name: "on_enabled";
+ //Can be overriden in inheriting class
+ }
+ }
+}
+
+group { "elm/check/base/show_password";
+ inherit: "elm/check/base/template";
+ nomouse;
+
+ images {
+ image: SHOW_PASSWORD_CHECKED_BG COMP;
+ image: SHOW_PASSWORD_UNCHECKED_BG COMP;
+ }
+
+ parts {
+ image { "bg";
+ desc { "default";
+ image.normal: SHOW_PASSWORD_UNCHECKED_BG;
+ min: CUSTOM_CHECK_SIZE;
+ max: CUSTOM_CHECK_SIZE;
+ }
+ desc { "checked"
+ inherit: "default";
+ image.normal: SHOW_PASSWORD_CHECKED_BG;
+ }
+ }
+ }
+
+ program { name: "on_set_check";
+ action: STATE_SET "checked";
+ target: "bg";
+ transition: CUSTOM_CHECK_TRANSITION_TYPE;
+ }
+
+ program { name: "on_unset_check";
+ action: STATE_SET "default";
+ target: "bg";
+ transition: CUSTOM_CHECK_TRANSITION_TYPE;
+ }
+}
#define WPS_POPUP_SLIDER_VIEW_LAYOUT_PADDING_TOP_MIN_INC 266 28
#define WPS_POPUP_SLIDER_VIEW_LAYOUT_SWALLOW_MIN_INC 266 10
+// Define macros for password editfield
+#define PASSWORD_EDITFIELD_BG_HEIGHT_INC 120
+#define PASSWORD_EDITFIELD_PADDING_MIN_INC 32 33
+
+#define PASSWORD_EDITFIELD_PADDING_LINE_LEFT_MIN_INC 32 0
+#define PASSWORD_EDITFIELD_PADDING_LINE_RIGHT_MIN_INC 64 0
+#define PASSWORD_EDITFIELD_PADDING_LINE_BOTTOM_MIN_INC 0 20
+#define PASSWORD_EDITFIELD_LINE_RECT_MIN_INC 0 2
+
+#define PASSWORD_EDITFIELD_PADDING_ELM_SWALLOW_CONTENT_MIN_INC 10 0
+#define PASSWORD_EDITFIELD_ELM_SWALLOW_CONTENT_ALIGN 0.5 0.5
+#define PASSWORD_EDITFIELD_ELM_SWALLOW_CONTENT_MIN_INC 0 54
+
+#define PASSWORD_EDITFIELD_PADDING_ELM_SWALLOW_BUTTON_RIGHT_MIN_INC 56 0
+#define PASSWORD_EDITFIELD_ELM_SWALLOW_BUTTON_MIN_INC 14 14
+
+#define PASSWORD_EDITFIELD_ELM_SWALLOW_END_MIN_INC 18 18
+#define PASSWORD_EDITFIELD_PADDING_SWALLOW_END_LEFT_MIN_INC 32 0
+
#define BUTTON_BG_SIZE 96 96
#define BUTTON_CIRCLE_SIZE 46 46
RESOURCE_IMAGE("core_button_effect_normal.#.png");
RESOURCE_IMAGE("core_button_effect_pressed.#.png");
RESOURCE_IMAGE("find_hidden_network.png");
+RESOURCE_IMAGE("wifi_icon_eye_pw_invisible.png");
+RESOURCE_IMAGE("wifi_icon_eye_pw_visible.png");
+RESOURCE_IMAGE("micro_x.png");
base_scale: 1.8;
plugins {
}
}
+#include "custom_check.edc"
+
group {
name: "popup_pbc_button_layout";
styles {
}
}
}
+group { "password";
+ parts {
+ rect { "clipper";
+ desc { "default";
+ color: 255 255 255 255;
+ }
+ }
+ rect { "bg";
+ scale;
+ clip: "clipper";
+ desc { "default";
+ min: 0 PASSWORD_EDITFIELD_BG_HEIGHT_INC;
+ color: 0 0 0 0;
+ }
+ }
+ spacer { "padding_top_left";
+ scale;
+ desc { "default";
+ min: PASSWORD_EDITFIELD_PADDING_MIN_INC;
+ fixed: 1 1;
+ align: 0.0 0.0;
+ rel1.to: "bg";
+ rel2.to: "bg";
+ rel2.relative: 0.0 0.0;
+ }
+ }
+ spacer { "padding_bottom_right";
+ scale;
+ desc { "default";
+ min: PASSWORD_EDITFIELD_PADDING_MIN_INC;
+ fixed: 1 1;
+ align: 1.0 1.0;
+ rel1.to: "bg";
+ rel1.relative: 1.0 1.0;
+ rel2.to: "bg";
+ }
+ }
+ spacer { "padding_line_left";
+ scale;
+ desc { "default";
+ min: PASSWORD_EDITFIELD_PADDING_LINE_LEFT_MIN_INC;
+ fixed: 1 0;
+ align: 0.0 0.5;
+ rel1.to: "bg";
+ rel2.to: "bg";
+ rel2.relative: 0.0 1.0;
+ }
+ }
+ spacer { "padding_line_right";
+ scale;
+ desc { "default";
+ min: PASSWORD_EDITFIELD_PADDING_LINE_RIGHT_MIN_INC;
+ fixed: 1 0;
+ align: 1.0 0.5;
+ rel1.to: "bg";
+ rel1.relative: 1.0 0.0;
+ rel2.to: "bg";
+ }
+ }
+ spacer { "padding_line_bottom";
+ scale;
+ desc { "default";
+ min: PASSWORD_EDITFIELD_PADDING_LINE_BOTTOM_MIN_INC;
+ fixed: 0 1;
+ align: 0.5 1.0;
+ rel1.to: "bg";
+ rel1.relative: 0.0 1.0;
+ rel2.to: "bg";
+ }
+ }
+ rect { "line_rect";
+ scale;
+ clip: "clipper";
+ desc { "default";
+ min: PASSWORD_EDITFIELD_LINE_RECT_MIN_INC;
+ fixed: 1 1;
+ align: 0.5 1.0;
+ rel1 {
+ to_x: "padding_line_left";
+ to_y: "padding_line_bottom";
+ relative: 1.0 0.0;
+ }
+ rel2 {
+ to_x: "padding_line_right";
+ to_y: "padding_line_bottom";
+ relative: 0.0 0.0;
+ }
+ color: 128 128 128 166;
+ }
+ desc { "focused";
+ inherit: "default";
+ color: 61 185 204 255;
+ }
+ }
+ spacer { "sizer_elm.swallow.end";
+ scale;
+ desc { "default";
+ min: PASSWORD_EDITFIELD_ELM_SWALLOW_END_MIN_INC;
+ fixed: 1 1;
+ align: 1.0 0.0;
+ rel1 {
+ to_x: "line_rect";
+ to_y: "bg";
+ relative: 1.0 0.3;
+ }
+ rel2 {
+ to: "bg";
+ relative: 1.0 1.0;
+ }
+ }
+ }
+ spacer { "padding_elm.swallow.button_right";
+ scale;
+ desc { "default";
+ min: PASSWORD_EDITFIELD_PADDING_ELM_SWALLOW_BUTTON_RIGHT_MIN_INC;
+ fixed: 1 0;
+ align: 1.0 0.5;
+ rel1 {
+ to: "bg";
+ relative: 1.0 0.0;
+ }
+ rel2.to: "bg";
+ }
+ }
+ spacer { "sizer_elm.swallow.button";
+ scale;
+ desc { "default";
+ min: PASSWORD_EDITFIELD_ELM_SWALLOW_BUTTON_MIN_INC;
+ fixed: 1 1;
+ align: 1.0 1.0;
+ rel1 {
+ to_x: "padding_elm.swallow.button_right";
+ to_y: "bg";
+ relative: 0.0 0.6;
+ }
+ rel2 {
+ to_x: "padding_elm.swallow.button_right";
+ to_y: "bg";
+ relative: 0.0 0.5;
+ }
+ }
+ }
+ spacer { "padding_elm.swallow.button_left";
+ scale;
+ desc { "default";
+ min: PASSWORD_EDITFIELD_PADDING_ELM_SWALLOW_CONTENT_MIN_INC;
+ fixed: 1 0;
+ align: 1.0 0.5;
+ rel1 {
+ to_x: "sizer_elm.swallow.button";
+ to_y: "bg";
+ relative: 0.0 0.0;
+ }
+ rel2 {
+ to_x: "sizer_elm.swallow.button";
+ to_y: "bg";
+ relative: 0.0 1.0;
+ }
+ }
+ }
+ spacer { "padding_elm.swallow.content_left";
+ scale;
+ desc { "default";
+ fixed: 1 0;
+ min: PASSWORD_EDITFIELD_PADDING_ELM_SWALLOW_CONTENT_MIN_INC;
+ align: 0.0 0.5;
+ rel1 {
+ to: "padding_top_left";
+ relative: 1.0 1.0;
+ }
+ rel2 {
+ to_x: "padding_top_left";
+ to_y: "padding_bottom_right";
+ relative: 1.0 0.0;
+ }
+ }
+ }
+ spacer { "padding_elm.swallow.content_right";
+ scale;
+ desc { "default";
+ fixed: 1 0;
+ min: PASSWORD_EDITFIELD_PADDING_ELM_SWALLOW_CONTENT_MIN_INC;
+ align: 1.0 0.5;
+ rel1 {
+ to_x: "padding_bottom_right";
+ to_y: "padding_top_left";
+ relative: 0.0 1.0;
+ }
+ rel2 {
+ to: "padding_bottom_right";
+ relative: 0.0 0.0;
+ }
+ }
+ }
+ spacer { "sizer_elm.swallow.content";
+ scale;
+ desc { "default";
+ min: PASSWORD_EDITFIELD_ELM_SWALLOW_CONTENT_MIN_INC;
+ rel1 {
+ to: "padding_elm.swallow.content_left";
+ relative: 1.0 0.0;
+ }
+ rel2 {
+ to: "padding_elm.swallow.content_right";
+ relative: 0.0 1.0;
+ }
+ }
+ desc { "show_button";
+ inherit: "default";
+ rel2 {
+ to_x: "padding_elm.swallow.button_left";
+ to_y: "padding_elm.swallow.content_right";
+ relative: 0.0 1.0;
+ }
+ }
+ }
+ swallow { "elm.swallow.content";
+ scale;
+ clip: "clipper";
+ desc { "default";
+ align: PASSWORD_EDITFIELD_ELM_SWALLOW_CONTENT_ALIGN;
+ rel.to: "sizer_elm.swallow.content";
+ }
+ }
+ swallow { "elm.swallow.button";
+ scale;
+ clip: "clipper";
+ desc { "default";
+ fixed: 1 0;
+ rel.to: "sizer_elm.swallow.button";
+ vis;
+ }
+ desc { "show_button";
+ inherit: "default";
+ vis;
+ }
+ }
+ swallow { "elm.swallow.end";
+ scale;
+ clip: "clipper";
+ desc { "default";
+ fixed: 1 0;
+ rel.to: "sizer_elm.swallow.end";
+ vis;
+ }
+ }
+ }
+ programs {
+ program { "focused";
+ signal: "elm,state,focused";
+ source: "";
+ action: STATE_SET "focused";
+ target: "line_rect";
+ }
+ program { "unfocused";
+ signal: "elm,state,unfocused";
+ source: "";
+ action: STATE_SET "default";
+ target: "line_rect";
+ }
+ program { "show_button";
+ signal: "elm,action,show,button";
+ source: "";
+ action: STATE_SET "show_button";
+ target: "sizer_elm.swallow.content";
+ target: "elm.swallow.button";
+ }
+ program { "hide_button";
+ signal: "elm,action,hide,button";
+ source: "";
+ action: STATE_SET "default";
+ target: "sizer_elm.swallow.content";
+ target: "elm.swallow.button";
+ }
+ }
+ }
}