From 02c3a9031a5bffa26e4d1d97267a64ae390d5989 Mon Sep 17 00:00:00 2001 From: Yannick Mauray Date: Thu, 27 Jun 2024 20:35:52 +0200 Subject: [PATCH] feat: set window size --- lib/main.dart | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/lib/main.dart b/lib/main.dart index 35ed604..131447a 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -74,8 +74,14 @@ Future getIcons() async { void main() async { WidgetsFlutterBinding.ensureInitialized(); // Don't forget to also change the size in linux/my_application.cc:50 - setWindowMinSize(const Size(692, 580)); - setWindowMaxSize(const Size(692, 580)); + // Don't forget to also change the size in macos/Runner/MainFlutterWindow.swift:7 + if (Platform.isMacOS) { + setWindowMinSize(const Size(692 + 2, 580 + 30)); + setWindowMaxSize(const Size(692 + 2, 580 + 30)); + } else { + setWindowMinSize(const Size(692, 580)); + setWindowMaxSize(const Size(692, 580)); + } final foundQuickGet = await Process.run('which', ['quickget']); if (foundQuickGet.exitCode == 0) { gOperatingSystems = loadOperatingSystems(false);