Fix circular locking in prompts (#6456)

Sometimes Cocoa calls app delegate methods (notably the display link)
while we're calling Cocoa methods. This causes a deadlock unless we
are careful to run cocao methods while we're not holding our internal
locks

Release Notes:

- Fixed a crash when opening the MacOS Save As dialogue.
865369882eConrad Irwin committed on 1/25/2024, 3:10:32 AM· committed by GitHubparentsa181dc8249a6da
1 file changedLine totals unavailable