Skip to content

Commit

Permalink
Fix lint issues
Browse files Browse the repository at this point in the history
  • Loading branch information
ufrshubham committed Nov 28, 2023
1 parent 603ebac commit 91e8edd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions lib/game/game.dart
Original file line number Diff line number Diff line change
Expand Up @@ -295,6 +295,7 @@ class SpacescapeGame extends FlameGame
case AppLifecycleState.inactive:
case AppLifecycleState.paused:
case AppLifecycleState.detached:
case AppLifecycleState.hidden:
if (_player.health > 0) {
pauseEngine();
overlays.remove(PauseButton.id);
Expand Down
4 changes: 2 additions & 2 deletions lib/screens/game_play.dart
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ class GamePlay extends StatelessWidget {
// WillPopScope provides us a way to decide if
// this widget should be poped or not when user
// presses the back button.
body: WillPopScope(
onWillPop: () async => false,
body: PopScope(
canPop: false,
// GameWidget is useful to inject the underlying
// widget of any class extending from Flame's Game class.
child: GameWidget(
Expand Down

0 comments on commit 91e8edd

Please sign in to comment.