aboutsummaryrefslogtreecommitdiff
path: root/libtopmenu-server
diff options
context:
space:
mode:
authorJavier <dev.git@javispedro.com>2014-05-17 19:53:53 +0200
committerJavier <dev.git@javispedro.com>2014-05-17 19:53:53 +0200
commit14d288511323d4f384d4764ab25a42693ff19f4a (patch)
treed69907ed23d9df328459b598c0c8f914782013cd /libtopmenu-server
parentfae72947043ae3b1627dac77b3c42bf2e1dbbd09 (diff)
downloadtopmenu-gtk-14d288511323d4f384d4764ab25a42693ff19f4a.tar.gz
topmenu-gtk-14d288511323d4f384d4764ab25a42693ff19f4a.zip
gtk3 client library + module now hackishly working
Diffstat (limited to 'libtopmenu-server')
-rw-r--r--libtopmenu-server/Makefile.am19
-rw-r--r--libtopmenu-server/topmenu-widget.c2
-rw-r--r--libtopmenu-server/topmenu-widget.h2
3 files changed, 17 insertions, 6 deletions
diff --git a/libtopmenu-server/Makefile.am b/libtopmenu-server/Makefile.am
index 8a17f5f..98de595 100644
--- a/libtopmenu-server/Makefile.am
+++ b/libtopmenu-server/Makefile.am
@@ -1,7 +1,18 @@
-lib_LTLIBRARIES = libtopmenu-server.la
-libtopmenu_server_la_SOURCES = topmenu-server.c topmenu-server.h topmenu-widget.c topmenu-widget.h
-libtopmenu_server_la_CPPFLAGS = $(GTK_CFLAGS) $(WNCK_CFLAGS) $(MATEWNCK_CFLAGS) -DG_LOG_DOMAIN=\"topmenu-server\"
-libtopmenu_server_la_LIBADD = $(GTK_LIBS) $(WNCK_LIBS) $(MATEWNCK_LIBS)
+if GTK3
+
+lib_LTLIBRARIES = libtopmenu-server-gtk3.la
+libtopmenu_server_gtk3_la_SOURCES = topmenu-server.c topmenu-server.h topmenu-widget.c topmenu-widget.h
+libtopmenu_server_gtk3_la_CPPFLAGS = $(GTK_CFLAGS) $(WNCK_CFLAGS) $(MATEWNCK_CFLAGS) -DG_LOG_DOMAIN=\"topmenu-server\"
+libtopmenu_server_gtk3_la_LIBADD = $(GTK_LIBS) $(WNCK_LIBS) $(MATEWNCK_LIBS)
+
+else
+
+lib_LTLIBRARIES = libtopmenu-server-gtk2.la
+libtopmenu_server_gtk2_la_SOURCES = topmenu-server.c topmenu-server.h topmenu-widget.c topmenu-widget.h
+libtopmenu_server_gtk2_la_CPPFLAGS = $(GTK_CFLAGS) $(WNCK_CFLAGS) $(MATEWNCK_CFLAGS) -DG_LOG_DOMAIN=\"topmenu-server\"
+libtopmenu_server_gtk2_la_LIBADD = $(GTK_LIBS) $(WNCK_LIBS) $(MATEWNCK_LIBS)
+
+endif
include_HEADERS = topmenu-server.h topmenu-widget.h
diff --git a/libtopmenu-server/topmenu-widget.c b/libtopmenu-server/topmenu-widget.c
index 8121fc5..e4c51de 100644
--- a/libtopmenu-server/topmenu-widget.c
+++ b/libtopmenu-server/topmenu-widget.c
@@ -123,7 +123,7 @@ static void topmenu_widget_embed_topmenu_window(TopMenuWidget *self, Window wind
GdkWindow *cur = gtk_socket_get_plug_window(self->socket);
if (cur) {
- if (gdk_x11_window_get_xid(cur) == window) {
+ if (GDK_WINDOW_XID(cur) == window) {
// Trying to embed the same client again
return; // Nothing to do
}
diff --git a/libtopmenu-server/topmenu-widget.h b/libtopmenu-server/topmenu-widget.h
index 19d9784..1634bcc 100644
--- a/libtopmenu-server/topmenu-widget.h
+++ b/libtopmenu-server/topmenu-widget.h
@@ -3,7 +3,7 @@
#include <gtk/gtk.h>
-#if GTK_VERSION == 3
+#if GTK_MAJOR_VERSION == 3
#include <gtk/gtkx.h>
#endif