summaryrefslogtreecommitdiff
path: root/mate-dictionary/src/gdict-applet.c
diff options
context:
space:
mode:
Diffstat (limited to 'mate-dictionary/src/gdict-applet.c')
-rw-r--r--mate-dictionary/src/gdict-applet.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/mate-dictionary/src/gdict-applet.c b/mate-dictionary/src/gdict-applet.c
index 726ad85f..009e1502 100644
--- a/mate-dictionary/src/gdict-applet.c
+++ b/mate-dictionary/src/gdict-applet.c
@@ -333,8 +333,12 @@ gdict_applet_build_window (GdictApplet *applet)
gtk_container_add (GTK_CONTAINER (window), frame);
gtk_widget_show (frame);
priv->frame = frame;
-
+
+#if GTK_CHECK_VERSION (3, 0, 0)
+ vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 12);
+#else
vbox = gtk_vbox_new (FALSE, 12);
+#endif
gtk_container_set_border_width (GTK_CONTAINER (vbox), 6);
gtk_container_add (GTK_CONTAINER (frame), vbox);
gtk_widget_show (vbox);
@@ -512,6 +516,9 @@ gdict_applet_draw (GdictApplet *applet)
if (priv->box)
gtk_widget_destroy (priv->box);
+#if GTK_CHECK_VERSION (3, 0, 0)
+ box = gtk_box_new (priv->orient, 0);
+#else
switch (priv->orient)
{
case GTK_ORIENTATION_VERTICAL:
@@ -524,6 +531,7 @@ gdict_applet_draw (GdictApplet *applet)
g_assert_not_reached ();
break;
}
+#endif
gtk_container_add (GTK_CONTAINER (applet), box);
gtk_widget_show (box);
@@ -546,7 +554,11 @@ gdict_applet_draw (GdictApplet *applet)
gtk_box_pack_start (GTK_BOX (box), priv->toggle, FALSE, FALSE, 0);
gtk_widget_show (priv->toggle);
+#if GTK_CHECK_VERSION (3, 0, 0)
+ hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
+#else
hbox = gtk_hbox_new (FALSE, 0);
+#endif
gtk_container_set_border_width (GTK_CONTAINER (hbox), 0);
gtk_container_add (GTK_CONTAINER (priv->toggle), hbox);
gtk_widget_show (hbox);