Is there a way to change my app icon dynamically when switching between Dark/Light Mode in macOS Mojave?
I wish to change the icon appearance to appear appropriately in system alerts and notifications.
Is there a way to change my app icon dynamically when switching between Dark/Light Mode in macOS Mojave?
I wish to change the icon appearance to appear appropriately in system alerts and notifications.
It seems like your best bet is to handle the icon change yourself: listen to appearance change notifications, and update the icon accordingly.
To set the Dock icon:
NSImage
to NSApp.applicationIconImage
. However, this only works when the app is running, and the change is cleared when the app quits.© 2022 - 2024 — McMap. All rights reserved.