migrate: fl_lib v235

This commit is contained in:
lollipopkit🏳️‍⚧️
2025-01-13 21:57:12 +08:00
parent 0ae0241800
commit 4777166dd9
7 changed files with 54 additions and 55 deletions

View File

@@ -3,6 +3,6 @@
abstract class BuildData {
static const String name = "ServerBox";
static const int build = 1124;
static const int build = 1123;
static const int script = 59;
}

View File

@@ -49,14 +49,14 @@ class _ServerPageState extends State<ServerPage>
bool _useDoubleColumn = false;
final _scrollController = ScrollController();
final _autoHideKey = GlobalKey<AutoHideState>();
final _autoHideCtrl = AutoHideController();
@override
void dispose() {
super.dispose();
_timer?.cancel();
_scrollController.dispose();
_autoHideKey.currentState?.dispose();
_autoHideCtrl.dispose();
_tag.dispose();
}
@@ -105,7 +105,7 @@ class _ServerPageState extends State<ServerPage>
),
body: GestureDetector(
behavior: HitTestBehavior.opaque,
onTap: () => _autoHideKey.currentState?.show(),
onTap: () => _autoHideCtrl.show(),
child: ListenableBuilder(
listenable: Stores.setting.textFactor.listenable(),
builder: (_, __) {
@@ -115,10 +115,10 @@ class _ServerPageState extends State<ServerPage>
),
),
floatingActionButton: AutoHide(
key: _autoHideKey,
direction: AxisDirection.right,
offset: 75,
controller: _scrollController,
scrollController: _scrollController,
hideController: _autoHideCtrl,
child: FloatingActionButton(
heroTag: 'addServer',
onPressed: () => ServerEditPage.route.go(context),

View File

@@ -392,19 +392,10 @@ final class _AppSettingsPageState extends State<AppSettingsPage> {
)
];
if (!_setting.useSystemPrimaryColor.fetch()) {
children.addAll([
Input(
onSubmitted: _onSaveColor,
controller: ctrl,
hint: '#8b2252',
icon: Icons.colorize,
suggestion: false,
),
ColorPicker(
color: Color(_setting.colorSeed.fetch()),
onColorChanged: (c) => ctrl.text = c.toHex,
)
]);
children.add(ColorPicker(
color: Color(_setting.colorSeed.fetch()),
onColorChanged: (c) => ctrl.text = c.toHex,
));
}
return Column(
mainAxisSize: MainAxisSize.min,