Added rootNavigator attribute to fullscreenDialog above the tab bar

This commit is contained in:
Felix Kirchner
2025-05-02 23:31:28 +02:00
parent d4b4d841a7
commit 74148aed8a
2 changed files with 5 additions and 4 deletions

View File

@@ -82,8 +82,9 @@ class _ActiveGameViewState extends State<ActiveGameView> {
style: TextStyle(fontSize: 22)), style: TextStyle(fontSize: 22)),
onTap: () async { onTap: () async {
// ignore: unused_local_variable // ignore: unused_local_variable
final val = await Navigator.push( final val =
context, await Navigator.of(context, rootNavigator: true)
.push(
CupertinoPageRoute( CupertinoPageRoute(
fullscreenDialog: true, fullscreenDialog: true,
builder: (context) => RoundView( builder: (context) => RoundView(

View File

@@ -293,8 +293,8 @@ class _RoundViewState extends State<RoundView> {
if (widget.gameSession.isGameFinished == true) { if (widget.gameSession.isGameFinished == true) {
Navigator.pop(context, widget.gameSession); Navigator.pop(context, widget.gameSession);
} else { } else {
Navigator.pushReplacement( Navigator.of(context, rootNavigator: true)
context, .pushReplacement(
CupertinoPageRoute( CupertinoPageRoute(
builder: (context) => RoundView( builder: (context) => RoundView(
gameSession: widget.gameSession, gameSession: widget.gameSession,