My app shows modal dialog using "NSApp runModalForWindow". It seems Stage Manager can't switch apps while showing modal dialog in one operation. The behavior of this issue was different from now in macOS 13.0. Here is the steps.
Steps:
-
Make two sample apps (I used IKEH's sample - https://github.com/pommdau/Qiita_ModalWindowSample)
-
Enable Stage Manager
-
Run "sample app1" and "sample app 2"
-
Switch to "sample app 1" by "Recent applications" and show modal dialog (Click "Open Modal Window")
-
Switch to "sample app 2" by "Recent applications" and show modal dialog
-
Try switching to "sample app 1" again by "Recent applications"
--> Fails (cannot switch "sample app 1")
-
Try switching to "sample app 1" again by "Recent applications"
--> Succeeds (able to switch "sample app 1")
note) By using "NSWindow beginSheet" instead of "NSApp runModalForWindow", I can switch.
Is this issue of "NSApp runModalForWindow" OS bug ? Or is the problem with how the API is useds ? Has Anyone had the same issue or knows a workaround?