nikawhite pushed a commit to branch master.

http://git.enlightenment.org/tools/eflete.git/commit/?id=608623bf0a9ea7746c6a313450823c0dc2ccf2b0

commit 608623bf0a9ea7746c6a313450823c0dc2ccf2b0
Author: Tetiana Naumenko <t.naume...@samsung.com>
Date:   Fri Jun 9 12:03:20 2017 +0300

    theme: made layout/popup/hint scalable
    
    Change-Id: I29efc1ec6353c3f8504105494eccaccf7aa9a900
---
 data/themes/default/widgets/layout.edc | 84 ++++++++++++++++++++++++++++++----
 src/bin/ui/popup.c                     |  2 +-
 2 files changed, 77 insertions(+), 9 deletions(-)

diff --git a/data/themes/default/widgets/layout.edc 
b/data/themes/default/widgets/layout.edc
index d79f690d0..f3a9e473a 100644
--- a/data/themes/default/widgets/layout.edc
+++ b/data/themes/default/widgets/layout.edc
@@ -82,20 +82,46 @@ group { name: "elm/layout/popup/hint";
    parts {
       part { name: "event";
          type: RECT;
+         scale: 1;
          description { state: "default" 0.0;
             rel1.offset: -9999 -9999;
             rel2.offset: 9999 9999;
             color: 0 0 0 0;
          }
       }
+      part { name: "top_left_space";
+         type: SPACER;
+         scale: 1;
+         description { state: "default" 0.0;
+            align: 1.0 1.0;
+            fixed: 1 1;
+            min: 6 6;
+            max: 6 6;
+            rel2.relative: 0.0 0.0;
+         }
+      }
+      part { name: "bottom_right_space";
+         type: SPACER;
+         scale: 1;
+         description { state: "default" 0.0;
+            align: 0.0 0.0;
+            fixed: 1 1;
+            min: 6 6;
+            max: 6 6;
+            rel1.relative: 1.0 1.0;
+         }
+      }
       part { name: "bg";
          type: IMAGE;
+         scale: 1;
          description { state: "default" 0.0;
             rel1 {
-               offset: -6 -6;
+               relative: 0.0 0.0;
+               to: "top_left_space";
             }
             rel2 {
-               offset: 6 6;
+               relative: 1.0 1.0;
+               to: "bottom_right_space";
             }
             image {
                normal: "hint-background.png";
@@ -104,30 +130,72 @@ group { name: "elm/layout/popup/hint";
             }
          }
       }
-      part { name: "elm.swallow.content";
-         type: SWALLOW;
+      part { name: "left_content_space";
+         type: SPACER;
+         scale: 1;
          description { state: "default" 0.0;
             align: 0.0 0.0;
+            fixed: 1 1;
+            min: 8 6;
+            max: 8 6;
             rel1 {
-               offset: 6 6;
+               relative: 0.0 0.0;
                to: "bg";
             }
+         }
+      }
+      part { name: "right_content_space";
+         type: SPACER;
+         scale: 1;
+         description { state: "default" 0.0;
+            align: 1.0 1.0;
+            fixed: 1 1;
+            min: 6 6;
+            max: 6 6;
             rel2 {
                relative: 1.0 0.0;
-               offset: -7 -7;
                to_x: "bg";
                to_y: "elm.swallow.ok";
             }
          }
       }
+      part { name: "elm.swallow.content";
+         type: SWALLOW;
+         scale: 1;
+         description { state: "default" 0.0;
+            align: 0.0 0.0;
+            rel1 {
+               relative: 1.0 1.0;
+               to: "left_content_space";
+            }
+            rel2 {
+               relative: 0.0 0.0;
+               to: "right_content_space";
+            }
+         }
+      }
+      part { name: "right_ok_space";
+         type: SPACER;
+         scale: 1;
+         description { state: "default" 0.0;
+            align: 1.0 1.0;
+            fixed: 1 1;
+            min: 6 6;
+            max: 6 6;
+            rel2 {
+               to: "bg";
+            }
+         }
+      }
       part { name: "elm.swallow.ok";
          type: SWALLOW;
+         scale: 1;
          description { state: "default" 0.0;
             align: 1.0 1.0;
             max: 32 16;
             rel2 {
-               offset: -7 -7;
-               to: "bg";
+               relative: 0.0 0.0;
+               to: "right_ok_space";
             }
          }
       }
diff --git a/src/bin/ui/popup.c b/src/bin/ui/popup.c
index d814f484f..cf835391d 100644
--- a/src/bin/ui/popup.c
+++ b/src/bin/ui/popup.c
@@ -1292,7 +1292,7 @@ popup_colorselector_helper(Evas_Object *follow_up,
    /* small hack, hide not necessary button */
    evas_object_hide(elm_layout_content_unset(fs, "elm.swallow.cancel"));
    evas_object_size_hint_min_set(helper, COLOR_W, COLOR_H);
-   evas_object_resize(helper, COLOR_W, COLOR_H);
+   evas_object_resize(helper, COLOR_W * elm_config_scale_get(), COLOR_H * 
elm_config_scale_get());
 
 #if !HAVE_TIZEN
    BUTTON_ADD(fs, helper_data->button, _("Ok"))

-- 


Reply via email to