feat: max cache size

Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-04-20 20:39:17 +08:00
parent a2af297a84
commit ae901c709d
7 changed files with 78 additions and 10 deletions

View File

@@ -468,6 +468,9 @@ class GStorage {
SettingBoxKey.pageTransition,
defaultValue: Transition.native.index)];
static num get maxCacheSize => GStorage.setting
.get(SettingBoxKey.maxCacheSize, defaultValue: pow(1024, 3));
static List<double> get dynamicDetailRatio => List<double>.from(setting
.get(SettingBoxKey.dynamicDetailRatio, defaultValue: [60.0, 40.0]));
@@ -669,6 +672,7 @@ class SettingBoxKey {
/// 其他
autoUpdate = 'autoUpdate',
autoClearCache = 'autoClearCache',
maxCacheSize = 'maxCacheSize',
defaultShowComment = 'defaultShowComment',
replySortType = 'replySortType',
defaultDynamicType = 'defaultDynamicType',