[libdazzle] tree: clear lingering icon-name



commit bae0b8fa19a4a2a45fb1f9f275e41ca7606f0240
Author: Christian Hergert <chergert redhat com>
Date:   Sun Jan 7 19:51:35 2018 -0800

    tree: clear lingering icon-name
    
    If we did not get an icon-name, we might still have an icon-name
    set in the cell renderer. This ensures we clear it.

 src/tree/dzl-tree.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/tree/dzl-tree.c b/src/tree/dzl-tree.c
index bac4af6..215f55f 100644
--- a/src/tree/dzl-tree.c
+++ b/src/tree/dzl-tree.c
@@ -435,7 +435,7 @@ pixbuf_func (GtkCellLayout   *cell_layout,
 
   icon = dzl_tree_node_get_gicon (node);
   g_object_get (cell, "gicon", &old_icon, NULL);
-  if (icon != old_icon)
+  if (icon != old_icon || icon == NULL)
     g_object_set (cell, "gicon", icon, NULL);
 }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]