calendar: Only highlight one day as today
authorTimm Bäder <mail@baedert.org>
Fri, 27 Mar 2020 07:39:16 +0000 (08:39 +0100)
committerTimm Bäder <mail@baedert.org>
Fri, 27 Mar 2020 08:50:30 +0000 (09:50 +0100)
Fixes #2490

gtk/gtkcalendar.c

index 8a8b9d26d3b1b77da4e078b44faf02409ecdae2c..f38d8ac91e20f30e1021f61f254968019ec24b9a 100644 (file)
@@ -1457,7 +1457,8 @@ gtk_calendar_select_day (GtkCalendar *self,
         else
           gtk_widget_unset_state_flags (label, GTK_STATE_FLAG_SELECTED);
 
-        if (day == today_day)
+        if (day == today_day &&
+            priv->day_month[y][x] == MONTH_CURRENT)
           gtk_widget_add_css_class (label, "today");
         else
           gtk_widget_remove_css_class (label, "today");