From: Colin Leroy Date: Sat, 28 Dec 2013 17:15:31 +0000 (+0100) Subject: Fix bug #3020, "Use theme doesn't change some icons until restart" X-Git-Tag: 3.10.0~217 X-Git-Url: http://git.claws-mail.org/?p=claws.git;a=commitdiff_plain;h=7bd41ae67a9fe6bd800d4cec9f2f1e012a244ba6 Fix bug #3020, "Use theme doesn't change some icons until restart" --- diff --git a/src/addr_compl.c b/src/addr_compl.c index ed7355788..7472fc1ad 100644 --- a/src/addr_compl.c +++ b/src/addr_compl.c @@ -969,6 +969,17 @@ static void addrcompl_add_entry( CompletionWindow *cw, gchar *address ) { #endif } +void addrcompl_reflect_prefs_pixmap_theme(void) { + if (group_pixbuf) { + g_object_unref(G_OBJECT(group_pixbuf)); + group_pixbuf = NULL; + } + if (email_pixbuf) { + g_object_unref(G_OBJECT(email_pixbuf)); + email_pixbuf = NULL; + } +} + /** * Completion idle function. This function is called by the main (UI) thread * during UI idle time while an address search is in progress. Items from the diff --git a/src/addr_compl.h b/src/addr_compl.h index 3dbdc8ddb..de9d4b1b5 100644 --- a/src/addr_compl.h +++ b/src/addr_compl.h @@ -54,4 +54,5 @@ void addrcompl_teardown ( void ); void addr_compl_add_address1(const char *str, address_entry *ae); +void addrcompl_reflect_prefs_pixmap_theme(void); #endif /* __ADDR_COMPL_H__ */ diff --git a/src/prefs_themes.c b/src/prefs_themes.c index 2f3202c17..6c69fba9d 100644 --- a/src/prefs_themes.c +++ b/src/prefs_themes.c @@ -428,14 +428,15 @@ static void prefs_themes_btn_use_clicked_cb(GtkWidget *widget, gpointer data) gchar *theme_str; theme_str = tdata->displayed; - + g_free(prefs_common.pixmap_theme_path); - + prefs_common.pixmap_theme_path = g_strdup(theme_str); - + main_window_reflect_prefs_all_real(TRUE); compose_reflect_prefs_pixmap_theme(); - + addrcompl_reflect_prefs_pixmap_theme(); + prefs_themes_update_buttons(tdata); }