@@ -296,34 +296,35 @@ class EditGroupSettingsDialogState extends State<EditGroupSettingsDialog> {
296296 ),
297297 const SizedBox (height: 16 ),
298298 const Text ('Welche Merkmale müssen zutreffen?' ),
299- Row (
300- mainAxisAlignment : MainAxisAlignment .spaceEvenly ,
301- children : [
302- Expanded (
303- child : RadioListTile < String >(
304- title : const Text ( 'eines' ),
305- value : 'OR' ,
306- groupValue : orFilter ? 'OR' : 'AND' ,
307- onChanged : ( String ? value) {
308- setState (() {
309- orFilter = value == 'OR' ;
310- });
311- } ,
312- ) ,
299+ Padding (
300+ padding : const EdgeInsets . symmetric (vertical : 8.0 ) ,
301+ child : ToggleButtons (
302+ isSelected : [orFilter, ! orFilter],
303+ onPressed : ( int index) {
304+ setState (() {
305+ orFilter =
306+ index == 0 ; // 0 -> 'eines' (OR), 1 -> 'alle' (AND)
307+ });
308+ },
309+ borderRadius : BorderRadius . circular ( 6 ),
310+ constraints : const BoxConstraints (
311+ minHeight : 36 ,
312+ minWidth : 80 ,
313313 ),
314- Expanded (
315- child: RadioListTile <String >(
316- title: const Text ('alle' ),
317- value: 'AND' ,
318- groupValue: orFilter ? 'OR' : 'AND' ,
319- onChanged: (String ? value) {
320- setState (() {
321- orFilter = value == 'OR' ;
322- });
323- },
314+ color: Theme .of (context).colorScheme.onSurface,
315+ selectedColor: Theme .of (context).colorScheme.onPrimary,
316+ fillColor: Theme .of (context).colorScheme.primary,
317+ children: const [
318+ Padding (
319+ padding: EdgeInsets .symmetric (horizontal: 12.0 ),
320+ child: Text ('eines' ),
324321 ),
325- ),
326- ],
322+ Padding (
323+ padding: EdgeInsets .symmetric (horizontal: 12.0 ),
324+ child: Text ('alle' ),
325+ ),
326+ ],
327+ ),
327328 ),
328329 const SizedBox (height: 16 ),
329330 if (orFilter)
0 commit comments