diff options
author | raveit65 <[email protected]> | 2016-05-30 17:16:15 +0200 |
---|---|---|
committer | raveit65 <[email protected]> | 2016-05-30 17:16:15 +0200 |
commit | b446782d0f4a7ce1c91a1092c979c5fe2fdbb9dd (patch) | |
tree | 1ba68b5ea9267737a91daee002bfa269ac0a25e9 /mate-dictionary/src/gdict-applet.c | |
parent | e07af0d9049af36e1670a12deff39ea09616b6cd (diff) | |
download | mate-utils-b446782d0f4a7ce1c91a1092c979c5fe2fdbb9dd.tar.bz2 mate-utils-b446782d0f4a7ce1c91a1092c979c5fe2fdbb9dd.tar.xz |
GTK+3 mdict: do not use deprecated gtk_widget_size_request
Diffstat (limited to 'mate-dictionary/src/gdict-applet.c')
-rw-r--r-- | mate-dictionary/src/gdict-applet.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/mate-dictionary/src/gdict-applet.c b/mate-dictionary/src/gdict-applet.c index 009e1502..424a4c75 100644 --- a/mate-dictionary/src/gdict-applet.c +++ b/mate-dictionary/src/gdict-applet.c @@ -38,6 +38,10 @@ #include "gdict-common.h" #include "gdict-aligned-window.h" +#if !GTK_CHECK_VERSION(3,0,0) +#define gtk_widget_get_preferred_size(x,y,z) gtk_widget_size_request(x,y) +#endif + #define GDICT_APPLET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GDICT_TYPE_APPLET, GdictAppletClass)) #define GDICT_APPLET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GDICT_TYPE_APPLET, GdictAppletClass)) @@ -149,7 +153,7 @@ set_window_default_size (GdictApplet *applet) height = font_size * WINDOW_NUM_ROWS; /* Use at least the requisition size of the window... */ - gtk_widget_size_request (widget, &req); + gtk_widget_get_preferred_size (widget, NULL, &req); width = MAX (width, req.width); height = MAX (height, req.height); |