hermet pushed a commit to branch master.

http://git.enlightenment.org/core/elementary.git/commit/?id=2839881f37ea85b3469d8fd37cfaa4f9d67458fa

commit 2839881f37ea85b3469d8fd37cfaa4f9d67458fa
Author: jiin.moon <jiin.m...@samsung.com>
Date:   Thu Dec 18 17:53:44 2014 +0900

    elm/image: Fix an unclipped issue about image bigger than object size
    
    Summary:
    When resizes an image
    if "fill_inside" and "aspect_fixed" in Elm_Image_Data struct are "TRUE",
    extra width or height go outside of the object area.
    The width or height on outside will be clipped.
    @fix
    
    Reviewers: Hermet
    
    Differential Revision: https://phab.enlightenment.org/D1794
---
 src/lib/elm_image.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/lib/elm_image.c b/src/lib/elm_image.c
index cab94bf..e7076b8 100644
--- a/src/lib/elm_image.c
+++ b/src/lib/elm_image.c
@@ -183,6 +183,10 @@ _elm_image_internal_sizing_eval(Evas_Object *obj, 
Elm_Image_Data *sd)
 
         evas_object_move(sd->img, x, y);
         evas_object_image_fill_set(sd->img, 0, 0, w, h);
+
+        if (x < 0) w+=x;
+        if (y < 0) h+=y;
+
         evas_object_resize(sd->img, w, h);
      }
    evas_object_move(sd->hit_rect, x, y);

-- 


Reply via email to