commit 07f81f065f5b942668fce25ea519ba79237bc12d
Author: Vitaly Minko <vitaly.minko@gmail.com>
Date:   Mon Nov 15 20:28:35 2010 +0300

    Need to request size for the search bar manually (#634688).

diff --git a/libempathy-gtk/empathy-search-bar.c b/libempathy-gtk/empathy-search-bar.c
index 9a27795..8de119b 100644
--- a/libempathy-gtk/empathy-search-bar.c
+++ b/libempathy-gtk/empathy-search-bar.c
@@ -58,6 +58,23 @@ empathy_search_bar_new (EmpathyChatView *view)
 }
 
 static void
+empathy_search_bar_size_request (GtkWidget *widget,
+    GtkRequisition *requisition)
+{
+  GtkBin *bin;
+  GtkWidget *child;
+
+  bin = GTK_BIN (widget);
+  child = gtk_bin_get_child (bin);
+
+  if (child && gtk_widget_get_visible (child))
+    {
+      gtk_widget_get_preferred_width (child, &requisition->width, NULL);
+      gtk_widget_get_preferred_height (child, &requisition->height, NULL);
+    }
+}
+
+static void
 empathy_search_bar_size_allocate (GtkWidget *widget,
     GtkAllocation *allocation)
 {
@@ -290,6 +307,7 @@ empathy_search_bar_class_init (EmpathySearchBarClass *class)
   g_type_class_add_private (gobject_class, sizeof (EmpathySearchBarPriv));
 
   /* Neither GtkBin nor GtkContainer seems to do this for us :( */
+  widget_class->size_request = empathy_search_bar_size_request;
   widget_class->size_allocate = empathy_search_bar_size_allocate;
 }
 
