mirror of
https://github.com/lil-org/tokenary.git
synced 2025-01-07 14:10:28 +03:00
Avoid moving active space when trying to quit macOS app
This commit is contained in:
parent
9553ed98f5
commit
9a377eea61
@ -160,11 +160,14 @@ class Agent: NSObject {
|
||||
alert.alertStyle = .warning
|
||||
alert.addButton(withTitle: Strings.ok)
|
||||
alert.addButton(withTitle: Strings.cancel)
|
||||
if alert.runModal() == .alertFirstButtonReturn {
|
||||
NSApp.terminate(nil)
|
||||
}
|
||||
if updateStatusBarAfterwards {
|
||||
setupStatusBarItem()
|
||||
|
||||
DispatchQueue.main.async { [weak self] in
|
||||
if alert.runModal() == .alertFirstButtonReturn {
|
||||
NSApp.terminate(nil)
|
||||
}
|
||||
if updateStatusBarAfterwards {
|
||||
self?.setupStatusBarItem()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user