summaryrefslogtreecommitdiff
path: root/gtk/gtkscrolledwindow.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2008-08-29 04:26:19 +0000
committerMatthias Clasen <matthiasc@src.gnome.org>2008-08-29 04:26:19 +0000
commitf646e475e7b716ed9bd2f8c5cb6fddf9319a629f (patch)
treeaa6a1d0c9400701ba7b33c69dc2e618071b7451e /gtk/gtkscrolledwindow.c
parent9eae7a1d2e7457d67ba00bb8c35775c1523fa186 (diff)
downloadgtk+-f646e475e7b716ed9bd2f8c5cb6fddf9319a629f.tar.gz
Bug 549262 – GtkScrolledWindow should not accept focus unless
2008-08-29 Matthias Clasen <mclasen@redhat.com> Bug 549262 – GtkScrolledWindow should not accept focus unless GTK_CAN_FOCUS is set * gtk/gtkscrolledwindow.c (gtk_scrolled_window_focus): only grab the focus, if GTK_WIDGET_CAN_FOCUS() returns TRUE. Patch by Sven Herzberg svn path=/trunk/; revision=21233
Diffstat (limited to 'gtk/gtkscrolledwindow.c')
-rw-r--r--gtk/gtkscrolledwindow.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gtk/gtkscrolledwindow.c b/gtk/gtkscrolledwindow.c
index 78f1110295..8134792a1f 100644
--- a/gtk/gtkscrolledwindow.c
+++ b/gtk/gtkscrolledwindow.c
@@ -1547,7 +1547,7 @@ gtk_scrolled_window_focus (GtkWidget *widget,
return TRUE;
}
- if (!had_focus_child)
+ if (!had_focus_child && GTK_WIDGET_CAN_FOCUS (widget))
{
gtk_widget_grab_focus (widget);
return TRUE;