Skip to content

Commit

Permalink
fix: Black window flash when starting the app (#1003)
Browse files Browse the repository at this point in the history
  • Loading branch information
karniv00l authored Jan 2, 2024
1 parent 7e1005d commit 02e44fc
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -58,15 +58,6 @@ Future<void> main(List<String> rawArgs) async {
await DesktopTools.window.setPreventClose(true);
}

await DesktopTools.ensureInitialized(
DesktopWindowOptions(
hideTitleBar: true,
title: "Spotube",
backgroundColor: Colors.transparent,
minimumSize: const Size(300, 700),
),
);

await SystemTheme.accentColor.load();

if (!kIsWeb) {
Expand Down Expand Up @@ -107,6 +98,15 @@ Future<void> main(List<String> rawArgs) async {
path: hiveCacheDir,
);

await DesktopTools.ensureInitialized(
DesktopWindowOptions(
hideTitleBar: true,
title: "Spotube",
backgroundColor: Colors.transparent,
minimumSize: const Size(300, 700),
),
);

Catcher2(
enableLogger: arguments["verbose"],
debugConfig: Catcher2Options(
Expand Down

0 comments on commit 02e44fc

Please sign in to comment.