yoz pushed a commit to branch master.

http://git.enlightenment.org/misc/entrance.git/commit/?id=f3bfb371ce5d8398a796c896d4547eb9187b6bc5

commit f3bfb371ce5d8398a796c896d4547eb9187b6bc5
Author: MichaĆ«l Bouchaud (yoz) <[email protected]>
Date:   Tue May 13 17:35:35 2014 +0200

    entrance: simplify pool code
---
 src/bin/entrance_gui.c | 35 ++++++++++++++---------------------
 1 file changed, 14 insertions(+), 21 deletions(-)

diff --git a/src/bin/entrance_gui.c b/src/bin/entrance_gui.c
index 714d1fe..3787ed9 100644
--- a/src/bin/entrance_gui.c
+++ b/src/bin/entrance_gui.c
@@ -458,30 +458,23 @@ entrance_gui_xsessions_get(void)
 void
 entrance_gui_conf_set(const Entrance_Conf_Gui_Event *conf)
 {
-   if (_gui->background_pool && conf->background_pool)
+   Entrance_Image *img;
+   EINA_LIST_FREE(_gui->background_pool, img)
      {
-        Entrance_Image *img;
-        EINA_LIST_FREE(_gui->background_pool, img)
-          {
-             eina_stringshare_del(img->path);
-             eina_stringshare_del(img->group);
-             free(img);
-          }
-     }
-   if (conf->background_pool)
-     _gui->background_pool = conf->background_pool;
-   if (_gui->icon_pool && conf->icon_pool)
+        eina_stringshare_del(img->path);
+        eina_stringshare_del(img->group);
+        free(img);
+      }
+   _gui->background_pool = conf->background_pool;
+
+   EINA_LIST_FREE(_gui->icon_pool, img)
      {
-        Entrance_Image *img;
-        EINA_LIST_FREE(_gui->icon_pool, img)
-          {
-             eina_stringshare_del(img->path);
-             eina_stringshare_del(img->group);
-             free(img);
-          }
+        eina_stringshare_del(img->path);
+        eina_stringshare_del(img->group);
+        free(img);
      }
-   if (conf->icon_pool)
-     _gui->icon_pool = conf->icon_pool;
+   _gui->icon_pool = conf->icon_pool;
+
    if (_gui->bg.path != conf->bg.path)
      {
         if ((conf->bg.path) && (*conf->bg.path))

-- 


Reply via email to