]> err.no Git - mapper/commitdiff
Initialize gdk threads and wrap gtk_main in enter/leave
authorKaj-Michael Lang <milang@tal.org>
Tue, 5 Aug 2008 12:06:53 +0000 (15:06 +0300)
committerKaj-Michael Lang <milang@tal.org>
Tue, 5 Aug 2008 12:06:53 +0000 (15:06 +0300)
src/mapper.c

index 75116096ba33c0453e7f2847036484a06c3e6c7c..4cbf3b637a33f6fcd6d04b9fdc938ba2de2f4377 100644 (file)
@@ -472,6 +472,7 @@ textdomain(GETTEXT_PACKAGE);
 
 g_thread_init(NULL);
 g_type_init();
+gdk_threads_init();
 g_set_application_name("Mapper");
 #if defined (WITH_GST)
 gst_init(&argc, &argv);
@@ -492,7 +493,9 @@ init_progress=gtk_progress_bar_new();
 init_dialog=progress_dialog(NULL, "Mapper is loading...",init_progress);
 gtk_widget_show_all(init_dialog);
 g_idle_add((GSourceFunc)mapper_init, NULL);
+gdk_threads_enter();
 gtk_main();
+gdk_threads_leave();
 mapper_destroy();
 
 return 0;