From dba401f22f4aa533d74bb5429e807fbc3c42ec00 Mon Sep 17 00:00:00 2001 From: infirit Date: Sun, 23 Nov 2014 11:23:52 +0100 Subject: Gtk3: Silence GtkBox deprecation warnings --- mate-panel/nothing.cP | 3 ++- mate-panel/panel-addto.c | 5 +++++ mate-panel/panel-ditem-editor.c | 4 ++++ mate-panel/panel-force-quit.c | 4 ++++ 4 files changed, 15 insertions(+), 1 deletion(-) (limited to 'mate-panel') diff --git a/mate-panel/nothing.cP b/mate-panel/nothing.cP index cfb935c5..13d45cc3 100644 --- a/mate-panel/nothing.cP +++ b/mate-panel/nothing.cP @@ -8,6 +8,7 @@ #include #if GTK_CHECK_VERSION (3, 0, 0) #include +#define gtk_vbox_new(X, Y) gtk_box_new(GTK_ORIENTATION_VERTICAL, Y) #endif #include @@ -1571,4 +1572,4 @@ panel_dialog_window_event (GtkWidget *window, return FALSE; } -#endif \ No newline at end of file +#endif diff --git a/mate-panel/panel-addto.c b/mate-panel/panel-addto.c index 377ec852..401fd9ed 100644 --- a/mate-panel/panel-addto.c +++ b/mate-panel/panel-addto.c @@ -52,6 +52,11 @@ #include "panel-schemas.h" #include "panel-stock-icons.h" +#if GTK_CHECK_VERSION (3, 0, 0) +#define gtk_vbox_new(X, Y) gtk_box_new(GTK_ORIENTATION_VERTICAL, Y) +#define gtk_hbox_new(X, Y) gtk_box_new(GTK_ORIENTATION_HORIZONTAL, Y) +#endif + typedef struct { PanelWidget *panel_widget; diff --git a/mate-panel/panel-ditem-editor.c b/mate-panel/panel-ditem-editor.c index 7a4a9e64..9521df17 100644 --- a/mate-panel/panel-ditem-editor.c +++ b/mate-panel/panel-ditem-editor.c @@ -40,6 +40,10 @@ #include "panel-util.h" #include "panel-marshal.h" +#if GTK_CHECK_VERSION (3, 0, 0) +#define gtk_hbox_new(X, Y) gtk_box_new(GTK_ORIENTATION_HORIZONTAL, Y) +#endif + struct _PanelDItemEditorPrivate { /* we keep a ditem around, since we can never have absolutely diff --git a/mate-panel/panel-force-quit.c b/mate-panel/panel-force-quit.c index 9b3afaa0..8231b8f1 100644 --- a/mate-panel/panel-force-quit.c +++ b/mate-panel/panel-force-quit.c @@ -35,6 +35,10 @@ #include "panel-icon-names.h" #include "panel-stock-icons.h" +#if GTK_CHECK_VERSION (3, 0, 0) +#define gtk_vbox_new(X, Y) gtk_box_new(GTK_ORIENTATION_VERTICAL, Y) +#endif + static GdkFilterReturn popup_filter (GdkXEvent *gdk_xevent, GdkEvent *event, GtkWidget *popup); -- cgit v1.2.1