From: sungwook79.park Date: Wed, 17 Aug 2016 13:13:51 +0000 (+0900) Subject: Modify Selector Icon UI to circle X-Git-Tag: submit/tizen/20160817.221822~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5391ab10176d04451edf0baf50573e1ec1e8d8bc;hp=aae7e7068b22e5975d7182262b97c4538cdac25d;p=platform%2Fcore%2Fuifw%2Finputdelegator.git Modify Selector Icon UI to circle Change-Id: I3827ea5155af799e1e6178812242bedcbdba07e8 Signed-off-by: sungwook79.park --- diff --git a/res/edje/w-input-selector.edc b/res/edje/w-input-selector.edc index d9e9fd3..a436e58 100755 --- a/res/edje/w-input-selector.edc +++ b/res/edje/w-input-selector.edc @@ -580,7 +580,6 @@ collections { } ) } - //Gesture VI program { name: "do_start_expand_0.0"; action: STATE_SET "default" 0.0; @@ -672,13 +671,297 @@ collections { } +// 3 button + group { + name: "elm/genlist/item/3button_flat/default"; + alias: "elm/genlist/item/3button_flat_recent/default"; + data.item: "treesize" 0; + data.item: "flips" "elm.flip.icon elm.flip.content"; + data.item: "contents" "base elm.icon.1 elm.icon.2 elm.icon.3 elm.icon.1.touch_area elm.icon.2.touch_area elm.icon.3.touch_area"; + data.item: "vi_effect" "on"; + data.item: "dim" "off"; + data.item: "focus_bg" "off"; + + + parts { + PART_LIST_BG + PART_LIST_PADDINGS( + LIST_BUTTON_PADDING_LEFT_SIZE_INC, LIST_BUTTON_PADDING_RIGHT_SIZE_INC, + LIST_BUTTON_PADDING_2BUTTON_TOP_SIZE_INC, LIST_BUTTON_PADDING_BOTTOM_SIZE_INC + ) + + PART(SWALLOW, "base", + DESC_LRTB("elm.padding.left", "elm.padding.right", "elm.padding.top", "elm.padding.bottom", + min: 360 0; + fixed: 1 0; + visible: 1; + ) + ) + + part { + name: "elm.icon.1"; // left icon + type: SWALLOW; + description { + state: "default" 0.0; + visible: 1; + align: 0.5 0.5; + fixed: 1 1; + min: 100 100; + max: 100 100; + rel1 { relative: 60/360 0.5; to: "base"; offset: 0 0;} + rel2 { relative: 60/360 0.5; to: "base"; offset: 0 0;} + } + } + part { + name: "elm.icon.1.touch_area"; // left icon + type: SWALLOW; + description { + state: "default" 0.0; + visible: 1; + align: 0.5 0.5; + fixed: 1 1; + min: 120 120; + max: 120 120; + rel1 { relative: 60/360 0.5; to: "base"; offset: 0 0;} + rel2 { relative: 60/360 0.5; to: "base"; offset: 0 0;} + } + } + + part { + name: "elm.icon.2"; // center icon + type: SWALLOW; + description { + state: "default" 0.0; + visible: 1; + align: 0.5 0.5; + fixed: 1 1; + min: 100 100; + max: 100 100; + rel1 { relative: 180/360 0.5; to: "base"; offset: 0 0;} + rel2 { relative: 180/360 0.5; to: "base"; offset: 0 0;} + } + + } + part { + name: "elm.icon.2.touch_area"; // center icon + type: SWALLOW; + description { + state: "default" 0.0; + visible: 1; + align: 0.5 0.5; + fixed: 1 1; + min: 120 120; + max: 120 120; + rel1 { relative: 180/360 0.5; to: "base"; offset: 0 0;} + rel2 { relative: 180/360 0.5; to: "base"; offset: 0 0;} + } + + } + + + part { + name: "elm.icon.3"; // right icon + type: SWALLOW; + description { + state: "default" 0.0; + visible: 1; + align: 0.5 0.5; + fixed: 1 1; + min: 100 100; + max: 100 100; + rel1 { relative: 300/360 0.5; to: "base"; offset: 0 0;} + rel2 { relative: 300/360 0.5; to: "base"; offset: 0 0;} + } + } + part { + name: "elm.icon.3.touch_area"; // right icon + type: SWALLOW; + description { + state: "default" 0.0; + visible: 1; + align: 0.5 0.5; + fixed: 1 1; + min: 120 120; + max: 120 120; + rel1 { relative: 300/360 0.5; to: "base"; offset: 0 0;} + rel2 { relative: 300/360 0.5; to: "base"; offset: 0 0;} + } + } + + } + } + +//2button + group { + name: "elm/genlist/item/2button_flat/default"; + data.item: "treesize" 0; + data.item: "flips" "elm.flip.icon elm.flip.content"; + data.item: "contents" "base elm.icon.1 elm.icon.2 elm.icon.1.touch_area elm.icon.2.touch_area"; + data.item: "vi_effect" "on"; + data.item: "dim" "off"; + data.item: "focus_bg" "off"; + + + parts { + PART_LIST_BG + PART_LIST_PADDINGS( + LIST_BUTTON_PADDING_LEFT_SIZE_INC, LIST_BUTTON_PADDING_RIGHT_SIZE_INC, + LIST_BUTTON_PADDING_2BUTTON_TOP_SIZE_INC, LIST_BUTTON_PADDING_BOTTOM_SIZE_INC + ) + + PART(SWALLOW, "base", + DESC_LRTB("elm.padding.left", "elm.padding.right", "elm.padding.top", "elm.padding.bottom", + min: 360 0; + fixed: 1 0; + visible: 1; + ) + ) + + part { + name: "elm.icon.1"; // left icon + type: SWALLOW; + description { + state: "default" 0.0; + visible: 1; + align: 0.5 0.5; + fixed: 1 1; + min: 100 100; + max: 100 100; + rel1 { relative: 120/360 0.5; to: "base"; offset: 0 0;} + rel2 { relative: 120/360 0.5; to: "base"; offset: 0 0;} + } + } + part { + name: "elm.icon.1.touch_area"; // left icon + type: SWALLOW; + description { + state: "default" 0.0; + visible: 1; + align: 0.5 0.5; + fixed: 1 1; + min: 120 120; + max: 120 120; + rel1 { relative: 120/360 0.5; to: "base"; offset: 0 0;} + rel2 { relative: 120/360 0.5; to: "base"; offset: 0 0;} + } + } + + part { + name: "elm.icon.2"; // center icon + type: SWALLOW; + description { + state: "default" 0.0; + visible: 1; + align: 0.5 0.5; + fixed: 1 1; + min: 100 100; + max: 100 100; + rel1 { relative: 240/360 0.5; to: "base"; offset: 0 0;} + rel2 { relative: 240/360 0.5; to: "base"; offset: 0 0;} + } + + } + part { + name: "elm.icon.2.touch_area"; // center icon + type: SWALLOW; + description { + state: "default" 0.0; + visible: 1; + align: 0.5 0.5; + fixed: 1 1; + min: 120 120; + max: 120 120; + rel1 { relative: 240/360 0.5; to: "base"; offset: 0 0;} + rel2 { relative: 240/360 0.5; to: "base"; offset: 0 0;} + } + + } + } + } + + group { name: "elm/button/base/ime/transparent"; + parts { + part { + name: "bg"; + type: RECT; + scale: 1; + description { + state: "default" 0.0; + min: 0 130; + color_class: "AO015"; + visible: 0; + } + description { + state: "pressed" 0.0; + inherit: "default" 0.0; + color_class: "AO015P"; + } + description { + state: "disabled" 0.0; + inherit: "default" 0.0; + color_class: "AO015D"; + } + } + part { + name: "padding_left_top"; + type: SPACER; + scale: 1; + description { + state: "default" 0.0; + align: 0.0 0.0; + rel2.relative: 0.0 0.0; + min: 0 0; + fixed: 1 1; + } + } + part { + name: "padding_right_bottom"; + type: SPACER; + scale: 1; + description { + state: "default" 0.0; + align: 1.0 1.0; + rel1.relative: 1.0 1.0; + min: 0 0; + fixed: 1 1; + } + } + part { + name: "icon_rect"; + type: SPACER; + scale: 1; + description { + state: "default" 0.0; + align: 0.0 0.5; + rel1 { + relative: 1.0 1.0; + to: "padding_left_top"; + } + rel2 { + relative: 1.0 0.0; + to_x: "padding_left_top"; + to_y: "padding_right_bottom"; + } + min: 0 0; + fixed: 1 1; + } + description { + state: "visible" 0.0; + inherit: "default" 0.0; + min: 134 61; + max: 134 61; + fixed: 1 1; + } + } + } + } + group { name: "elm/genlist/item/2button/default"; data.item: "treesize" 0; data.item: "flips" "elm.flip.icon elm.flip.content"; data.item: "contents" "base elm.icon.1.touch_area elm.icon.2.touch_area elm.icon.1 elm.icon.2 elm.swallow.center_check"; data.item: "vi_effect" "off"; - parts { PART_LIST_BG PART_LIST_PADDINGS( diff --git a/res/edje/w-input-stt.edc b/res/edje/w-input-stt.edc index a7ea837..8eda165 100755 --- a/res/edje/w-input-stt.edc +++ b/res/edje/w-input-stt.edc @@ -149,7 +149,7 @@ collections color_class { name: "AO01153L1"; - color: 163 163 163 100; + color: 0 0 255 255; } color_class { @@ -164,7 +164,7 @@ collections color_class { name: "AO01154L1"; - color: 110 110 110 100; + color: 97 12 117 255; } color_class { @@ -179,7 +179,7 @@ collections color_class { name: "AO01155L1"; - color: 122 122 122 100; + color: 255 0 0 255; } color_class { @@ -1368,608 +1368,583 @@ collections #define BUTTON_PADDING_SIZE_INC 20 0 #define BUTTON_HEIGHT_INC 122 #define BUTTON_ICON_SIZE_INC 60 60 - group { name: "elm/button/base/default"; - script { - public mouse_down = 0; - public multi_down = 0; - } - parts { - part { name: "bg"; - type: RECT; - scale: 1; - description { state: "default" 0.0; - min: 0 BUTTON_HEIGHT_INC; - color: 128 128 128 128; - } - description { state: "pressed" 0.0; - inherit: "default" 0.0; - color: 128 128 128 128; - } - description { state: "disabled" 0.0; - inherit: "default" 0.0; - color: 128 128 128 128; - } - } - part { name: "padding_left_top"; - type: SPACER; - scale: 1; - description { state: "default" 0.0; - align: 0.0 0.0; - rel2.relative: 0.0 0.0; - min: BUTTON_PADDING_SIZE_INC; - fixed: 1 1; - } - } - part { name: "padding_right_bottom"; - type: SPACER; - scale: 1; - description { state: "default" 0.0; - align: 1.0 1.0; - rel1.relative: 1.0 1.0; - min: BUTTON_PADDING_SIZE_INC; - fixed: 1 1; - } - } - part { name: "icon_rect"; - type: SPACER; - scale: 1; - description { state: "default" 0.0; - align: 0.0 0.5; - rel1 { - relative: 1.0 1.0; - to: "padding_left_top"; - } - rel2 { - relative: 1.0 0.0; - to_x: "padding_left_top"; - to_y: "padding_right_bottom"; - } - min: 0 0; - fixed: 1 1; - } - description { state: "visible" 0.0; - inherit: "default" 0.0; - min: BUTTON_ICON_SIZE_INC; - max: BUTTON_ICON_SIZE_INC; - fixed: 1 1; - } - } - part { name: "elm.swallow.content"; - type: SWALLOW; - clip_to: "elm.swallow.content.clip"; - scale: 1; - description { state: "default" 0.0; - visible: 0; - align: 0.0 0.5; - rel1 { - relative: 1.0 1.0; - to: "padding_left_top"; - } - rel2 { - relative: 1.0 0.0; - to_x: "padding_left_top"; - to_y: "padding_right_bottom"; - } - fixed: 1 0; - } - description { state: "visible" 0.0; - fixed: 1 1; - min: BUTTON_ICON_SIZE_INC; - max: BUTTON_ICON_SIZE_INC; - align: 1.0 0.5; - rel1 { - relative: 0.0 1.0; - to_x: "elm.text"; - to_y: "padding_left_top"; - } - rel2 { - relative: 0.0 0.0; - to_x: "elm.text"; - to_y: "padding_right_bottom"; - } - } - description { state: "icononly" 0.0; - min: BUTTON_ICON_SIZE_INC; - max: BUTTON_ICON_SIZE_INC; - } - } - part { name: "elm.text"; - type: TEXTBLOCK; - mouse_events: 0; - scale: 1; - description { state: "default" 0.0; - fixed: 1 1; - rel1 { - relative: 1.0 1.0; - to_x: "icon_rect"; - to_y: "padding_left_top"; - } - rel2 { - relative: 0.0 0.0; - to: "padding_right_bottom"; - } - text { - max: 1 0; - style: "button_general_text_normal"; - } - } - description { state: "disabled" 0.0; - inherit: "default" 0.0; - text.style: "button_general_text_dim"; - } - description { state: "pressed" 0.0; - inherit: "default" 0.0; - text.style: "button_general_text_press"; - } - } - part { name: "elm.swallow.content.clip"; - type: RECT; - scale: 1; - description { state: "default" 0.0; - color: 128 128 128 128; - } - description { state: "disabled" 0.0; - inherit: "default" 0.0; - color: 128 128 128 128; - } - } - part { name: "event"; - type: RECT; - scale: 1; - description { state: "default" 0.0; - color: 0 0 0 0; - rel1.to: "bg"; - rel2.to: "bg"; - } - } - } - programs { - program { name: "pressed"; - signal: "mouse,down,1*"; - source: "event"; - script { - if ((get_int(multi_down) == 0) && (get_int(mouse_down) == 0)) - { - set_int(mouse_down, 1); - run_program(PROGRAM:"button_press1"); - } - } - } - program { name: "button_press1"; - script { - new st[31]; - new Float:vl; - get_state(PART:"bg", st, 30, vl); - if (strcmp(st, "disabled")) { - set_state(PART:"bg", "pressed", 0.0); - set_state(PART:"elm.text", "pressed", 0.0); - emit("elm,action,press", ""); - } - } - } - program { name: "unpressed"; - signal: "mouse,up,1"; - source: "event"; - script { - if (get_int(mouse_down) == 1) { - set_int(mouse_down, 0); - run_program(PROGRAM:"button_unpress1"); - } - } - } - program { name: "button_unpress1"; - script { - new st[31]; - new Float:vl; - get_state(PART:"bg", st, 30, vl); - if (strcmp(st, "disabled")) { - set_state(PART:"bg", "default", 0.0); - set_state(PART:"elm.text", "default", 0.0); - emit("elm,action,unpress", ""); - } - } - } - program { name: "touch_snd"; - signal: "mouse,clicked,1"; - source: "event"; - script { - new st[31]; - new Float:vl; - if (get_int(multi_down) == 0) { - get_state(PART:"bg", st, 30, vl); - if (strcmp(st, "disabled")) { - //run_program(PROGRAM:"play_sample"); - emit("elm,action,click", ""); - } - } - } - } - program { - name: "play_sample"; - action: RUN_PLUGIN "touch_sound"; - } - program { name: "text_show"; - signal: "elm,state,text,visible"; - source: "elm"; - script { - new st[31]; - new Float:vl; - get_state(PART:"elm.swallow.content", st, 30, vl); - if (!strcmp(st, "icononly")) - { - set_state(PART:"elm.swallow.content", "visible", 0.0); - set_state(PART:"icon_rect", "visible", 0.0); - } - get_state(PART:"bg", st, 30, vl); - if (strcmp(st, "disabled")) - set_state(PART:"elm.text", "default", 0.0); - else - set_state(PART:"elm.text", "disabled", 0.0); - } - } - program { name: "text_hide"; - signal: "elm,state,text,hidden"; - source: "elm"; - script { - new st[31]; - new Float:vl; - get_state(PART:"elm.swallow.content", st, 30, vl); - if (!strcmp(st, "visible")) - { - set_state(PART:"elm.swallow.content", "icononly", 0.0); - set_state(PART:"icon_rect", "default", 0.0); - } - set_state(PART:"elm.text", "default", 0.0); - } - } - program { name: "icon_show"; - signal: "elm,state,icon,visible"; - source: "elm"; - action: STATE_SET "visible" 0.0; - target: "elm.swallow.content"; - target: "icon_rect"; - } - program { name: "icon_hide"; - signal: "elm,state,icon,hidden"; - source: "elm"; - action: STATE_SET "default" 0.0; - target: "elm.swallow.content"; - target: "icon_rect"; - } - program { name: "disable"; - signal: "elm,state,disabled"; - source: "elm"; - action: STATE_SET "disabled" 0.0; - target: "bg"; - target: "elm.swallow.content.clip"; - target: "elm.text"; - } - program { name: "enable"; - signal: "elm,state,enabled"; - source: "elm"; - action: STATE_SET "default" 0.0; - target: "bg"; - target: "elm.swallow.content.clip"; - target: "elm.text"; - } - program { name: "multi_down"; - signal: "elm,action,multi,down"; - source: "elm"; - script { - set_int(multi_down, 1); - } - } - program { name: "multi_up"; - signal: "elm,action,multi,up"; - source: "elm"; - script { - set_int(multi_down, 0); - } - } - } - } - - group { name: "elm/button/base/ime_transparent"; - inherit: "elm/button/base/default"; - parts { - part { name: "bg"; - type: RECT; - scale: 1; - description { state: "default" 0.0; - min: 0 112; + group { name: "elm/button/base/default"; + script { + public mouse_down = 0; + public multi_down = 0; + } + parts { + part { name: "bg"; + type: RECT; + scale: 1; + description { state: "default" 0.0; + min: 0 BUTTON_HEIGHT_INC; + color_class: "W011"; + } + description { state: "pressed" 0.0; + inherit: "default" 0.0; + color_class: "W011P"; + } + description { state: "disabled" 0.0; + inherit: "default" 0.0; + color_class: "W011D"; + } + } + part { name: "padding_left_top"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + align: 0.0 0.0; + rel2.relative: 0.0 0.0; + min: BUTTON_PADDING_SIZE_INC; + fixed: 1 1; + } + } + part { name: "padding_right_bottom"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + align: 1.0 1.0; + rel1.relative: 1.0 1.0; + min: BUTTON_PADDING_SIZE_INC; + fixed: 1 1; + } + } + part { name: "icon_rect"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + align: 0.0 0.5; + rel1 { + relative: 1.0 1.0; + to: "padding_left_top"; + } + rel2 { + relative: 1.0 0.0; + to_x: "padding_left_top"; + to_y: "padding_right_bottom"; + } + min: 0 0; + fixed: 1 1; + } + description { state: "visible" 0.0; + inherit: "default" 0.0; + min: BUTTON_ICON_SIZE_INC; + max: BUTTON_ICON_SIZE_INC; + fixed: 1 1; + } + } + part { name: "elm.swallow.content"; + type: SWALLOW; + clip_to: "elm.swallow.content.clip"; + scale: 1; + description { state: "default" 0.0; visible: 0; - } - description { state: "pressed" 0.0; + align: 0.0 0.5; + rel1 { + relative: 1.0 1.0; + to: "padding_left_top"; + } + rel2 { + relative: 1.0 0.0; + to_x: "padding_left_top"; + to_y: "padding_right_bottom"; + } + fixed: 1 0; + } + description { state: "visible" 0.0; + fixed: 1 1; + min: BUTTON_ICON_SIZE_INC; + max: BUTTON_ICON_SIZE_INC; + align: 1.0 0.5; + rel1 { + relative: 0.0 1.0; + to_x: "elm.text"; + to_y: "padding_left_top"; + } + rel2 { + relative: 0.0 0.0; + to_x: "elm.text"; + to_y: "padding_right_bottom"; + } + } + description { state: "icononly" 0.0; + min: BUTTON_ICON_SIZE_INC; + max: BUTTON_ICON_SIZE_INC; + } + } + part { name: "elm.text"; + type: TEXTBLOCK; + mouse_events: 0; + scale: 1; + description { state: "default" 0.0; + fixed: 1 1; + rel1 { + relative: 1.0 1.0; + to_x: "icon_rect"; + to_y: "padding_left_top"; + } + rel2 { + relative: 0.0 0.0; + to: "padding_right_bottom"; + } + text { + max: 1 0; + style: "button_general_text_normal"; + } + } + description { state: "disabled" 0.0; inherit: "default" 0.0; - } - description { state: "disabled" 0.0; + text.style: "button_general_text_dim"; + } + description { state: "pressed" 0.0; inherit: "default" 0.0; + text.style: "button_general_text_press"; + } + } + part { name: "elm.swallow.content.clip"; + type: RECT; + scale: 1; + description { state: "default" 0.0; + color_class: "F022L1i"; + } + description { state: "disabled" 0.0; + inherit: "default" 0.0; + color_class: "F022L1iD"; + } + } + part { name: "event"; + type: RECT; + scale: 1; + description { state: "default" 0.0; + color: 0 0 0 0; + rel1.to: "bg"; + rel2.to: "bg"; + } + } + } + programs { + program { name: "pressed"; + signal: "mouse,down,1*"; + source: "event"; + script { + if ((get_int(multi_down) == 0) && (get_int(mouse_down) == 0)) + { + set_int(mouse_down, 1); + run_program(PROGRAM:"button_press1"); + } + } + } + program { name: "button_press1"; + script { + new st[31]; + new Float:vl; + get_state(PART:"bg", st, 30, vl); + if (strcmp(st, "disabled")) { + set_state(PART:"bg", "pressed", 0.0); + set_state(PART:"elm.text", "pressed", 0.0); + emit("elm,action,press", ""); + } + } + } + program { name: "unpressed"; + signal: "mouse,up,1"; + source: "event"; + script { + if (get_int(mouse_down) == 1) { + set_int(mouse_down, 0); + run_program(PROGRAM:"button_unpress1"); + } + } + } + program { name: "button_unpress1"; + script { + new st[31]; + new Float:vl; + get_state(PART:"bg", st, 30, vl); + if (strcmp(st, "disabled")) { + set_state(PART:"bg", "default", 0.0); + set_state(PART:"elm.text", "default", 0.0); + emit("elm,action,unpress", ""); + } + } + } + program { name: "touch_snd"; + signal: "mouse,clicked,1"; + source: "event"; + script { + new st[31]; + new Float:vl; + if (get_int(multi_down) == 0) { + get_state(PART:"bg", st, 30, vl); + if (strcmp(st, "disabled")) { + //run_program(PROGRAM:"play_sample"); + emit("elm,action,click", ""); + } + } + } + } + program { + name: "play_sample"; + action: RUN_PLUGIN "touch_sound"; + } + program { name: "text_show"; + signal: "elm,state,text,visible"; + source: "elm"; + script { + new st[31]; + new Float:vl; + get_state(PART:"elm.swallow.content", st, 30, vl); + if (!strcmp(st, "icononly")) + { + set_state(PART:"elm.swallow.content", "visible", 0.0); + set_state(PART:"icon_rect", "visible", 0.0); + } + get_state(PART:"bg", st, 30, vl); + if (strcmp(st, "disabled")) + set_state(PART:"elm.text", "default", 0.0); + else + set_state(PART:"elm.text", "disabled", 0.0); + } + } + program { name: "text_hide"; + signal: "elm,state,text,hidden"; + source: "elm"; + script { + new st[31]; + new Float:vl; + get_state(PART:"elm.swallow.content", st, 30, vl); + if (!strcmp(st, "visible")) + { + set_state(PART:"elm.swallow.content", "icononly", 0.0); + set_state(PART:"icon_rect", "default", 0.0); + } + set_state(PART:"elm.text", "default", 0.0); + } + } + program { name: "icon_show"; + signal: "elm,state,icon,visible"; + source: "elm"; + action: STATE_SET "visible" 0.0; + target: "elm.swallow.content"; + target: "icon_rect"; + } + program { name: "icon_hide"; + signal: "elm,state,icon,hidden"; + source: "elm"; + action: STATE_SET "default" 0.0; + target: "elm.swallow.content"; + target: "icon_rect"; + } + program { name: "disable"; + signal: "elm,state,disabled"; + source: "elm"; + action: STATE_SET "disabled" 0.0; + target: "bg"; + target: "elm.swallow.content.clip"; + target: "elm.text"; + } + program { name: "enable"; + signal: "elm,state,enabled"; + source: "elm"; + action: STATE_SET "default" 0.0; + target: "bg"; + target: "elm.swallow.content.clip"; + target: "elm.text"; + } + program { name: "multi_down"; + signal: "elm,action,multi,down"; + source: "elm"; + script { + set_int(multi_down, 1); + } + } + program { name: "multi_up"; + signal: "elm,action,multi,up"; + source: "elm"; + script { + set_int(multi_down, 0); + } + } + } +} + + group { name: "elm/button/base/ime_transparent"; + inherit: "elm/button/base/default"; + parts { + part { name: "bg"; + type: RECT; + scale: 1; + description { state: "default" 0.0; + min: 0 112; + visible: 0; + } + description { state: "pressed" 0.0; + inherit: "default" 0.0; + } + description { state: "disabled" 0.0; + inherit: "default" 0.0; } } } } group { name: "elm/button/base/ime_button"; - alias: "elm/button/base/ime_button_stt"; - inherit: "elm/button/base/default"; - parts { - part { name: "bg"; - type: IMAGE; - scale: 1; - description { state: "default" 0.0; - min: 0 0; - color_class: "AO01153L1"; - visible: 1; - image.normal: "./w_mode_ic_bg.png"; - } - description { state: "pressed" 0.0; - inherit: "default" 0.0; - color_class: "AO01153L1P"; - } - description { state: "disabled" 0.0; - inherit: "default" 0.0; - color: 128 128 128 128; + alias: "elm/button/base/ime_button_stt"; + inherit: "elm/button/base/default"; + parts { + part { name: "bg"; + type: IMAGE; + scale: 1; + description { state: "default" 0.0; + min: 0 0; + color_class: "AO01153L1"; + visible: 1; + image.normal: "./w_mode_ic_bg.png"; + } + description { state: "pressed" 0.0; + inherit: "default" 0.0; + color_class: "AO01153L1P"; + } + description { state: "disabled" 0.0; + inherit: "default" 0.0; + color_class: "W011D"; } } - part { name: "elm.swallow.content"; - type: SWALLOW; - scale: 1; - clip_to: "elm.swallow.content.clip"; - description { state: "default" 0.0; - visible: 1; - align: 0.5 0.5; - rel1 { relative: 0.0 0.0; to: "bg";} - rel2 { relative: 1.0 1.0; to: "bg";} - fixed: 1 1; - } - description { state: "visible" 0.0; - inherit: "default" 0.0; - visible: 1; - } - description { state: "icononly" 0.0; - inherit: "default" 0.0; - visible: 1; - } - } - part { name: "elm.swallow.content.clip"; - type: RECT; - scale: 1; - description { state: "default" 0.0; - color_class: "AO01153L3"; - } - description { state: "pressed" 0.0; - inherit: "default" 0.0; - color_class: "AO01153L3P"; + part { name: "elm.swallow.content"; + type: SWALLOW; + scale: 1; + clip_to: "elm.swallow.content.clip"; + description { state: "default" 0.0; + visible: 1; + align: 0.5 0.5; + rel1 { relative: 0.0 0.0; to: "bg";} + rel2 { relative: 1.0 1.0; to: "bg";} + fixed: 1 1; + } + description { state: "visible" 0.0; + inherit: "default" 0.0; + visible: 1; + } + description { state: "icononly" 0.0; + inherit: "default" 0.0; + visible: 1; + } } - description { state: "disabled" 0.0; - inherit: "default" 0.0; - color: 128 128 128 128; - } - } - part { name: "elm.swallow.content_ef"; - type: SWALLOW; - scale: 1; - description { state: "default" 0.0; - visible: 1; - align: 0.5 0.5; - rel1 { relative: 0.0 0.0; to: "bg";} - rel2 { relative: 1.0 1.0; to: "bg";} - fixed: 1 1; - } - } - } - programs { - program { name: "pressed"; - signal: "mouse,down,1*"; - source: "event"; - script { - if ((get_int(multi_down) == 0) && (get_int(mouse_down) == 0)) - { - set_int(mouse_down, 1); - run_program(PROGRAM:"button_press1"); - } - } - } - program { name: "button_press1"; - script { - new st[31]; - new Float:vl; - get_state(PART:"bg", st, 30, vl); - if (strcmp(st, "disabled")) { - set_state(PART:"bg", "pressed", 0.0); - set_state(PART:"elm.swallow.content.clip", "pressed", 0.0); - emit("elm,action,press", ""); - } - } - } - program { name: "unpressed"; - signal: "mouse,up,1"; - source: "event"; - script { - if (get_int(mouse_down) == 1) { - set_int(mouse_down, 0); - run_program(PROGRAM:"button_unpress1"); - } - } - } - program { name: "button_unpress1"; - script { - new st[31]; - new Float:vl; - get_state(PART:"bg", st, 30, vl); - if (strcmp(st, "disabled")) { - set_state(PART:"bg", "default", 0.0); - set_state(PART:"elm.swallow.content.clip", "default", 0.0); - emit("elm,action,unpress", ""); - } - } - } - } + + } + programs { + program { name: "pressed"; + signal: "mouse,down,1*"; + source: "event"; + script { + if ((get_int(multi_down) == 0) && (get_int(mouse_down) == 0)) + { + set_int(mouse_down, 1); + run_program(PROGRAM:"button_press1"); + } + } + } + program { name: "button_press1"; + script { + new st[31]; + new Float:vl; + get_state(PART:"bg", st, 30, vl); + if (strcmp(st, "disabled")) { + set_state(PART:"bg", "pressed", 0.0); + set_state(PART:"elm.swallow.content.clip", "pressed", 0.0); + emit("elm,action,press", ""); + } + } + } + program { name: "unpressed"; + signal: "mouse,up,1"; + source: "event"; + script { + if (get_int(mouse_down) == 1) { + set_int(mouse_down, 0); + run_program(PROGRAM:"button_unpress1"); + } + } + } + program { name: "button_unpress1"; + script { + new st[31]; + new Float:vl; + get_state(PART:"bg", st, 30, vl); + if (strcmp(st, "disabled")) { + set_state(PART:"bg", "default", 0.0); + set_state(PART:"elm.swallow.content.clip", "default", 0.0); + emit("elm,action,unpress", ""); + } + } + } + } } group { name: "elm/button/base/ime_button_emoticon"; - inherit: "elm/button/base/ime_button"; - parts { - part { name: "bg"; - type: IMAGE; - scale: 1; - description { state: "default" 0.0; - min: 0 0; - color_class: "AO01154L1"; - visible: 1; - image.normal: "./w_mode_ic_bg.png"; - } - description { state: "pressed" 0.0; - inherit: "default" 0.0; - color_class: "AO01154L1P"; - } - description { state: "disabled" 0.0; - inherit: "default" 0.0; - color: 128 128 128 128; + inherit: "elm/button/base/ime_button"; + parts { + part { name: "bg"; + type: IMAGE; + scale: 1; + description { state: "default" 0.0; + min: 0 0; + color_class: "AO01154L1"; + visible: 1; + image.normal: "./w_mode_ic_bg.png"; + } + description { state: "pressed" 0.0; + inherit: "default" 0.0; + color_class: "AO01154L1P"; + } + description { state: "disabled" 0.0; + inherit: "default" 0.0; + color_class: "W011D"; + } } } } - } group { name: "elm/button/base/ime_button_keyboard"; - inherit: "elm/button/base/ime_button"; - parts { - part { name: "bg"; - type: IMAGE; - scale: 1; - description { state: "default" 0.0; - min: 0 0; - color_class: "AO01155L1"; - visible: 1; - image.normal: "./w_mode_ic_bg.png"; - } - description { state: "pressed" 0.0; - inherit: "default" 0.0; - color_class: "AO01155L1P"; - } - description { state: "disabled" 0.0; - inherit: "default" 0.0; - color: 128 128 128 128; + inherit: "elm/button/base/ime_button"; + parts { + part { name: "bg"; + type: IMAGE; + scale: 1; + description { state: "default" 0.0; + min: 0 0; + color_class: "AO01155L1"; + visible: 1; + image.normal: "./w_mode_ic_bg.png"; + } + description { state: "pressed" 0.0; + inherit: "default" 0.0; + color_class: "AO01155L1P"; + } + description { state: "disabled" 0.0; + inherit: "default" 0.0; + color_class: "W011D"; } } } } group { name: "elm/button/base/ime_button_template"; - inherit: "elm/button/base/ime_button"; - parts { - part { name: "bg"; - type: IMAGE; - scale: 1; - description { state: "default" 0.0; - min: 76 76; - max: 76 76; - color_class: "AO01161"; - visible: 1; - image.normal: "./w_mode_ic_bg.png"; - } - description { state: "pressed" 0.0; - inherit: "default" 0.0; - color_class: "AO01161P"; - } - description { state: "disabled" 0.0; - inherit: "default" 0.0; - color_class: "AO01161D"; + inherit: "elm/button/base/ime_button"; + parts { + part { name: "bg"; + type: IMAGE; + scale: 1; + description { state: "default" 0.0; + min: 76 76; + max: 76 76; + color_class: "AO01161"; + visible: 1; + image.normal: "./w_mode_ic_bg.png"; + } + description { state: "pressed" 0.0; + inherit: "default" 0.0; + color_class: "AO01161P"; + } + description { state: "disabled" 0.0; + inherit: "default" 0.0; + color_class: "AO01161D"; } } - part { name: "elm.swallow.content.clip"; - type: RECT; - scale: 1; - description { state: "default" 0.0; - color_class: "AO0116"; - } - description { state: "pressed" 0.0; - inherit: "default" 0.0; - color_class: "AO0116P"; + part { name: "elm.swallow.content.clip"; + type: RECT; + scale: 1; + description { state: "default" 0.0; + color_class: "AO01153L3"; + } + description { state: "pressed" 0.0; + inherit: "default" 0.0; + color_class: "AO01153L3P"; + } + description { state: "disabled" 0.0; + inherit: "default" 0.0; + color_class: "AO01153L3D"; + } } - description { state: "disabled" 0.0; - inherit: "default" 0.0; - color_class: "AO0116D"; - } - } } } group { name: "elm/button/base/ime_button_stt_confirm"; - inherit: "elm/button/base/ime_button"; - parts { - part { name: "bg"; - type: IMAGE; - scale: 1; - description { state: "default" 0.0; - min: 0 0; - color_class: "AO015L2"; - visible: 0; - image.normal: "./b_stt_icon_btn.png"; - } - description { state: "pressed" 0.0; - inherit: "default" 0.0; - color_class: "AO015L2P"; - } - description { state: "disabled" 0.0; - inherit: "default" 0.0; - color_class: "AO015L2D"; + inherit: "elm/button/base/ime_button"; + parts { + part { name: "bg"; + type: IMAGE; + scale: 1; + description { state: "default" 0.0; + min: 0 0; + color_class: "AO015L2"; + visible: 0; + image.normal: "./b_stt_icon_btn.png"; + } + description { state: "pressed" 0.0; + inherit: "default" 0.0; + color_class: "AO015L2P"; + } + description { state: "disabled" 0.0; + inherit: "default" 0.0; + color_class: "AO015L2D"; } } - part { name: "elm.swallow.content.clip"; - type: RECT; - scale: 1; - description { state: "default" 0.0; - color_class: "AO015L2"; - } - description { state: "pressed" 0.0; - inherit: "default" 0.0; - color_class: "AO015L2P"; + part { name: "elm.swallow.content.clip"; + type: RECT; + scale: 1; + description { state: "default" 0.0; + color_class: "AO015L2"; + } + description { state: "pressed" 0.0; + inherit: "default" 0.0; + color_class: "AO015L2P"; + } + description { state: "disabled" 0.0; + inherit: "default" 0.0; + color_class: "AO015L2D"; + } } - description { state: "disabled" 0.0; - inherit: "default" 0.0; - color_class: "AO015L2D"; - } - } } } group { name: "elm/button/base/touch_area"; - inherit: "elm/button/base/default"; - parts { - part { name: "bg"; - type: RECT; - scale: 1; - description { state: "default" 0.0; - min: 0 0; - color: 0 0 0 0; - visible: 1; - } - description { state: "pressed" 0.0; - inherit: "default" 0.0; - } - description { state: "disabled" 0.0; - inherit: "default" 0.0; + inherit: "elm/button/base/default"; + parts { + part { name: "bg"; + type: RECT; + scale: 1; + description { state: "default" 0.0; + min: 0 0; + color: 0 0 0 0; + visible: 1; + } + description { state: "pressed" 0.0; + inherit: "default" 0.0; + } + description { state: "disabled" 0.0; + inherit: "default" 0.0; } } } - programs { - program { name: "touch_snd"; - signal: "mouse,clicked,1"; - source: "event"; - script { - new st[31]; - new Float:vl; - if (get_int(multi_down) == 0) { - get_state(PART:"bg", st, 30, vl); - if (strcmp(st, "disabled")) { - run_program(PROGRAM:"play_sample"); - emit("elm,action,click", ""); - } + programs { + program { name: "touch_snd"; + signal: "mouse,clicked,1"; + source: "event"; + script { + new st[31]; + new Float:vl; + if (get_int(multi_down) == 0) { + get_state(PART:"bg", st, 30, vl); + if (strcmp(st, "disabled")) { + run_program(PROGRAM:"play_sample"); + emit("elm,action,click", ""); + } + } } - } - } - } + } + } } #define NAVIFRAME_VIEW_TRANS_TIME 0.4 //time for push and pop diff --git a/src/w-input-selector.cpp b/src/w-input-selector.cpp index 542d2bb..4156397 100755 --- a/src/w-input-selector.cpp +++ b/src/w-input-selector.cpp @@ -178,13 +178,15 @@ static Evas_Object * __ise_gl_2button_content_get(void *data, Evas_Object *obj, elm_image_resizable_set(ic, EINA_TRUE, EINA_TRUE); string path = get_resource_path(); if (!strcmp(part, "elm.icon.1")) { - elm_object_style_set(btn, "anchor"); string path_ic; if(!strcmp(first_input_type, "input_voice")) { + elm_object_style_set(btn, "ime_button_stt"); path_ic = path + "images/w_mode_stt_ic.png"; } else if (!strcmp(first_input_type, "input_emoticon")) { + elm_object_style_set(btn, "ime_button_emoticon"); path_ic = path + "images/Delta_w_mode_emoticon_ic.png"; } else if (!strcmp(first_input_type, "input_keyboard")) { + elm_object_style_set(btn, "ime_button_keyboard"); path_ic = path + "images/w_mode_keyboard_ic.png"; evas_object_propagate_events_set(btn, EINA_FALSE); } @@ -192,13 +194,15 @@ static Evas_Object * __ise_gl_2button_content_get(void *data, Evas_Object *obj, elm_object_content_set(btn, ic); evas_object_layer_set(btn, 32000); } else if (!strcmp(part, "elm.icon.2")){ - elm_object_style_set(btn, "anchor"); string path_ic; if(!strcmp(second_input_type, "input_voice")) { + elm_object_style_set(btn, "ime_button_stt"); path_ic = path + "images/w_mode_stt_ic.png"; } else if (!strcmp(second_input_type, "input_emoticon")) { + elm_object_style_set(btn, "ime_button_emoticon"); path_ic = path + "images/Delta_w_mode_emoticon_ic.png"; } else if (!strcmp(second_input_type, "input_keyboard")) { + elm_object_style_set(btn, "ime_button_keyboard"); path_ic = path + "images/w_mode_keyboard_ic.png"; evas_object_propagate_events_set(btn, EINA_FALSE); } @@ -253,21 +257,21 @@ static Evas_Object * __ise_gl_3button_content_get(void *data, Evas_Object *obj, elm_image_resizable_set(ic, EINA_TRUE, EINA_TRUE); string path = get_resource_path(); if (!strcmp(part, "elm.icon.1")) { - elm_object_style_set(btn, "anchor"); + elm_object_style_set(btn, "ime_button_stt"); string path_ic = path + "images/w_mode_stt_ic.png"; elm_image_file_set(ic, path_ic.c_str(), NULL); elm_object_content_set(btn, ic); evas_object_layer_set(btn, 32000); } else if (!strcmp(part, "elm.icon.2")){ - elm_object_style_set(btn, "anchor"); + elm_object_style_set(btn, "ime_button_emoticon"); string path_ic = path + "images/Delta_w_mode_emoticon_ic.png"; elm_image_file_set(ic, path_ic.c_str(), NULL); elm_object_content_set(btn, ic); evas_object_layer_set(btn, 32000); } else if (!strcmp(part, "elm.icon.3")){ - elm_object_style_set(btn, "anchor"); + elm_object_style_set(btn, "ime_button_keyboard"); string path_ic = path + "images/w_mode_keyboard_ic.png"; elm_image_file_set(ic, path_ic.c_str(), NULL); elm_object_content_set(btn, ic); @@ -575,13 +579,13 @@ void _create_genlist_items(void* user_data) Elm_Genlist_Item_Class * itc1 = elm_genlist_item_class_new(); if(g_input_type_data.input_type_array_len == 2){ - itc1->item_style = "2button"; + itc1->item_style = "2button_flat"; itc1->func.text_get = NULL; itc1->func.content_get = __ise_gl_2button_content_get; itc1->func.state_get = NULL; itc1->func.del = NULL; } else { - itc1->item_style = "3button"; + itc1->item_style = "3button_flat"; itc1->func.text_get = NULL; itc1->func.content_get = __ise_gl_3button_content_get; itc1->func.state_get = NULL;