🐛 Fix windows title bar issue

This commit is contained in:
LittleSheep 2024-09-01 17:36:21 +08:00
parent 710ab755fc
commit ed7b69f7b3
2 changed files with 5 additions and 4 deletions

View File

@ -66,7 +66,7 @@ class RhythmApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return GetMaterialApp.router(
title: 'DietaryGuard',
title: 'RhythmBox',
routerDelegate: router.routerDelegate,
routeInformationParser: router.routeInformationParser,
routeInformationProvider: router.routeInformationProvider,

View File

@ -39,11 +39,12 @@ class WindowManagerTools with WidgetsBindingObserver {
WidgetsBinding.instance.addObserver(instance);
await windowManager.waitUntilReadyToShow(
const WindowOptions(
WindowOptions(
title: 'RhythmBox',
backgroundColor: Colors.transparent,
minimumSize: Size(300, 700),
titleBarStyle: TitleBarStyle.hidden,
minimumSize: const Size(300, 700),
titleBarStyle:
PlatformInfo.isMacOS ? TitleBarStyle.hidden : TitleBarStyle.normal,
center: true,
),
() async {