rimmed pushed a commit to branch master.

http://git.enlightenment.org/tools/eflete.git/commit/?id=1e0a1dbcc03c6da0dea91c7231dad8f8aad650e8

commit 1e0a1dbcc03c6da0dea91c7231dad8f8aad650e8
Author: Vyacheslav Reutskiy <v.reuts...@samsung.com>
Date:   Tue Jul 14 08:24:58 2015 +0300

    Styles: make button style 'elipsis' more minimal
    
    Change-Id: I5c19f7eb56df939af7bfb853e765fa67c8388cd2
---
 data/themes/default/widgets/button.edc | 268 +++------------------------------
 1 file changed, 21 insertions(+), 247 deletions(-)

diff --git a/data/themes/default/widgets/button.edc 
b/data/themes/default/widgets/button.edc
index 7e2cce7..dd5f2c1 100644
--- a/data/themes/default/widgets/button.edc
+++ b/data/themes/default/widgets/button.edc
@@ -551,277 +551,51 @@ group { name: "elm/button/base/elipsis";
       image: "input-select-file-clicked.png" COMP;
    }
    parts {
-      part { name: "button_image";
-         mouse_events: 1;
+      part { name: "bg";
+         type: IMAGE;
          description { state: "default" 0.0;
-            SET_SIZE(19, 17);
+            min: 19 17;
+            max: 19 17;
             image {
                normal: "input-select-file.png";
                middle: SOLID;
             }
          }
          description { state: "clicked" 0.0;
-            inherit: "default" 0.0;
-            image.normal: "input-select-file-clicked.png";
-         }
-         description { state: "disabled" 0.0;
-            inherit:  "default" 0.0;
-            image.normal: "input-select-file.png";
-            color: 64 64 64 100;
-         }
-      }
-      part { name: "elm.swallow.content";
-         type: SWALLOW;
-         description { state: "default" 0.0;
-            fixed: 1 0;
-            visible: 0;
-            align: 0.0 0.5;
-            rel1.offset: 2 2;
-            rel2 {
-               offset: 1 -3;
-               relative: 0.0 1.0;
-            }
-         }
-         description { state: "visible" 0.0;
-            inherit: "default" 0.0;
-            fixed: 1 0;
-            visible: 1;
-            aspect: 1.0 1.0;
-            rel2.offset: 2 -3;
-         }
-         description { state: "icononly" 0.0;
-            inherit: "default" 0.0;
-            fixed: 0 0;
-            visible: 1;
-            align: 0.5 0.5;
-            rel2 {
-               offset: -3 -3;
-               relative: 1.0 1.0;
-            }
-         }
-      }
-      part {
-         name:          "elm.text";
-         type:          TEXT;
-         effect:        SOFT_SHADOW;
-         mouse_events:  0;
-         scale: 1;
-         description { state: "default" 0.0;
-            visible: 0;
-            rel1 {
-               to_x: "elm.swallow.content";
-               relative: 1.0 0.0;
-               offset: 0 2;
-            }
-            rel2.offset: -3 -3;
-            color: 224 224 224 255;
-            color3: 0 0 0 64;
-            text {
-               font: FN;
-               size: 10;
-               min: 0 0;
-               align: 0.5 0.5;
-               text_class: "button";
-            }
-         }
-         description { state: "visible" 0.0;
-            inherit: "default" 0.0;
-            visible: 1;
-            text {
-               min: 1 1;
-               ellipsis: -1;
-            }
-         }
-         description { state: "disabled" 0.0;
-            inherit: "default" 0.0;
-         }
-         description { state: "disabled_visible" 0.0;
-            inherit: "default" 0.0;
-            color: 0 0 0 128;
-            color3: 0 0 0 0;
-            visible: 1;
-            text {
-               min: 1 1;
-               ellipsis: -1;
-            }
-         }
-      }
-      part { name: "over2";
-         type: RECT;
-         mouse_events: 1;
-         repeat_events: 1;
-         ignore_flags: ON_HOLD;
-         description { state: "default" 0.0;
-            color: 0 0 0 0;
-         }
-         description { state: "disabled" 0.0;
-            inherit:  "default" 0.0;
-            visible: 0;
-         }
-      }
-      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;
-         }
-      }
-      // used to force sizing of icon to follow label sizing nearby
-      part { name: "sizer.content"; type: TEXT;
-         mouse_events:  0;
-         scale: 1;
-         description { state: "default" 0.0;
-            visible: 0;
-            text {
-               font: FN;
-               size: 10;
-               min: 0 0;
-               text_class: "button";
-            }
-         }
-         description { state: "visible" 0.0;
-            inherit: "default" 0.0;
-            rel1.to: "elm.swallow.content";
-            rel2.to: "elm.swallow.content";
-            text {
-               min: 1 1;
-               ellipsis: -1;
-               text: "M";
+            min: 19 17;
+            max: 19 17;
+            image {
+               normal: "input-select-file-clicked.png";
+               middle: SOLID;
             }
          }
-         description { state: "icononly" 0.0;
-            inherit: "visible" 0.0;
-         }
       }
-      // end sizer
    }
    programs {
-      program {
-         name:   "button_click";
+      program { name: "button_click";
          signal: "mouse,down,1";
-         source: "over2";
+         source: "bg";
          action: SIGNAL_EMIT "elm,action,press" "";
          after: "button_click_anim";
       }
-      program {
-         name:   "button_click_anim";
-         action: STATE_SET "clicked" 0.0;
-         target: "button_image";
-      }
-      program {
-         name:   "button_unclick";
+      program { name: "button_unclick";
          signal: "mouse,up,1";
-         source: "over2";
+         source: "bg";
          action: SIGNAL_EMIT "elm,action,unpress" "";
          after: "button_unclick_anim";
       }
-      program {
-         name:   "button_unclick_anim";
-         action: STATE_SET "default" 0.0;
-         target: "button_image";
-      }
-      program {
-         name:   "button_unclick3";
+      program { name: "button_unclick3";
          signal: "mouse,clicked,1";
-         source: "over2";
+         source: "bg";
          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:"sizer.content", "visible", 0.0);
-            }
-            get_state(PART:"elm.text", st, 30, vl);
-            if (!strcmp(st, "disabled") || (!strcmp(st, "disabled_visible")))
-              set_state(PART:"elm.text", "disabled_visible", 0.0);
-            else
-              set_state(PART:"elm.text", "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:"sizer.content", "icononly", 0.0);
-            }
-            set_state(PART:"elm.text", "default", 0.0);
-            get_state(PART:"elm.text", st, 30, vl);
-            if (!strcmp(st, "default") || (!strcmp(st, "visible")))
-              set_state(PART:"elm.text", "default", 0.0);
-            else
-              set_state(PART:"elm.text", "disabled", 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:"sizer.content", "visible", 0.0);
-            }
-            else {
-               set_state(PART:"elm.swallow.content", "icononly", 0.0);
-               set_state(PART:"sizer.content", "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: "sizer.content";
-      }
-      program { name: "disable";
-         signal: "elm,state,disabled";
-         source: "elm";
-         script {
-            new st[31];
-            new Float:vl;
-            set_state(PART:"button_image", "disabled", 0.0);
-            set_state(PART:"over2", "disabled", 0.0);
-            set_state(PART:"disabler", "disabled", 0.0);
-            get_state(PART:"elm.text", st, 30, vl);
-            if (!strcmp(st, "visible") || !strcmp(st, "disabled_visible"))
-              set_state(PART:"elm.text", "disabled_visible", 0.0);
-            else
-              set_state(PART:"elm.text", "disabled", 0.0);
-         }
+      program { name: "button_unclick_anim";
+         action: STATE_SET "default" 0.00;
+         target: "bg";
       }
-      program { name: "enable";
-         signal: "elm,state,enabled";
-         source: "elm";
-         script {
-            new st[31];
-            new Float:vl;
-            set_state(PART:"button_image", "visible", 0.0);
-            set_state(PART:"over2", "visible", 0.0);
-            set_state(PART:"disabler", "visible", 0.0);
-            get_state(PART:"elm.text", st, 30, vl);
-            if (!strcmp(st, "visible") || !strcmp(st, "disabled_visible"))
-              set_state(PART:"elm.text", "visible", 0.0);
-            else
-              set_state(PART:"elm.text", "default", 0.0);
-         }
+      program { name: "button_click_anim";
+         action: STATE_SET "clicked" 0.00;
+         target: "bg";
       }
    }
 }

-- 


Reply via email to