summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar waker <wakeroid@gmail.com>2012-08-08 18:34:25 +0200
committerGravatar waker <wakeroid@gmail.com>2012-08-08 18:34:25 +0200
commite4ebb9a8569ce5ca5f8aed9a9292eaff56557c40 (patch)
treed704fe3ed012751c080ae4ac83af09ae9fbd111b
parentfa3d7b5639963005869673a540594360133a70d9 (diff)
get rid of ULTRA_PORTABLE define, gtk stuff now works without it
-rw-r--r--plugins/converter/support.c2
-rw-r--r--plugins/converter/support.h6
-rw-r--r--plugins/gtkui/Makefile.am4
-rw-r--r--plugins/gtkui/ddblistview.c4
-rw-r--r--plugins/gtkui/ddbtabstrip.c2
-rw-r--r--plugins/gtkui/gtkui.c8
-rw-r--r--plugins/gtkui/gtkui.h4
-rw-r--r--plugins/gtkui/support.c2
-rw-r--r--plugins/gtkui/support.h6
-rw-r--r--plugins/shellexecui/support.c2
-rw-r--r--plugins/shellexecui/support.h6
11 files changed, 21 insertions, 25 deletions
diff --git a/plugins/converter/support.c b/plugins/converter/support.c
index 1eef6efc..b3816098 100644
--- a/plugins/converter/support.c
+++ b/plugins/converter/support.c
@@ -197,7 +197,7 @@ gtk_combo_box_text_get_active_text (GtkComboBoxText *combo_box) {
#endif
-#if !GTK_CHECK_VERSION(2,18,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,18,0)
void
gtk_widget_set_allocation (GtkWidget *widget, const GtkAllocation *allocation) {
widget->allocation.x = (allocation)->x;
diff --git a/plugins/converter/support.h b/plugins/converter/support.h
index 00e31c0f..2161fb55 100644
--- a/plugins/converter/support.h
+++ b/plugins/converter/support.h
@@ -104,7 +104,7 @@ void gtk_combo_box_text_prepend_text (GtkComboBoxText *combo_box, const gchar *t
gchar *gtk_combo_box_text_get_active_text (GtkComboBoxText *combo_box);
#endif
-#if !GTK_CHECK_VERSION(2,14,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,14,0)
#define gtk_widget_get_window(widget) ((widget)->window)
#define gtk_selection_data_get_target(data) (data->target)
#define gtk_dialog_get_content_area(dialog) (dialog->vbox)
@@ -116,7 +116,7 @@ gchar *gtk_combo_box_text_get_active_text (GtkComboBoxText *combo_box);
#define gtk_adjustment_get_upper(adj) (adj->upper)
#endif
-#if !GTK_CHECK_VERSION(2,18,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,18,0)
#define gtk_widget_set_has_window(widget, has_window) \
if (has_window) GTK_WIDGET_UNSET_FLAGS (widget, GTK_NO_WINDOW); \
else GTK_WIDGET_SET_FLAGS (widget, GTK_NO_WINDOW);
@@ -127,7 +127,7 @@ void gtk_widget_set_window(GtkWidget *widget, GdkWindow *window);
#endif
-#if !GTK_CHECK_VERSION(2,18,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,18,0)
void gtk_widget_set_allocation (GtkWidget *widget,
const GtkAllocation *allocation);
diff --git a/plugins/gtkui/Makefile.am b/plugins/gtkui/Makefile.am
index 2f6461ca..bb3bfca5 100644
--- a/plugins/gtkui/Makefile.am
+++ b/plugins/gtkui/Makefile.am
@@ -74,7 +74,7 @@ GTK_ROOT_216=@top_srcdir@/$(LIB)/gtk-2.16.0
ddb_gui_GTK2_la_LIBADD = $(LDADD) -L$(GTK_ROOT_216)/lib -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lglib-2.0 $(SM_LIBADD)
-ddb_gui_GTK2_la_CFLAGS = -std=c99 -I$(GTK_ROOT_216)/include/gtk-2.0 -I$(GTK_ROOT_216)/lib/gtk-2.0/include -I$(GTK_ROOT_216)/include/atk-1.0 -I$(GTK_ROOT_216)/include/cairo -I$(GTK_ROOT_216)/include/pango-1.0 -I$(GTK_ROOT_216)/include -I$(GTK_ROOT_216)/include/glib-2.0 -I$(GTK_ROOT_216)/lib/glib-2.0/include -DULTRA_COMPATIBLE=1 $(SM_CFLAGS)
+ddb_gui_GTK2_la_CFLAGS = -std=c99 -I$(GTK_ROOT_216)/include/gtk-2.0 -I$(GTK_ROOT_216)/lib/gtk-2.0/include -I$(GTK_ROOT_216)/include/atk-1.0 -I$(GTK_ROOT_216)/include/cairo -I$(GTK_ROOT_216)/include/pango-1.0 -I$(GTK_ROOT_216)/include -I$(GTK_ROOT_216)/include/glib-2.0 -I$(GTK_ROOT_216)/lib/glib-2.0/include $(SM_CFLAGS)
else
ddb_gui_GTK2_la_LIBADD = $(LDADD) $(GTK2_DEPS_LIBS) $(SM_LIBADD)
ddb_gui_GTK2_la_CFLAGS = -std=c99 $(GTK2_DEPS_CFLAGS) $(SM_CFLAGS)
@@ -97,7 +97,7 @@ ddb_gui_GTK2_fallback_la_LDFLAGS = -module
ddb_gui_GTK2_fallback_la_LIBADD = $(LDADD) -L$(GTK_ROOT)/lib $(GTK_ROOT)/lib/libgtk-x11-2.0.la $(GTK_ROOT)/lib/libgdk-x11-2.0.la $(GTK_ROOT)/lib/libpangoft2-1.0.la $(GTK_ROOT)/lib/libpangocairo-1.0.la $(GTK_ROOT)/lib/libgdk_pixbuf-2.0.la -lm $(GTK_ROOT)/lib/libcairo.la $(GTK_ROOT)/lib/libpango-1.0.la $(GTK_ROOT)/lib/libgobject-2.0.la $(GTK_ROOT)/lib/libgmodule-2.0.la $(GTK_ROOT)/lib/libgthread-2.0.la -lrt $(GTK_ROOT)/lib/libglib-2.0.la $(SM_LIBADD)
-ddb_gui_GTK2_fallback_la_CFLAGS = -std=c99 -I $(GTK_ROOT)/include -I $(GTK_ROOT)/lib/gtk-2.0/include -I $(GTK_ROOT)/include/glib-2.0 -I $(GTK_ROOT)/include/gtk-2.0 -I $(GTK_ROOT)/include/cairo -I $(GTK_ROOT)/lib/glib-2.0/include/ -I $(GTK_ROOT)/include/pango-1.0 -I $(GTK_ROOT)/include/atk-1.0 -DULTRA_COMPATIBLE=1 $(SM_CFLAGS)
+ddb_gui_GTK2_fallback_la_CFLAGS = -std=c99 -I $(GTK_ROOT)/include -I $(GTK_ROOT)/lib/gtk-2.0/include -I $(GTK_ROOT)/include/glib-2.0 -I $(GTK_ROOT)/include/gtk-2.0 -I $(GTK_ROOT)/include/cairo -I $(GTK_ROOT)/lib/glib-2.0/include/ -I $(GTK_ROOT)/include/pango-1.0 -I $(GTK_ROOT)/include/atk-1.0 $(SM_CFLAGS)
endif
diff --git a/plugins/gtkui/ddblistview.c b/plugins/gtkui/ddblistview.c
index 8acbbf5f..3045b5e3 100644
--- a/plugins/gtkui/ddblistview.c
+++ b/plugins/gtkui/ddblistview.c
@@ -2390,7 +2390,7 @@ ddb_listview_header_motion_notify_event (GtkWidget *widget,
ev_x = event->x;
ev_y = event->y;
ev_state = event->state;
-#if GTK_CHECK_VERSION(2,12,0) && !defined(ULTRA_COMPATIBLE)
+#if GTK_CHECK_VERSION(2,12,0)
gdk_event_request_motions (event);
#endif
@@ -2752,7 +2752,7 @@ ddb_listview_motion_notify_event (GtkWidget *widget,
{
int x = event->x;
int y = event->y;
-#if GTK_CHECK_VERSION(2,12,0) && !defined(ULTRA_COMPATIBLE)
+#if GTK_CHECK_VERSION(2,12,0)
gdk_event_request_motions (event);
#endif
DdbListview *ps = DDB_LISTVIEW (g_object_get_data (G_OBJECT (widget), "owner"));
diff --git a/plugins/gtkui/ddbtabstrip.c b/plugins/gtkui/ddbtabstrip.c
index b21a0378..9e2c25a0 100644
--- a/plugins/gtkui/ddbtabstrip.c
+++ b/plugins/gtkui/ddbtabstrip.c
@@ -1198,7 +1198,7 @@ on_tabstrip_motion_notify_event (GtkWidget *widget,
ev_x = event->x;
ev_y = event->y;
ev_state = event->state;
-#if GTK_CHECK_VERSION(2,12,0) && !defined(ULTRA_COMPATIBLE)
+#if GTK_CHECK_VERSION(2,12,0)
gdk_event_request_motions (event);
#endif
if ((ev_state & GDK_BUTTON1_MASK) && ts->prepare) {
diff --git a/plugins/gtkui/gtkui.c b/plugins/gtkui/gtkui.c
index 4f7e5cac..d4647e7e 100644
--- a/plugins/gtkui/gtkui.c
+++ b/plugins/gtkui/gtkui.c
@@ -236,7 +236,7 @@ update_songinfo (gpointer ctx) {
void
set_tray_tooltip (const char *text) {
if (trayicon) {
-#if !GTK_CHECK_VERSION(2,16,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,16,0)
gtk_status_icon_set_tooltip (trayicon, text);
#else
gtk_status_icon_set_tooltip_text (trayicon, text);
@@ -307,8 +307,7 @@ mainwin_toggle_visible (void) {
}
}
-#if !GTK_CHECK_VERSION(2,14,0) || defined(ULTRA_COMPATIBLE)
-
+#if !GTK_CHECK_VERSION(2,14,0)
gboolean
on_trayicon_activate (GtkWidget *widget,
gpointer user_data)
@@ -570,9 +569,10 @@ gtkui_update_status_icon (gpointer unused) {
g_object_set (trayicon, "visible", FALSE, NULL);
}
-#if !GTK_CHECK_VERSION(2,14,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,14,0)
g_signal_connect ((gpointer)trayicon, "activate", G_CALLBACK (on_trayicon_activate), NULL);
#else
+ printf ("connecting button tray signals\n");
g_signal_connect ((gpointer)trayicon, "scroll_event", G_CALLBACK (on_trayicon_scroll_event), NULL);
g_signal_connect ((gpointer)trayicon, "button_press_event", G_CALLBACK (on_trayicon_button_press_event), NULL);
#endif
diff --git a/plugins/gtkui/gtkui.h b/plugins/gtkui/gtkui.h
index 13e3e9cb..0f764901 100644
--- a/plugins/gtkui/gtkui.h
+++ b/plugins/gtkui/gtkui.h
@@ -29,10 +29,6 @@
#include "../../config.h"
#endif
-//#if defined(ULTRA_COMPATIBLE)
-//#warning compiling for compatibility with gtk <2.14
-//#endif
-
#include "../../deadbeef.h"
extern DB_functions_t *deadbeef;
diff --git a/plugins/gtkui/support.c b/plugins/gtkui/support.c
index 1eef6efc..b3816098 100644
--- a/plugins/gtkui/support.c
+++ b/plugins/gtkui/support.c
@@ -197,7 +197,7 @@ gtk_combo_box_text_get_active_text (GtkComboBoxText *combo_box) {
#endif
-#if !GTK_CHECK_VERSION(2,18,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,18,0)
void
gtk_widget_set_allocation (GtkWidget *widget, const GtkAllocation *allocation) {
widget->allocation.x = (allocation)->x;
diff --git a/plugins/gtkui/support.h b/plugins/gtkui/support.h
index 00e31c0f..2161fb55 100644
--- a/plugins/gtkui/support.h
+++ b/plugins/gtkui/support.h
@@ -104,7 +104,7 @@ void gtk_combo_box_text_prepend_text (GtkComboBoxText *combo_box, const gchar *t
gchar *gtk_combo_box_text_get_active_text (GtkComboBoxText *combo_box);
#endif
-#if !GTK_CHECK_VERSION(2,14,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,14,0)
#define gtk_widget_get_window(widget) ((widget)->window)
#define gtk_selection_data_get_target(data) (data->target)
#define gtk_dialog_get_content_area(dialog) (dialog->vbox)
@@ -116,7 +116,7 @@ gchar *gtk_combo_box_text_get_active_text (GtkComboBoxText *combo_box);
#define gtk_adjustment_get_upper(adj) (adj->upper)
#endif
-#if !GTK_CHECK_VERSION(2,18,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,18,0)
#define gtk_widget_set_has_window(widget, has_window) \
if (has_window) GTK_WIDGET_UNSET_FLAGS (widget, GTK_NO_WINDOW); \
else GTK_WIDGET_SET_FLAGS (widget, GTK_NO_WINDOW);
@@ -127,7 +127,7 @@ void gtk_widget_set_window(GtkWidget *widget, GdkWindow *window);
#endif
-#if !GTK_CHECK_VERSION(2,18,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,18,0)
void gtk_widget_set_allocation (GtkWidget *widget,
const GtkAllocation *allocation);
diff --git a/plugins/shellexecui/support.c b/plugins/shellexecui/support.c
index 1eef6efc..b3816098 100644
--- a/plugins/shellexecui/support.c
+++ b/plugins/shellexecui/support.c
@@ -197,7 +197,7 @@ gtk_combo_box_text_get_active_text (GtkComboBoxText *combo_box) {
#endif
-#if !GTK_CHECK_VERSION(2,18,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,18,0)
void
gtk_widget_set_allocation (GtkWidget *widget, const GtkAllocation *allocation) {
widget->allocation.x = (allocation)->x;
diff --git a/plugins/shellexecui/support.h b/plugins/shellexecui/support.h
index 064cd5bc..b7800a1d 100644
--- a/plugins/shellexecui/support.h
+++ b/plugins/shellexecui/support.h
@@ -104,7 +104,7 @@ void gtk_combo_box_text_prepend_text (GtkComboBoxText *combo_box, const gchar *t
gchar *gtk_combo_box_text_get_active_text (GtkComboBoxText *combo_box);
#endif
-#if !GTK_CHECK_VERSION(2,14,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,14,0)
#define gtk_widget_get_window(widget) ((widget)->window)
#define gtk_selection_data_get_target(data) (data->target)
#define gtk_dialog_get_content_area(dialog) (dialog->vbox)
@@ -116,7 +116,7 @@ gchar *gtk_combo_box_text_get_active_text (GtkComboBoxText *combo_box);
#define gtk_adjustment_get_upper(adj) (adj->upper)
#endif
-#if !GTK_CHECK_VERSION(2,18,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,18,0)
#define gtk_widget_set_has_window(widget, has_window) \
if (has_window) GTK_WIDGET_UNSET_FLAGS (widget, GTK_NO_WINDOW); \
else GTK_WIDGET_SET_FLAGS (widget, GTK_NO_WINDOW);
@@ -127,7 +127,7 @@ void gtk_widget_set_window(GtkWidget *widget, GdkWindow *window);
#endif
-#if !GTK_CHECK_VERSION(2,18,0) || defined(ULTRA_COMPATIBLE)
+#if !GTK_CHECK_VERSION(2,18,0)
void gtk_widget_set_allocation (GtkWidget *widget,
const GtkAllocation *allocation);