diff --git a/SUBasicUpdateDriver.m b/SUBasicUpdateDriver.m index 29c6ac23..50a25268 100644 --- a/SUBasicUpdateDriver.m +++ b/SUBasicUpdateDriver.m @@ -154,7 +154,7 @@ if ([[updater delegate] respondsToSelector:@selector(updater:didFindValidUpdate:)]) [[updater delegate] updater:updater didFindValidUpdate:updateItem]; NSDictionary *userInfo = (updateItem != nil) ? @{SUUpdaterAppcastItemNotificationKey : updateItem} : nil; - [[NSNotificationCenter defaultCenter] postNotificationName:SUUpdaterDidFinishLoadingAppCastNotification object:updater userInfo:userInfo]; + [[NSNotificationCenter defaultCenter] postNotificationName:SUUpdaterDidFindValidUpdateNotification object:updater userInfo:userInfo]; [self downloadUpdate]; } diff --git a/SUConstants.h b/SUConstants.h index b755ca58..c6126a8b 100644 --- a/SUConstants.h +++ b/SUConstants.h @@ -33,8 +33,6 @@ // Notifications: // ----------------------------------------------------------------------------- -extern NSString *const SUUpdaterWillRestartNotification; - extern NSString *const SUTechnicalErrorInformationKey; // ----------------------------------------------------------------------------- diff --git a/SUConstants.m b/SUConstants.m index d08b3c2a..832391ef 100644 --- a/SUConstants.m +++ b/SUConstants.m @@ -13,7 +13,6 @@ #import "SUVersionComparisonProtocol.h" #import "SUConstants.h" -NSString *const SUUpdaterWillRestartNotification = @"SUUpdaterWillRestartNotificationName"; NSString *const SUTechnicalErrorInformationKey = @"SUTechnicalErrorInformation"; NSString *const SUHasLaunchedBeforeKey = @"SUHasLaunchedBefore"; diff --git a/SUUpdater.h b/SUUpdater.h index d044b132..4992c66e 100644 --- a/SUUpdater.h +++ b/SUUpdater.h @@ -80,10 +80,11 @@ extern NSString *const SUUpdaterDidFinishLoadingAppCastNotification; extern NSString *const SUUpdaterDidFindValidUpdateNotification; extern NSString *const SUUpdaterDidNotFindUpdateNotification; -extern NSString *const SUUpdaterWillInstallUpdateNotification; -extern NSString *const SUUpdaterWillRelaunchApplicationNotification; +extern NSString *const SUUpdaterWillRestartNotification; +#define SUUpdaterWillRelaunchApplicationNotification SUUpdaterWillRestartNotification; +#define SUUpdaterWillInstallUpdateNotification SUUpdaterWillRestartNotification; -// Key for the SUAppcastItem object in the SUUpdaterDidFindValidUpdateNotification & SUUpdaterWillInstallUpdateNotification userInfos +// Key for the SUAppcastItem object in the SUUpdaterDidFindValidUpdateNotification userInfo extern NSString *const SUUpdaterAppcastItemNotificationKey; // Key for the SUAppcast object in the SUUpdaterDidFinishLoadingAppCastNotification userInfo extern NSString *const SUUpdaterAppcastNotificationKey; diff --git a/SUUpdater.m b/SUUpdater.m index 69f43986..dc0135c6 100644 --- a/SUUpdater.m +++ b/SUUpdater.m @@ -23,8 +23,7 @@ NSString *const SUUpdaterDidFinishLoadingAppCastNotification = @"SUUpdaterDidFinishLoadingAppCastNotification"; NSString *const SUUpdaterDidFindValidUpdateNotification = @"SUUpdaterDidFindValidUpdateNotification"; NSString *const SUUpdaterDidNotFindUpdateNotification = @"SUUpdaterDidNotFindUpdateNotification"; -NSString *const SUUpdaterWillInstallUpdateNotification = @"SUUpdaterWillInstallUpdateNotification"; -NSString *const SUUpdaterWillRelaunchApplicationNotification = @"SUUpdaterWillRelaunchApplicationNotification"; +NSString *const SUUpdaterWillRestartNotification = @"SUUpdaterWillRestartNotificationName"; NSString *const SUUpdaterAppcastItemNotificationKey = @"SUUpdaterAppcastItemNotificationKey"; NSString *const SUUpdaterAppcastNotificationKey = @"SUUpdaterAppCastNotificationKey";