diff options
author | Matthias Clasen <mclasen@redhat.com> | 2011-08-10 16:00:38 +0200 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2011-08-10 16:34:20 +0200 |
commit | 2ba9c4b4a7d9ffc3161e2db1774743182a365d99 (patch) | |
tree | 71eafdf29308d8cf5b2adba4df97461ee9b5568a /gtk/gtkcalendar.c | |
parent | 6596dbff312ecdc65681c37f3de21217d7731388 (diff) | |
download | gtk+-2ba9c4b4a7d9ffc3161e2db1774743182a365d99.tar.gz |
Make focus rectangles optional
This commit introduces a new setting, gtk-visible-focus, backed
by the Gtk/VisibleFocus X setting. Its three values control how
focus rectangles are displayed.
'always' is equivalent to the traditional GTK+ behaviour of always
rendering focus rectangles.
'never' does what it says, and is intended for keyboardless
situations, e.g. tablets.
'automatic' hides focus rectangles initially, until the user
interacts with the keyboard, at which point focus rectangles
become visible.
https://bugzilla.gnome.org/show_bug.cgi?id=649567
Diffstat (limited to 'gtk/gtkcalendar.c')
-rw-r--r-- | gtk/gtkcalendar.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gtk/gtkcalendar.c b/gtk/gtkcalendar.c index c8eac51368..cff79bf564 100644 --- a/gtk/gtkcalendar.c +++ b/gtk/gtkcalendar.c @@ -2710,8 +2710,8 @@ calendar_paint_day (GtkCalendar *calendar, pango_cairo_show_layout (cr, layout); } - if (gtk_widget_has_focus (widget) - && priv->focus_row == row && priv->focus_col == col) + if (gtk_widget_has_visible_focus (widget) && + priv->focus_row == row && priv->focus_col == col) gtk_render_focus (context, cr, day_rect.x, day_rect.y, day_rect.width, day_rect.height); |