diff --git a/Sparkle/SUAppcastItem.h b/Sparkle/SUAppcastItem.h index e4c2a06d..86843bfb 100644 --- a/Sparkle/SUAppcastItem.h +++ b/Sparkle/SUAppcastItem.h @@ -32,6 +32,7 @@ SU_EXPORT @interface SUAppcastItem : NSObject @property (getter=isDeltaUpdate, readonly) BOOL deltaUpdate; @property (getter=isCriticalUpdate, readonly) BOOL criticalUpdate; +@property (getter=isInformationOnlyUpdate, readonly) BOOL informationOnlyUpdate; // Returns the dictionary provided in initWithDictionary; this might be useful later for extensions. @property (readonly, copy) NSDictionary *propertiesDictionary; diff --git a/Sparkle/SUAppcastItem.m b/Sparkle/SUAppcastItem.m index 2a11f247..67eeee07 100644 --- a/Sparkle/SUAppcastItem.m +++ b/Sparkle/SUAppcastItem.m @@ -55,6 +55,11 @@ return [self.propertiesDictionary[SUAppcastElementTags] containsObject:SUAppcastElementCriticalUpdate]; } +- (BOOL)isInformationOnlyUpdate +{ + return (([self infoURL] != nil) && ([self fileURL] == nil)); +} + - (instancetype)initWithDictionary:(NSDictionary *)dict { return [self initWithDictionary:dict failureReason:nil]; diff --git a/Sparkle/SUUpdateAlert.m b/Sparkle/SUUpdateAlert.m index 6338956d..a386c716 100644 --- a/Sparkle/SUUpdateAlert.m +++ b/Sparkle/SUUpdateAlert.m @@ -186,7 +186,7 @@ [self.window setLevel:NSFloatingWindowLevel]; // This means the window will float over all other apps, if our app is switched out ?! } - if ([self.updateItem fileURL] == nil) { + if (self.updateItem.isInformationOnlyUpdate) { [self.installButton setTitle:SULocalizedString(@"Learn More...", @"Alternate title for 'Install Update' button when there's no download in RSS feed.")]; [self.installButton setAction:@selector(openInfoURL:)]; }