Enlightenment CVS committal

Author  : tsauerbeck
Project : e17
Module  : libs/esmart

Dir     : e17/libs/esmart/src/lib/esmart_container


Modified Files:
        esmart_container.c 


Log Message:
fixed esmart_container_sort(). thanks to xnowfall
===================================================================
RCS file: 
/cvsroot/enlightenment/e17/libs/esmart/src/lib/esmart_container/esmart_container.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -3 -r1.8 -r1.9
--- esmart_container.c  9 Jan 2005 02:36:00 -0000       1.8
+++ esmart_container.c  19 Apr 2005 09:05:52 -0000      1.9
@@ -25,8 +25,9 @@
    
    o = ((Container_Element *) d1)->obj;
    oo = ((Container_Element *) d2)->obj;
-   if (_sort_func) return 0;
-   return _sort_func(d1, d2);
+
+   /* _sort_func is checked for NULL below */
+   return _sort_func(o, oo);
 }
 
 void esmart_container_sort(Evas_Object *container, int (*func)(Evas_Object *, 
Evas_Object *$))
@@ -35,6 +36,8 @@
   
    cont = _container_fetch(container);
    if (!cont) return;
+
+   if (!func) return;
     
    _sort_func = func;
    cont->elements = evas_list_sort(cont->elements,




-------------------------------------------------------
This SF.Net email is sponsored by: New Crystal Reports XI.
Version 11 adds new functionality designed to reduce time involved in
creating, integrating, and deploying reporting solutions. Free runtime info,
new features, or free trial, at: http://www.businessobjects.com/devxi/728
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to