[gthumb: 18/20] fixed some errors when linunque is not used



commit bab5929bf9d68c19f2e51f4ffd1c2ffdfe4f59f0
Author: Paolo Bacchilega <paobac src gnome org>
Date:   Thu May 12 13:12:09 2011 +0200

    fixed some errors when linunque is not used

 gthumb/main.c |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)
---
diff --git a/gthumb/main.c b/gthumb/main.c
index b25f5ad..a6e6001 100644
--- a/gthumb/main.c
+++ b/gthumb/main.c
@@ -57,7 +57,9 @@ int      ClutterInitResult = CLUTTER_INIT_ERROR_UNKNOWN;
 #endif
 
 
+#ifdef HAVE_UNIQUE
 static UniqueApp   *gthumb_app;
+#endif
 static char       **remaining_args;
 static const char  *program_argv0; /* argv[0] from main(); used as the command to restart the program */
 static gboolean     restart = FALSE;
@@ -261,6 +263,9 @@ gth_restore_session (EggSMClient *client)
 }
 
 
+#ifdef HAVE_UNIQUE
+
+
 static void
 show_window (GtkWindow  *window,
 	     const char *startup_id,
@@ -272,8 +277,6 @@ show_window (GtkWindow  *window,
 }
 
 
-#ifdef HAVE_UNIQUE
-
 static UniqueResponse
 unique_app_message_received_cb (UniqueApp         *unique_app,
 				UniqueCommand      command,
@@ -557,11 +560,11 @@ main (int argc, char *argv[])
 #ifdef HAVE_UNIQUE
 	if (! unique_app_is_running (gthumb_app))
 		gtk_main ();
+	g_object_unref (gthumb_app);
 #else
 	gtk_main ();
 #endif
 
-	g_object_unref (gthumb_app);
 	gth_main_release ();
 	gth_pref_release ();
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]