--- /dev/null
+/*
+ * Copyright (c) 2015 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.
+ */
+
+styles {
+ style {
+ name, "entry_single_textblock_style";
+ base, "font=TizenSans font_size="32" align=left color=#cccccc wrap=none texti_class=entry left_margin=0 right_margin=0";
+ tag, "br" "";
+ tag, "ps" "";
+ tag, "em" "+ font_style=Oblique";
+ tag, "link" "+ color=#800 underline=on underline_color=#8008";
+ tag, "hilight" "+ font_weight=Bold";
+ tag, "preedit" "+ underline=on underline_color=#000";
+ tag, "preedit_sel" "+ backing=on backing_color=#000 color=#FFFFFF";
+ }
+ style {
+ name, "entry_single_textblock_selected_style";
+ base, "font=TizenSans font_size="32" align=left color=#0077f6 wrap=none text_class=entry left_margin=0 right_margin=0";
+ tag, "br" "";
+ tag, "ps" "";
+ tag, "em" "+ font_style=Oblique";
+ tag, "link" "+ color=#800 underline=on underline_color=#8008";
+ tag, "hilight" "+ font_weight=Bold";
+ tag, "preedit" "+ underline=on underline_color=#000";
+ tag, "preedit_sel" "+ backing=on backing_color=#000 color=#FFFFFF";
+ }
+ style {
+ name, "entry_single_textblock_disabled_style";
+ base, "font=TizenSans font_size="32" align=left color=#c8c8c8 wrap=none text_class=entry left_margin=0 right_margin=0";
+ tag, "br" "";
+ tag, "ps" "";
+ tag, "em" "+ font_style=Oblique";
+ tag, "link" "+ color=#00000080 underline=on underline_color=#00000080";
+ tag, "hilight" "+ font_weight=Bold";
+ tag, "preedit" "+ underline=on underline_color=#000";
+ tag, "preedit_sel" "+ backing=on backing_color=#000 color=#FFFFFF";
+ }
+ style {
+ name, "entry_single_textblock_guide_style";
+ base, "font=TizenSans font_size="32" align=left color=#7f7f7f wrap=none text_class=entry left_margin=0 right_margin=0 ellipsis=0.0";
+ tag, "br" "";
+ tag, "ps" "";
+ tag, "em" "+ font_style=Oblique";
+ tag, "hilight" "+ font_weight=Bold";
+ }
+}
+styles {
+ style {
+ name, "entry_textblock_style";
+ base, "font=TizenSans font_size=32 align=left color=#cccccc wrap=none text_class=entry left_margin=0 right_margin=0";
+ tag, "em" "+ font_style=Oblique";
+ tag, "link" "+ color=#800 underline=on underline_color=#8008";
+ tag, "hilight" "+ font_weight=Bold";
+ tag, "preedit" "+ underline=on underline_color=#000";
+ tag, "preedit_sel" "+ backing=on backing_color=#000 color=#000";
+ }
+ style {
+ name, "entry_textblock_selected_style";
+ base, "font=TizenSans font_size=32 align=left color=#0077f6 wrap=none text_class=entry left_margin=0 right_margin=0";
+ tag, "em" "+ font_style=Oblique";
+ tag, "link" "+ color=#800 underline=on underline_color=#8008";
+ tag, "hilight" "+ font_weight=Bold";
+ tag, "preedit" "+ underline=on underline_color=#000";
+ tag, "preedit_sel" "+ backing=on backing_color=#000 color=#000";
+ }
+ style {
+ name, "entry_textblock_disabled_style";
+ base, "font=TizenSans font_size=32 align=left color=#3d3d3d wrap=none text_class=entry left_margin=0 right_margin=0";
+ tag, "em" "+ font_style=Oblique";
+ tag, "link" "+ color=#00000080 underline=on underline_color=#00000080";
+ tag, "hilight" "+ font_weight=Bold";
+ tag, "preedit" "+ underline=on underline_color=#000";
+ tag, "preedit_sel" "+ backing=on backing_color=#000 color=#000";
+ }
+ style {
+ name, "entry_textblock_guide_style";
+ base, "font=TizenSans font_size=32 align=left color=#7f7f7f wrap=none text_class=entry left_margin=0 right_margin=0 ellipsis=0.0";
+ tag, "em" "+ font_style=Oblique";
+ tag, "hilight" "+ font_weight=Bold";
+ }
+}
+images {
+ image, "search_searchbar_small_bg_foc.png" COMP;
+ image, "search_searchbar_small_bg_nor.png" COMP;
+ image, "search_searchbar_small_bg_dis.png" COMP;
+}
+group {
+ name, "elm/scroller/entry/contents";
+ alias, "elm/scroller/entry_single/contents";
+ parts {
+ part {
+ name, "bg";
+ description {
+ state, "default" 0.0;
+ visible, 0;
+ }
+ }
+ part {
+ name, "pad.left";
+ type, SPACER;
+ scale, 1;
+ description {
+ state, "default" 0.0;
+ min, 28 5;
+ max, 28 5;
+ fixed, 1 1;
+ rel1.to, "bg";
+ align, 0.0 0.0;
+ }
+ }
+ part {
+ name, "pad.right";
+ type, SPACER;
+ scale, 1;
+ description {
+ state, "default" 0.0;
+ min, 30 5;
+ max, 30 5;
+ fixed, 1 1;
+ rel2.to, "bg";
+ align, 1.0 1.0;
+ }
+ }
+ part {
+ name, "base_highlight";
+ after, "bg";
+ scale, 1;
+ description {
+ state, "default" 0.0;
+ rel1.to, "bg";
+ rel2.to, "bg";
+ image {
+ normal, "search_searchbar_small_bg_nor.png";
+ border, 4 4 4 4;
+ border_scale, 1;
+ }
+ }
+ description {
+ state, "selected" 0.0;
+ inherit, "default" 0.0;
+ image.normal, "search_searchbar_small_bg_foc.png";
+ }
+ description {
+ state, "over" 0.0;
+ inherit, "default" 0.0;
+ image.normal, "search_searchbar_small_bg_foc.png";
+ }
+ description {
+ state, "disabled" 0.0;
+ inherit, "default" 0.0;
+ image.normal, "search_searchbar_small_bg_dis.png";
+ }
+ description {
+ state, "highlight" 0.0;
+ inherit, "default" 0.0;
+ image.normal, "search_searchbar_small_bg_foc.png";
+ }
+ description {
+ state, "normal" 0.0;
+ inherit, "default" 0.0;
+ image.normal, "search_searchbar_small_bg_nor.png";
+ }
+ }
+ part {
+ name, "clipper";
+ type, RECT;
+ description {
+ state, "default" 0.0;
+ rel1.to, "pad.left";
+ rel1.relative, 1.0 1.0;
+ rel2.to, "pad.right";
+ rel2.relative, 0.0 0.0;
+ }
+ }
+ part {
+ name, "elm.swallow.content";
+ type, SWALLOW;
+ clip_to, "clipper";
+ description {
+ state, "default" 0.0;
+ rel1.to, "pad.left";
+ rel1.relative, 1.0 1.0;
+ rel2.to, "pad.right";
+ rel2.relative, 0.0 0.0;
+ }
+ }
+ }
+ programs {
+ program {
+ name, "disable";
+ signal, "elm,state,disabled";
+ source, "elm";
+ action, STATE_SET "disabled" 0.0;
+ target, "base_highlight";
+ }
+ program {
+ name, "select";
+ signal, "elm,state,selected";
+ source, "elm";
+ action, STATE_SET "selected" 0.0;
+ target, "base_highlight";
+ }
+ program {
+ name, "over";
+ signal, "elm,state,mouse,in";
+ source, "elm";
+ action, STATE_SET "over" 0.0;
+ target, "base_highlight";
+ }
+ program {
+ name, "enable";
+ signal, "elm,state,enabled";
+ source, "elm";
+ action, STATE_SET "default" 0.0;
+ target, "base_highlight";
+ }
+ program {
+ name, "go_active";
+ signal, "elm,state,selected";
+ source, "elm";
+ action, STATE_SET "selected" 0.0;
+ target, "base_highlight";
+ }
+ program {
+ name, "go_passive";
+ signal, "elm,state,unselected";
+ source, "elm";
+ action, STATE_SET "default" 0.0;
+ target, "base_highlight";
+ }
+ program {
+ name, "highlight_show";
+ signal, "elm,action,focus_highlight,show";
+ source, "elm";
+ action, STATE_SET "selected" 0.0;
+ transition, ACCELERATE 0.01;
+ target, "base_highlight";
+ }
+ program {
+ name, "highlight_hide";
+ signal, "elm,action,focus_highlight,hide";
+ source, "elm";
+ action, STATE_SET "normal" 0.0;
+ transition, DECELERATE 0.01;
+ target, "base_highlight";
+ }
+ }
+}
+group {
+ name, "elm/entry/base/contents";
+ alias, "elm/entry/base/default";
+ data {
+ item, "focus_highlight" "on";
+ }
+ parts {
+ part {
+ name, "elm.guide";
+ type, TEXTBLOCK;
+ mouse_events, 0;
+ scale, 1;
+ description {
+ state, "default" 0.0;
+ rel1.to, "elm.text";
+ rel2.to, "elm.text";
+ text {
+ style, "entry_textblock_guide_style";
+ min, 0 1;
+ }
+ }
+ description {
+ state, "hidden" 0.0;
+ inherit, "default" 0.0;
+ visible, 0;
+ }
+ }
+ part {
+ name, "elm.text";
+ type, TEXTBLOCK;
+ mouse_events, 1;
+ scale, 1;
+ entry_mode, EDITABLE;
+ select_mode, DEFAULT;
+ cursor_mode, BEFORE;
+ multiline, 0;
+ source, "elm/entry/selection/contents";
+ source4, "elm/entry/cursor/contents";
+ source5, "elm/entry/anchor/contents";
+ description {
+ state, "default" 0.0;
+ text {
+ style, "entry_textblock_style";
+ min, 0 1;
+ align, 0.0 0.5;
+ }
+ }
+ description {
+ state, "disabled" 0.0;
+ inherit, "default" 0.0;
+ text {
+ style, "entry_textblock_disabled_style";
+ min, 0 1;
+ }
+ }
+ description {
+ state, "selected" 0.0;
+ inherit, "default" 0.0;
+ text {
+ style, "entry_textblock_selected_style";
+ min, 0 1;
+ }
+ }
+ description {
+ state, "highlight" 0.0;
+ inherit, "default" 0.0;
+ text {
+ style, "entry_textblock_selected_style";
+ min, 0 1;
+ }
+ }
+ description {
+ state, "enabled" 0.0;
+ inherit, "default" 0.0;
+ text {
+ style, "entry_textblock_style";
+ min, 0 1;
+ }
+ }
+ }
+ }
+ programs {
+ program {
+ name, "focus";
+ signal, "load";
+ source, "";
+ action, FOCUS_SET;
+ target, "elm.text";
+ }
+ program {
+ name, "disable";
+ signal, "elm,state,disabled";
+ source, "elm";
+ action, STATE_SET "disabled" 0.0;
+ target, "elm.text";
+ }
+ program {
+ name, "select";
+ signal, "elm,state,selected";
+ source, "elm";
+ action, STATE_SET "selected" 0.0;
+ target, "elm.text";
+ }
+ program {
+ name, "over";
+ signal, "elm,state,mouse,in";
+ source, "elm";
+ action, STATE_SET "over" 0.0;
+ target, "elm.text";
+ }
+ program {
+ name, "enable";
+ signal, "elm,state,enabled";
+ source, "elm";
+ action, STATE_SET "default" 0.0;
+ target, "elm.text";
+ target, "elm.guide";
+ }
+ program {
+ name, "go_active";
+ signal, "elm,state,selected";
+ source, "elm";
+ action, STATE_SET "selected" 0.0;
+ target, "elm.text";
+ target, "elm.guide";
+ }
+ program {
+ name, "go_passive";
+ signal, "elm,state,unselected";
+ source, "elm";
+ action, STATE_SET "default" 0.0;
+ target, "elm.text";
+ target, "elm.guide";
+ }
+ program {
+ name, "gdisable";
+ signal, "elm,guide,disabled";
+ source, "elm";
+ action, STATE_SET "hidden" 0.0;
+ target, "elm.guide";
+ }
+ program {
+ name, "genable";
+ signal, "elm,guide,enabled";
+ source, "elm";
+ action, STATE_SET "default" 0.0;
+ target, "elm.guide";
+ }
+ program {
+ name, "highlight_show";
+ signal, "elm,action,focus_highlight,show";
+ source, "elm";
+ action, STATE_SET "selected" 0.0;
+ transition, ACCELERATE 0.01;
+ target, "elm.text";
+ }
+ program {
+ name, "highlight_hide";
+ signal, "elm,action,focus_highlight,hide";
+ source, "elm";
+ action, STATE_SET "normal" 0.0;
+ transition, DECELERATE 0.01;
+ target, "elm.text";
+ }
+ }
+}
+group {
+ name, "elm/entry/base-single/contents";
+ inherit, "elm/entry/base/contents";
+ parts {
+ part {
+ name, "elm.guide";
+ type, TEXTBLOCK;
+ mouse_events,0;
+ scale, 1;
+ description {
+ state, "default" 0.0;
+ rel1.to, "elm.text";
+ rel2.to, "elm.text";
+ text {
+ style, "entry_single_textblock_guide_style";
+ min, 0 1;
+ }
+ }
+ description {
+ state, "hidden" 0.0;
+ inherit, "default" 0.0;
+ visible, 0;
+ }
+ }
+ part {
+ name, "elm.text";
+ type, TEXTBLOCK;
+ mouse_events, 1;
+ scale, 1;
+ multiline, 0;
+ description {
+ state, "default" 0.0;
+ text {
+ style, "entry_single_textblock_style";
+ min, 1 1;
+ ellipsis, -1;
+ max, 0 0;
+ align, 0.0 0.5;
+ }
+ }
+ description {
+ state, "disabled" 0.0;
+ inherit, "default" 0.0;
+ text {
+ style, "entry_single_textblock_disabled_style";
+ }
+ }
+ description {
+ state, "selected" 0.0;
+ inherit, "default" 0.0;
+ text {
+ style, "entry_single_textblock_selected_style";
+ min, 0 1;
+ }
+ }
+ description {
+ state, "enabled" 0.0;
+ inherit, "default" 0.0;
+ text {
+ style, "entry_single_textblock_style";
+ min, 0 1;
+ }
+ }
+ }
+ }
+}
+group {
+ name, "elm/entry/base-single-noedit/contents";
+ inherit, "elm/entry/base/contents";
+ parts {
+ part {
+ name, "elm.guide";
+ type, TEXTBLOCK;
+ mouse_events, 0;
+ scale, 1;
+ description {
+ state, "default" 0.0;
+ rel1.to, "elm.text";
+ rel2.to, "elm.text";
+ text {
+ style, "entry_single_textblock_guide_style";
+ min, 0 1;
+ }
+ }
+ description {
+ state, "hidden" 0.0;
+ inherit, "default" 0.0;
+ visible, 0;
+ }
+ }
+ part {
+ name, "elm.text";
+ entry_mode, PLAIN;
+ multiline, 0;
+ scale, 1;
+ source, "elm/entry/selection/contents";
+ source4, "";
+ source5,"elm/entry/anchor/contents";
+ description {
+ state, "default" 0.0;
+ text {
+ style, "entry_single_textblock_style";
+ min, 1 1;
+ ellipsis, -1;
+ max, 0 0;
+ align, 0.0 0.5;
+ }
+ }
+ description {
+ state, "disabled" 0.0;
+ inherit, "default" 0.0;
+ text {
+ style, "entry_single_textblock_disabled_style";
+ }
+ }
+ }
+ }
+}
+group {
+ name, "elm/entry/selection/contents";
+ parts {
+ part {
+ name, "bg";
+ type, RECT;
+ mouse_events, 0;
+ scale, 1;
+ description {
+ state, "default" 0.0;
+ color, 128 128 128 128;
+ }
+ }
+ }
+}
+group {
+ name, "elm/entry/anchor/contents";
+ parts {
+ part {
+ name, "bg";
+ type, RECT;
+ mouse_events, 0;
+ scale, 1;
+ description {
+ state, "default" 0.0;
+ color, 128 0 0 64;
+ }
+ }
+ }
+}
+group {
+ name, "elm/entry/cursor/contents";
+ parts {
+ part {
+ name, "base";
+ type, SPACER;
+ scale, 1;
+ description {
+ state, "default" 0.0;
+ }
+ }
+ part {
+ name, "cursor";
+ type, RECT;
+ mouse_events, 0;
+ scale, 1;
+ description {
+ state, "default" 0.0;
+ min, 2 36;
+ max, 2 36;
+ fixed, 1 1;
+ color, 69 143 255 255;
+ visible, 0;
+ }
+ description {
+ state, "visible" 0.0;
+ inherit, "default" 0.0;
+ visible, 1;
+ }
+ }
+ }
+ programs {
+ program {
+ name, "blink";
+ action, STATE_SET "visible" 0.0;
+ in, 0.4 0.0;
+ target, "cursor";
+ after, "blink2";
+ }
+ program {
+ name, "blink2";
+ action, STATE_SET "default" 0.0;
+ in, 0.4 0.0;
+ target, "cursor";
+ after, "blink";
+ }
+ program {
+ name, "focused";
+ signal, "elm,action,focus";
+ source, "elm";
+ after, "blink";
+ }
+ program {
+ name, "noblink";
+ action, ACTION_STOP;
+ target, "blink";
+ target, "blink2";
+ after, "noblink2";
+ }
+ program {
+ name, "noblink2";
+ action, STATE_SET "default" 0.0;
+ target, "cursor";
+ }
+ program {
+ name, "unfocused";
+ signal, "elm,action,unfocus";
+ source, "elm";
+ action, STATE_SET "default" 0.0;
+ target, "cursor";
+ after, "noblink";
+ }
+ }
+}
static void _focused(int id, void *data, Evas_Object *obj,
Elm_Object_Item *item)
{
- struct _priv *priv;
-
switch (id) {
case INPUT_HANDLER_TYPE_PHOTO:
case INPUT_HANDLER_TYPE_DELETE:
elm_object_signal_emit(obj, SIG_FOCUS, SRC_PROG);
break;
case INPUT_HANDLER_TYPE_ENTRY:
- priv = data;
elm_object_signal_emit(obj, SIG_SELECT, SRC_ELM);
- elm_object_signal_emit(priv->ly, SIG_FOCUS, SRC_PROG);
break;
default:
return;
static void _unfocused(int id, void *data, Evas_Object *obj,
Elm_Object_Item *item)
{
- struct _priv *priv;
-
switch (id) {
case INPUT_HANDLER_TYPE_PHOTO:
case INPUT_HANDLER_TYPE_DELETE:
elm_object_signal_emit(obj, SIG_UNFOCUS, SRC_PROG);
break;
case INPUT_HANDLER_TYPE_ENTRY:
- priv = data;
elm_object_signal_emit(obj, SIG_UNSELECT, SRC_ELM);
- elm_object_signal_emit(priv->ly, SIG_UNFOCUS, SRC_PROG);
break;
default:
return;
priv->del = btn;
}
-static void _change_entry(Evas_Object *name, Evas_Object *ly, Eina_Bool disable,
- const char *text, const char *signal)
+static void _change_entry(Evas_Object *name, Eina_Bool disable, const char *text,
+ const char *signal)
{
elm_entry_entry_set(name, text);
elm_object_focus_allow_set(name, disable);
elm_entry_editable_set(name, disable);
- elm_object_signal_emit(ly, signal, SRC_PROG);
+ elm_object_signal_emit(name, signal, SRC_ELM);
}
static void _reset(struct _priv *priv)
focus_photo = utils_get_focus_photo_from_photo(photo);
_load_user_icon(priv, photo, focus_photo);
} else {
- _change_entry(priv->name, priv->ly, EINA_TRUE, "", SIG_ENABLE);
+ _change_entry(priv->name, EINA_TRUE, "", SIG_ENABLE);
_load_user_icon(priv, IMAGE_USER_CURRENT_DEFAULT,
IMAGE_USER_CURRENT_DEFAULT_FOCUS);
}
if (priv->di) {
elm_object_part_text_set(priv->base, PART_USER_EDIT_TITLE,
MESSAGE_EDIT_USER);
- _change_entry(priv->name, priv->ly, EINA_FALSE, priv->di->title,
- SIG_DISABLE);
+ _change_entry(priv->name, EINA_FALSE, priv->di->title, SIG_DISABLE);
if (priv->user_type == USER_ITEM_ADMIN &&
priv->di->type != USER_ITEM_ADMIN)
_load_del_btn(priv);