aboutsummaryrefslogtreecommitdiffstats
path: root/modules/mail/e-mail-shell-sidebar.c
diff options
context:
space:
mode:
Diffstat (limited to 'modules/mail/e-mail-shell-sidebar.c')
-rw-r--r--modules/mail/e-mail-shell-sidebar.c26
1 files changed, 14 insertions, 12 deletions
diff --git a/modules/mail/e-mail-shell-sidebar.c b/modules/mail/e-mail-shell-sidebar.c
index 491d5068d7..ac736a0a67 100644
--- a/modules/mail/e-mail-shell-sidebar.c
+++ b/modules/mail/e-mail-shell-sidebar.c
@@ -201,8 +201,8 @@ guess_screen_width (EMailShellSidebar *sidebar)
screen, gtk_widget_get_window (toplevel));
else {
/* We don't know in which monitor the window manager
- * will put us. So we will just use the geometry of the
- * first monitor.
+ * will put us. So we will just use the geometry of
+ * the first monitor.
*/
monitor = 0;
}
@@ -218,18 +218,21 @@ guess_screen_width (EMailShellSidebar *sidebar)
}
static void
-mail_shell_sidebar_size_request (GtkWidget *widget, GtkRequisition *requisition)
+mail_shell_sidebar_size_request (GtkWidget *widget,
+ GtkRequisition *requisition)
{
/* We override the normal size-request handler so that we can
- * spit out a treeview with a suitable width. We measure the length
- * of a typical string and use that as the requisition's width.
+ * spit out a treeview with a suitable width. We measure the
+ * length of a typical string and use that as the requisition's
+ * width.
*
- * EMFolderTreeClass, our parent class, is based on GtkTreeView, which
- * doesn't really have a good way of figuring out a minimum width for
- * the tree. This is really GTK+'s fault at large, as it only has
- * "minimum size / allocated size", instead of "minimum size / preferred
- * size / allocated size". Hopefully the extended-layout branch of GTK+
- * will get merged soon and then we can remove this crap.
+ * EMFolderTreeClass, our parent class, is based on GtkTreeView,
+ * which doesn't really have a good way of figuring out a minimum
+ * width for the tree. This is really GTK+'s fault at large, as
+ * it only has "minimum size / allocated size", instead of
+ * "minimum size / preferred size / allocated size". Hopefully
+ * the extended-layout branch of GTK+ will get merged soon and
+ * then we can remove this crap.
*/
EMailShellSidebar *sidebar;
@@ -256,7 +259,6 @@ mail_shell_sidebar_size_request (GtkWidget *widget, GtkRequisition *requisition)
/* Thickness of frame shadow plus some slack for padding. */
border = 2 * style->xthickness + 4;
-
sidebar_width = ink_rect.width + border;
sidebar_width = MIN (sidebar_width, screen_width / 4);
requisition->width = MAX (requisition->width, sidebar_width);