aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libindicator/Makefile.am6
-rw-r--r--tools/indicator-loader.c5
2 files changed, 10 insertions, 1 deletions
diff --git a/libindicator/Makefile.am b/libindicator/Makefile.am
index de87e3b..edb4fac 100644
--- a/libindicator/Makefile.am
+++ b/libindicator/Makefile.am
@@ -51,9 +51,13 @@ libindicator_la_SOURCES = \
indicator-object-marshal.h \
indicator-object-marshal.c \
indicator-service.c \
- indicator-service-manager.c \
+ indicator-service-manager.c
+
+if USE_GTK3
+libindicator_la_SOURCES += \
indicator-ng.c \
indicator-ng.h
+endif
libindicator_la_CFLAGS = \
$(LIBINDICATOR_CFLAGS) \
diff --git a/tools/indicator-loader.c b/tools/indicator-loader.c
index 51d2e46..d275c43 100644
--- a/tools/indicator-loader.c
+++ b/tools/indicator-loader.c
@@ -24,7 +24,10 @@ License along with this library. If not, see
#include <gtk/gtk.h>
#include <libindicator/indicator-object.h>
+
+#if GTK_MAJOR_VERSION == 3
#include <libindicator/indicator-ng.h>
+#endif
static GHashTable * entry_to_menuitem = NULL;
@@ -137,6 +140,7 @@ load_module (const gchar * name, GtkWidget * menu)
if (g_str_has_suffix(name, G_MODULE_SUFFIX)) {
io = indicator_object_new_from_file(name);
}
+#if GTK_MAJOR_VERSION == 3
else if (g_str_has_suffix(name, ".indicator")) {
GError *error = NULL;
@@ -147,6 +151,7 @@ load_module (const gchar * name, GtkWidget * menu)
return FALSE;
}
}
+#endif
else
return FALSE;