summaryrefslogtreecommitdiff
path: root/src/macos.m
diff options
context:
space:
mode:
Diffstat (limited to 'src/macos.m')
-rw-r--r--src/macos.m22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/macos.m b/src/macos.m
index 35594b7b..cfbca488 100644
--- a/src/macos.m
+++ b/src/macos.m
@@ -709,3 +709,25 @@ iColor systemAccent_Color(void) {
709#endif 709#endif
710 return (iColor){ 255, 255, 255, 255 }; 710 return (iColor){ 255, 255, 255, 255 };
711} 711}
712
713#if defined (LAGRANGE_ENABLE_SPARKLE)
714#import <Sparkle/Sparkle.h>
715
716void init_Updater(void) {
717 SUUpdater *updater = [SUUpdater sharedUpdater];
718 /* Add it to the menu. */
719 NSMenu *appMenu = [[[NSApp mainMenu] itemAtIndex:0] submenu];
720 NSMenuItem *item = [appMenu insertItemWithTitle:@"Check for Updates…"
721 action:@selector(checkForUpdates:)
722 keyEquivalent:@""
723 atIndex:3];
724 item.target = updater;
725}
726
727#else
728/* dummy as a fallback */
729void init_Updater(void) {}
730#endif
731
732void deinit_Updater(void) {}
733void checkNow_Updater(void) {}