Skip to content

Commit

Permalink
revert back to old window_on_top, it works fine in my test
Browse files Browse the repository at this point in the history
  • Loading branch information
rustdesk committed Jul 7, 2023
1 parent 53fdddb commit 685d960
Showing 1 changed file with 3 additions and 12 deletions.
15 changes: 3 additions & 12 deletions flutter/lib/common.dart
Original file line number Diff line number Diff line change
Expand Up @@ -552,18 +552,9 @@ void window_on_top(int? id) async {
if (id == null) {
print("Bring window on top");
// main window
if (!Platform.isMacOS && desktopType == DesktopType.cm &&
!(await windowManager.isMinimized() ||
!await windowManager.isVisible())) {
await windowManager.setAlwaysOnTop(true);
Future.delayed(Duration(microseconds: 500), () async {
windowManager.setAlwaysOnTop(false);
});
} else {
windowManager.restore();
windowManager.show();
windowManager.focus();
}
windowManager.restore();
windowManager.show();
windowManager.focus();
rustDeskWinManager.registerActiveWindow(kWindowMainId);
} else {
WindowController.fromWindowId(id)
Expand Down

0 comments on commit 685d960

Please sign in to comment.