move safety check to actually do stuff here
authordiscomfitor <discomfitor@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Sun, 4 Dec 2011 22:02:02 +0000 (22:02 +0000)
committerdiscomfitor <discomfitor@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Sun, 4 Dec 2011 22:02:02 +0000 (22:02 +0000)
git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/elementary@65872 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/elm_win.c

index b4d1f88..367089d 100644 (file)
@@ -639,8 +639,6 @@ _elm_win_obj_callback_resize(void *data, Evas *e __UNUSED__, Evas_Object *obj, v
         Evas_Coord w = 1, h = 1;
 
         evas_object_geometry_get(obj, NULL, NULL, &w, &h);
-        if (w < 1) w = 1;
-        if (h < 1) h = 1;
         if (win->constrain)
           {
              int sw, sh;
@@ -648,6 +646,8 @@ _elm_win_obj_callback_resize(void *data, Evas *e __UNUSED__, Evas_Object *obj, v
              w = MIN(w, sw);
              h = MIN(h, sh);
           }
+        if (w < 1) w = 1;
+        if (h < 1) h = 1;
         evas_object_image_size_set(win->img_obj, w, h);
      }
 }