Refine Menu Bar Only mode behavior and fix observer leak
This commit is contained in:
parent
b4b3920bc3
commit
3d52cb6fe8
@ -25,6 +25,10 @@ class MenuBarManager: ObservableObject {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
NotificationCenter.default.removeObserver(self)
|
||||||
|
}
|
||||||
|
|
||||||
@objc private func windowDidClose(_ notification: Notification) {
|
@objc private func windowDidClose(_ notification: Notification) {
|
||||||
guard isMenuBarOnly else { return }
|
guard isMenuBarOnly else { return }
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user