mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-01-13 11:38:31 +08:00
fix(notifs): Hopefully prevent gc of NodeObjC objects
This commit is contained in:
parent
417a9a0f10
commit
52ea696810
1 changed files with 4 additions and 0 deletions
|
@ -23,6 +23,10 @@ class NativeNotificationManagerMacOSX
|
|||
@_delegate = Delegate('alloc')('init')
|
||||
@_center('setDelegate', @_delegate)
|
||||
|
||||
# Ensure that these objects are never, ever garbage collected
|
||||
global.__nativeNotificationManagerMacOSXDelegate = Delegate
|
||||
global.__nativeNotificationManagerMacOSX = @
|
||||
|
||||
ipc.on('fire-native-notification', @onFireNotification)
|
||||
|
||||
shouldPresentNotification: (self, _cmd, center, notif) =>
|
||||
|
|
Loading…
Reference in a new issue