Polished context menus on files and grade average calculator

This commit is contained in:
2023-06-07 19:56:50 +02:00
parent 7ec339af0c
commit 7b52589d9e
2 changed files with 4 additions and 6 deletions

View File

@ -68,14 +68,14 @@ class _GradeAverageState extends State<GradeAverage> {
}, icon: const Icon(Icons.delete_forever)),
),
PopupMenuButton<bool>(
enableFeedback: true,
initialValue: gradeSystem,
icon: const Icon(Icons.more_horiz),
itemBuilder: (context) => [true, false].map((e) => PopupMenuItem<bool>(
value: e,
enabled: e != gradeSystem,
child: Row(
children: [
Icon(e ? Icons.calculate_outlined : Icons.school_outlined, color: Theme.of(context).colorScheme.onSurface),
const SizedBox(width: 15),
Text(e ? "Notensystem" : "Punktesystem"),
],
),
@ -102,8 +102,6 @@ class _GradeAverageState extends State<GradeAverage> {
} else {
switchSystem();
}
},
),
],