# HG changeset patch # User nenolod # Date 1160029009 25200 # Node ID a6a248bfafc3770a4d24db79e6910939dffaa227 # Parent df23110701d04be25255634aae1a1cc9ff3c2251 [svn] - create the windows during skin load process after the skin.hints has been loaded diff -r df23110701d0 -r a6a248bfafc3 ChangeLog --- a/ChangeLog Wed Oct 04 23:11:06 2006 -0700 +++ b/ChangeLog Wed Oct 04 23:16:49 2006 -0700 @@ -1,3 +1,11 @@ +2006-10-05 06:11:06 +0000 William Pitcock + revision [2577] + - load skins before creating the UI + + trunk/audacious/main.c | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + + 2006-10-05 06:09:40 +0000 William Pitcock revision [2575] - more hardcoded values removed diff -r df23110701d0 -r a6a248bfafc3 audacious/main.c --- a/audacious/main.c Wed Oct 04 23:11:06 2006 -0700 +++ b/audacious/main.c Wed Oct 04 23:16:49 2006 -0700 @@ -1076,11 +1076,6 @@ exit(EXIT_FAILURE); } - mainwin_create(); - - playlistwin_create(); - equalizerwin_create(); - GDK_THREADS_ENTER(); } diff -r df23110701d0 -r a6a248bfafc3 audacious/widgets/skin.c --- a/audacious/widgets/skin.c Wed Oct 04 23:11:06 2006 -0700 +++ b/audacious/widgets/skin.c Wed Oct 04 23:16:49 2006 -0700 @@ -310,6 +310,14 @@ width = gdk_pixbuf_get_width(pixbuf); height = gdk_pixbuf_get_height(pixbuf); + /* create the windows if they haven't been created yet, needed for bootstrapping */ + if (mainwin == NULL) + { + mainwin_create(); + equalizerwin_create(); + playlistwin_create(); + } + if (!(pixmap = gdk_pixmap_new(mainwin->window, width, height, gdk_rgb_get_visual()->depth))) { g_object_unref(pixbuf); @@ -1318,12 +1326,12 @@ skin->path = g_strdup(path); if (!file_is_archive(path)) { + /* Parse the hints for this skin. */ + skin_parse_hints(skin, NULL); + skin_load_pixmaps(skin, path); skin_load_cursor(skin, path); - /* Parse the hints for this skin. */ - skin_parse_hints(skin, NULL); - return TRUE; } @@ -1332,12 +1340,12 @@ return FALSE; } + /* Parse the hints for this skin. */ + skin_parse_hints(skin, cpath); + skin_load_pixmaps(skin, cpath); skin_load_cursor(skin, cpath); - /* Parse the hints for this skin. */ - skin_parse_hints(skin, cpath); - del_directory(cpath); g_free(cpath);