diff options
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | capplet/Makefile.am | 1 | ||||
-rw-r--r-- | capplet/gkbd-indicator-plugins-capplet.c | 31 | ||||
-rw-r--r-- | configure.in | 20 | ||||
-rw-r--r-- | m4/intltool.m4 | 56 | ||||
-rw-r--r-- | test/gkbd-keyboard-drawing-test.c | 2 |
6 files changed, 44 insertions, 73 deletions
@@ -1,3 +1,10 @@ +2008-08-14 svu + + * test/gkbd-keyboard-drawing-test.c, m4/intltool.m4, configure.in, + capplet/gkbd-indicator-plugins-capplet.c, capplet/Makefile.am: dropped + dependency on libgnomeui, + http://bugzilla.gnome.org/show_bug.cgi?id=534140 + 2008-06-11 svu * libgnomekbd/gkbd-keyboard-drawing.c: using connect_after for the diff --git a/capplet/Makefile.am b/capplet/Makefile.am index 353d10f..d6257f2 100644 --- a/capplet/Makefile.am +++ b/capplet/Makefile.am @@ -11,6 +11,7 @@ desktop_DATA = $(Desktop_in_files:.desktop.in=.desktop) gkbd_indicator_plugins_capplet_CFLAGS = \ -I$(top_srcdir) -Wall -Werror \ + $(GCONF_CFLAGS) \ $(LIBGLADE_CFLAGS) \ $(LIBGNOME_CFLAGS) \ $(LIBGNOMEUI_CFLAGS) \ diff --git a/capplet/gkbd-indicator-plugins-capplet.c b/capplet/gkbd-indicator-plugins-capplet.c index ac166b2..c5628b0 100644 --- a/capplet/gkbd-indicator-plugins-capplet.c +++ b/capplet/gkbd-indicator-plugins-capplet.c @@ -27,8 +27,6 @@ #include <glib/gi18n.h> #include <gdk/gdkx.h> #include <glade/glade.h> -#include <libgnomeui/gnome-ui-init.h> -#include <libgnomeui/gnome-help.h> static GkbdKeyboardConfig initialSysKbdConfig; static GMainLoop *loop; @@ -242,11 +240,26 @@ CappletResponse (GtkDialog * dialog, gint response) { if (response == GTK_RESPONSE_HELP) { GError *error = NULL; - gnome_help_display_on_screen ("gkbd", - "gkb-indicator-applet-plugins", - gtk_widget_get_screen - (GTK_WIDGET (dialog)), - &error); + GdkAppLaunchContext *ctx = gdk_app_launch_context_new (); + + g_app_info_launch_default_for_uri("ghelp:gkbd?gkb-indicator-applet-plugins", + G_APP_LAUNCH_CONTEXT (ctx), &error); + + if (error) { + GtkWidget *d = NULL; + + d = gtk_message_dialog_new (GTK_WINDOW (dialog), + GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT, + GTK_MESSAGE_ERROR, GTK_BUTTONS_CLOSE, + _("Unable to open help file")); + gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (d), + "%s", error->message); + g_signal_connect (d, "response", G_CALLBACK (gtk_widget_destroy), NULL); + gtk_window_present (GTK_WINDOW (d)); + + g_error_free (error); + } + return; } @@ -336,9 +349,7 @@ main (int argc, char **argv) bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8"); textdomain (GETTEXT_PACKAGE); memset (&gipc, 0, sizeof (gipc)); - gnome_program_init ("gkbd", VERSION, - LIBGNOMEUI_MODULE, argc, argv, - GNOME_PROGRAM_STANDARD_PROPERTIES, NULL); + gtk_init_with_args (&argc, &argv, "gkbd", NULL, NULL, NULL); if (!gconf_init (argc, argv, &gconf_error)) { g_warning (_("Failed to init GConf: %s\n"), gconf_error->message); diff --git a/configure.in b/configure.in index ca9cf56..5584966 100644 --- a/configure.in +++ b/configure.in @@ -14,15 +14,13 @@ AC_CONFIG_MACRO_DIR(m4) dnl *************************************************************************** dnl *** Minimum library versions for libgnomekbd *** dnl *************************************************************************** -GLIB_REQUIRED=2.6 +GLIB_REQUIRED=2.16 DBUS_REQUIRED=0.92 DBUS_GLIB_REQUIRED=0.34 GCONF_REQUIRED=2.14.0 -GDK_REQUIRED=2.10.3 -GTK_REQUIRED=2.10.3 +GDK_REQUIRED=2.13 +GTK_REQUIRED=2.13 LIBGLADE_REQUIRED=2.6.0 -LIBGNOME_REQUIRED=2.16.0 -LIBGNOMEUI_REQUIRED=2.16.0 LIBXKLAVIER_REQUIRED=3.2 AC_SUBST([DBUS_REQUIRED]) @@ -31,8 +29,6 @@ AC_SUBST([GCONF_REQUIRED]) AC_SUBST([LIBGLADE_REQUIRED]) AC_SUBST([GDK_REQUIRED]) AC_SUBST([GTK_REQUIRED]) -AC_SUBST([LIBGNOME_REQUIRED]) -AC_SUBST([LIBGNOMEUI_REQUIRED]) AC_SUBST([LIBXKLAVIER_REQUIRED]) dnl *************************************************************************** @@ -102,16 +98,6 @@ PKG_CHECK_MODULES(LIBGLADE, libglade-2.0 >= $LIBGLADE_REQUIRED) AC_SUBST(LIBGLADE_CFLAGS) AC_SUBST(LIBGLADE_LIBS) -PKG_CHECK_MODULES(LIBGNOME, libgnome-2.0 >= $LIBGNOME_REQUIRED) - -AC_SUBST(LIBGNOME_CFLAGS) -AC_SUBST(LIBGNOME_LIBS) - -PKG_CHECK_MODULES(LIBGNOMEUI, libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED) - -AC_SUBST(LIBGNOMEUI_CFLAGS) -AC_SUBST(LIBGNOMEUI_LIBS) - AC_PATH_PROG(GCONFTOOL, gconftool-2, no) if test x"$GCONFTOOL" = xno; then diff --git a/m4/intltool.m4 b/m4/intltool.m4 index f27ec0f..de0b191 100644 --- a/m4/intltool.m4 +++ b/m4/intltool.m4 @@ -23,7 +23,7 @@ ## the same distribution terms that you use for the rest of that program. dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml]) -# serial 36 IT_PROG_INTLTOOL +# serial 40 IT_PROG_INTLTOOL AC_DEFUN([IT_PROG_INTLTOOL], [AC_PREREQ([2.50])dnl @@ -39,14 +39,21 @@ if test -n "$1"; then AC_MSG_CHECKING([for intltool >= $1]) INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'` - INTLTOOL_APPLIED_VERSION=`awk -F\" '/\\$VERSION / { print $ 2; }' ${ac_aux_dir}/intltool-update.in` - [INTLTOOL_APPLIED_VERSION_AS_INT=`awk -F\" '/\\$VERSION / { split($ 2, VERSION, "."); print VERSION[1] * 1000 + VERSION[2] * 100 + VERSION[3];}' ${ac_aux_dir}/intltool-update.in` + INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3` + [INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'` ] AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found]) test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" || AC_MSG_ERROR([Your intltool is too old. You need intltool $1 or later.]) fi +AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update]) +AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge]) +AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract]) +if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then + AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.]) +fi + INTLTOOL_DESKTOP_RULE='%.desktop: %.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' INTLTOOL_KEYS_RULE='%.keys: %.keys.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' @@ -101,12 +108,7 @@ if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then AC_MSG_ERROR([GNU gettext tools not found; required for intltool]) fi -# Use the tools built into the package, not the ones that are installed. -AC_SUBST(INTLTOOL_EXTRACT, '$(top_builddir)/intltool-extract') -AC_SUBST(INTLTOOL_MERGE, '$(top_builddir)/intltool-merge') -AC_SUBST(INTLTOOL_UPDATE, '$(top_builddir)/intltool-update') - -AC_PATH_PROG(INTLTOOL_PERL, perl) +AC_PATH_PROG(INTLTOOL_PERL, [perl]) if test -z "$INTLTOOL_PERL"; then AC_MSG_ERROR([perl not found; required for intltool]) fi @@ -152,42 +154,6 @@ AC_SUBST(DATADIRNAME) IT_PO_SUBDIR([po]) -dnl The following is very similar to -dnl -dnl AC_CONFIG_FILES([intltool-extract intltool-merge intltool-update]) -dnl -dnl with the following slight differences: -dnl - the *.in files are in ac_aux_dir, -dnl - if the file haven't changed upon reconfigure, it's not touched, -dnl - the evaluation of the third parameter enables a hack which computes -dnl the actual value of $libdir, -dnl - the user sees "executing intltool commands", instead of -dnl "creating intltool-extract" and such. -dnl -dnl Nothing crucial here, and we could use AC_CONFIG_FILES, if there were -dnl a reason for it. - -AC_CONFIG_COMMANDS([intltool], [ - -for file in intltool-extract intltool-merge intltool-update; do - sed -e "s|@INTLTOOL_EXTRACT@|`pwd`/intltool-extract|g" \ - -e "s|@INTLTOOL_LIBDIR@|${INTLTOOL_LIBDIR}|g" \ - -e "s|@INTLTOOL_PERL@|${INTLTOOL_PERL}|g" \ - < ${ac_aux_dir}/${file}.in > ${file}.out - if cmp -s ${file} ${file}.out 2>/dev/null; then - rm -f ${file}.out - else - mv -f ${file}.out ${file} - fi - chmod ugo+x ${file} - chmod u+w ${file} -done - -], -[INTLTOOL_PERL='${INTLTOOL_PERL}' ac_aux_dir='${ac_aux_dir}' -prefix="$prefix" exec_prefix="$exec_prefix" INTLTOOL_LIBDIR="$libdir" -INTLTOOL_EXTRACT='${INTLTOOL_EXTRACT}']) - ]) diff --git a/test/gkbd-keyboard-drawing-test.c b/test/gkbd-keyboard-drawing-test.c index f855ca3..47b6efa 100644 --- a/test/gkbd-keyboard-drawing-test.c +++ b/test/gkbd-keyboard-drawing-test.c @@ -163,7 +163,7 @@ main (gint argc, gchar ** argv) gint monitor; GdkRectangle rect; GOptionContext *context; - gint rc; + GkbdKeyboardDrawingGroupLevel groupLevels[4] = { {0, 0}, {1, 0}, {0, 1}, {1, 1} }; GkbdKeyboardDrawingGroupLevel *pgroupLevels[4] = |