mirror of
https://github.com/lollipopkit/flutter_server_box.git
synced 2026-01-31 21:34:45 +01:00
fix: bakPath & lib l10n
This commit is contained in:
@@ -77,11 +77,9 @@ class MyApp extends StatelessWidget {
|
||||
|
||||
Widget _buildAppContent(BuildContext ctx) {
|
||||
//if (Pros.app.isWearOS) return const WearHome();
|
||||
ctx.setLibL10n();
|
||||
return const HomePage();
|
||||
}
|
||||
|
||||
// bool _isSmallDevice(BuildContext ctx) =>
|
||||
// MediaQuery.of(ctx).size.shortestSide < 600;
|
||||
}
|
||||
|
||||
void _setup(BuildContext context) async {
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
class BuildData {
|
||||
static const String name = "ServerBox";
|
||||
static const int build = 910;
|
||||
static const int build = 911;
|
||||
static const String engine = "3.22.0";
|
||||
static const String buildAt = "2024-05-23 19:27:43";
|
||||
static const String buildAt = "2024-05-23 20:06:43";
|
||||
static const int modifications = 2;
|
||||
static const int script = 48;
|
||||
}
|
||||
|
||||
@@ -64,7 +64,7 @@ void _runInZone(void Function() body) {
|
||||
Future<void> _initApp() async {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
|
||||
await Paths.init(BuildData.name);
|
||||
await Paths.init(BuildData.name, bakName: 'srvbox');
|
||||
await _initData();
|
||||
_setupDebug();
|
||||
|
||||
|
||||
@@ -159,14 +159,19 @@ class _SnippetEditPageState extends State<SnippetEditPage>
|
||||
child: ValBuilder(
|
||||
listenable: _autoRunOn,
|
||||
builder: (vals) {
|
||||
final subtitle = vals.isEmpty
|
||||
? null
|
||||
: vals
|
||||
.map((e) => Pros.server.pick(id: e)?.spi.name ?? e)
|
||||
.join(', ');
|
||||
return ListTile(
|
||||
leading: const Icon(Icons.settings_remote, size: 19),
|
||||
title: Text(l10n.autoRun),
|
||||
trailing: const Icon(Icons.keyboard_arrow_right),
|
||||
subtitle: vals.isEmpty
|
||||
subtitle: subtitle == null
|
||||
? null
|
||||
: Text(
|
||||
vals.join(', '),
|
||||
subtitle,
|
||||
maxLines: 1,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
),
|
||||
@@ -175,7 +180,9 @@ class _SnippetEditPageState extends State<SnippetEditPage>
|
||||
final serverIds = await context.showPickDialog(
|
||||
title: l10n.autoRun,
|
||||
items: Pros.server.serverOrder,
|
||||
name: (e) => Pros.server.pick(id: e)?.spi.name ?? e,
|
||||
initial: vals,
|
||||
clearable: true,
|
||||
);
|
||||
if (serverIds != null) {
|
||||
_autoRunOn.value = serverIds;
|
||||
|
||||
Reference in New Issue
Block a user