[dasher] Use gdkkeysyms-compat.h if present.



commit 61754833c262cf3528c83afd5ac101496c83dfd8
Author: Patrick Welche <prlw1 cam ac uk>
Date:   Thu Mar 31 19:15:39 2011 +0200

    Use gdkkeysyms-compat.h if present.
    
    Since 8 Sep 2010 gdk key names are prefixed with KEY_ e.g., GDK_a becomes
    GDK_KEY_a. We still care about gtk more than 7 months old.

 Src/Gtk2/KeyboardHelper.cpp |    3 +++
 configure.ac                |    2 ++
 2 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/Src/Gtk2/KeyboardHelper.cpp b/Src/Gtk2/KeyboardHelper.cpp
index 53ccb1d..9b46ad1 100644
--- a/Src/Gtk2/KeyboardHelper.cpp
+++ b/Src/Gtk2/KeyboardHelper.cpp
@@ -3,6 +3,9 @@
 #include <X11/Xlib.h>
 #include <gdk/gdk.h>
 #include <gdk/gdkkeysyms.h>
+#ifdef HAVE_GDK_GDKKEYSYMS_COMPAT_H
+#include <gdk/gdkkeysyms-compat.h>
+#endif
 #include <gdk/gdkx.h>
 #include <cstring>
 #include <iostream>
diff --git a/configure.ac b/configure.ac
index 48361a7..19c9181 100644
--- a/configure.ac
+++ b/configure.ac
@@ -216,7 +216,9 @@ then
 	save_CFLAGS="$CFLAGS"
 	save_LIBS="$LIBS"
 	CFLAGS="$CFLAGS $GTK2_CFLAGS"
+	CPPFLAGS="$CPPFLAGS $GTK2_CFLAGS"
 	LIBS="$LIBS $GTK2_LIBS"
+	AC_CHECK_HEADERS([gdk/gdkkeysyms-compat.h])
 	AC_CHECK_FUNCS([gtk_builder_new gtk_show_uri gdk_window_get_width], [],
 		[if test "x$ac_cv_func_gtk_builder_new" = "xno"; then
 			AC_MSG_ERROR([A version of GTK+ providing GtkBuilder is necessary.])



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