changeset 25897:44ce467babaf

Fix the issue with the themes not showing up in the list. N.B.: there are two calls to purple_theme_manager_init() in purple_core_init(). I'm guessing it should be initialized earlier rather than later (on the assumption that the sound/smiley stuff wants it available). The call to init the PurpleThemeManager? stuff should be before both the sound and smiley init. refs #7760 committer: Gary Kramlich <grim@reaperworld.com>
author Paul Aurich <paul@darkrain42.org>
date Tue, 06 Jan 2009 03:52:31 +0000
parents 6c6846d169d6
children dc2584ebaa1a
files libpurple/core.c pidgin/gtkprefs.c
diffstat 2 files changed, 8 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/core.c	Tue Jan 06 03:50:44 2009 +0000
+++ b/libpurple/core.c	Tue Jan 06 03:52:31 2009 +0000
@@ -175,7 +175,6 @@
 	purple_idle_init();
 	purple_smileys_init();
 	purple_theme_manager_init();
-	purple_theme_manager_refresh();
 	/*
 	 * Call this early on to try to auto-detect our IP address and
 	 * hopefully save some time later.
@@ -185,6 +184,9 @@
 	if (ops != NULL && ops->ui_init != NULL)
 		ops->ui_init();
 
+	/* The UI may have registered some theme types, so refresh them */
+	purple_theme_manager_refresh();
+
 	return TRUE;
 }
 
--- a/pidgin/gtkprefs.c	Tue Jan 06 03:50:44 2009 +0000
+++ b/pidgin/gtkprefs.c	Tue Jan 06 03:52:31 2009 +0000
@@ -2468,8 +2468,11 @@
 		gtk_window_present(GTK_WINDOW(prefs));
 		return;
 	}
-	
-	/* add everthing in the thmeme manager before the window is loaded */
+
+	/* Refresh the list of themes before showing the preferences window */
+	purple_theme_manager_refresh();
+
+	/* add everything in the theme manager before the window is loaded */
 	if (prefs_themes_unsorted) {
 		purple_theme_manager_for_each_theme(prefs_themes_sort);
 		prefs_themes_unsorted = FALSE;