From dce84e781fc99d25ce99aa63b18a139f097743bb Mon Sep 17 00:00:00 2001 From: raveit65 Date: Fri, 17 Jun 2016 20:01:52 +0200 Subject: GTK+-3 app-resizer: don't use deprecated gtk_widget_size_request --- libslab/app-resizer.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'libslab') diff --git a/libslab/app-resizer.c b/libslab/app-resizer.c index da304ecc..d8e9277a 100644 --- a/libslab/app-resizer.c +++ b/libslab/app-resizer.c @@ -24,6 +24,10 @@ #include "app-shell.h" #include "app-resizer.h" +#if !GTK_CHECK_VERSION(3,0,0) +#define gtk_widget_get_preferred_size(x,y,z) gtk_widget_size_request(x,y) +#endif + static void app_resizer_class_init (AppResizerClass *); static void app_resizer_init (AppResizer *); static void app_resizer_size_allocate (GtkWidget * resizer, GtkAllocation * allocation); @@ -262,7 +266,7 @@ app_resizer_size_allocate (GtkWidget * widget, GtkAllocation * allocation) GtkRequisition req; /* Have to do this so that it requests, and thus gets allocated, new amount */ - gtk_widget_size_request (child, &req); + gtk_widget_get_preferred_size (child, &req, NULL); resizer->cur_num_cols = new_num_cols; } -- cgit v1.2.1