diff options
author | Tristan Van Berkom <tristan@upstairslabs.com> | 2014-10-23 17:19:34 +0900 |
---|---|---|
committer | Tristan Van Berkom <tristan@upstairslabs.com> | 2014-10-23 17:19:34 +0900 |
commit | e4775b6f7a00b18bd930ac9a99e29b3d9079b857 (patch) | |
tree | d838e08628ae520683c6c46e7181c378f0ae0d83 | |
parent | a7c536dc3db2560a0767a25d9904f68e3b8a47f4 (diff) | |
download | glade-csd.tar.gz |
Depend on GTK+ 3.15csd
Avoid GTK_CHECK_VERSION ifdefs working around the absense of
gtk_window_get_titlebar().
-rw-r--r-- | configure.ac | 2 | ||||
-rw-r--r-- | plugins/gtk+/glade-gtk-window.c | 17 | ||||
-rw-r--r-- | plugins/gtk+/glade-window-editor.c | 18 |
3 files changed, 1 insertions, 36 deletions
diff --git a/configure.ac b/configure.ac index 9792a54d..514a9369 100644 --- a/configure.ac +++ b/configure.ac @@ -145,7 +145,7 @@ GOBJECT_INTROSPECTION_CHECK([1.32.0]) dnl ================================================================ dnl Check for gtk+ dnl ================================================================ -GTK_REQUIRED=3.12.0 +GTK_REQUIRED=3.15.0 PKG_CHECK_MODULES([GTK],[ gtk+-3.0 >= $GTK_REQUIRED gmodule-2.0 diff --git a/plugins/gtk+/glade-gtk-window.c b/plugins/gtk+/glade-gtk-window.c index 2d7fde4d..7f221f39 100644 --- a/plugins/gtk+/glade-gtk-window.c +++ b/plugins/gtk+/glade-gtk-window.c @@ -38,23 +38,6 @@ #define CSD_DISABLED_MESSAGE _("This property does not apply to client-side decorated windows") -#if !GTK_CHECK_VERSION (3,15,0) -static void check_titlebar (GtkWidget *widget, gpointer data) -{ - GtkWidget **titlebar = data; - if (gtk_style_context_has_class (gtk_widget_get_style_context (widget), "titlebar")) - *titlebar = widget; -} - -static GtkWidget * -gtk_window_get_titlebar (GtkWindow *window) -{ - GtkWidget *titlebar = NULL; - gtk_container_forall (GTK_CONTAINER (window), check_titlebar, &titlebar); - return titlebar; -} -#endif - static void glade_gtk_window_parse_finished (GladeProject * project, GObject * object) { diff --git a/plugins/gtk+/glade-window-editor.c b/plugins/gtk+/glade-window-editor.c index fe4d8159..0ea7c79d 100644 --- a/plugins/gtk+/glade-window-editor.c +++ b/plugins/gtk+/glade-window-editor.c @@ -194,24 +194,6 @@ icon_file_toggled (GtkWidget *widget, glade_editable_load (GLADE_EDITABLE (window_editor), gwidget); } -#if !GTK_CHECK_VERSION (3,15,0) -/* Hack to find the titlebar */ -static void check_titlebar (GtkWidget *widget, gpointer data) -{ - GtkWidget **titlebar = data; - if (gtk_style_context_has_class (gtk_widget_get_style_context (widget), "titlebar")) - *titlebar = widget; -} - -static GtkWidget * -gtk_window_get_titlebar (GtkWindow *window) -{ - GtkWidget *titlebar = NULL; - gtk_container_forall (GTK_CONTAINER (window), check_titlebar, &titlebar); - return titlebar; -} -#endif - static void use_csd_toggled (GtkWidget *widget, GladeWindowEditor *window_editor) |