mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
mod: add check update
Closes #112 Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -29,6 +29,7 @@ import 'package:PiliPlus/utils/feed_back.dart';
|
||||
import 'package:PiliPlus/utils/global_data.dart';
|
||||
import 'package:PiliPlus/utils/recommend_filter.dart';
|
||||
import 'package:PiliPlus/utils/storage.dart';
|
||||
import 'package:PiliPlus/utils/utils.dart';
|
||||
import 'package:auto_orientation/auto_orientation.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
@@ -1886,4 +1887,17 @@ List<SettingsModel> get extraSettings => [
|
||||
setKey: SettingBoxKey.autoClearCache,
|
||||
defaultVal: false,
|
||||
),
|
||||
SettingsModel(
|
||||
settingsType: SettingsType.sw1tch,
|
||||
title: '检查更新',
|
||||
subtitle: '每次启动时检查是否需要更新',
|
||||
leading: const Icon(Icons.system_update_alt_outlined),
|
||||
setKey: SettingBoxKey.autoUpdate,
|
||||
defaultVal: true,
|
||||
onChanged: (val) {
|
||||
if (val) {
|
||||
Utils.checkUpdate();
|
||||
}
|
||||
},
|
||||
),
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user