antler119 / system_tray

A Flutter package that makes it easy to customize and work with your Flutter desktop app's system tray.
MIT License
214 stars 51 forks source link

Is there any way to force the app window to come to the foreground when shown? #49

Open Kevin-McKee opened 2 years ago

Kevin-McKee commented 2 years ago

When showing/popping up a message, is there any way to force it to come to the foreground? Sometimes it does, but other times I just get a blinking icon on the taskbar which I have to click on in order to bring the window to the foreground

BlakeMines commented 1 year ago

MacOS: For bitsdojo_window: You can use the package bitsdojo_window, then navigate to project>macos>Runner>MainFlutterWindow.swift and add the line "self.level = .floating" in the "override func bitsdojo_window_configure()" function body inside of the MainFlutterWindow class. Any OS: For window_manager: window_manager contains the built-in feature to set the window to always show on top.