summaryrefslogtreecommitdiffstats
path: root/src/tab-chrome.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/tab-chrome.c')
-rw-r--r--src/tab-chrome.c20
1 files changed, 14 insertions, 6 deletions
diff --git a/src/tab-chrome.c b/src/tab-chrome.c
index d5de77b..a42ff26 100644
--- a/src/tab-chrome.c
+++ b/src/tab-chrome.c
@@ -54,15 +54,23 @@ static void
back_forward_toggle_button_toggled_cb(GtkToggleButton *toggle_button,
GtkStack *stack)
{
+ GtkWidget *child;
+
/* Use gtk_widget_show() and gtk_widget_hide() instead of
* gtk_stack_set_visible_child() so that the stack fits the size of only
* the visible child. */
- gtk_widget_show_all(gtk_stack_get_child_by_name(stack,
- gtk_toggle_button_get_active(toggle_button) ?
- "text" : "list"));
- gtk_widget_hide(gtk_stack_get_child_by_name(stack,
- gtk_toggle_button_get_active(toggle_button) ?
- "list" : "text"));
+
+ child = gtk_stack_get_child_by_name(stack,
+ gtk_toggle_button_get_active(toggle_button) ? "text" : "list");
+ gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(child),
+ GTK_POLICY_NEVER, GTK_POLICY_NEVER);
+ gtk_widget_show_all(child);
+
+ child = gtk_stack_get_child_by_name(stack,
+ gtk_toggle_button_get_active(toggle_button) ? "list" : "text");
+ gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(child),
+ GTK_POLICY_NEVER, GTK_POLICY_NEVER);
+ gtk_widget_hide(child);
}
static GtkWidget *