}
///////////////////////////////////////////////////////////////////////////////////////
- group { name: "elm/button/base/sweep";
- alias: "elm/button/base/text_only/sweep";
- alias: "elm/button/base/hidden";
- alias: "elm/button/base/sweep/multiline";
- data {
- item: "focus_highlight" "on";
- }
- images {
- image: "00_button_01.png" COMP;
- image: "00_button_01_press.png" COMP;
- image: "00_button_01_dim.png" COMP;
- image: "00_button_01_focus.png" COMP;
- }
- script {
- public button_state = BUTTON_STATE_ENABLED;
- }
- styles{
- style { name: "btn_sweep_multiline";
- base: "font=Tizen:style=Regular font_size="BUTTON_SWEEP_FONT_SIZE_INC" align=center color=#ffffff wrap=mixed linegap=-7 ellipsis=1.0 text_class=tizen";
- tag: "br" "\n";
- tag: "ps" "ps";
- tag: "tab" "\t";
- }
- }
- parts {
- part { name: "button_image";
- scale: 1;
- description { state: "default" 0.0;
- min: BUTTON_SWEEP_BG_NORMAL_MIN_INC;
- image {
- normal: "00_button_01.png";
- border: BUTTON_SWEEP_BG_BORDER_INC;
- border_scale: 1;
- }
- }
- description { state: "clicked" 0.0;
- inherit: "default" 0.0;
- image.normal: "00_button_01_press.png";
- }
- description { state: "disabled" 0.0;
- inherit: "default" 0.0;
- image.normal: "00_button_01_dim.png";
- }
- description { state: "focused" 0.0;
- inherit: "default" 0.0;
- image.normal: "00_button_01_press.png";
- }
- }
- part { name: "focus_image";
- scale: 1;
- mouse_events: 0;
- repeat_events: 1;
- description { state: "default" 0.0;
- visible: 0;
- rel1.to : "button_image";
- rel2.to : "button_image";
- image {
- normal: "00_button_01_focus.png";
- border: BUTTON_SWEEP_BG_BORDER_INC;
- border_scale: 1;
- }
- }
- description { state: "focused" 0.0;
- inherit: "default" 0.0;
- visible: 1;
- }
- }
- part { name: "padding_left_top";
- type: RECT;
- scale: 1;
- mouse_events: 0;
- description { state: "default" 0.0;
- align: 0.0 0.0;
- rel2.relative: 0.0 0.0;
- min: BUTTON_SWEEP_PADDING_MIN_INC;
- fixed: 1 1;
- visible: 0;
- }
- }
- part { name: "padding_right_bottom";
- type: RECT;
- scale: 1;
- mouse_events: 0;
- description { state: "default" 0.0;
- align: 1.0 1.0;
- rel1.relative: 1.0 1.0;
- min: BUTTON_SWEEP_PADDING_MIN_INC;
- fixed: 1 1;
- visible: 0;
- }
- }
- part { name: "icon_rect";
- type: RECT;
- scale: 1;
- mouse_events: 0;
- description { state: "default" 0.0;
- min: BUTTON_SWEEP_ICON_RECT_MIN_INC;
- fixed: 1 0;
- rel1 {
- relative: 0.0 1.0;
- to_x: "elm.swallow.content";
- to_y: "padding_left_top";
- }
- rel2 {
- relative: 1.0 0.0;
- to_x: "elm.swallow.content";
- to_y: "padding_right_bottom";
- }
- align: 0.0 0.5;
- color: 0 0 0 0;
- }
- }
- part { name: "padding_icon_text";
- type: RECT;
- scale: 1;
- mouse_events: 0;
- description { state: "default" 0.0; //when only icon or no icon is there
- visible: 0;
- fixed: 1 0;
- min: 0 0;
- rel1 {
- relative: 1.0 0.0;
- to: "icon_rect";
- }
- rel2.to: "icon_rect";
- align: 0.0 0.0;
- }
- description { state: "visible" 0.0; //when icon is visible
- inherit: "default" 0.0;
- min: BUTTON_SWEEP_PADDING_ICON_TEXT_VISIBLE_MIN_INC;
- }
- description { state: "icononly" 0.0;
- inherit: "default" 0.0;
- }
- }
- part { name: "elm.swallow.content";
- type: SWALLOW;
- scale: 1;
- clip_to: "clipper";
- 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;
- inherit: "default" 0.0;
- min: BUTTON_SWEEP_ICONONLY_ICON_MIN_INC;
- max: BUTTON_SWEEP_ICONONLY_ICON_MIN_INC;
- visible: 1;
- aspect: 1.0 1.0;
- aspect_preference: VERTICAL;
- }
- description { state: "icononly" 0.0;
- min: BUTTON_SWEEP_ICONONLY_ICON_MIN_INC;
- max: BUTTON_SWEEP_ICONONLY_ICON_MIN_INC;
- }
- }
- part { name: "elm.text";
- type: TEXTBLOCK;
- mouse_events: 0;
- effect: SHADOW BOTTOM;
- scale: 1;
- clip_to: "clipper";
- description { state: "default" 0.0;
- fixed: 1 1;
- visible: 0;
- rel1 {
- relative: 1.0 1.0;
- to_x: "padding_icon_text";
- to_y: "padding_left_top";
- }
- rel2 {
- relative: 0.0 0.0;
- to: "padding_right_bottom";
- }
- color: BUTTON_SWEEP_BUTTON_TEXT_NORMAL_COLOR_INC;
- color2: BUTTON_TEXT_SHADOW_NORMAL_COLOR_INC;
- text {
- style: "btn_sweep_multiline";
- align: 0.5 0.45;
- }
- }
- description { state: "visible" 0.0;
- inherit: "default" 0.0;
- visible: 1;
- min: BUTTON_SWEEP_TEXT_MIN_INC;
- }
- description { state: "clicked" 0.0;
- inherit: "default" 0.0;
- visible: 1;
- min: 0 0;
- color: BUTTON_SWEEP_BUTTON_TEXT_PRESSED_COLOR_INC;
- }
- description { state: "disabled" 0.0;
- inherit: "default" 0.0;
- }
- description { state: "disabled_visible" 0.0;
- inherit: "default" 0.0;
- color: BUTTON_SWEEP_BUTTON_TEXT_DISABLED_COLOR_INC;
- visible: 1;
- min: BUTTON_SWEEP_TEXT_MIN_INC;
- }
- description { state: "focused" 0.0;
- inherit: "default" 0.0;
- visible: 1;
- min: 0 0;
- color: BUTTON_SWEEP_BUTTON_TEXT_FOCUSED_COLOR_INC;
- }
- }
- part { name: "over2";
- type: RECT;
- repeat_events: 1;
- ignore_flags: ON_HOLD;
- description { state: "default" 0.0;
- color: 0 0 0 0;
- }
- }
- part { name: "over3";
- type: RECT;
- repeat_events: 1;
- description { state: "default" 0.0;
- color: 0 0 0 0;
- }
- }
- part { name: "clipper";
- type: RECT;
- description { state: "default" 0.0;
- color: BUTTON_DISCLIP_NORMAL_COLOR_INC;
- }
- description { state: "disabled" 0.0;
- inherit: "default" 0.0;
- color: BUTTON_DISCLIP_DISABLED_COLOR_INC;
- }
- }
- part { name: "disabler";
- type: RECT;
- description { state: "default" 0.0;
- color: 0 0 0 0;
- visible: 0;
- }
- description { state: "disabled" 0.0;
- inherit: "default" 0.0;
- visible: 1;
- }
- }
- }
- programs {
- program { name: "button_click";
- signal: "mouse,down,1";
- source: "over2";
- action: SIGNAL_EMIT "elm,action,press" "";
- after: "button_click_anim";
- }
- program { name: "button_click_anim";
- action: STATE_SET "clicked" 0.0;
- target: "button_image";
- after: "text_clicked";
- }
- program { name: "text_clicked";
- script {
- new st[31];
- new Float:vl;
- get_state(PART:"elm.text", st, 30, vl);
- if (!strcmp(st, "visible"))
- set_state(PART:"elm.text", "clicked", 0.0);
- }
- }
- program { name: "button_double_click";
- signal: "mouse,down,1,double";
- source: "over2";
- after: "button_click_anim";
- }
- program { name: "button_unpress";
- action: SIGNAL_EMIT "elm,action,unpress" "";
- }
- program { name: "button_mouseout_clicked";
- signal: "mouse,up,1";
- source: "over3";
- script {
- new st[31];
- new Float:vl;
- get_state(PART:"elm.swallow.content", st, 30, vl);
- if (strcmp(st, "icononly"))
- {
- emit("elm,action,default,text,set", "");
- set_state(PART:"elm.text", "visible", 0.0);
- }
- if (get_int(button_state) != BUTTON_STATE_DISABLED)
- set_state(PART:"button_image", "default", 0.0);
- }
- after: button_unpress;
- }
- program { name: "touch_snd";
- signal: "mouse,clicked,1";
- source: "over2";
- action: PLAY_SAMPLE "touch_sound" 1.0;
- after: button_unclick3;
- }
- program { name: "button_unclick3";
- action: SIGNAL_EMIT "elm,action,click" "";
- }
- 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:"padding_icon_text", "visible", 0.0);
- }
- if (get_int(button_state) != BUTTON_STATE_DISABLED)
- set_state(PART:"elm.text", "visible", 0.0);
- else
- set_state(PART:"elm.text", "disabled_visible", 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:"padding_icon_text", "icononly", 0.0);
- }
- set_state(PART:"elm.text", "default", 0.0);
- }
- }
- program { name: "icon_show";
- signal: "elm,state,icon,visible";
- source: "elm";
- script {
- new st[31];
- new Float:vl;
- get_state(PART:"elm.text", st, 30, vl);
- if (!strcmp(st, "visible"))
- {
- set_state(PART:"elm.swallow.content", "visible", 0.0);
- set_state(PART:"padding_icon_text", "visible", 0.0);
- }
- else
- {
- set_state(PART:"elm.swallow.content", "icononly", 0.0);
- set_state(PART:"padding_icon_text", "icononly", 0.0);
- }
- }
- }
- program { name: "icon_hide";
- signal: "elm,state,icon,hidden";
- source: "elm";
- action: STATE_SET "default" 0.0;
- target: "elm.swallow.content";
- target: "padding_icon_text";
- }
- program { name: "disable";
- signal: "elm,state,disabled";
- source: "elm";
- action: STATE_SET "disabled" 0.0;
- target: "button_image";
- target: "clipper";
- target: "disabler";
- after: "disable_text";
- }
- program { name: "disable_text";
- script {
- new st[31];
- new Float:vl;
- get_state(PART:"elm.text", st, 30, vl);
- if (!strcmp(st, "visible"))
- set_state(PART:"elm.text", "disabled_visible", 0.0);
- else
- set_state(PART:"elm.text", "disabled", 0.0);
- set_int(button_state, BUTTON_STATE_DISABLED);
- }
- }
- program { name: "enable";
- signal: "elm,state,enabled";
- source: "elm";
- action: STATE_SET "default" 0.0;
- target: "button_image";
- target: "clipper";
- target: "disabler";
- after: "enable_text";
- }
- program { name: "enable_text";
- script {
- new st[31];
- new Float:vl;
- get_state(PART:"elm.text", st, 30, vl);
- if (!strcmp(st, "disabled_visible"))
- set_state(PART:"elm.text", "visible", 0.0);
- else
- set_state(PART:"elm.text", "default", 0.0);
- set_int(button_state, BUTTON_STATE_ENABLED);
- }
- }
- program { name: "action_focus";
- signal: "elm,action,focus_highlight,show";
- source: "elm";
- action: STATE_SET "focused" 0.0;
- target: "focus_image";
- }
- program { name: "action_unfocus";
- signal: "elm,action,focus_highlight,hide";
- source: "elm";
- action: STATE_SET "default" 0.0;
- target: "focus_image";
- }
- }
- }
-
-///////////////////////////////////////////////////////////////////////////////////////
- group { name: "elm/button/base/sweep/delete";
- inherit: "elm/button/base/sweep";
- alias: "elm/button/base/sweep/delete/multiline";
- images {
- image: "00_button_01_delete_press.png" COMP;
- image: "00_button_01_delete.png" COMP;
- image: "00_button_01_delete_dim.png" COMP;
- }
- styles{
- style { name: "btn_sweep_delete_multiline";
- base: "font=Tizen:style=Regular font_size="BUTTON_SWEEP_FONT_SIZE_INC" align=center color=#ffffff wrap=mixed linegap=-7 ellipsis=1.0 text_class=tizen";
- tag: "br" "\n";
- tag: "ps" "ps";
- tag: "tab" "\t";
- }
- }
- parts {
- part { name: "button_image";
- scale: 1;
- description { state: "default" 0.0;
- min: BUTTON_SWEEP_BG_NORMAL_MIN_INC;
- image {
- normal: "00_button_01_delete.png";
- border: BUTTON_SWEEP_BG_BORDER_INC;
- border_scale: 1;
- }
- }
- description { state: "clicked" 0.0;
- inherit: "default" 0.0;
- image.normal: "00_button_01_delete_press.png";
- }
- description { state: "disabled" 0.0;
- inherit: "default" 0.0;
- image.normal: "00_button_01_delete_dim.png";
- }
- description { state: "focused" 0.0;
- inherit: "default" 0.0;
- image.normal: "00_button_01_delete_press.png";
- }
- }
- part { name: "elm.text";
- type: TEXTBLOCK;
- mouse_events: 0;
- effect: SHADOW BOTTOM;
- scale: 1;
- clip_to: "clipper";
- description { state: "default" 0.0;
- fixed: 1 1;
- visible: 0;
- rel1 {
- relative: 1.0 1.0;
- to_x: "padding_icon_text";
- to_y: "padding_left_top";
- }
- rel2 {
- relative: 0.0 0.0;
- to: "padding_right_bottom";
- }
- color: BUTTON_DELETE_BUTTON_TEXT_NORMAL_COLOR_INC;
- color2: BUTTON_TEXT_SHADOW_NORMAL_COLOR_INC;
- text {
- style: "btn_sweep_multiline";
- align: 0.5 0.45;
- }
- }
- description { state: "visible" 0.0;
- inherit: "default" 0.0;
- visible: 1;
- min: BUTTON_SWEEP_TEXT_MIN_INC;
- }
- description { state: "clicked" 0.0;
- inherit: "default" 0.0;
- visible: 1;
- min: 0 0;
- color: BUTTON_DELETE_BUTTON_TEXT_PRESSED_COLOR_INC;
- }
- description { state: "disabled" 0.0;
- inherit: "default" 0.0;
- }
- description { state: "disabled_visible" 0.0;
- inherit: "default" 0.0;
- color: BUTTON_DELETE_BUTTON_TEXT_DISABLED_COLOR_INC;
- visible: 1;
- min: BUTTON_SWEEP_TEXT_MIN_INC;
- }
- description { state: "focused" 0.0;
- inherit: "default" 0.0;
- visible: 1;
- min: 0 0;
- color: BUTTON_DELETE_BUTTON_TEXT_FOCUSED_COLOR_INC;
- }
- }
- }
- }
-
-///////////////////////////////////////////////////////////////////////////////////////
group { name: "elm/button/base/popup_button/default";
alias: "elm/button/base/popup_button/menustyle";
alias: "elm/button/base/popup_button/liststyle";