[gtranslator] Accept the --introspect-dump arg



commit b2163818830d4e2a6813ba3effadc155df0d0c7c
Author: Tomeu Vizoso <tomeu vizoso collabora co uk>
Date:   Thu Nov 4 18:12:40 2010 +0100

    Accept the --introspect-dump arg

 src/Makefile.am       |    2 +-
 src/gtr-application.c |    8 ++++++++
 2 files changed, 9 insertions(+), 1 deletions(-)
---
diff --git a/src/Makefile.am b/src/Makefile.am
index 6d97308..453ba68 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -168,7 +168,7 @@ Gtranslator-2.0.gir: gtranslator
 INTROSPECTION_SCANNER_ARGS = -I$(top_srcdir) --warn-all
 Gtranslator_2_0_gir_NAMESPACE = Gtr
 Gtranslator_2_0_gir_VERSION = 2.0
-Gtranslator_2_0_gir_PROGRAM = $(builddir)/src
+Gtranslator_2_0_gir_PROGRAM = $(builddir)/gtranslator
 Gtranslator_2_0_gir_FILES = $(INST_H_FILES) $(libgtranslator_c_files)
 Gtranslator_2_0_gir_INCLUDES = Gtk-3.0 GtkSource-3.0
 
diff --git a/src/gtr-application.c b/src/gtr-application.c
index 2d49052..2df5222 100644
--- a/src/gtr-application.c
+++ b/src/gtr-application.c
@@ -42,6 +42,10 @@
 #include <glib/gi18n.h>
 #include <gtk/gtk.h>
 
+#ifdef ENABLE_INTROSPECTION
+#include <girepository.h>
+#endif
+
 #ifdef GDK_WINDOWING_X11
 #include <gdk/gdkx.h>
 #endif
@@ -364,6 +368,10 @@ gtr_application_command_line (GApplication            *application,
   g_option_context_add_main_entries (context, options, GETTEXT_PACKAGE);
   g_option_context_add_group (context, gtk_get_option_group (TRUE));
 
+#ifdef ENABLE_INTROSPECTION
+  g_option_context_add_group (context, g_irepository_get_option_group ());
+#endif
+
   if (!g_option_context_parse (context, &argc, &argv, &error))
     {
        g_print(_("%s\nRun '%s --help' to see a full list of available command line options.\n"),



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