From e77ee5d5d38ad95bce550db62bf4105f43cf88c6 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Sat, 2 Jan 2010 22:46:23 -0600 Subject: Coding style and whitespace cleanup. --- widgets/misc/e-calendar.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'widgets/misc/e-calendar.c') diff --git a/widgets/misc/e-calendar.c b/widgets/misc/e-calendar.c index e9aacfa8b9..920e83d3a3 100644 --- a/widgets/misc/e-calendar.c +++ b/widgets/misc/e-calendar.c @@ -587,7 +587,10 @@ e_calendar_focus (GtkWidget *widget, GtkDirectionType direction) /* get current focused item, if e-calendar has had focus */ if (GTK_WIDGET_HAS_FOCUS (widget) || e_calendar_button_has_focus (cal)) - for (index = 0; canvas->focused_item && index < E_CALENDAR_FOCUS_CHILDREN_NUM; ++index) { + for (index = 0; index < E_CALENDAR_FOCUS_CHILDREN_NUM; ++index) { + if (canvas->focused_item == NULL) + break; + if (children[index] == canvas->focused_item) { focused_index = index; break; -- cgit v1.2.3