mirror of
https://github.com/lollipopkit/flutter_server_box.git
synced 2025-12-17 07:14:28 +01:00
fix: webdav
This commit is contained in:
@@ -586,7 +586,7 @@
|
|||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||||
CLANG_ENABLE_MODULES = YES;
|
CLANG_ENABLE_MODULES = YES;
|
||||||
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
||||||
CURRENT_PROJECT_VERSION = 678;
|
CURRENT_PROJECT_VERSION = 682;
|
||||||
DEVELOPMENT_TEAM = BA88US33G6;
|
DEVELOPMENT_TEAM = BA88US33G6;
|
||||||
ENABLE_BITCODE = NO;
|
ENABLE_BITCODE = NO;
|
||||||
INFOPLIST_FILE = "Runner/Info-$(CONFIGURATION).plist";
|
INFOPLIST_FILE = "Runner/Info-$(CONFIGURATION).plist";
|
||||||
@@ -596,7 +596,7 @@
|
|||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
"@executable_path/Frameworks",
|
"@executable_path/Frameworks",
|
||||||
);
|
);
|
||||||
MARKETING_VERSION = 1.0.678;
|
MARKETING_VERSION = 1.0.682;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox;
|
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox;
|
||||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||||
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
||||||
@@ -720,7 +720,7 @@
|
|||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||||
CLANG_ENABLE_MODULES = YES;
|
CLANG_ENABLE_MODULES = YES;
|
||||||
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
||||||
CURRENT_PROJECT_VERSION = 678;
|
CURRENT_PROJECT_VERSION = 682;
|
||||||
DEVELOPMENT_TEAM = BA88US33G6;
|
DEVELOPMENT_TEAM = BA88US33G6;
|
||||||
ENABLE_BITCODE = NO;
|
ENABLE_BITCODE = NO;
|
||||||
INFOPLIST_FILE = "Runner/Info-$(CONFIGURATION).plist";
|
INFOPLIST_FILE = "Runner/Info-$(CONFIGURATION).plist";
|
||||||
@@ -730,7 +730,7 @@
|
|||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
"@executable_path/Frameworks",
|
"@executable_path/Frameworks",
|
||||||
);
|
);
|
||||||
MARKETING_VERSION = 1.0.678;
|
MARKETING_VERSION = 1.0.682;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox;
|
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox;
|
||||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||||
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
||||||
@@ -748,7 +748,7 @@
|
|||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||||
CLANG_ENABLE_MODULES = YES;
|
CLANG_ENABLE_MODULES = YES;
|
||||||
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
||||||
CURRENT_PROJECT_VERSION = 678;
|
CURRENT_PROJECT_VERSION = 682;
|
||||||
DEVELOPMENT_TEAM = BA88US33G6;
|
DEVELOPMENT_TEAM = BA88US33G6;
|
||||||
ENABLE_BITCODE = NO;
|
ENABLE_BITCODE = NO;
|
||||||
INFOPLIST_FILE = "Runner/Info-$(CONFIGURATION).plist";
|
INFOPLIST_FILE = "Runner/Info-$(CONFIGURATION).plist";
|
||||||
@@ -758,7 +758,7 @@
|
|||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
"@executable_path/Frameworks",
|
"@executable_path/Frameworks",
|
||||||
);
|
);
|
||||||
MARKETING_VERSION = 1.0.678;
|
MARKETING_VERSION = 1.0.682;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox;
|
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox;
|
||||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||||
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
||||||
@@ -779,7 +779,7 @@
|
|||||||
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
||||||
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
CURRENT_PROJECT_VERSION = 678;
|
CURRENT_PROJECT_VERSION = 682;
|
||||||
DEVELOPMENT_TEAM = BA88US33G6;
|
DEVELOPMENT_TEAM = BA88US33G6;
|
||||||
GCC_C_LANGUAGE_STANDARD = gnu11;
|
GCC_C_LANGUAGE_STANDARD = gnu11;
|
||||||
GENERATE_INFOPLIST_FILE = YES;
|
GENERATE_INFOPLIST_FILE = YES;
|
||||||
@@ -792,7 +792,7 @@
|
|||||||
"@executable_path/Frameworks",
|
"@executable_path/Frameworks",
|
||||||
"@executable_path/../../Frameworks",
|
"@executable_path/../../Frameworks",
|
||||||
);
|
);
|
||||||
MARKETING_VERSION = 1.0.678;
|
MARKETING_VERSION = 1.0.682;
|
||||||
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
|
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
|
||||||
MTL_FAST_MATH = YES;
|
MTL_FAST_MATH = YES;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.StatusWidget;
|
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.StatusWidget;
|
||||||
@@ -818,7 +818,7 @@
|
|||||||
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
||||||
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
CURRENT_PROJECT_VERSION = 678;
|
CURRENT_PROJECT_VERSION = 682;
|
||||||
DEVELOPMENT_TEAM = BA88US33G6;
|
DEVELOPMENT_TEAM = BA88US33G6;
|
||||||
GCC_C_LANGUAGE_STANDARD = gnu11;
|
GCC_C_LANGUAGE_STANDARD = gnu11;
|
||||||
GENERATE_INFOPLIST_FILE = YES;
|
GENERATE_INFOPLIST_FILE = YES;
|
||||||
@@ -831,7 +831,7 @@
|
|||||||
"@executable_path/Frameworks",
|
"@executable_path/Frameworks",
|
||||||
"@executable_path/../../Frameworks",
|
"@executable_path/../../Frameworks",
|
||||||
);
|
);
|
||||||
MARKETING_VERSION = 1.0.678;
|
MARKETING_VERSION = 1.0.682;
|
||||||
MTL_FAST_MATH = YES;
|
MTL_FAST_MATH = YES;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.StatusWidget;
|
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.StatusWidget;
|
||||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||||
@@ -854,7 +854,7 @@
|
|||||||
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
||||||
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
CURRENT_PROJECT_VERSION = 678;
|
CURRENT_PROJECT_VERSION = 682;
|
||||||
DEVELOPMENT_TEAM = BA88US33G6;
|
DEVELOPMENT_TEAM = BA88US33G6;
|
||||||
GCC_C_LANGUAGE_STANDARD = gnu11;
|
GCC_C_LANGUAGE_STANDARD = gnu11;
|
||||||
GENERATE_INFOPLIST_FILE = YES;
|
GENERATE_INFOPLIST_FILE = YES;
|
||||||
@@ -867,7 +867,7 @@
|
|||||||
"@executable_path/Frameworks",
|
"@executable_path/Frameworks",
|
||||||
"@executable_path/../../Frameworks",
|
"@executable_path/../../Frameworks",
|
||||||
);
|
);
|
||||||
MARKETING_VERSION = 1.0.678;
|
MARKETING_VERSION = 1.0.682;
|
||||||
MTL_FAST_MATH = YES;
|
MTL_FAST_MATH = YES;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.StatusWidget;
|
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.StatusWidget;
|
||||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||||
@@ -890,7 +890,7 @@
|
|||||||
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
||||||
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
CURRENT_PROJECT_VERSION = 678;
|
CURRENT_PROJECT_VERSION = 682;
|
||||||
DEVELOPMENT_ASSET_PATHS = "";
|
DEVELOPMENT_ASSET_PATHS = "";
|
||||||
DEVELOPMENT_TEAM = BA88US33G6;
|
DEVELOPMENT_TEAM = BA88US33G6;
|
||||||
ENABLE_PREVIEWS = YES;
|
ENABLE_PREVIEWS = YES;
|
||||||
@@ -902,7 +902,7 @@
|
|||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
"@executable_path/Frameworks",
|
"@executable_path/Frameworks",
|
||||||
);
|
);
|
||||||
MARKETING_VERSION = 1.0.678;
|
MARKETING_VERSION = 1.0.682;
|
||||||
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
|
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
|
||||||
MTL_FAST_MATH = YES;
|
MTL_FAST_MATH = YES;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.WatchEnd;
|
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.WatchEnd;
|
||||||
@@ -931,7 +931,7 @@
|
|||||||
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
||||||
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
CURRENT_PROJECT_VERSION = 678;
|
CURRENT_PROJECT_VERSION = 682;
|
||||||
DEVELOPMENT_ASSET_PATHS = "";
|
DEVELOPMENT_ASSET_PATHS = "";
|
||||||
DEVELOPMENT_TEAM = BA88US33G6;
|
DEVELOPMENT_TEAM = BA88US33G6;
|
||||||
ENABLE_PREVIEWS = YES;
|
ENABLE_PREVIEWS = YES;
|
||||||
@@ -943,7 +943,7 @@
|
|||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
"@executable_path/Frameworks",
|
"@executable_path/Frameworks",
|
||||||
);
|
);
|
||||||
MARKETING_VERSION = 1.0.678;
|
MARKETING_VERSION = 1.0.682;
|
||||||
MTL_FAST_MATH = YES;
|
MTL_FAST_MATH = YES;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.WatchEnd;
|
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.WatchEnd;
|
||||||
PRODUCT_NAME = ServerBox;
|
PRODUCT_NAME = ServerBox;
|
||||||
@@ -969,7 +969,7 @@
|
|||||||
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
||||||
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
CURRENT_PROJECT_VERSION = 678;
|
CURRENT_PROJECT_VERSION = 682;
|
||||||
DEVELOPMENT_ASSET_PATHS = "";
|
DEVELOPMENT_ASSET_PATHS = "";
|
||||||
DEVELOPMENT_TEAM = BA88US33G6;
|
DEVELOPMENT_TEAM = BA88US33G6;
|
||||||
ENABLE_PREVIEWS = YES;
|
ENABLE_PREVIEWS = YES;
|
||||||
@@ -981,7 +981,7 @@
|
|||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
"@executable_path/Frameworks",
|
"@executable_path/Frameworks",
|
||||||
);
|
);
|
||||||
MARKETING_VERSION = 1.0.678;
|
MARKETING_VERSION = 1.0.682;
|
||||||
MTL_FAST_MATH = YES;
|
MTL_FAST_MATH = YES;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.WatchEnd;
|
PRODUCT_BUNDLE_IDENTIFIER = com.lollipopkit.toolbox.WatchEnd;
|
||||||
PRODUCT_NAME = ServerBox;
|
PRODUCT_NAME = ServerBox;
|
||||||
|
|||||||
@@ -9,6 +9,8 @@ import 'package:toolbox/data/res/store.dart';
|
|||||||
import 'package:webdav_client/webdav_client.dart';
|
import 'package:webdav_client/webdav_client.dart';
|
||||||
|
|
||||||
abstract final class Webdav {
|
abstract final class Webdav {
|
||||||
|
static const _prefix = 'srvbox/';
|
||||||
|
|
||||||
static var _client = WebdavClient(
|
static var _client = WebdavClient(
|
||||||
url: Stores.setting.webdavUrl.fetch(),
|
url: Stores.setting.webdavUrl.fetch(),
|
||||||
user: Stores.setting.webdavUser.fetch(),
|
user: Stores.setting.webdavUser.fetch(),
|
||||||
@@ -35,7 +37,7 @@ abstract final class Webdav {
|
|||||||
try {
|
try {
|
||||||
await _client.writeFile(
|
await _client.writeFile(
|
||||||
localPath ?? '${await Paths.doc}/$relativePath',
|
localPath ?? '${await Paths.doc}/$relativePath',
|
||||||
relativePath,
|
_prefix + relativePath,
|
||||||
);
|
);
|
||||||
} catch (e, s) {
|
} catch (e, s) {
|
||||||
_logger.warning('Upload $relativePath failed', e, s);
|
_logger.warning('Upload $relativePath failed', e, s);
|
||||||
@@ -46,7 +48,7 @@ abstract final class Webdav {
|
|||||||
|
|
||||||
static Future<WebdavErr?> delete(String relativePath) async {
|
static Future<WebdavErr?> delete(String relativePath) async {
|
||||||
try {
|
try {
|
||||||
await _client.remove(relativePath);
|
await _client.remove(_prefix + relativePath);
|
||||||
} catch (e, s) {
|
} catch (e, s) {
|
||||||
_logger.warning('Delete $relativePath failed', e, s);
|
_logger.warning('Delete $relativePath failed', e, s);
|
||||||
return WebdavErr(type: WebdavErrType.generic, message: '$e');
|
return WebdavErr(type: WebdavErrType.generic, message: '$e');
|
||||||
@@ -60,7 +62,7 @@ abstract final class Webdav {
|
|||||||
}) async {
|
}) async {
|
||||||
try {
|
try {
|
||||||
await _client.readFile(
|
await _client.readFile(
|
||||||
relativePath,
|
_prefix + relativePath,
|
||||||
localPath ?? '${await Paths.doc}/$relativePath',
|
localPath ?? '${await Paths.doc}/$relativePath',
|
||||||
);
|
);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|||||||
@@ -2,9 +2,9 @@
|
|||||||
|
|
||||||
class BuildData {
|
class BuildData {
|
||||||
static const String name = "ServerBox";
|
static const String name = "ServerBox";
|
||||||
static const int build = 678;
|
static const int build = 682;
|
||||||
static const String engine = "3.16.3";
|
static const String engine = "3.16.4";
|
||||||
static const String buildAt = "2023-12-17 18:43:29";
|
static const String buildAt = "2023-12-19 15:18:22";
|
||||||
static const int modifications = 8;
|
static const int modifications = 10;
|
||||||
static const int script = 31;
|
static const int script = 32;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -32,7 +32,6 @@ class SettingStore extends PersistentStore {
|
|||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
/// Lanch page idx
|
/// Lanch page idx
|
||||||
late final launchPage = property(
|
late final launchPage = property(
|
||||||
'launchPage',
|
'launchPage',
|
||||||
@@ -64,7 +63,7 @@ class SettingStore extends PersistentStore {
|
|||||||
'textFactor',
|
'textFactor',
|
||||||
1.0,
|
1.0,
|
||||||
);
|
);
|
||||||
|
|
||||||
late final primaryColor = property(
|
late final primaryColor = property(
|
||||||
'primaryColor',
|
'primaryColor',
|
||||||
4287106639,
|
4287106639,
|
||||||
|
|||||||
@@ -37,7 +37,7 @@ import 'view/widget/appbar.dart';
|
|||||||
|
|
||||||
Future<void> main() async {
|
Future<void> main() async {
|
||||||
_runInZone(() async {
|
_runInZone(() async {
|
||||||
await initApp();
|
await _initApp();
|
||||||
runApp(
|
runApp(
|
||||||
MultiProvider(
|
MultiProvider(
|
||||||
providers: [
|
providers: [
|
||||||
@@ -72,7 +72,7 @@ void _runInZone(void Function() body) {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
Future<void> initApp() async {
|
Future<void> _initApp() async {
|
||||||
WidgetsFlutterBinding.ensureInitialized();
|
WidgetsFlutterBinding.ensureInitialized();
|
||||||
await _initDesktopWindow();
|
await _initDesktopWindow();
|
||||||
|
|
||||||
@@ -128,7 +128,7 @@ void _setupLogger() {
|
|||||||
|
|
||||||
Future<void> _initDesktopWindow() async {
|
Future<void> _initDesktopWindow() async {
|
||||||
if (!isDesktop) return;
|
if (!isDesktop) return;
|
||||||
|
|
||||||
await windowManager.ensureInitialized();
|
await windowManager.ensureInitialized();
|
||||||
await CustomAppBar.updateTitlebarHeight();
|
await CustomAppBar.updateTitlebarHeight();
|
||||||
|
|
||||||
|
|||||||
@@ -123,7 +123,8 @@ class BackupPage extends StatelessWidget {
|
|||||||
child: ExpandTile(
|
child: ExpandTile(
|
||||||
leading: const Icon(Icons.storage),
|
leading: const Icon(Icons.storage),
|
||||||
title: const Text('WebDAV'),
|
title: const Text('WebDAV'),
|
||||||
initiallyExpanded: !(isIOS || isMacOS),
|
initiallyExpanded:
|
||||||
|
!(isIOS || isMacOS) && Stores.setting.webdavSync.fetch(),
|
||||||
children: [
|
children: [
|
||||||
ListTile(
|
ListTile(
|
||||||
title: Text(l10n.setting),
|
title: Text(l10n.setting),
|
||||||
|
|||||||
@@ -135,7 +135,7 @@ class _ServerDetailPageState extends State<ServerDetailPage>
|
|||||||
(e) => Row(
|
(e) => Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
children: [
|
children: [
|
||||||
Text(e.key.i18n, style: UIs.textSize15),
|
Text(e.key.i18n, style: UIs.textSize13),
|
||||||
Text(e.value, style: UIs.textSize13Grey)
|
Text(e.value, style: UIs.textSize13Grey)
|
||||||
],
|
],
|
||||||
).padding(const EdgeInsets.symmetric(vertical: 2)),
|
).padding(const EdgeInsets.symmetric(vertical: 2)),
|
||||||
|
|||||||
@@ -296,7 +296,8 @@ class _ServerPageState extends State<ServerPage>
|
|||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
children: [
|
children: [
|
||||||
_wrapWithSizedbox(_buildPercentCircle(ss.cpu.usedPercent()), true),
|
_wrapWithSizedbox(_buildPercentCircle(ss.cpu.usedPercent()), true),
|
||||||
_wrapWithSizedbox(_buildPercentCircle(ss.mem.usedPercent * 100), true),
|
_wrapWithSizedbox(
|
||||||
|
_buildPercentCircle(ss.mem.usedPercent * 100), true),
|
||||||
_wrapWithSizedbox(_buildNet(ss, spi.id)),
|
_wrapWithSizedbox(_buildNet(ss, spi.id)),
|
||||||
_wrapWithSizedbox(_buildDisk(ss, spi.id)),
|
_wrapWithSizedbox(_buildDisk(ss, spi.id)),
|
||||||
],
|
],
|
||||||
@@ -357,10 +358,7 @@ class _ServerPageState extends State<ServerPage>
|
|||||||
children: [
|
children: [
|
||||||
Text(
|
Text(
|
||||||
spi.name,
|
spi.name,
|
||||||
style: const TextStyle(
|
style: UIs.textSize13Bold,
|
||||||
fontSize: 15,
|
|
||||||
fontWeight: FontWeight.bold,
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
const Icon(
|
const Icon(
|
||||||
Icons.keyboard_arrow_right,
|
Icons.keyboard_arrow_right,
|
||||||
@@ -584,7 +582,7 @@ class _ServerPageState extends State<ServerPage>
|
|||||||
!Stores.setting.serverTabUseOldUI.fetch()) {
|
!Stores.setting.serverTabUseOldUI.fetch()) {
|
||||||
return 135;
|
return 135;
|
||||||
}
|
}
|
||||||
return 105;
|
return 106;
|
||||||
}
|
}
|
||||||
|
|
||||||
void _askFor({
|
void _askFor({
|
||||||
|
|||||||
@@ -56,18 +56,20 @@ class _SettingPageState extends State<SettingPage> {
|
|||||||
final _netViewTypeKey = GlobalKey<PopupMenuButtonState<NetViewType>>();
|
final _netViewTypeKey = GlobalKey<PopupMenuButtonState<NetViewType>>();
|
||||||
final _setting = Stores.setting;
|
final _setting = Stores.setting;
|
||||||
|
|
||||||
final _selectedColorValue = ValueNotifier(0);
|
late final _selectedColorValue = ValueNotifier(_setting.primaryColor.fetch());
|
||||||
final _nightMode = ValueNotifier(0);
|
late final _nightMode = ValueNotifier(_setting.themeMode.fetch());
|
||||||
final _maxRetryCount = ValueNotifier(0);
|
late final _maxRetryCount = ValueNotifier(_setting.maxRetryCount.fetch());
|
||||||
final _updateInterval = ValueNotifier(0);
|
late final _updateInterval =
|
||||||
final _termFontSize = ValueNotifier(0.0);
|
ValueNotifier(_setting.serverStatusUpdateInterval.fetch());
|
||||||
final _editorFontSize = ValueNotifier(0.0);
|
late final _termFontSize = ValueNotifier(_setting.termFontSize.fetch());
|
||||||
final _localeCode = ValueNotifier('');
|
late final _editorFontSize = ValueNotifier(_setting.editorFontSize.fetch());
|
||||||
final _editorTheme = ValueNotifier('');
|
late final _localeCode = ValueNotifier('');
|
||||||
final _editorDarkTheme = ValueNotifier('');
|
late final _editorTheme = ValueNotifier(_setting.editorTheme.fetch());
|
||||||
final _keyboardType = ValueNotifier(0);
|
late final _editorDarkTheme = ValueNotifier(_setting.editorDarkTheme.fetch());
|
||||||
final _rotateQuarter = ValueNotifier(0);
|
late final _keyboardType = ValueNotifier(_setting.keyboardType.fetch());
|
||||||
final _netViewType = ValueNotifier(NetViewType.speed);
|
late final _rotateQuarter =
|
||||||
|
ValueNotifier(_setting.fullScreenRotateQuarter.fetch());
|
||||||
|
late final _netViewType = ValueNotifier(_setting.netViewType.fetch());
|
||||||
late final _textScaler = ValueNotifier(_setting.textFactor.fetch());
|
late final _textScaler = ValueNotifier(_setting.textFactor.fetch());
|
||||||
|
|
||||||
@override
|
@override
|
||||||
@@ -81,22 +83,6 @@ class _SettingPageState extends State<SettingPage> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
|
||||||
void initState() {
|
|
||||||
super.initState();
|
|
||||||
_nightMode.value = _setting.themeMode.fetch();
|
|
||||||
_updateInterval.value = _setting.serverStatusUpdateInterval.fetch();
|
|
||||||
_maxRetryCount.value = _setting.maxRetryCount.fetch();
|
|
||||||
_selectedColorValue.value = _setting.primaryColor.fetch();
|
|
||||||
_termFontSize.value = _setting.termFontSize.fetch();
|
|
||||||
_editorFontSize.value = _setting.editorFontSize.fetch();
|
|
||||||
_editorTheme.value = _setting.editorTheme.fetch();
|
|
||||||
_editorDarkTheme.value = _setting.editorDarkTheme.fetch();
|
|
||||||
_keyboardType.value = _setting.keyboardType.fetch();
|
|
||||||
_rotateQuarter.value = _setting.fullScreenRotateQuarter.fetch();
|
|
||||||
_netViewType.value = _setting.netViewType.fetch();
|
|
||||||
}
|
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
|
|||||||
Reference in New Issue
Block a user