机器状态数据和地图切换,系统配置页面
This commit is contained in:
@@ -317,7 +317,9 @@ class _SystemSettingsPageState extends State<SystemSettingsPage> {
|
||||
if (state is UpdateUpToDate) {
|
||||
ScaffoldMessenger.of(context).showSnackBar(
|
||||
SnackBar(
|
||||
content: const Text('当前已是最新版本'),
|
||||
content: Text(
|
||||
AppLocalizations.of(context).translate('my_v2.up_to_date'),
|
||||
),
|
||||
backgroundColor: context.appColors.success,
|
||||
duration: const Duration(seconds: 2),
|
||||
),
|
||||
@@ -326,6 +328,7 @@ class _SystemSettingsPageState extends State<SystemSettingsPage> {
|
||||
},
|
||||
builder: (context, state) {
|
||||
final isChecking = state is UpdateChecking;
|
||||
final l10n = AppLocalizations.of(context);
|
||||
return Row(
|
||||
children: [
|
||||
Expanded(
|
||||
@@ -333,7 +336,7 @@ class _SystemSettingsPageState extends State<SystemSettingsPage> {
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Text(
|
||||
'版本更新',
|
||||
l10n.translate('my_v2.version_update'),
|
||||
style: TextStyle(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.bold,
|
||||
@@ -342,7 +345,12 @@ class _SystemSettingsPageState extends State<SystemSettingsPage> {
|
||||
),
|
||||
const SizedBox(height: 4),
|
||||
Text(
|
||||
'当前版本: $_currentVersion ($_currentVersionCode)',
|
||||
l10n
|
||||
.translate('my_v2.current_version')
|
||||
.replaceAll(
|
||||
'%s',
|
||||
'$_currentVersion ($_currentVersionCode)',
|
||||
),
|
||||
style: TextStyle(
|
||||
fontSize: 13,
|
||||
color: context.appColors.textTertiary,
|
||||
@@ -350,7 +358,9 @@ class _SystemSettingsPageState extends State<SystemSettingsPage> {
|
||||
),
|
||||
const SizedBox(height: 2),
|
||||
Text(
|
||||
isChecking ? '正在检查更新...' : '点击检查是否有新版本',
|
||||
isChecking
|
||||
? l10n.translate('my_v2.checking_update')
|
||||
: l10n.translate('my_v2.tap_to_check'),
|
||||
style: TextStyle(
|
||||
fontSize: 13,
|
||||
color: context.appColors.textTertiary,
|
||||
@@ -379,9 +389,9 @@ class _SystemSettingsPageState extends State<SystemSettingsPage> {
|
||||
color: const Color(0xFF165DFF),
|
||||
borderRadius: BorderRadius.circular(8),
|
||||
),
|
||||
child: const Text(
|
||||
'检查更新',
|
||||
style: TextStyle(
|
||||
child: Text(
|
||||
l10n.translate('my_v2.check_update'),
|
||||
style: const TextStyle(
|
||||
fontSize: 14,
|
||||
color: Colors.white,
|
||||
fontWeight: FontWeight.w500,
|
||||
|
||||
Reference in New Issue
Block a user