Commit d69597df authored by Milan Crha's avatar Milan Crha

Bug 746950 - Menu item tooltip changes height of status bar

parent 6740f514
......@@ -365,6 +365,7 @@ shell_taskbar_size_allocate (GtkWidget *widget,
{
EShellTaskbar *shell_taskbar;
gint fixed_height, minimum_height = 0, natural_height = 0;
gboolean height_changed;
if (GTK_WIDGET_CLASS (e_shell_taskbar_parent_class)->get_preferred_height)
GTK_WIDGET_CLASS (e_shell_taskbar_parent_class)->get_preferred_height (widget, &minimum_height, &natural_height);
......@@ -374,11 +375,15 @@ shell_taskbar_size_allocate (GtkWidget *widget,
/* Maximum height allocation sticks. */
fixed_height = shell_taskbar->priv->fixed_height;
fixed_height = MAX (fixed_height, MAX (allocation->height, minimum_height));
height_changed = fixed_height != shell_taskbar->priv->fixed_height;
shell_taskbar->priv->fixed_height = fixed_height;
/* Chain up to parent's size_allocate() method. */
GTK_WIDGET_CLASS (e_shell_taskbar_parent_class)->
size_allocate (widget, allocation);
if (height_changed)
g_object_set (G_OBJECT (shell_taskbar), "height-request", fixed_height, NULL);
}
static void
......
......@@ -747,6 +747,11 @@ shell_window_create_shell_view (EShellWindow *shell_window,
widget = GTK_WIDGET (e_shell_view_get_shell_taskbar (shell_view));
gtk_notebook_append_page (notebook, widget, NULL);
e_binding_bind_property (
widget, "height-request",
shell_window->priv->tooltip_label, "height-request",
G_BINDING_SYNC_CREATE);
/* Listen for changes that affect the shell window. */
e_signal_connect_notify_swapped (
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment