1
0
mirror of https://gitlab.com/comunic/comunicmobile synced 2024-11-21 20:39:22 +00:00

Fix navigability issue

This commit is contained in:
Pierre HUBERT 2021-05-29 15:57:31 +02:00
parent fa8c1f46a1
commit a076c08429

View File

@ -37,6 +37,16 @@ class PresenceCalendarWidget extends StatefulWidget {
class _PresenceCalendarWidgetState extends State<PresenceCalendarWidget> {
var selectedDay = DateTime.now();
@override
void didUpdateWidget(covariant PresenceCalendarWidget oldWidget) {
super.didUpdateWidget(oldWidget);
if (oldWidget.selectedDay != widget.selectedDay) {
selectedDay = widget.selectedDay;
setState(() {});
}
}
@override
Widget build(BuildContext context) {
return TableCalendar(