Commit ac5571fd authored by Manish Singh's avatar Manish Singh

colormaps should be inited before we do gtk stuff

-Yosh
parent 15697fb3
......@@ -311,58 +311,62 @@ my_idle_proc(void)
static void
make_initialization_status_window(void)
{
if (no_interface == FALSE && no_splash == FALSE)
if (no_interface == FALSE)
{
GtkWidget *vbox;
get_standard_colormaps ();
if (no_splash == FALSE)
{
GtkWidget *vbox;
win_initstatus = gtk_window_new(GTK_WINDOW_DIALOG);
gtk_window_set_wmclass (GTK_WINDOW(win_initstatus), "gimp_startup", "Gimp");
gtk_window_set_title(GTK_WINDOW(win_initstatus),
"GIMP Startup");
win_initstatus = gtk_window_new(GTK_WINDOW_DIALOG);
gtk_window_set_wmclass (GTK_WINDOW(win_initstatus), "gimp_startup", "Gimp");
gtk_window_set_title(GTK_WINDOW(win_initstatus),
"GIMP Startup");
if (no_splash_image == FALSE && splash_logo_load_size (win_initstatus))
{
show_logo = SHOW_LATER;
}
if (no_splash_image == FALSE && splash_logo_load_size (win_initstatus))
{
show_logo = SHOW_LATER;
}
vbox = gtk_vbox_new(FALSE, 4);
gtk_container_add(GTK_CONTAINER(win_initstatus), vbox);
vbox = gtk_vbox_new(FALSE, 4);
gtk_container_add(GTK_CONTAINER(win_initstatus), vbox);
gtk_widget_push_visual (gtk_preview_get_visual ());
gtk_widget_push_colormap (gtk_preview_get_cmap ());
gtk_widget_push_visual (gtk_preview_get_visual ());
gtk_widget_push_colormap (gtk_preview_get_cmap ());
logo_area = gtk_drawing_area_new ();
logo_area = gtk_drawing_area_new ();
gtk_widget_pop_colormap ();
gtk_widget_pop_visual ();
gtk_widget_pop_colormap ();
gtk_widget_pop_visual ();
gtk_signal_connect (GTK_OBJECT (logo_area), "expose_event",
(GtkSignalFunc) splash_logo_expose, NULL);
logo_area_width = ( logo_width > LOGO_WIDTH_MIN ) ? logo_width : LOGO_WIDTH_MIN;
logo_area_height = ( logo_height > LOGO_HEIGHT_MIN ) ? logo_height : LOGO_HEIGHT_MIN;
gtk_drawing_area_size (GTK_DRAWING_AREA (logo_area), logo_area_width, logo_area_height);
gtk_box_pack_start_defaults(GTK_BOX(vbox), logo_area);
gtk_signal_connect (GTK_OBJECT (logo_area), "expose_event",
(GtkSignalFunc) splash_logo_expose, NULL);
logo_area_width = ( logo_width > LOGO_WIDTH_MIN ) ? logo_width : LOGO_WIDTH_MIN;
logo_area_height = ( logo_height > LOGO_HEIGHT_MIN ) ? logo_height : LOGO_HEIGHT_MIN;
gtk_drawing_area_size (GTK_DRAWING_AREA (logo_area), logo_area_width, logo_area_height);
gtk_box_pack_start_defaults(GTK_BOX(vbox), logo_area);
label1 = gtk_label_new("");
gtk_box_pack_start_defaults(GTK_BOX(vbox), label1);
label2 = gtk_label_new("");
gtk_box_pack_start_defaults(GTK_BOX(vbox), label2);
label1 = gtk_label_new("");
gtk_box_pack_start_defaults(GTK_BOX(vbox), label1);
label2 = gtk_label_new("");
gtk_box_pack_start_defaults(GTK_BOX(vbox), label2);
pbar = gtk_progress_bar_new();
gtk_box_pack_start_defaults(GTK_BOX(vbox), pbar);
pbar = gtk_progress_bar_new();
gtk_box_pack_start_defaults(GTK_BOX(vbox), pbar);
gtk_widget_show(vbox);
gtk_widget_show (logo_area);
gtk_widget_show(label1);
gtk_widget_show(label2);
gtk_widget_show(pbar);
gtk_widget_show(vbox);
gtk_widget_show (logo_area);
gtk_widget_show(label1);
gtk_widget_show(label2);
gtk_widget_show(pbar);
gtk_window_position(GTK_WINDOW(win_initstatus),
GTK_WIN_POS_CENTER);
gtk_window_position(GTK_WINDOW(win_initstatus),
GTK_WIN_POS_CENTER);
gtk_widget_show(win_initstatus);
gtk_widget_show(win_initstatus);
gtk_window_set_policy (GTK_WINDOW (win_initstatus), FALSE, TRUE, FALSE);
gtk_window_set_policy (GTK_WINDOW (win_initstatus), FALSE, TRUE, FALSE);
}
}
}
......@@ -440,7 +444,6 @@ app_init ()
/* Now we are ready to draw the splash-screen-image to the start-up window */
if (no_interface == FALSE)
{
get_standard_colormaps ();
if (no_splash_image == FALSE && show_logo && splash_logo_load (win_initstatus)) {
show_logo = SHOW_NOW;
splash_logo_draw (logo_area);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment