diff options
-rw-r--r-- | src/tree.c | 9 | ||||
-rw-r--r-- | src/util.c | 4 |
2 files changed, 13 insertions, 0 deletions
@@ -30,6 +30,15 @@ #include "zenity.h" #include "util.h" +#if GTK_MAJOR_VERSION == 2 +static void +gtk_widget_get_preferred_size (GtkWidget *widget, GtkRequisition *minimum_size, GtkRequisition *natural_size) +{ + gtk_widget_size_request(widget, natural_size); + gtk_widget_get_size_request(widget, &(minimum_size->width), &(minimum_size->height)); +} +#endif + #define MAX_ELEMENTS_BEFORE_SCROLLING 5 #define PRINT_HIDE_COLUMN_SEPARATOR "," @@ -45,6 +45,10 @@ #define ZENITY_ERROR_DEFAULT -1 #define ZENITY_EXTRA_DEFAULT 127 +#if defined(GDK_WINDOWING_X11) && !defined(GDK_IS_X11_DISPLAY) +#define GDK_IS_X11_DISPLAY(display) 1 +#endif + GtkBuilder* zenity_util_load_ui_file (const gchar *root_widget, ...) { |