Changed button style
This commit is contained in:
@@ -8,7 +8,6 @@ import 'package:tallee/data/models/player.dart';
|
|||||||
import 'package:tallee/data/models/score_entry.dart';
|
import 'package:tallee/data/models/score_entry.dart';
|
||||||
import 'package:tallee/l10n/generated/app_localizations.dart';
|
import 'package:tallee/l10n/generated/app_localizations.dart';
|
||||||
import 'package:tallee/presentation/widgets/buttons/custom_width_button.dart';
|
import 'package:tallee/presentation/widgets/buttons/custom_width_button.dart';
|
||||||
import 'package:tallee/presentation/widgets/buttons/main_menu_button.dart';
|
|
||||||
import 'package:tallee/presentation/widgets/tiles/match_result_view/custom_radio_list_tile.dart';
|
import 'package:tallee/presentation/widgets/tiles/match_result_view/custom_radio_list_tile.dart';
|
||||||
import 'package:tallee/presentation/widgets/tiles/match_result_view/live_edit_list_tile.dart';
|
import 'package:tallee/presentation/widgets/tiles/match_result_view/live_edit_list_tile.dart';
|
||||||
import 'package:tallee/presentation/widgets/tiles/match_result_view/score_list_tile.dart';
|
import 'package:tallee/presentation/widgets/tiles/match_result_view/score_list_tile.dart';
|
||||||
@@ -109,9 +108,8 @@ class _MatchResultViewState extends State<MatchResultView> {
|
|||||||
Expanded(
|
Expanded(
|
||||||
child: isLiveEditMode && rulesetSupportsScoreEntry()
|
child: isLiveEditMode && rulesetSupportsScoreEntry()
|
||||||
? ListView.builder(
|
? ListView.builder(
|
||||||
itemCount: allPlayers.length + 1,
|
itemCount: allPlayers.length,
|
||||||
itemBuilder: (context, index) {
|
itemBuilder: (context, index) {
|
||||||
if (index < allPlayers.length) {
|
|
||||||
return LiveEditListTile(
|
return LiveEditListTile(
|
||||||
title: allPlayers[index].name,
|
title: allPlayers[index].name,
|
||||||
onChanged: (value) {
|
onChanged: (value) {
|
||||||
@@ -121,22 +119,6 @@ class _MatchResultViewState extends State<MatchResultView> {
|
|||||||
},
|
},
|
||||||
value: int.tryParse(controller[index].text) ?? 0,
|
value: int.tryParse(controller[index].text) ?? 0,
|
||||||
);
|
);
|
||||||
} else {
|
|
||||||
return Center(
|
|
||||||
child: Padding(
|
|
||||||
padding: const EdgeInsets.only(top: 30),
|
|
||||||
child: MainMenuButton(
|
|
||||||
text: 'Ansicht verlassen',
|
|
||||||
onPressed: () => {
|
|
||||||
setState(() {
|
|
||||||
isLiveEditMode = false;
|
|
||||||
}),
|
|
||||||
},
|
|
||||||
icon: Icons.close,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
);
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
: Container(
|
: Container(
|
||||||
@@ -254,6 +236,14 @@ class _MatchResultViewState extends State<MatchResultView> {
|
|||||||
}
|
}
|
||||||
: null,
|
: null,
|
||||||
),
|
),
|
||||||
|
] else ...[
|
||||||
|
CustomWidthButton(
|
||||||
|
text: 'Ansicht verlassen',
|
||||||
|
sizeRelativeToWidth: 0.95,
|
||||||
|
onPressed: () => setState(() {
|
||||||
|
isLiveEditMode = false;
|
||||||
|
}),
|
||||||
|
),
|
||||||
],
|
],
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
|||||||
Reference in New Issue
Block a user