From c29cb6688dd71a282ac8079657076415ae3d05a8 Mon Sep 17 00:00:00 2001 From: Xan Lopez Date: Tue, 8 Dec 2009 17:53:11 +0200 Subject: ephy-statusbar: avoid widget surgery hacks with newer GTK+s Bug #602130 --- src/ephy-statusbar.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/ephy-statusbar.c b/src/ephy-statusbar.c index af2b2348d..b60c72e73 100644 --- a/src/ephy-statusbar.c +++ b/src/ephy-statusbar.c @@ -161,13 +161,19 @@ ephy_statusbar_init (EphyStatusbar *t) gtk_statusbar_set_has_resize_grip (gstatusbar, TRUE); +#if GTK_CHECK_VERSION (2, 19, 1) priv->hbox = gtk_hbox_new (FALSE, 4); - +#else + priv->hbox = gtk_statusbar_get_message_area (gstatusbar); +#endif priv->icon_container = gtk_hbox_new (FALSE, 4); gtk_box_pack_start (GTK_BOX (priv->hbox), priv->icon_container, FALSE, FALSE, 0); gtk_widget_show (priv->icon_container); +#if GTK_CHECK_VERSION (2, 19, 1) + gtk_box_reorder_child (GTK_BOX (priv->hbox), priv->icon_container, 0); +#else /* Put the label in the hbox, and substitute the hbox into the frame */ g_object_ref (gstatusbar->label); gtk_container_remove (GTK_CONTAINER (gstatusbar->frame), gstatusbar->label); @@ -175,6 +181,7 @@ ephy_statusbar_init (EphyStatusbar *t) g_object_unref (gstatusbar->label); gtk_container_add (GTK_CONTAINER (gstatusbar->frame), priv->hbox); gtk_widget_show (priv->hbox); +#endif /* Create security icon */ create_icon_frame (t, -- cgit v1.2.3