This commit is contained in:
lollipopkit🏳️‍⚧️
2024-09-21 23:12:15 +08:00
parent c062c12a0e
commit eab06abcaf
23 changed files with 180 additions and 66 deletions

View File

@@ -62,6 +62,12 @@ class _ServerDetailPageState extends State<ServerDetailPage>
late final _collapse = _settings.collapseUIDefault.fetch();
late final _textFactor = TextScaler.linear(_settings.textFactor.fetch());
@override
void dispose() {
super.dispose();
_netSortType.dispose();
}
@override
void didChangeDependencies() {
super.didChangeDependencies();

View File

@@ -72,12 +72,6 @@ class _ServerEditPageState extends State<ServerEditPage> with AfterLayoutMixin {
_portController.dispose();
_usernameController.dispose();
_passwordController.dispose();
_nameFocus.dispose();
_ipFocus.dispose();
_alterUrlFocus.dispose();
_portFocus.dispose();
_usernameFocus.dispose();
_pveAddrCtrl.dispose();
_preferTempDevCtrl.dispose();
_logoUrlCtrl.dispose();
_wolMacCtrl.dispose();
@@ -85,6 +79,21 @@ class _ServerEditPageState extends State<ServerEditPage> with AfterLayoutMixin {
_wolPwdCtrl.dispose();
_netDevCtrl.dispose();
_scriptDirCtrl.dispose();
_nameFocus.dispose();
_ipFocus.dispose();
_alterUrlFocus.dispose();
_portFocus.dispose();
_usernameFocus.dispose();
_pveAddrCtrl.dispose();
_keyIdx.dispose();
_autoConnect.dispose();
_jumpServer.dispose();
_pveIgnoreCert.dispose();
_env.dispose();
_customCmds.dispose();
_tags.dispose();
}
@override

View File

@@ -51,6 +51,15 @@ class _ServerPageState extends State<ServerPage>
final _scrollController = ScrollController();
final _autoHideKey = GlobalKey<AutoHideState>();
@override
void dispose() {
super.dispose();
_timer?.cancel();
_scrollController.dispose();
_autoHideKey.currentState?.dispose();
_tag.dispose();
}
@override
void initState() {
super.initState();

View File

@@ -14,15 +14,34 @@ final class _TopBar extends StatelessWidget implements PreferredSizeWidget {
@override
Widget build(BuildContext context) {
return Padding(
padding: const EdgeInsets.only(left: 17),
padding: const EdgeInsets.only(left: 10),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
const Center(
child: Text(
BuildData.name,
style: TextStyle(fontSize: 20),
textAlign: TextAlign.center,
Center(
child: InkWell(
borderRadius: BorderRadius.circular(13),
onTap: () => DebugPage.route.go(
context,
args: const DebugPageArgs(title: 'Logs(${BuildData.build})'),
),
child: const Padding(
padding: EdgeInsets.symmetric(horizontal: 7),
child: Row(
children: [
Text(
BuildData.name,
style: TextStyle(fontSize: 20),
textAlign: TextAlign.center,
),
Icon(
Icons.keyboard_arrow_right,
color: Colors.grey,
size: 17,
),
],
),
),
),
),
const SizedBox(width: 30),