flutter: windows: Do not show play sounds settings

This commit is contained in:
Calcitem 2021-05-09 23:01:29 +08:00
parent 276fabc0e9
commit 2ddc9ca221
1 changed files with 9 additions and 4 deletions

View File

@ -17,6 +17,7 @@
*/ */
import 'dart:async'; import 'dart:async';
import 'dart:io';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
@ -251,9 +252,13 @@ class _GameSettingsPageState extends State<GameSettingsPage> {
), ),
], ],
), ),
SizedBox(height: AppTheme.sizedBoxHeight), !Platform.isWindows
Text(S.of(context).playSounds, style: AppTheme.settingsHeaderStyle), ? SizedBox(height: AppTheme.sizedBoxHeight)
SettingsCard( : Container(height: 0.0, width: 0.0),
!Platform.isWindows
? Text(S.of(context).playSounds, style: AppTheme.settingsHeaderStyle)
: Container(height: 0.0, width: 0.0),
!Platform.isWindows? SettingsCard(
context: context, context: context,
children: <Widget>[ children: <Widget>[
SettingsSwitchListTile( SettingsSwitchListTile(
@ -263,7 +268,7 @@ class _GameSettingsPageState extends State<GameSettingsPage> {
titleString: S.of(context).playSoundsInTheGame, titleString: S.of(context).playSoundsInTheGame,
), ),
], ],
), ): Container(height: 0.0, width: 0.0),
SizedBox(height: AppTheme.sizedBoxHeight), SizedBox(height: AppTheme.sizedBoxHeight),
Text(S.of(context).whoMovesFirst, style: AppTheme.settingsHeaderStyle), Text(S.of(context).whoMovesFirst, style: AppTheme.settingsHeaderStyle),
SettingsCard( SettingsCard(