Enlightenment CVS committal

Author  : pfritz
Project : e17
Module  : libs/ewl

Dir     : e17/libs/ewl/src/lib


Modified Files:
        ewl_window.c ewl_embed.c 


Log Message:
fix ewl_embed move issue

===================================================================
RCS file: /cvs/e/e17/libs/ewl/src/lib/ewl_window.c,v
retrieving revision 1.55
retrieving revision 1.56
diff -u -3 -r1.55 -r1.56
--- ewl_window.c        10 Jun 2006 00:35:06 -0000      1.55
+++ ewl_window.c        20 Jun 2006 00:55:17 -0000      1.56
@@ -72,8 +72,6 @@
         * Override the default configure callbacks since the window
         * has special needs for placement.
         */
-       ewl_callback_del(EWL_WIDGET(w), EWL_CALLBACK_CONFIGURE,
-                       ewl_overlay_configure_cb);
        ewl_callback_prepend(EWL_WIDGET(w), EWL_CALLBACK_CONFIGURE,
                             ewl_window_configure_cb, NULL);
 
===================================================================
RCS file: /cvs/e/e17/libs/ewl/src/lib/ewl_embed.c,v
retrieving revision 1.69
retrieving revision 1.70
diff -u -3 -r1.69 -r1.70
--- ewl_embed.c 2 Jun 2006 21:56:50 -0000       1.69
+++ ewl_embed.c 20 Jun 2006 00:55:17 -0000      1.70
@@ -101,6 +101,8 @@
                             ewl_embed_configure_cb, NULL);
        ewl_callback_prepend(EWL_WIDGET(w), EWL_CALLBACK_FOCUS_OUT,
                             ewl_embed_focus_out_cb, NULL);
+       ewl_callback_del(EWL_WIDGET(w), EWL_CALLBACK_CONFIGURE,
+                            ewl_overlay_configure_cb);
 
        ecore_list_append(ewl_embed_list, w);
 
@@ -1629,36 +1631,21 @@
         */
        ecore_dlist_goto_first(EWL_CONTAINER(w)->children);
        while ((child = ecore_dlist_next(EWL_CONTAINER(w)->children))) {
-               int x, y;
                int size;
 
-               /*
-                * Try to give the child the full size of the window from it's
-                * base position. The object will constrict it based on the
-                * fill policy. Don't add the TOP and LEFT insets since
-                * they've already been accounted for.
-                */
-               x = ewl_object_current_x_get(EWL_OBJECT(child));
-               y = ewl_object_current_y_get(EWL_OBJECT(child));
 
-               if (x < CURRENT_X(w)) {
-                       x = CURRENT_X(w);
-                       size = ewl_object_preferred_w_get(EWL_OBJECT(child));
-                       if (size > PREFERRED_W(w))
-                               ewl_object_preferred_inner_w_set(EWL_OBJECT(w),
-                                               size);
-               }
-
-               if (y < CURRENT_Y(w)) {
-                       y = CURRENT_Y(w);
-                       size = ewl_object_preferred_h_get(EWL_OBJECT(child));
-                       if (size > PREFERRED_H(w))
-                               ewl_object_preferred_inner_h_set(EWL_OBJECT(w),
-                                               size);
-               }
+               size = ewl_object_preferred_w_get(EWL_OBJECT(child));
+               if (size > PREFERRED_W(w))
+                       ewl_object_preferred_inner_w_set(EWL_OBJECT(w),
+                                       size);
+
+               size = ewl_object_preferred_h_get(EWL_OBJECT(child));
+               if (size > PREFERRED_H(w))
+                       ewl_object_preferred_inner_h_set(EWL_OBJECT(w),
+                                       size);
 
-               ewl_object_place(child, x, y, CURRENT_W(w) - (x - CURRENT_X(w)),
-                                CURRENT_H(w) - (y - CURRENT_Y(w)));
+               ewl_object_place(child, CURRENT_X(w), CURRENT_Y(w), 
+                                       CURRENT_W(w), CURRENT_H(w));
        }
 
        DLEAVE_FUNCTION(DLEVEL_STABLE);




_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to