diff options
Diffstat (limited to 'capplets')
-rw-r--r-- | capplets/keybindings/eggcellrendererkeys.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/capplets/keybindings/eggcellrendererkeys.c b/capplets/keybindings/eggcellrendererkeys.c index 1805d583..b521cf0a 100644 --- a/capplets/keybindings/eggcellrendererkeys.c +++ b/capplets/keybindings/eggcellrendererkeys.c @@ -6,6 +6,10 @@ #include "eggcellrendererkeys.h" #include "eggaccelerators.h" +#if !GTK_CHECK_VERSION(3,0,0) +#define gtk_widget_get_preferred_size(x,y,z) gtk_widget_size_request(x,y) +#endif + #ifndef EGG_COMPILATION #ifndef _ #define _(x) dgettext (GETTEXT_PACKAGE, x) @@ -354,7 +358,7 @@ egg_cell_renderer_keys_get_size (GtkCellRenderer *cell, if (keys->sizing_label == NULL) keys->sizing_label = gtk_label_new (TOOLTIP_TEXT); - gtk_widget_size_request (keys->sizing_label, &requisition); + gtk_widget_get_preferred_size (keys->sizing_label, &requisition, NULL); (* GTK_CELL_RENDERER_CLASS (parent_class)->get_size) (cell, widget, cell_area, x_offset, y_offset, width, height); /* FIXME: need to take the cell_area et al. into account */ if (width) |