mirror of https://github.com/borgbase/vorta
Limit objc dependency. Fix maximize issue.
This commit is contained in:
parent
20ab578a17
commit
57c0c4d47b
|
@ -38,7 +38,7 @@ install_requires =
|
|||
keyring
|
||||
apscheduler
|
||||
sentry-sdk
|
||||
pyobjc-framework-Cocoa
|
||||
pyobjc-framework-Cocoa; sys_platform == 'darwin'
|
||||
tests_require =
|
||||
pytest
|
||||
pytest-qt
|
||||
|
|
|
@ -25,7 +25,8 @@ class DarwinNotifications(VortaNotifications):
|
|||
notification.setTitle_(title)
|
||||
notification.setInformativeText_(text)
|
||||
center = NSUserNotificationCenter.defaultUserNotificationCenter()
|
||||
center.deliverNotification_(notification)
|
||||
if center is not None: # Only works when run from app bundle.
|
||||
center.deliverNotification_(notification)
|
||||
|
||||
|
||||
class LinuxNotifications(VortaNotifications):
|
||||
|
|
Loading…
Reference in New Issue