Enlightenment CVS committal

Author  : devilhorns
Project : e17
Module  : apps/e

Dir     : e17/apps/e/src/bin


Modified Files:
        e_shelf.c 


Log Message:
Some shelf fixes.
- Use -1 during a call to evas_list_sort rather than evas_list_count. -1
will sort the whole list anyway, and we avoid the extra call to list_count.
- Don't sort shelves during every add. They are sorted when e_shelf_list is
called anyway.
- Fix shelf numbering in the shelf list dialog.

===================================================================
RCS file: /cvs/e/e17/apps/e/src/bin/e_shelf.c,v
retrieving revision 1.86
retrieving revision 1.87
diff -u -3 -r1.86 -r1.87
--- e_shelf.c   2 Dec 2007 20:19:21 -0000       1.86
+++ e_shelf.c   8 Dec 2007 23:40:57 -0000       1.87
@@ -72,16 +72,18 @@
        cf_es = l->data;
        if (cf_es->id <= 0) cf_es->id = id + 1;
        zone = e_util_container_zone_id_get(cf_es->container, cf_es->zone);
-       id = cf_es->id;
-       if (zone) e_shelf_config_new(zone, cf_es);
+       if (zone) 
+         {
+            id = cf_es->id;
+            e_shelf_config_new(zone, cf_es);
+         }
      }
 }
 
 EAPI Evas_List *
 e_shelf_list(void)
 {
-   shelves = evas_list_sort(shelves, evas_list_count(shelves), 
-                           _e_shelf_cb_id_sort);
+   shelves = evas_list_sort(shelves, -1, _e_shelf_cb_id_sort);
    return shelves;
 }
 
@@ -183,7 +185,6 @@
                                      _e_shelf_cb_menu_items_append, es);
    
    shelves = evas_list_append(shelves, es);
-   shelves = evas_list_sort(shelves, -1, _e_shelf_cb_id_sort);
    
    es->hidden = 0;
    es->hide_step = 0;



-------------------------------------------------------------------------
SF.Net email is sponsored by: 
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to