Revert "Removed Sparkle"

This reverts commit b54ee58ec3.
swiftingly
Christopher Snowhill 2022-06-21 18:00:30 -07:00
parent bc9e7b5d67
commit d59b5335e9
189 changed files with 7504 additions and 17 deletions

View File

@ -7,6 +7,7 @@
@class PlaylistController; @class PlaylistController;
@class PlaylistView; @class PlaylistView;
@class PlaylistLoader; @class PlaylistLoader;
@class SUUpdater;
@interface AppController : NSObject { @interface AppController : NSObject {
IBOutlet NSObjectController *currentEntryController; IBOutlet NSObjectController *currentEntryController;
@ -47,6 +48,8 @@
IBOutlet FileTreeViewController *fileTreeViewController; IBOutlet FileTreeViewController *fileTreeViewController;
IBOutlet SUUpdater *updater;
NSOperationQueue *queue; // Since we are the app delegate, we take care of the op queue NSOperationQueue *queue; // Since we are the app delegate, we take care of the op queue
NSMutableSet *expandedNodes; NSMutableSet *expandedNodes;

View File

@ -28,6 +28,8 @@
#import "Shortcuts.h" #import "Shortcuts.h"
#import <MASShortcut/Shortcut.h> #import <MASShortcut/Shortcut.h>
#import <Sparkle/Sparkle.h>
@import Firebase; @import Firebase;
void *kAppControllerContext = &kAppControllerContext; void *kAppControllerContext = &kAppControllerContext;
@ -149,6 +151,11 @@ BOOL kAppControllerShuttingDown = NO;
[FIRApp configure]; [FIRApp configure];
[FIRAnalytics setAnalyticsCollectionEnabled:YES]; [FIRAnalytics setAnalyticsCollectionEnabled:YES];
#ifdef DEBUG
// Prevent updates automatically in debug builds
[updater setAutomaticallyChecksForUpdates:NO];
#endif
[[totalTimeField cell] setBackgroundStyle:NSBackgroundStyleRaised]; [[totalTimeField cell] setBackgroundStyle:NSBackgroundStyleRaised];
[self.infoButton setToolTip:NSLocalizedString(@"InfoButtonTooltip", @"")]; [self.infoButton setToolTip:NSLocalizedString(@"InfoButtonTooltip", @"")];

View File

@ -20,22 +20,22 @@
<rect key="contentRect" x="331" y="367" width="1000" height="400"/> <rect key="contentRect" x="331" y="367" width="1000" height="400"/>
<rect key="screenRect" x="0.0" y="0.0" width="1920" height="1055"/> <rect key="screenRect" x="0.0" y="0.0" width="1920" height="1055"/>
<value key="minSize" type="size" width="750" height="200"/> <value key="minSize" type="size" width="750" height="200"/>
<stackView key="contentView" distribution="equalSpacing" orientation="vertical" alignment="centerX" spacing="0.0" misplaced="YES" detachesHiddenViews="YES" id="2"> <stackView key="contentView" distribution="equalSpacing" orientation="vertical" alignment="centerX" spacing="0.0" detachesHiddenViews="YES" id="2">
<rect key="frame" x="0.0" y="0.0" width="1000" height="400"/> <rect key="frame" x="0.0" y="0.0" width="1015" height="400"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews> <subviews>
<splitView dividerStyle="thin" vertical="YES" translatesAutoresizingMaskIntoConstraints="NO" id="2123"> <splitView dividerStyle="thin" vertical="YES" translatesAutoresizingMaskIntoConstraints="NO" id="2123">
<rect key="frame" x="0.0" y="354" width="1015" height="46"/> <rect key="frame" x="0.0" y="350" width="1015" height="50"/>
<subviews> <subviews>
<scrollView fixedFrame="YES" borderType="none" autohidesScrollers="YES" horizontalLineScroll="24" horizontalPageScroll="0.0" verticalLineScroll="24" verticalPageScroll="0.0" hasHorizontalScroller="NO" usesPredominantAxisScrolling="NO" id="206" userLabel="Scroll View - Playlist View"> <scrollView fixedFrame="YES" borderType="none" autohidesScrollers="YES" horizontalLineScroll="24" horizontalPageScroll="0.0" verticalLineScroll="24" verticalPageScroll="0.0" hasHorizontalScroller="NO" usesPredominantAxisScrolling="NO" id="206" userLabel="Scroll View - Playlist View">
<rect key="frame" x="0.0" y="0.0" width="1015" height="46"/> <rect key="frame" x="0.0" y="0.0" width="1015" height="50"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<clipView key="contentView" drawsBackground="NO" copiesOnScroll="NO" id="KWC-Ti-8KY"> <clipView key="contentView" drawsBackground="NO" copiesOnScroll="NO" id="KWC-Ti-8KY">
<rect key="frame" x="0.0" y="0.0" width="1015" height="46"/> <rect key="frame" x="0.0" y="0.0" width="1015" height="50"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews> <subviews>
<tableView focusRingType="none" verticalHuggingPriority="750" allowsExpansionToolTips="YES" alternatingRowBackgroundColors="YES" autosaveName="Playlist" rowHeight="18" headerView="1517" viewBased="YES" id="207" customClass="PlaylistView"> <tableView focusRingType="none" verticalHuggingPriority="750" allowsExpansionToolTips="YES" alternatingRowBackgroundColors="YES" autosaveName="Playlist" rowHeight="18" headerView="1517" viewBased="YES" id="207" customClass="PlaylistView">
<rect key="frame" x="0.0" y="0.0" width="1015" height="29"/> <rect key="frame" x="0.0" y="0.0" width="1015" height="33"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<size key="intercellSpacing" width="3" height="6"/> <size key="intercellSpacing" width="3" height="6"/>
<color key="backgroundColor" name="controlBackgroundColor" catalog="System" colorSpace="catalog"/> <color key="backgroundColor" name="controlBackgroundColor" catalog="System" colorSpace="catalog"/>
@ -188,7 +188,7 @@
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews> <subviews>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="ZWb-jm-i9i"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="ZWb-jm-i9i">
<rect key="frame" x="1" y="1" width="4" height="16"/> <rect key="frame" x="0.0" y="1" width="4" height="16"/>
<textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="3QN-Ok-QPu"> <textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="3QN-Ok-QPu">
<font key="font" usesAppearanceFont="YES"/> <font key="font" usesAppearanceFont="YES"/>
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
@ -229,11 +229,11 @@
<tableColumnResizingMask key="resizingMask" resizeWithTable="YES" userResizable="YES"/> <tableColumnResizingMask key="resizingMask" resizeWithTable="YES" userResizable="YES"/>
<prototypeCellViews> <prototypeCellViews>
<tableCellView id="gpC-Oe-Rog"> <tableCellView id="gpC-Oe-Rog">
<rect key="frame" x="235" y="3" width="149" height="18"/> <rect key="frame" x="234.5" y="3" width="149" height="18"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews> <subviews>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="1WK-qN-Mgj"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="1WK-qN-Mgj">
<rect key="frame" x="0.0" y="1" width="150" height="16"/> <rect key="frame" x="0.0" y="1" width="149" height="16"/>
<textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="71l-3L-S3g"> <textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="71l-3L-S3g">
<font key="font" usesAppearanceFont="YES"/> <font key="font" usesAppearanceFont="YES"/>
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
@ -316,11 +316,11 @@
<tableColumnResizingMask key="resizingMask" resizeWithTable="YES" userResizable="YES"/> <tableColumnResizingMask key="resizingMask" resizeWithTable="YES" userResizable="YES"/>
<prototypeCellViews> <prototypeCellViews>
<tableCellView id="hhB-nv-e78"> <tableCellView id="hhB-nv-e78">
<rect key="frame" x="541" y="3" width="95" height="18"/> <rect key="frame" x="540.5" y="3" width="95" height="18"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews> <subviews>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="tHy-sM-HDB"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="tHy-sM-HDB">
<rect key="frame" x="0.0" y="1" width="96" height="16"/> <rect key="frame" x="0.0" y="1" width="95" height="16"/>
<textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="Igo-5f-yim"> <textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="Igo-5f-yim">
<font key="font" usesAppearanceFont="YES"/> <font key="font" usesAppearanceFont="YES"/>
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
@ -401,7 +401,7 @@
<tableColumnResizingMask key="resizingMask" resizeWithTable="YES" userResizable="YES"/> <tableColumnResizingMask key="resizingMask" resizeWithTable="YES" userResizable="YES"/>
<prototypeCellViews> <prototypeCellViews>
<tableCellView id="rRl-p9-Awr"> <tableCellView id="rRl-p9-Awr">
<rect key="frame" x="736" y="3" width="144" height="18"/> <rect key="frame" x="735.5" y="3" width="144" height="18"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews> <subviews>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="yW6-2w-6mN"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="yW6-2w-6mN">
@ -441,11 +441,11 @@
<tableColumnResizingMask key="resizingMask" resizeWithTable="YES" userResizable="YES"/> <tableColumnResizingMask key="resizingMask" resizeWithTable="YES" userResizable="YES"/>
<prototypeCellViews> <prototypeCellViews>
<tableCellView id="hgh-VE-5kl"> <tableCellView id="hgh-VE-5kl">
<rect key="frame" x="883" y="3" width="38" height="18"/> <rect key="frame" x="882.5" y="3" width="38" height="18"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews> <subviews>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="yEY-MI-d3o"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="yEY-MI-d3o">
<rect key="frame" x="0.0" y="1" width="39" height="16"/> <rect key="frame" x="0.0" y="1" width="38" height="16"/>
<textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="tus-lr-RhS"> <textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="tus-lr-RhS">
<font key="font" usesAppearanceFont="YES"/> <font key="font" usesAppearanceFont="YES"/>
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
@ -485,7 +485,7 @@
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews> <subviews>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="QFJ-4l-2O6"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="QFJ-4l-2O6">
<rect key="frame" x="1" y="1" width="4" height="16"/> <rect key="frame" x="0.0" y="1" width="4" height="16"/>
<textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="gKK-cS-RP5"> <textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="gKK-cS-RP5">
<font key="font" usesAppearanceFont="YES"/> <font key="font" usesAppearanceFont="YES"/>
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
@ -529,7 +529,7 @@
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews> <subviews>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="Qvd-sk-vRc"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="Qvd-sk-vRc">
<rect key="frame" x="1" y="1" width="4" height="16"/> <rect key="frame" x="0.0" y="1" width="4" height="16"/>
<textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="YwT-z9-2d2"> <textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="YwT-z9-2d2">
<font key="font" usesAppearanceFont="YES"/> <font key="font" usesAppearanceFont="YES"/>
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
@ -573,7 +573,7 @@
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews> <subviews>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="gXW-DX-EsQ"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="gXW-DX-EsQ">
<rect key="frame" x="1" y="1" width="4" height="16"/> <rect key="frame" x="0.0" y="1" width="4" height="16"/>
<textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="vaJ-Bc-ebE"> <textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="vaJ-Bc-ebE">
<font key="font" usesAppearanceFont="YES"/> <font key="font" usesAppearanceFont="YES"/>
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
@ -1242,6 +1242,11 @@
<action selector="showWindow:" target="Hd4-Wy-Rfl" id="xfd-8T-SL4"/> <action selector="showWindow:" target="Hd4-Wy-Rfl" id="xfd-8T-SL4"/>
</connections> </connections>
</menuItem> </menuItem>
<menuItem title="Check for Updates..." id="302">
<connections>
<action selector="checkForUpdates:" target="1303" id="1304"/>
</connections>
</menuItem>
<menuItem isSeparatorItem="YES" id="1100"> <menuItem isSeparatorItem="YES" id="1100">
<modifierMask key="keyEquivalentModifierMask" command="YES"/> <modifierMask key="keyEquivalentModifierMask" command="YES"/>
</menuItem> </menuItem>
@ -2049,6 +2054,7 @@ Gw
<outlet property="shuffleButton" destination="1637" id="Nzr-Mw-z9P"/> <outlet property="shuffleButton" destination="1637" id="Nzr-Mw-z9P"/>
<outlet property="spotlightWindowController" destination="1675" id="1677"/> <outlet property="spotlightWindowController" destination="1675" id="1677"/>
<outlet property="totalTimeField" destination="778" id="1659"/> <outlet property="totalTimeField" destination="778" id="1659"/>
<outlet property="updater" destination="1303" id="gDn-jb-V0R"/>
</connections> </connections>
</customObject> </customObject>
<menu title="Menu" autoenablesItems="NO" id="513" userLabel="DockMenu"> <menu title="Menu" autoenablesItems="NO" id="513" userLabel="DockMenu">
@ -2308,6 +2314,7 @@ Gw
<point key="canvasLocation" x="-117" y="-407"/> <point key="canvasLocation" x="-117" y="-407"/>
</menu> </menu>
<customObject id="1217" userLabel="PreferencesController" customClass="PreferencesController"/> <customObject id="1217" userLabel="PreferencesController" customClass="PreferencesController"/>
<customObject id="1303" userLabel="SUUpdater" customClass="SUUpdater"/>
<customObject id="1319" userLabel="PlaylistLoader" customClass="PlaylistLoader"> <customObject id="1319" userLabel="PlaylistLoader" customClass="PlaylistLoader">
<connections> <connections>
<outlet property="playbackController" destination="705" id="EBV-A8-3bM"/> <outlet property="playbackController" destination="705" id="EBV-A8-3bM"/>

View File

@ -175,6 +175,8 @@
8384916C18083EAB00E7332D /* stopTemplate.pdf in Resources */ = {isa = PBXBuildFile; fileRef = 8384915618083EAB00E7332D /* stopTemplate.pdf */; }; 8384916C18083EAB00E7332D /* stopTemplate.pdf in Resources */ = {isa = PBXBuildFile; fileRef = 8384915618083EAB00E7332D /* stopTemplate.pdf */; };
8384916D18083EAB00E7332D /* volume1Template.pdf in Resources */ = {isa = PBXBuildFile; fileRef = 8384915718083EAB00E7332D /* volume1Template.pdf */; }; 8384916D18083EAB00E7332D /* volume1Template.pdf in Resources */ = {isa = PBXBuildFile; fileRef = 8384915718083EAB00E7332D /* volume1Template.pdf */; };
8384916E18083EAB00E7332D /* volume3Template.pdf in Resources */ = {isa = PBXBuildFile; fileRef = 8384915818083EAB00E7332D /* volume3Template.pdf */; }; 8384916E18083EAB00E7332D /* volume3Template.pdf in Resources */ = {isa = PBXBuildFile; fileRef = 8384915818083EAB00E7332D /* volume3Template.pdf */; };
838F851E256B4E5E00C3E614 /* Sparkle.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 838F851D256B4E5E00C3E614 /* Sparkle.framework */; };
838F851F256B4E8B00C3E614 /* Sparkle.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = 838F851D256B4E5E00C3E614 /* Sparkle.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
83978E16285C58190076ED21 /* FirebaseCrashlytics in Frameworks */ = {isa = PBXBuildFile; productRef = 83978E15285C58190076ED21 /* FirebaseCrashlytics */; }; 83978E16285C58190076ED21 /* FirebaseCrashlytics in Frameworks */ = {isa = PBXBuildFile; productRef = 83978E15285C58190076ED21 /* FirebaseCrashlytics */; };
83978E26285C596F0076ED21 /* FirebaseAnalytics in Frameworks */ = {isa = PBXBuildFile; productRef = 83978E25285C596F0076ED21 /* FirebaseAnalytics */; }; 83978E26285C596F0076ED21 /* FirebaseAnalytics in Frameworks */ = {isa = PBXBuildFile; productRef = 83978E25285C596F0076ED21 /* FirebaseAnalytics */; };
83978E29285C5C0A0076ED21 /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 83978E28285C5C0A0076ED21 /* GoogleService-Info.plist */; }; 83978E29285C5C0A0076ED21 /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 83978E28285C5C0A0076ED21 /* GoogleService-Info.plist */; };
@ -748,6 +750,7 @@
83B72E3B279045B7006007A3 /* libfdk-aac.2.dylib in CopyFiles */, 83B72E3B279045B7006007A3 /* libfdk-aac.2.dylib in CopyFiles */,
8305963C277F013200EBFAAE /* File_Extractor.framework in CopyFiles */, 8305963C277F013200EBFAAE /* File_Extractor.framework in CopyFiles */,
ED69CBCA25BE32E80090B90D /* MASShortcut.framework in CopyFiles */, ED69CBCA25BE32E80090B90D /* MASShortcut.framework in CopyFiles */,
838F851F256B4E8B00C3E614 /* Sparkle.framework in CopyFiles */,
17F561400C3BD4F30019975C /* CogAudio.framework in CopyFiles */, 17F561400C3BD4F30019975C /* CogAudio.framework in CopyFiles */,
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
@ -1021,6 +1024,7 @@
8384915818083EAB00E7332D /* volume3Template.pdf */ = {isa = PBXFileReference; lastKnownFileType = image.pdf; name = volume3Template.pdf; path = Images/volume3Template.pdf; sourceTree = "<group>"; }; 8384915818083EAB00E7332D /* volume3Template.pdf */ = {isa = PBXFileReference; lastKnownFileType = image.pdf; name = volume3Template.pdf; path = Images/volume3Template.pdf; sourceTree = "<group>"; };
83859520234FEB35004E9946 /* Cog.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = Cog.entitlements; sourceTree = "<group>"; }; 83859520234FEB35004E9946 /* Cog.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = Cog.entitlements; sourceTree = "<group>"; };
838F84FF25687C5C00C3E614 /* Cog-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Cog-Bridging-Header.h"; sourceTree = "<group>"; }; 838F84FF25687C5C00C3E614 /* Cog-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Cog-Bridging-Header.h"; sourceTree = "<group>"; };
838F851D256B4E5E00C3E614 /* Sparkle.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Sparkle.framework; path = ThirdParty/Frameworks/Sparkle.framework; sourceTree = "<group>"; };
83978E28285C5C0A0076ED21 /* GoogleService-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "GoogleService-Info.plist"; sourceTree = "<group>"; }; 83978E28285C5C0A0076ED21 /* GoogleService-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "GoogleService-Info.plist"; sourceTree = "<group>"; };
83988F0C27BE0A5900A0E89A /* RedundantPlaylistDataStore.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RedundantPlaylistDataStore.h; sourceTree = "<group>"; }; 83988F0C27BE0A5900A0E89A /* RedundantPlaylistDataStore.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RedundantPlaylistDataStore.h; sourceTree = "<group>"; };
83988F0D27BE0A5900A0E89A /* RedundantPlaylistDataStore.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RedundantPlaylistDataStore.m; sourceTree = "<group>"; }; 83988F0D27BE0A5900A0E89A /* RedundantPlaylistDataStore.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RedundantPlaylistDataStore.m; sourceTree = "<group>"; };
@ -1105,6 +1109,7 @@
83978E26285C596F0076ED21 /* FirebaseAnalytics in Frameworks */, 83978E26285C596F0076ED21 /* FirebaseAnalytics in Frameworks */,
17BB5CF90B8A86350009ACB1 /* AudioUnit.framework in Frameworks */, 17BB5CF90B8A86350009ACB1 /* AudioUnit.framework in Frameworks */,
17BB5CFA0B8A86350009ACB1 /* CoreAudio.framework in Frameworks */, 17BB5CFA0B8A86350009ACB1 /* CoreAudio.framework in Frameworks */,
838F851E256B4E5E00C3E614 /* Sparkle.framework in Frameworks */,
17BB5CFB0B8A86350009ACB1 /* CoreAudioKit.framework in Frameworks */, 17BB5CFB0B8A86350009ACB1 /* CoreAudioKit.framework in Frameworks */,
83978E16285C58190076ED21 /* FirebaseCrashlytics in Frameworks */, 83978E16285C58190076ED21 /* FirebaseCrashlytics in Frameworks */,
17BB5EA60B8A87850009ACB1 /* IOKit.framework in Frameworks */, 17BB5EA60B8A87850009ACB1 /* IOKit.framework in Frameworks */,
@ -1148,6 +1153,7 @@
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
ED69CBB825BE328C0090B90D /* MASShortcut.xcodeproj */, ED69CBB825BE328C0090B90D /* MASShortcut.xcodeproj */,
838F851D256B4E5E00C3E614 /* Sparkle.framework */,
17F5612A0C3BD4DC0019975C /* CogAudio.xcodeproj */, 17F5612A0C3BD4DC0019975C /* CogAudio.xcodeproj */,
1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */, 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */,
); );

View File

@ -0,0 +1 @@
Versions/Current/Autoupdate

View File

@ -0,0 +1 @@
Versions/Current/Headers

View File

@ -0,0 +1 @@
Versions/Current/Modules

View File

@ -0,0 +1 @@
Versions/Current/PrivateHeaders

View File

@ -0,0 +1 @@
Versions/Current/Resources

View File

@ -0,0 +1 @@
Versions/Current/Sparkle

View File

@ -0,0 +1 @@
Versions/Current/Updater.app

Binary file not shown.

View File

@ -0,0 +1,59 @@
//
// SPUDownloadData.h
// Sparkle
//
// Created by Mayur Pawashe on 8/10/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#ifdef BUILDING_SPARKLE_DOWNLOADER_SERVICE
// Ignore incorrect warning
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wquoted-include-in-framework-header"
#import "SUExport.h"
#pragma clang diagnostic pop
#else
#import <Sparkle/SUExport.h>
#endif
NS_ASSUME_NONNULL_BEGIN
/**
* A class for containing downloaded data along with some information about it.
*/
SU_EXPORT @interface SPUDownloadData : NSObject <NSSecureCoding>
/**
* The raw data that was downloaded.
*/
@property (nonatomic, readonly) NSData *data;
/**
* The URL that was fetched from.
*
* This may be different from the URL in the request if there were redirects involved.
*/
@property (nonatomic, readonly, copy) NSURL *URL;
/**
* The IANA charset encoding name if available. Eg: "utf-8"
*/
@property (nonatomic, readonly, nullable, copy) NSString *textEncodingName;
/**
* The MIME type if available. Eg: "text/plain"
*/
@property (nonatomic, readonly, nullable, copy) NSString *MIMEType;
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,116 @@
//
// SPUStandardUpdaterController.h
// Sparkle
//
// Created by Mayur Pawashe on 2/28/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
NS_ASSUME_NONNULL_BEGIN
@class SPUUpdater;
@class SPUStandardUserDriver;
@class NSMenuItem;
@protocol SPUUserDriver, SPUUpdaterDelegate, SPUStandardUserDriverDelegate;
/**
A controller class that instantiates a `SPUUpdater` and allows binding UI to its updater settings.
This class can be instantiated in a nib or created programatically using `-initWithUpdaterDelegate:userDriverDelegate:` or `-initWithStartingUpdater:updaterDelegate:userDriverDelegate:`.
The controller's updater targets the application's main bundle and uses Sparkle's standard user interface.
Typically, this class is used by sticking it as a custom NSObject subclass in an Interface Builder nib (probably in MainMenu) but it works well programatically too.
The controller creates an `SPUUpdater` instance using a `SPUStandardUserDriver` and allows hooking up the check for updates action and handling menu item validation.
It also allows hooking up the updater's and user driver's delegates.
If you need more control over what bundle you want to update, or you want to provide a custom user interface (via `SPUUserDriver`), please use `SPUUpdater` directly instead.
*/
SU_EXPORT @interface SPUStandardUpdaterController : NSObject
{
/**
* Interface builder outlet for the updater's delegate.
*/
IBOutlet __weak id<SPUUpdaterDelegate> updaterDelegate;
/**
* Interface builder outlet for the user driver's delegate.
*/
IBOutlet __weak id<SPUStandardUserDriverDelegate> userDriverDelegate;
}
/**
Accessible property for the updater. Some properties on the updater can be binded via KVO
When instantiated from a nib, don't perform update checks before the application has finished launching in a MainMenu nib (i.e applicationDidFinishLaunching:) or before the corresponding window/view controller has been loaded (i.e, windowDidLoad or viewDidLoad). The updater is not guaranteed to be started yet before these points.
*/
@property (nonatomic, readonly) SPUUpdater *updater;
/**
Accessible property for the updater's user driver.
*/
@property (nonatomic, readonly) SPUStandardUserDriver *userDriver;
/**
Create a new `SPUStandardUpdaterController` from a nib.
You cannot call this initializer directly. You must instantiate a `SPUStandardUpdaterController` inside of a nib (typically the MainMenu nib) to use it.
To create a `SPUStandardUpdaterController` programatically, use `-initWithUpdaterDelegate:userDriverDelegate:` or `-initWithStartingUpdater:updaterDelegate:userDriverDelegate:` instead.
*/
- (instancetype)init NS_UNAVAILABLE;
/**
Create a new `SPUStandardUpdaterController` programmatically.
The updater is started automatically. See `-startUpdater` for more information.
*/
- (instancetype)initWithUpdaterDelegate:(nullable id<SPUUpdaterDelegate>)updaterDelegate userDriverDelegate:(nullable id<SPUStandardUserDriverDelegate>)userDriverDelegate;
/**
Create a new `SPUStandardUpdaterController` programmatically allowing you to specify whether or not to start the updater immediately.
You can specify whether or not you want to start the updater immediately.
If you do not start the updater, you must invoke `-startUpdater` at a later time to start it.
*/
- (instancetype)initWithStartingUpdater:(BOOL)startUpdater updaterDelegate:(nullable id<SPUUpdaterDelegate>)updaterDelegate userDriverDelegate:(nullable id<SPUStandardUserDriverDelegate>)userDriverDelegate;
/**
Starts the updater if it has not already been started.
You should only call this method yourself if you opted out of starting the updater on initialization.
Hence, do not call this yourself if you are instantiating this controller from a nib.
This invokes `-[SPUUpdater startUpdater:]`. If the application is misconfigured with Sparkle, an error is logged and an alert is shown to the user (after a few seconds) to contact the developer.
If you want more control over this behavior, you can create your own `SPUUpdater` instead of using `SPUStandardUpdaterController`.
*/
- (void)startUpdater;
/**
Explicitly checks for updates and displays a progress dialog while doing so.
This method is meant for a main menu item.
Connect any NSMenuItem to this action in Interface Builder or programmatically,
and Sparkle will check for updates and report back its findings verbosely when it is invoked.
When the target/action of the menu item is set to this controller and this method,
this controller also handles enabling/disabling the menu item by checking
`-[SPUUpdater canCheckForUpdates]`
This action checks updates by invoking `-[SPUUpdater checkForUpdates]`
*/
- (IBAction)checkForUpdates:(nullable id)sender;
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,44 @@
//
// SPUStandardUserDriver.h
// Sparkle
//
// Created by Mayur Pawashe on 2/14/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SPUUserDriver.h>
#import <Sparkle/SUExport.h>
NS_ASSUME_NONNULL_BEGIN
@protocol SPUStandardUserDriverDelegate;
/**
Sparkle's standard built-in user driver for updater interactions
*/
SU_EXPORT @interface SPUStandardUserDriver : NSObject <SPUUserDriver>
/**
Initializes a Sparkle's standard user driver for user update interactions
@param hostBundle The target bundle of the host that is being updated.
@param delegate The optional delegate to this user driver.
*/
- (instancetype)initWithHostBundle:(NSBundle *)hostBundle delegate:(nullable id<SPUStandardUserDriverDelegate>)delegate;
/**
Use initWithHostBundle:delegate: instead.
*/
- (instancetype)init NS_UNAVAILABLE;
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,64 @@
//
// SPUStandardUserDriverDelegate.h
// Sparkle
//
// Created by Mayur Pawashe on 3/3/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
@protocol SUVersionDisplay;
/**
A protocol for Sparkle's standard user driver's delegate
This includes methods related to UI interactions
*/
SU_EXPORT @protocol SPUStandardUserDriverDelegate <NSObject>
@optional
/**
Called before showing a modal alert window,
to give the opportunity to hide attached windows that may get in the way.
*/
- (void)standardUserDriverWillShowModalAlert;
/**
Called after showing a modal alert window,
to give the opportunity to hide attached windows that may get in the way.
*/
- (void)standardUserDriverDidShowModalAlert;
/**
Returns an object that formats version numbers for display to the user.
If you don't implement this method or return @c nil, the standard version formatter will be used.
*/
- (_Nullable id <SUVersionDisplay>)standardUserDriverRequestsVersionDisplayer;
/**
Handles showing the full release notes to the user.
When a user checks for new updates and no new update is found, Sparkle will offer to show the application's version history to the user
by providing a "Version History" button in the no new update available alert.
If this delegate method is not implemented, Sparkle will instead offer to open the
`fullReleaseNotesLink` (or `releaseNotesLink` if the former is unavailable) from the appcast's latest `item` in the user's web browser.
If this delegate method is implemented, Sparkle will instead ask the delegate to show the full release notes to the user.
A delegate may want to implement this method if they want to show in-app or offline release notes.
@param item The appcast item corresponding to the latest version available.
*/
- (void)standardUserDriverShowVersionHistoryForAppcastItem:(SUAppcastItem *_Nonnull)item;
@end

View File

@ -0,0 +1,33 @@
//
// SPUUpdateCheck.h
// SPUUpdateCheck
//
// Created by Mayur Pawashe on 8/28/21.
// Copyright © 2021 Sparkle Project. All rights reserved.
//
#ifndef SPUUpdateCheck_h
#define SPUUpdateCheck_h
/**
Describes the type of update check being performed.
Each update check corresponds to an update check method on `SPUUpdater`.
*/
typedef NS_ENUM(NSInteger, SPUUpdateCheck)
{
/**
The user-initiated update check corresponding to `-[SPUUpdater checkForUpdates]`.
*/
SPUUpdateCheckUpdates = 0,
/**
The background scheduled update check corresponding to `-[SPUUpdater checkForUpdatesInBackground]`.
*/
SPUUpdateCheckUpdatesInBackground = 1,
/**
The informational probe update check corresponding to `-[SPUUpdater checkForUpdateInformation]`.
*/
SPUUpdateCheckUpdateInformation = 2
};
#endif /* SPUUpdateCheck_h */

View File

@ -0,0 +1,40 @@
//
// SPUUpdatePermissionRequest.h
// Sparkle
//
// Created by Mayur Pawashe on 8/14/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
NS_ASSUME_NONNULL_BEGIN
/**
This class represents information needed to make a permission request for checking updates.
*/
SU_EXPORT @interface SPUUpdatePermissionRequest : NSObject<NSSecureCoding>
/**
Initializes a new update permission request instance.
@param systemProfile The system profile information.
*/
- (instancetype)initWithSystemProfile:(NSArray<NSDictionary<NSString *, NSString *> *> *)systemProfile;
/**
A read-only property for the user's system profile.
*/
@property (nonatomic, readonly) NSArray<NSDictionary<NSString *, NSString *> *> *systemProfile;
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,301 @@
//
// SPUUpdater.h
// Sparkle
//
// Created by Andy Matuschak on 1/4/06.
// Copyright 2006 Andy Matuschak. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
#import <Sparkle/SPUUserDriver.h>
NS_ASSUME_NONNULL_BEGIN
@class SUAppcastItem, SUAppcast;
@protocol SPUUpdaterDelegate;
/**
The main API in Sparkle for controlling the update mechanism.
This class is used to configure the update parameters as well as manually and automatically schedule and control checks for updates.
For convenience, you can create a standard or nib instantiable updater by using `SPUStandardUpdaterController`.
Prefer to set initial properties in your bundle's Info.plist as described in [Customizing Sparkle](https://sparkle-project.org/documentation/customization/).
Otherwise only if you need dynamic behavior (eg. for user preferences) should you set properties on the updater such as:
- `automaticallyChecksForUpdates`
- `updateCheckInterval`
- `automaticallyDownloadsUpdates`
- `feedURL`
Please view the documentation on each of these properties for more detail if you are to configure them dynamically.
*/
SU_EXPORT @interface SPUUpdater : NSObject
/**
Initializes a new `SPUUpdater` instance
This creates an updater, but to start it and schedule update checks `-startUpdater:` needs to be invoked first.
Related: See `SPUStandardUpdaterController` which wraps a `SPUUpdater` instance and is suitable for instantiating inside of nib files.
@param hostBundle The bundle that should be targetted for updating.
@param applicationBundle The application bundle that should be waited for termination and relaunched (unless overridden). Usually this can be the same as hostBundle. This may differ when updating a plug-in or other non-application bundle.
@param userDriver The user driver that Sparkle uses for user update interaction.
@param delegate The delegate for `SPUUpdater`.
*/
- (instancetype)initWithHostBundle:(NSBundle *)hostBundle applicationBundle:(NSBundle *)applicationBundle userDriver:(id <SPUUserDriver>)userDriver delegate:(nullable id<SPUUpdaterDelegate>)delegate;
/**
Use `-initWithHostBundle:applicationBundle:userDriver:delegate:` or `SPUStandardUpdaterController` standard adapter instead.
If you want to drop an updater into a nib, use `SPUStandardUpdaterController`.
*/
- (instancetype)init NS_UNAVAILABLE;
/**
Starts the updater.
This method first checks if Sparkle is configured properly. A valid feed URL should be set before this method is invoked.
If the configuration is valid, an update cycle is started in the next main runloop cycle.
During this cycle, a permission prompt may be brought up (if needed) for checking if the user wants automatic update checking.
Otherwise if automatic update checks are enabled, a scheduled update alert may be brought up if enough time has elapsed since the last check.
See `automaticallyChecksForUpdates` for more information.
After starting the updater and before the next runloop cycle, one of `-checkForUpdates`, `-checkForUpdatesInBackground`, or `-checkForUpdateInformation` can be invoked.
This may be useful if you want to check for updates immediately or without showing a potential permission prompt.
If the updater cannot be started (i.e, due to a configuration issue in the application), you may want to fall back appropriately.
For example, the standard updater controller (`SPUStandardUpdaterController`) alerts the user that the app is misconfigured and to contact the developer.
This must be called on the main thread.
@param error The error that is populated if this method fails. Pass NULL if not interested in the error information.
@return YES if the updater started otherwise NO with a populated error
*/
- (BOOL)startUpdater:(NSError * __autoreleasing *)error;
/**
Checks for updates, and displays progress while doing so if needed.
This is meant for users initiating a new update check or checking the current update progress.
If an update hasn't started, the user may be shown that a new check for updates is occurring.
If an update has already been downloaded or begun installing from a previous session, the user may be presented to install that update.
If the user is already being presented with an update, that update will be shown to the user in active focus.
This will find updates that the user has previously opted into skipping.
See `canCheckForUpdates` property which can determine when this method may be invoked.
*/
- (void)checkForUpdates;
/**
Checks for updates, but does not display any UI unless an update is found.
You usually do not need to call this method directly. If `automaticallyChecksForUpdates` is @c YES,
Sparkle calls this method automatically according to its update schedule using the `updateCheckInterval`
and the `lastUpdateCheckDate`.
This is meant for programmatically initating a check for updates.
That is, it will display no UI unless it finds an update, in which case it proceeds as usual.
This will not find updates that the user has opted into skipping.
Note if there is no resumable update found, and automated updating is turned on,
the update will be downloaded in the background without disrupting the user.
This method does not do anything if there is a `sessionInProgress`.
*/
- (void)checkForUpdatesInBackground;
/**
Begins a "probing" check for updates which will not actually offer to
update to that version.
However, the delegate methods
`-[SPUUpdaterDelegate updater:didFindValidUpdate:]` and
`-[SPUUpdaterDelegate updaterDidNotFindUpdate:]` will be called,
so you can use that information in your UI.
`-[SPUUpdaterDelegate updater:didFinishUpdateCycleForUpdateCheck:error:]` will be called when
this probing check is completed.
Updates that have been skipped by the user will not be found.
This method does not do anything if there is a `sessionInProgress`.
*/
- (void)checkForUpdateInformation;
/**
A property indicating whether or not updates can be checked by the user.
An update check can be made by the user when an update session isn't in progress, or when an update or its progress is being shown to the user.
A user cannot check for updates when data (such as the feed or an update) is still being downloaded automatically in the background.
This property is suitable to use for menu item validation for seeing if `-checkForUpdates` can be invoked.
This property is also KVO-compliant.
Note this property does not reflect whether or not an update session is in progress. Please see `sessionInProgress` property instead.
*/
@property (nonatomic, readonly) BOOL canCheckForUpdates;
/**
A property indicating whether or not an update session is in progress.
An update session is in progress when the appcast is being downloaded, an update is being downloaded,
an update is being shown, update permission is being requested, or the installer is being started.
An active session is when Sparkle's fired scheduler is running.
Note an update session may not be running even though Sparkle's installer (ran as a separate process) may be running,
or even though the update has been downloaded but the installation has been deferred. In both of these cases, a new update session
may be activated with the update resumed at a later point (automatically or manually).
See also:
- `canCheckForUpdates` property which is more suited for menu item validation and deciding if the user can initiate update checks.
- `-[SPUUpdaterDelegate updater:didFinishUpdateCycleForUpdateCheck:error:]` which lets the updater delegate know when an update cycle and session finishes.
*/
@property (nonatomic, readonly) BOOL sessionInProgress;
/**
A property indicating whether or not to check for updates automatically.
By default, Sparkle asks users on second launch for permission if they want automatic update checks enabled
and sets this property based on their response. If `SUEnableAutomaticChecks` is set in the Info.plist,
this permission request is not performed however.
Setting this property will persist in the host bundle's user defaults.
Only set this property if you need dynamic behavior (e.g. user preferences).
The update schedule cycle will be reset in a short delay after the property's new value is set.
This is to allow reverting this property without kicking off a schedule change immediately
*/
@property (nonatomic) BOOL automaticallyChecksForUpdates;
/**
A property indicating the current automatic update check interval in seconds.
Setting this property will persist in the host bundle's user defaults.
For this reason, only set this property if you need dynamic behavior (eg user preferences).
Otherwise prefer to set SUScheduledCheckInterval directly in your Info.plist.
The update schedule cycle will be reset in a short delay after the property's new value is set.
This is to allow reverting this property without kicking off a schedule change immediately
*/
@property (nonatomic) NSTimeInterval updateCheckInterval;
/**
A property indicating whether or not updates can be automatically downloaded in the background.
By default, updates are not automatically downloaded.
Note that the developer can disallow automatic downloading of updates from being enabled.
In this case, this property will return NO regardless of how this property is set.
Setting this property will persist in the host bundle's user defaults.
For this reason, only set this property if you need dynamic behavior (eg user preferences).
Otherwise prefer to set SUAutomaticallyUpdate directly in your Info.plist.
*/
@property (nonatomic) BOOL automaticallyDownloadsUpdates;
/**
The URL of the appcast used to download update information.
If the updater's delegate implements `-[SPUUpdaterDelegate feedURLStringForUpdater:]`, this will return that feed URL.
Otherwise if the feed URL has been set before, the feed URL returned will be retrieved from the host bundle's user defaults.
Otherwise the feed URL in the host bundle's Info.plist will be returned.
If no feed URL can be retrieved, returns nil.
This property must be called on the main thread; calls from background threads will return nil.
*/
@property (nonatomic, readonly, nullable) NSURL *feedURL;
/**
Set the URL of the appcast used to download update information. Using this method is discouraged.
Setting this property will persist in the host bundle's user defaults.
To avoid this, you should consider implementing
`-[SPUUpdaterDelegate feedURLStringForUpdater:]` instead of using this method.
Passing nil will remove any feed URL that has been set in the host bundle's user defaults.
If you do not need to alternate between multiple feeds, set the SUFeedURL in your Info.plist instead of invoking this method.
For beta updates, you may consider migrating to `-[SPUUpdaterDelegate allowedChannelsForUpdater:]` in the future.
This method must be called on the main thread; calls from background threads will have no effect.
*/
- (void)setFeedURL:(nullable NSURL *)feedURL;
/**
The host bundle that is being updated.
*/
@property (nonatomic, readonly) NSBundle *hostBundle;
/**
The user agent used when checking for updates.
By default the user agent string returned is in the format:
$(BundleDisplayName)/$(BundleDisplayVersion) Sparkle/$(SparkleDisplayVersion)
BundleDisplayVersion is derived from the main application's Info.plist's CFBundleShortVersionString.
Note if Sparkle is being used to update another application, the bundle information retrieved is from the main application performing the updating.
This default implementation can be overrided.
*/
@property (nonatomic, copy) NSString *userAgentString;
/**
The HTTP headers used when checking for updates, downloading release notes, and downloading updates.
The keys of this dictionary are HTTP header fields and values are corresponding values.
*/
@property (nonatomic, copy, nullable) NSDictionary<NSString *, NSString *> *httpHeaders;
/**
A property indicating whether or not the user's system profile information is sent when checking for updates.
Setting this property will persist in the host bundle's user defaults.
*/
@property (nonatomic) BOOL sendsSystemProfile;
/**
The date of the last update check or nil if no check has been performed yet.
For testing purposes, the last update check is stored in the `SULastCheckTime` key in the host bundle's user defaults.
For example, `defaults delete my-bundle-id SULastCheckTime` can be invoked to clear the last update check time and test
if update checks are automatically scheduled.
*/
@property (nonatomic, readonly, copy, nullable) NSDate *lastUpdateCheckDate;
/**
Appropriately schedules or cancels the update checking timer according to the preferences for time interval and automatic checks.
If you change the `updateCheckInterval` or `automaticallyChecksForUpdates` properties, the update cycle will be reset automatically after a short delay.
The update cycle is also started automatically after the updater is started. In all these cases, this method should not be called directly.
This call does not change the date of the next check, but only the internal timer.
*/
- (void)resetUpdateCycle;
/**
The system profile information that is sent when checking for updates.
*/
@property (nonatomic, readonly, copy) NSArray<NSDictionary<NSString *, NSString *> *> *systemProfileArray;
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,458 @@
//
// SPUUpdaterDelegate.h
// Sparkle
//
// Created by Mayur Pawashe on 8/12/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
#import <Sparkle/SPUUpdateCheck.h>
@protocol SUVersionComparison;
@class SPUUpdater, SUAppcast, SUAppcastItem;
NS_ASSUME_NONNULL_BEGIN
// -----------------------------------------------------------------------------
// SUUpdater Notifications for events that might be interesting to more than just the delegate
// The updater will be the notification object
// -----------------------------------------------------------------------------
SU_EXPORT extern NSString *const SUUpdaterDidFinishLoadingAppCastNotification;
SU_EXPORT extern NSString *const SUUpdaterDidFindValidUpdateNotification;
SU_EXPORT extern NSString *const SUUpdaterDidNotFindUpdateNotification;
SU_EXPORT extern NSString *const SUUpdaterWillRestartNotification;
#define SUUpdaterWillRelaunchApplicationNotification SUUpdaterWillRestartNotification;
#define SUUpdaterWillInstallUpdateNotification SUUpdaterWillRestartNotification;
// Key for the SUAppcastItem object in the SUUpdaterDidFindValidUpdateNotification userInfo
SU_EXPORT extern NSString *const SUUpdaterAppcastItemNotificationKey;
// Key for the SUAppcast object in the SUUpdaterDidFinishLoadingAppCastNotification userInfo
SU_EXPORT extern NSString *const SUUpdaterAppcastNotificationKey;
// -----------------------------------------------------------------------------
// System Profile Keys
// -----------------------------------------------------------------------------
SU_EXPORT extern NSString *const SUSystemProfilerApplicationNameKey;
SU_EXPORT extern NSString *const SUSystemProfilerApplicationVersionKey;
SU_EXPORT extern NSString *const SUSystemProfilerCPU64bitKey;
SU_EXPORT extern NSString *const SUSystemProfilerCPUCountKey;
SU_EXPORT extern NSString *const SUSystemProfilerCPUFrequencyKey;
SU_EXPORT extern NSString *const SUSystemProfilerCPUTypeKey;
SU_EXPORT extern NSString *const SUSystemProfilerCPUSubtypeKey;
SU_EXPORT extern NSString *const SUSystemProfilerHardwareModelKey;
SU_EXPORT extern NSString *const SUSystemProfilerMemoryKey;
SU_EXPORT extern NSString *const SUSystemProfilerOperatingSystemVersionKey;
SU_EXPORT extern NSString *const SUSystemProfilerPreferredLanguageKey;
// -----------------------------------------------------------------------------
// SPUUpdater Delegate:
// -----------------------------------------------------------------------------
/**
Provides delegation methods to control the behavior of an `SPUUpdater` object.
*/
@protocol SPUUpdaterDelegate <NSObject>
@optional
/**
Returns whether to allow Sparkle to check for updates.
For example, this may be used to prevent Sparkle from interrupting a setup assistant.
Alternatively, you may want to consider starting the updater after eg: the setup assistant finishes.
Note in Swift, this method returns Void and is marked with the throws keyword. If this method
doesn't throw an error, the updater may perform an update check. Otherwise if an error is thrown (we recommend using an NSError),
then the updater may not perform an update check.
@param updater The updater instance.
@param updateCheck The type of update check that will be performed if the updater is allowed to check for updates.
@param error The populated error object if the updater may not perform a new update check. The @c NSLocalizedDescriptionKey user info key should be populated indicating a description of the error.
@return @c YES if the updater is allowed to check for updates, otherwise @c NO
*/
- (BOOL)updater:(SPUUpdater *)updater mayPerformUpdateCheck:(SPUUpdateCheck)updateCheck error:(NSError * __autoreleasing *)error;
/**
Returns the set of Sparkle channels the updater is allowed to find new updates from.
An appcast item can specify a channel the update is posted to. Without specifying a channel, the appcast item is posted to the default channel.
For instance:
```
<item>
<sparkle:version>2.0 Beta 1</sparkle:version>
<sparkle:channel>beta</sparkle:channel>
</item>
```
This example posts an update to the @c beta channel, so only updaters that are allowed to use the @c beta channel can find this update.
If the @c <sparkle:channel> element is not present, the update item is posted to the default channel and can be found by any updater.
You can pick any name you'd like for the channel. The valid characters for channel names are letters, numbers, dashes, underscores, and periods.
Note to use this feature, all app versions that your users may update from in your feed must use a version of Sparkle that supports this feature.
This feature was added in Sparkle 2.
@return The set of channel names the updater is allowed to find new updates in. An empty set is the default behavior,
which means the updater will only look for updates in the default channel.
*/
- (NSSet<NSString *> *)allowedChannelsForUpdater:(SPUUpdater *)updater;
/**
Returns a custom appcast URL used for checking for new updates.
Override this to dynamically specify the feed URL.
@param updater The updater instance.
@return An appcast feed URL to check for new updates in, or @c nil for the default behavior and if you don't want to be delegated this task.
*/
- (nullable NSString *)feedURLStringForUpdater:(SPUUpdater *)updater;
/**
Returns additional parameters to append to the appcast URL's query string.
This is potentially based on whether or not Sparkle will also be sending along the system profile.
@param updater The updater instance.
@param sendingProfile Whether the system profile will also be sent.
@return An array of dictionaries with keys: `key`, `value`, `displayKey`, `displayValue`, the latter two being specifically for display to the user.
*/
- (NSArray<NSDictionary<NSString *, NSString *> *> *)feedParametersForUpdater:(SPUUpdater *)updater sendingSystemProfile:(BOOL)sendingProfile;
/**
Returns whether Sparkle should prompt the user about checking for new updates automatically.
Use this to override the default behavior.
@param updater The updater instance.
@return @c YES if the updater should prompt for permission to check for new updates automatically, otherwise @c NO
*/
- (BOOL)updaterShouldPromptForPermissionToCheckForUpdates:(SPUUpdater *)updater;
/**
Returns an allowed list of system profile keys to be appended to the appcast URL's query string.
By default all keys will be included. This method allows overriding which keys should only be allowed.
@param updater The updater instance.
@return An array of system profile keys to include in the appcast URL's query string. Elements must be one of the `SUSystemProfiler*Key` constants. Return @c nil for the default behavior and if you don't want to be delegated this task.
*/
- (nullable NSArray<NSString *> *)allowedSystemProfileKeysForUpdater:(SPUUpdater *)updater;
/**
Called after Sparkle has downloaded the appcast from the remote server.
Implement this if you want to do some special handling with the appcast once it finishes loading.
@param updater The updater instance.
@param appcast The appcast that was downloaded from the remote server.
*/
- (void)updater:(SPUUpdater *)updater didFinishLoadingAppcast:(SUAppcast *)appcast;
/**
Called when a new valid update is found by the update driver.
@param updater The updater instance.
@param item The appcast item corresponding to the update that is proposed to be installed.
*/
- (void)updater:(SPUUpdater *)updater didFindValidUpdate:(SUAppcastItem *)item;
/**
Called when a valid new update is not found.
There are various reasons a new update is unavailable and can't be installed.
The userInfo dictionary on the error is populated with three keys:
- `SPULatestAppcastItemFoundKey`: if available, this may provide the latest `SUAppcastItem` that was found. This will be @c nil if it's unavailable.
- `SPUNoUpdateFoundReasonKey`: This will provide the `SPUNoUpdateFoundReason`.
For example the reason could be because the latest version in the feed requires a newer OS version or could be because the user is already on the latest version.
- `SPUNoUpdateFoundUserInitiatedKey`: A boolean that indicates if a new update was not found when the user intitiated an update check manually.
@param updater The updater instance.
@param error An error containing information on why a new valid update was not found
*/
- (void)updaterDidNotFindUpdate:(SPUUpdater *)updater error:(NSError *)error;
/**
Called when a valid new update is not found.
If more information is needed on why an update was not found, use `-[SPUUpdaterDelegate updaterDidNotFindUpdate:error:]` instead.
@param updater The updater instance.
*/
- (void)updaterDidNotFindUpdate:(SPUUpdater *)updater;
/**
Returns the item in the appcast corresponding to the update that should be installed.
Please consider using or migrating to other supported features before adopting this method.
Specifically:
- If you want to filter out certain tagged updates (like beta updates), consider `-[SPUUpdaterDelegate allowedChannelsForUpdater:]` instead.
- If you want to treat certain updates as informational-only, consider supplying @c <sparkle:informationalUpdate> with a set of affected versions users are updating from.
If you're using special logic or extensions in your appcast, implement this to use your own logic for finding a valid update, if any, in the given appcast.
Do not base your logic by filtering out items with a minimum or maximum OS version or minimum autoupdate version
because Sparkle already has logic for determining whether or not those items should be filtered out.
Also do not return a non-top level item from the appcast such as a delta item. Delta items will be ignored.
Sparkle picks the delta item from your selection if the appropriate one is available.
This method will not be invoked with an appcast that has zero items. Pick the best item from the appcast.
If an item is available that has the same version as the application or bundle to update, do not pick an item that is worse than that version.
This method may be called multiple times for different selections and filters. This method should be efficient.
Return `+[SUAppcastItem emptyAppcastItem]` if no appcast item is valid.
Return @c nil if you don't want to be delegated this task and want to let Sparkle handle picking the best valid update.
@param appcast The appcast that was downloaded from the remote server.
@param updater The updater instance.
@return The best valid appcast item.
*/
- (nullable SUAppcastItem *)bestValidUpdateInAppcast:(SUAppcast *)appcast forUpdater:(SPUUpdater *)updater;
/**
Returns whether or not the updater should proceed with the new chosen update from the appcast.
By default, the updater will always proceed with the best selected update found in an appcast. Override this to override this behavior.
If you return @c NO and populate the @c error, the user is not shown this @c updateItem nor is the update downloaded or installed.
Note in Swift, this method returns Void and is marked with the throws keyword. If this method doesn't throw an error, the updater will proceed with the update.
Otherwise if an error is thrown (we recommend using an NSError), then the will not proceed with the update.
@param updater The updater instance.
@param updateItem The selected update item to proceed with.
@param updateCheck The type of update check that would be performed if proceeded.
@param error An error object that must be populated by the delegate if the updater should not proceed with the update. The @c NSLocalizedDescriptionKey user info key should be populated indicating a description of the error.
@return @c YES if the updater should proceed with @c updateItem, otherwise @c NO if the updater should not proceed with the update with an @c error populated.
*/
- (BOOL)updater:(SPUUpdater *)updater shouldProceedWithUpdate:(SUAppcastItem *)updateItem updateCheck:(SPUUpdateCheck)updateCheck error:(NSError * __autoreleasing *)error;
/**
Called when an update is skipped by the user.
@param updater The updater instance.
@param item The appcast item corresponding to the update that the user skipped.
*/
- (void)updater:(SPUUpdater *)updater userDidSkipThisVersion:(SUAppcastItem *)item;
/**
Returns whether the release notes (if available) should be downloaded after an update is found and shown.
This is specifically for the @c <releaseNotesLink> element in the appcast item.
@param updater The updater instance.
@param updateItem The update item to download and show release notes from.
@return @c YES to download and show the release notes if available, otherwise @c NO. The default behavior is @c YES.
*/
- (BOOL)updater:(SPUUpdater *)updater shouldDownloadReleaseNotesForUpdate:(SUAppcastItem *)updateItem;
/**
Called immediately before downloading the specified update.
@param updater The updater instance.
@param item The appcast item corresponding to the update that is proposed to be downloaded.
@param request The mutable URL request that will be used to download the update.
*/
- (void)updater:(SPUUpdater *)updater willDownloadUpdate:(SUAppcastItem *)item withRequest:(NSMutableURLRequest *)request;
/**
Called immediately after succesfull download of the specified update.
@param updater The SUUpdater instance.
@param item The appcast item corresponding to the update that has been downloaded.
*/
- (void)updater:(SPUUpdater *)updater didDownloadUpdate:(SUAppcastItem *)item;
/**
Called after the specified update failed to download.
@param updater The updater instance.
@param item The appcast item corresponding to the update that failed to download.
@param error The error generated by the failed download.
*/
- (void)updater:(SPUUpdater *)updater failedToDownloadUpdate:(SUAppcastItem *)item error:(NSError *)error;
/**
Called when the user cancels an update while it is being downloaded.
@param updater The updater instance.
*/
- (void)userDidCancelDownload:(SPUUpdater *)updater;
/**
Called immediately before extracting the specified downloaded update.
@param updater The SUUpdater instance.
@param item The appcast item corresponding to the update that is proposed to be extracted.
*/
- (void)updater:(SPUUpdater *)updater willExtractUpdate:(SUAppcastItem *)item;
/**
Called immediately after extracting the specified downloaded update.
@param updater The SUUpdater instance.
@param item The appcast item corresponding to the update that has been extracted.
*/
- (void)updater:(SPUUpdater *)updater didExtractUpdate:(SUAppcastItem *)item;
/**
Called immediately before installing the specified update.
@param updater The updater instance.
@param item The appcast item corresponding to the update that is proposed to be installed.
*/
- (void)updater:(SPUUpdater *)updater willInstallUpdate:(SUAppcastItem *)item;
/**
Returns whether the relaunch should be delayed in order to perform other tasks.
This is not called if the user didn't relaunch on the previous update,
in that case it will immediately restart.
This may also not be called if the application is not going to relaunch after it terminates.
@param updater The updater instance.
@param item The appcast item corresponding to the update that is proposed to be installed.
@param installHandler The install handler that must be completed before continuing with the relaunch.
@return @c YES to delay the relaunch until @c installHandler is invoked.
*/
- (BOOL)updater:(SPUUpdater *)updater shouldPostponeRelaunchForUpdate:(SUAppcastItem *)item untilInvokingBlock:(void (^)(void))installHandler;
/**
Returns whether the application should be relaunched at all.
Some apps **cannot** be relaunched under certain circumstances.
This method can be used to explicitly prevent a relaunch.
@param updater The updater instance.
@return @c YES if the updater should be relaunched, otherwise @c NO if it shouldn't.
*/
- (BOOL)updaterShouldRelaunchApplication:(SPUUpdater *)updater;
/**
Called immediately before relaunching.
@param updater The updater instance.
*/
- (void)updaterWillRelaunchApplication:(SPUUpdater *)updater;
/**
Returns an object that compares version numbers to determine their arithmetic relation to each other.
This method allows you to provide a custom version comparator.
If you don't implement this method or return @c nil,
the standard version comparator will be used.
Note that the standard version comparator may be used during installation for preventing a downgrade,
even if you provide a custom comparator here.
@param updater The updater instance.
@return The custom version comparator or @c nil if you don't want to be delegated this task.
*/
- (nullable id<SUVersionComparison>)versionComparatorForUpdater:(SPUUpdater *)updater;
/**
Called when a background update will be scheduled after a delay.
Automatic update checks need to be enabled for this to trigger.
@param delay The delay in seconds until the next scheduled update will occur. This is an approximation and may vary due to system state.
@param updater The updater instance.
*/
- (void)updater:(SPUUpdater *)updater willScheduleUpdateCheckAfterDelay:(NSTimeInterval)delay;
/**
Called when no update checks will be scheduled in the future.
This may later change if automatic update checks become enabled.
@param updater The updater instance.
*/
- (void)updaterWillNotScheduleUpdateCheck:(SPUUpdater *)updater;
/**
Returns the decryption password (if any) which is used to extract the update archive DMG.
Return @c nil if no password should be used.
@param updater The updater instance.
@return The password used for decrypting the archive, or @c nil if no password should be used.
*/
- (nullable NSString *)decryptionPasswordForUpdater:(SPUUpdater *)updater;
/**
Called when an update is scheduled to be silently installed on quit after downloading the update automatically.
If the updater is given responsibility, it can later remind the user an update is available if they have not terminated the application for a long time.
Also if the updater is given responsibility and the update item is marked critical, the new update will be presented to the user immediately after.
Even if the @c immediateInstallHandler is not invoked, the installer will attempt to install the update on termination.
@param updater The updater instance.
@param item The appcast item corresponding to the update that is proposed to be installed.
@param immediateInstallHandler The install handler to immediately install the update. No UI interaction will be shown and the application will be relaunched after installation.
@return @c YES if the delegate will handle installing the update or @c NO if the updater should be given responsibility.
*/
- (BOOL)updater:(SPUUpdater *)updater willInstallUpdateOnQuit:(SUAppcastItem *)item immediateInstallationBlock:(void (^)(void))immediateInstallHandler;
/**
Called after the update driver aborts due to an error.
The update driver runs when checking for updates. This delegate method is called an error occurs during this process.
Some special possible values of `error.code` are:
- `SUNoUpdateError`: No new update was found.
- `SUInstallationCanceledError`: The user canceled installing the update when requested for authorization.
@param updater The updater instance.
@param error The error that caused the update driver to abort.
*/
- (void)updater:(SPUUpdater *)updater didAbortWithError:(NSError *)error;
/**
Called after the update driver finishes.
The update driver runs when checking for updates. This delegate method is called when that check is finished.
An update may be scheduled to be installed during the update cycle, or no updates may be found, or an available update may be dismissed or skipped (which is the same as no error).
If the @c error is @c nil, no error has occurred.
Some special possible values of `error.code` are:
- `SUNoUpdateError`: No new update was found.
- `SUInstallationCanceledError`: The user canceled installing the update when requested for authorization.
@param updater The updater instance.
@param updateCheck The type of update check was performed.
@param error The error that caused the update driver to abort. This is @c nil if the update driver finished normally and there is no error.
*/
- (void)updater:(SPUUpdater *)updater didFinishUpdateCycleForUpdateCheck:(SPUUpdateCheck)updateCheck error:(nullable NSError *)error;
/* Deprecated methods */
- (BOOL)updaterMayCheckForUpdates:(SPUUpdater *)updater __deprecated_msg("Please use -[SPUUpdaterDelegate updater:mayPerformUpdateCheck:error:] instead.");
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,61 @@
//
// SPUUpdaterSettings.h
// Sparkle
//
// Created by Mayur Pawashe on 3/27/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
NS_ASSUME_NONNULL_BEGIN
/**
This class can be used for reading certain updater settings.
It retrieves the settings by first looking into the host's user defaults.
If the setting is not found in there, then the host's Info.plist file is looked at.
*/
SU_EXPORT @interface SPUUpdaterSettings : NSObject
- (instancetype)initWithHostBundle:(NSBundle *)hostBundle;
/**
* Indicates whether or not automatic update checks are enabled.
*/
@property (readonly, nonatomic) BOOL automaticallyChecksForUpdates;
/**
* The regular update check interval.
*/
@property (readonly, nonatomic) NSTimeInterval updateCheckInterval;
/**
* Indicates whether or not automatically downloading updates is allowed to be turned on by the user.
*/
@property (readonly, nonatomic) BOOL allowsAutomaticUpdates;
/**
* Indicates whether or not automatically downloading updates is enabled by the user or developer.
*
* Note this does not indicate whether or not automatic downloading of updates is allowable.
* See `-allowsAutomaticUpdates` property for that.
*/
@property (readonly, nonatomic) BOOL automaticallyDownloadsUpdates;
/**
* Indicates whether or not anonymous system profile information is sent when checking for updates.
*/
@property (readonly, nonatomic) BOOL sendsSystemProfile;
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,287 @@
//
// SPUUserDriver.h
// Sparkle
//
// Created by Mayur Pawashe on 2/14/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SPUUserUpdateState.h>
#import <Sparkle/SUExport.h>
NS_ASSUME_NONNULL_BEGIN
@class SPUUpdatePermissionRequest, SUUpdatePermissionResponse, SUAppcastItem, SPUDownloadData;
/**
The API in Sparkle for controlling the user interaction.
This protocol is used for implementing a user interface for the Sparkle updater. Sparkle's internal drivers tell
an object that implements this protocol what actions to take and show to the user.
Every method in this protocol can be assumed to be called from the main thread.
*/
SU_EXPORT @protocol SPUUserDriver <NSObject>
/**
* Show an updater permission request to the user
*
* Ask the user for their permission regarding update checks.
* This is typically only called once per app installation.
*
* @param request The update permission request.
* @param reply A reply with a update permission response.
*/
- (void)showUpdatePermissionRequest:(SPUUpdatePermissionRequest *)request reply:(void (^)(SUUpdatePermissionResponse *))reply;
/**
* Show the user initating an update check
*
* Respond to the user initiating an update check. Sparkle uses this to show the user a window with an indeterminate progress bar.
*
* @param cancellation Invoke this cancellation block to cancel the update check before the update check is completed.
*/
- (void)showUserInitiatedUpdateCheckWithCancellation:(void (^)(void))cancellation;
/**
* Show the user a new update is found.
*
* Let the user know a new update is found and ask them what they want to do.
* Before this point, `-showUserInitiatedUpdateCheckWithCancellation:` may be called.
*
* The potential `stage`s on the updater @c state are:
*
* `SPUUpdateStateNotDownloaded` - Update has not been downloaded yet.
*
* `SPUUpdateStateDownloaded` - Update has already been downloaded but not started installing yet.
*
* `SPUUpdateStateInstalling` - Update has been downloaded and already started installing.
*
* The `userIntiated` property on the @c state indicates if the update was initiated by the user or if it was automatically scheduled in the background.
*
* Additionally, these properties on the @c appcastItem are of importance:
*
* @c appcastItem.informationOnlyUpdate indicates if the update is only informational and should not be downloaded. You can direct the user to the infoURL property of the appcastItem in their web browser. Sometimes information only updates are used as a fallback in case a bad update is shipped, so you'll want to support this case.
*
* @c appcastItem.majorUpgrade indicates if the update is a major or paid upgrade.
*
* @c appcastItem.criticalUpdate indicates if the update is a critical update.
*
* A reply of `SPUUserUpdateChoiceInstall` begins or resumes downloading or installing the update.
* If the state.stage is `SPUUserUpdateStateInstalling`, this may send a quit event to the application and relaunch it immediately (in this state, this behaves as a fast "install and Relaunch").
* Do not use this reply if @c appcastItem.informationOnlyUpdate is YES.
*
* A reply of `SPUUserUpdateChoiceDismiss` dismisses the update for the time being. The user may be reminded of the update at a later point.
* If the state.stage is `SPUUserUpdateStateDownloaded`, the downloaded update is kept after dismissing until the next time an update is shown to the user.
* If the state.stage is `SPUUserUpdateStateInstalling`, the installing update is also preserved after dismissing. In this state however, the update will also still be installed after the application is terminated.
*
* A reply of `SPUUserUpdateChoiceSkip` skips this particular version and won't notify the user again, unless they initiate an update check themselves.
* If @c appcastItem.majorUpgrade is YES, the major update and any future minor updates to that major release are skipped, unless a future minor update specifies a `<sparkle:ignoreSkippedUpgradesBelowVersion>` requirement.
* If the state.stage is `SPUUpdateStateInstalling`, the installation is also canceled when the update is skipped.
*
* @param appcastItem The Appcast Item containing information that reflects the new update.
* @param state The current state of the user update. See above discussion for notable properties.
* @param reply The reply which indicates if the update should be installed, dismissed, or skipped. See above discussion for more details.
*/
- (void)showUpdateFoundWithAppcastItem:(SUAppcastItem *)appcastItem state:(SPUUserUpdateState *)state reply:(void (^)(SPUUserUpdateChoice))reply;
/**
* Show the user the release notes for the new update
*
* Display the release notes to the user. This will be called after showing the new update.
* This is only applicable if the release notes are linked from the appcast, and are not directly embedded inside of the appcast file.
* That is, this may be invoked if the releaseNotesURL from the appcast item is non-nil.
*
* @param downloadData The data for the release notes that was downloaded from the new update's appcast.
*/
- (void)showUpdateReleaseNotesWithDownloadData:(SPUDownloadData *)downloadData;
/**
* Show the user that the new update's release notes could not be downloaded
*
* This will be called after showing the new update.
* This is only applicable if the release notes are linked from the appcast, and are not directly embedded inside of the appcast file.
* That is, this may be invoked if the releaseNotesURL from the appcast item is non-nil.
*
* @param error The error associated with why the new update's release notes could not be downloaded.
*/
- (void)showUpdateReleaseNotesFailedToDownloadWithError:(NSError *)error;
/**
* Show the user a new update was not found
*
* Let the user know a new update was not found after they tried initiating an update check.
* Before this point, `-showUserInitiatedUpdateCheckWithCancellation:` may be called.
*
* There are various reasons a new update is unavailable and can't be installed.
* The @c error object is populated with recovery and suggestion strings suitable to be shown in an alert.
*
* The @c userInfo dictionary on the @c error is also populated with two keys:
*
* `SPULatestAppcastItemFoundKey`: if available, this may provide the latest SUAppcastItem that was found.
*
* `SPUNoUpdateFoundReasonKey`: if available, this will provide the `SUNoUpdateFoundReason`. For example the reason could be because
* the latest version in the feed requires a newer OS version or could be because the user is already on the latest version.
*
* @param error The error associated with why a new update was not found. See above discussion for more details.
* @param acknowledgement Acknowledge to the updater that no update found error was shown.
*/
- (void)showUpdateNotFoundWithError:(NSError *)error acknowledgement:(void (^)(void))acknowledgement;
/**
* Show the user an update error occurred
*
* Let the user know that the updater failed with an error. This will not be invoked without the user having been
* aware that an update was in progress.
*
* Before this point, any of the non-error user driver methods may have been invoked.
*
* @param error The error associated with what update error occurred.
* @param acknowledgement Acknowledge to the updater that the error was shown.
*/
- (void)showUpdaterError:(NSError *)error acknowledgement:(void (^)(void))acknowledgement;
/**
* Show the user that downloading the new update initiated
*
* Let the user know that downloading the new update started.
*
* @param cancellation Invoke this cancellation block to cancel the download at any point before `-showDownloadDidStartExtractingUpdate` is invoked.
*/
- (void)showDownloadInitiatedWithCancellation:(void (^)(void))cancellation;
/**
* Show the user the content length of the new update that will be downloaded
*
* @param expectedContentLength The expected content length of the new update being downloaded.
* An implementor should be able to handle if this value is invalid (more or less than actual content length downloaded).
* Additionally, this method may be called more than once for the same download in rare scenarios.
*/
- (void)showDownloadDidReceiveExpectedContentLength:(uint64_t)expectedContentLength;
/**
* Show the user that the update download received more data
*
* This may be an appropriate time to advance a visible progress indicator of the download
* @param length The length of the data that was just downloaded
*/
- (void)showDownloadDidReceiveDataOfLength:(uint64_t)length;
/**
* Show the user that the update finished downloading and started extracting
*
* Sparkle uses this to show an indeterminate progress bar.
*
* Note that an update can resume at this point after having been downloaded before,
* so this may be called without any of the download callbacks being invoked prior.
*/
- (void)showDownloadDidStartExtractingUpdate;
/**
* Show the user that the update is extracting with progress
*
* Let the user know how far along the update extraction is.
*
* Before this point, `-showDownloadDidStartExtractingUpdate` is called.
*
* @param progress The progress of the extraction from a 0.0 to 1.0 scale
*/
- (void)showExtractionReceivedProgress:(double)progress;
/**
* Show the user that the update is ready to install & relaunch
*
* Let the user know that the update is ready to install and relaunch, and ask them whether they want to proceed.
* Note if the target application has already terminated, this method may not be invoked.
*
* A reply of `SPUUserUpdateChoiceInstall` installs the update the new update immediately. The application is relaunched only if it is still running by the time this reply is invoked. If the application terminates on its own, Sparkle will attempt to automatically install the update.
*
* A reply of `SPUUserUpdateChoiceDismiss` dismisses the update installation for the time being. Note the update may still be installed automatically after the application terminates.
*
* A reply of `SPUUserUpdateChoiceSkip` cancels the current update that has begun installing and dismisses the update. In this circumstance, the update is canceled but this update version is not skipped in the future.
*
* Before this point, `-showExtractionReceivedProgress:` or `-showUpdateFoundWithAppcastItem:state:reply:` may be called.
*
* @param reply The reply which indicates if the update should be installed, dismissed, or skipped. See above discussion for more details.
*/
- (void)showReadyToInstallAndRelaunch:(void (^)(SPUUserUpdateChoice))reply;
/**
* Show the user that the update is installing
*
* Let the user know that the update is currently installing.
*
* Before this point, `-showReadyToInstallAndRelaunch:` or `-showUpdateFoundWithAppcastItem:state:reply:` will be called.
*
* @param applicationTerminated Indicates if the application has been terminated already.
* If the application hasn't been terminated, a quit event is sent to the running application before installing the update.
* If the application or user delays or cancels termination, there may be an indefinite period of time before the application fully quits.
* It is up to the implementor whether or not to decide to continue showing installation progress in this case.
*/
- (void)showInstallingUpdateWithApplicationTerminated:(BOOL)applicationTerminated;
/**
* Show the user that the update installation finished
*
* Let the user know that the update finished installing.
*
* This will only be invoked if the updater process is still alive, which is typically not the case if
* the updater's lifetime is tied to the application it is updating. This implementation must not try to reference
* the old bundle prior to the installation, which will no longer be around.
*
* Before this point, `-showInstallingUpdateWithApplicationTerminated:` will be called.
*
* @param relaunched Indicates if the update was relaunched.
* @param acknowledgement Acknowledge to the updater that the finished installation was shown.
*/
- (void)showUpdateInstalledAndRelaunched:(BOOL)relaunched acknowledgement:(void (^)(void))acknowledgement;
/**
* Show the user the current presented update or its progress in utmost focus
*
* The user wishes to check for updates while the user is being shown update progress.
* Bring whatever is on screen to frontmost focus (permission request, update information, downloading or extraction status, choice to install update, etc).
*/
- (void)showUpdateInFocus;
/**
* Dismiss the current update installation
*
* Stop and tear down everything.
* Dismiss all update windows, alerts, progress, etc from the user.
* Basically, stop everything that could have been started. Sparkle may invoke this when aborting or finishing an update.
*/
- (void)dismissUpdateInstallation;
/*
* Below are deprecated methods that have been replaced by better alternatives.
* The deprecated methods will be used if the alternatives have not been implemented yet.
* In the future support for using these deprecated methods may be removed however.
*/
@optional
// Clients should move to non-deprecated methods
// Deprecated methods are only (temporarily) kept around for compatibility reasons
- (void)showUpdateNotFoundWithAcknowledgement:(void (^)(void))acknowledgement __deprecated_msg("Implement -showUpdateNotFoundWithError:acknowledgement: instead");
- (void)showUpdateInstallationDidFinishWithAcknowledgement:(void (^)(void))acknowledgement __deprecated_msg("Implement -showUpdateInstalledAndRelaunched:acknowledgement: instead");
- (void)dismissUserInitiatedUpdateCheck __deprecated_msg("Transition to new UI appropriately when a new update is shown, when no update is found, or when an update error occurs.");
- (void)showInstallingUpdate __deprecated_msg("Implement -showInstallingUpdateWithApplicationTerminated: instead.");
- (void)showSendingTerminationSignal __deprecated_msg("Implement -showInstallingUpdateWithApplicationTerminated: instead.");
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,84 @@
//
// SPUUserUpdateState.h
// Sparkle
//
// Created by Mayur Pawashe on 2/29/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#ifndef SPUUserUpdateState_h
#define SPUUserUpdateState_h
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
NS_ASSUME_NONNULL_BEGIN
/**
A choice made by the user when prompted with a new update.
*/
typedef NS_ENUM(NSInteger, SPUUserUpdateChoice) {
/**
Dismisses the update and skips being notified of it in the future.
*/
SPUUserUpdateChoiceSkip,
/**
Downloads (if needed) and installs the update.
*/
SPUUserUpdateChoiceInstall,
/**
Dismisses the update until Sparkle reminds the user of it at a later time.
*/
SPUUserUpdateChoiceDismiss,
};
/**
Describes the current stage an update is undergoing.
*/
typedef NS_ENUM(NSInteger, SPUUserUpdateStage) {
/**
The update has not been downloaded.
*/
SPUUserUpdateStageNotDownloaded,
/**
The update has already been downloaded but not begun installing.
*/
SPUUserUpdateStageDownloaded,
/**
The update has already been downloaded and began installing in the background.
*/
SPUUserUpdateStageInstalling
};
/**
This represents the user's current update state.
*/
SU_EXPORT @interface SPUUserUpdateState : NSObject
- (instancetype)init NS_UNAVAILABLE;
/**
The current update stage.
This stage indicates if data has been already downloaded or not, or if an update is currently being installed.
*/
@property (nonatomic, readonly) SPUUserUpdateStage stage;
/**
Indicates whether or not the update check was initiated by the user.
*/
@property (nonatomic, readonly) BOOL userInitiated;
@end
NS_ASSUME_NONNULL_END
#endif /* SPUUserUpdateState_h */

View File

@ -0,0 +1,44 @@
//
// SUAppcast.h
// Sparkle
//
// Created by Andy Matuschak on 3/12/06.
// Copyright 2006 Andy Matuschak. All rights reserved.
//
#ifndef SUAPPCAST_H
#define SUAPPCAST_H
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
NS_ASSUME_NONNULL_BEGIN
@class SUAppcastItem;
/**
The appcast representing a collection of `SUAppcastItem` items in the feed.
*/
SU_EXPORT @interface SUAppcast : NSObject
- (instancetype)init NS_UNAVAILABLE;
/**
The collection of update items.
These `SUAppcastItem` items are in the same order as specified in the appcast XML feed and are thus not sorted by version.
*/
@property (readonly, copy) NSArray<SUAppcastItem *> *items;
@end
NS_ASSUME_NONNULL_END
#endif

View File

@ -0,0 +1,376 @@
//
// SUAppcastItem.h
// Sparkle
//
// Created by Andy Matuschak on 3/12/06.
// Copyright 2006 Andy Matuschak. All rights reserved.
//
#ifndef SUAPPCASTITEM_H
#define SUAPPCASTITEM_H
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#ifdef BUILDING_SPARKLE_TESTS
// Ignore incorrect warning
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wquoted-include-in-framework-header"
#import "SUExport.h"
#pragma clang diagnostic pop
#else
#import <Sparkle/SUExport.h>
#endif
@class SUSignatures;
@class SPUAppcastItemState;
NS_ASSUME_NONNULL_BEGIN
/**
The appcast item describing an update in the application's appcast feed.
An appcast item represents a single update item in the `SUAppcast` contained within the @c <item> element.
Every appcast item must have a `versionString`, and either a `fileURL` or an `infoURL`.
All the remaining properties describing an update to the application are optional.
Extended documentation and examples on using appcast item features are available at:
https://sparkle-project.org/documentation/publishing/
*/
SU_EXPORT @interface SUAppcastItem : NSObject<NSSecureCoding>
/**
The version of the update item.
Sparkle uses this property to compare update items and determine the best available update item in the `SUAppcast`.
This corresponds to the application update's @c CFBundleVersion
This is extracted from the @c <sparkle:version> element, or the @c sparkle:version attribute from the @c <enclosure> element.
*/
@property (copy, readonly) NSString *versionString;
/**
The human-readable display version of the update item if provided.
This is the version string shown to the user when they are notified of a new update.
This corresponds to the application update's @c CFBundleShortVersionString
This is extracted from the @c <sparkle:shortVersionString> element, or the @c sparkle:shortVersionString attribute from the @c <enclosure> element.
*/
@property (copy, readonly, nullable) NSString *displayVersionString;
/**
The file URL to the update item if provided.
This download contains the actual update Sparkle will attempt to install.
In cases where a download cannot be provided, an `infoURL` must be provided instead.
A file URL should have an accompanying `contentLength` provided.
This is extracted from the @c url attribute in the @c <enclosure> element.
*/
@property (readonly, nullable) NSURL *fileURL;
/**
The content length of the download in bytes.
This property is used as a fallback when the server doesn't report the content length of the download.
In that case, it is used to report progress of the downloading update to the user.
A warning is outputted if this property is not equal the server's expected content length (if provided).
This is extracted from the @c length attribute in the @c <enclosure> element.
It should be specified if a `fileURL` is provided.
*/
@property (nonatomic, readonly) uint64_t contentLength;
/**
The info URL to the update item if provided.
This informational link is used to direct the user to learn more about an update they cannot download/install directly from within the application.
The link should point to the product's web page.
The informational link will be used if `informationOnlyUpdate` is @c YES
This is extracted from the @c <link> element.
*/
@property (readonly, nullable) NSURL *infoURL;
/**
Indicates whether or not the update item is only informational and has no download.
If `infoURL` is not present, this is @c NO
If `fileURL` is not present, this is @c YES
Otherwise this is determined based on the contents extracted from the @c <sparkle:informationalUpdate> element.
*/
@property (getter=isInformationOnlyUpdate, readonly) BOOL informationOnlyUpdate;
/**
The title of the appcast item if provided.
This is extracted from the @c <title> element.
*/
@property (copy, readonly, nullable) NSString *title;
/**
The date string of the appcast item if provided.
The `date` property is constructed from this property and expects this string to comply with the following date format:
`E, dd MMM yyyy HH:mm:ss Z`
This is extracted from the @c <pubDate> element.
*/
@property (copy, readonly, nullable) NSString *dateString;
/**
The date constructed from the `dateString` property if provided.
Sparkle by itself only uses this property for phased group rollouts specified via `phasedRolloutInterval`, but clients may query this property too.
This date is constructed using the @c en_US locale.
*/
@property (copy, readonly, nullable) NSDate *date;
/**
The release notes URL of the appcast item if provided.
This external link points to an HTML file that Sparkle downloads and renders to show the user a new or old update item's changelog.
An alternative to using an external release notes link is providing an embedded `itemDescription`.
This is extracted from the @c <sparkle:releaseNotesLink> element.
*/
@property (readonly, nullable) NSURL *releaseNotesURL;
/**
The description of the appcast item if provided.
A description may be provided for inline/embedded release notes for new updates using @c <![CDATA[...]]>
This is an alternative to providing a `releaseNotesURL`.
This is extracted from the @c <description> element.
*/
@property (copy, readonly, nullable) NSString *itemDescription;
/**
The full release notes URL of the appcast item if provided.
The link should point to the product's full changelog.
Sparkle's standard user interface offers to show these full release notes when a user checks for a new update and no new update is available.
This is extracted from the @c <sparkle:fullReleaseNotesLink> element.
*/
@property (readonly, nullable) NSURL *fullReleaseNotesURL;
/**
The required minimum system operating version string for this update if provided.
This version string should contain three period-separated components.
Example: @c 10.12.0
Use `minimumOperatingSystemVersionIsOK` property to test if the current running system passes this requirement.
This is extracted from the @c <sparkle:minimumSystemVersion> element.
*/
@property (copy, readonly, nullable) NSString *minimumSystemVersion;
/**
Indicates whether or not the current running system passes the `minimumSystemVersion` requirement.
*/
@property (nonatomic, readonly) BOOL minimumOperatingSystemVersionIsOK;
/**
The required maximum system operating version string for this update if provided.
A maximum system operating version requirement should only be made in unusual scenarios.
This version string should contain three period-separated components.
Example: @c 10.13.0
Use `maximumOperatingSystemVersionIsOK` property to test if the current running system passes this requirement.
This is extracted from the @c <sparkle:maximumSystemVersion> element.
*/
@property (copy, readonly, nullable) NSString *maximumSystemVersion;
/**
Indicates whether or not the current running system passes the `maximumSystemVersion` requirement.
*/
@property (nonatomic, readonly) BOOL maximumOperatingSystemVersionIsOK;
/**
The channel the update item is on if provided.
An update item may specify a custom channel name (such as @c beta) that can only be found by updaters that filter for that channel.
If no channel is provided, the update item is assumed to be on the default channel.
This is extracted from the @c <sparkle:channel> element.
Old applications must be using Sparkle 2 or later to interpret the channel element and to ignore unmatched channels.
*/
@property (nonatomic, readonly, nullable) NSString *channel;
/**
The installation type of the update at `fileURL`
This may be:
- @c application - indicates this is a regular application update.
- @c package - indicates this is a guided package installer update.
- @c interactive-package - indicates this is an interactive package installer update (deprecated; use "package" instead)
This is extracted from the @c sparkle:installationType attribute in the @c <enclosure> element.
If no installation type is provided in the enclosure, the installation type is inferred from the `fileURL` file extension instead.
If the file extension is @c pkg or @c mpkg, the installation type is @c package otherwise it is @c application
Hence, the installation type in the enclosure element only needs to be specified for package based updates distributed inside of a @c zip or other archive format.
Old applications must be using Sparkle 1.26 or later to support downloading bare package updates (`pkg` or `mpkg`) that are not additionally archived inside of a @c zip or other archive format.
*/
@property (nonatomic, copy, readonly) NSString *installationType;
/**
The phased rollout interval of the update item in seconds if provided.
This is the interval between when different groups of users are notified of a new update.
For this property to be used by Sparkle, the published `date` on the update item must be present as well.
After each interval after the update item's `date`, a new group of users become eligible for being notified of the new update.
This is extracted from the @c <sparkle:phasedRolloutInterval> element.
Old applications must be using Sparkle 1.25 or later to support phased rollout intervals, otherwise they may assume updates are immediately available.
*/
@property (copy, readonly, nullable) NSNumber* phasedRolloutInterval;
/**
The minimum bundle version string this update requires for automatically downloading and installing updates if provided.
If an application's bundle version meets this version requirement, it can install the new update item in the background automatically.
Otherwise if the requirement is not met, the user is always prompted to install the update. In this case, the update is assumed to be a `majorUpgrade`.
If the update is a `majorUpgrade` and the update is skipped by the user, other future update alerts with the same `minimumAutoupdateVersion` will also be skipped automatically unless an update specifies `ignoreSkippedUpgradesBelowVersion`.
This version string corresponds to the application's @c CFBundleVersion
This is extracted from the @c <sparkle:minimumAutoupdateVersion> element.
*/
@property (copy, readonly, nullable) NSString *minimumAutoupdateVersion;
/**
Indicates whether or not the update item is a major upgrade.
An update is a major upgrade if the application's bundle version doesn't meet the `minimumAutoupdateVersion` requirement.
*/
@property (getter=isMajorUpgrade, readonly) BOOL majorUpgrade;
/**
Previously skipped upgrades by the user will be ignored if they skipped an update whose version precedes this version.
This can only be applied if the update is a `majorUpgrade`.
This version string corresponds to the application's @c CFBundleVersion
This is extracted from the @c <sparkle:ignoreSkippedUpgradesBelowVersion> element.
Old applications must be using Sparkle 2.1 or later, otherwise this property will be ignored.
*/
@property (nonatomic, readonly, nullable) NSString *ignoreSkippedUpgradesBelowVersion;
/**
Indicates whether or not the update item is critical.
Critical updates are shown to the user more promptly. Sparkle's standard user interface also does not allow them to be skipped.
This is determined and extracted from a top-level @c <sparkle:criticalUpdate> element or a @c sparkle:criticalUpdate element inside of a @c sparkle:tags element.
Old applications must be using Sparkle 2 or later to support the top-level @c <sparkle:criticalUpdate> element.
*/
@property (getter=isCriticalUpdate, readonly) BOOL criticalUpdate;
/**
Specifies the operating system the download update is available for if provided.
If this property is not provided, then the supported operating system is assumed to be macOS.
Known potential values for this string are @c macos and @c windows
Sparkle on Mac ignores update items that are for other operating systems.
This is only useful for sharing appcasts between Sparkle on Mac and Sparkle on other operating systems.
Use `macOsUpdate` property to test if this update item is for macOS.
This is extracted from the @c sparkle:os attribute in the @c <enclosure> element.
*/
@property (copy, readonly, nullable) NSString *osString;
/**
Indicates whether or not this update item is for macOS.
This is determined from the `osString` property.
*/
@property (getter=isMacOsUpdate, readonly) BOOL macOsUpdate;
/**
The delta updates for this update item.
Sparkle uses these to download and apply a smaller update based on the version the user is updating from.
The key is based on the @c sparkle:version of the update.
The value is an update item that will have `deltaUpdate` be @c YES
Clients typically should not need to examine the contents of the delta updates.
This is extracted from the @c <sparkle:deltas> element.
*/
@property (copy, readonly, nullable) NSDictionary<NSString *, SUAppcastItem *> *deltaUpdates;
/**
Indicates whether or not the update item is a delta update.
An update item is a delta update if it is in the `deltaUpdates` of another update item.
*/
@property (getter=isDeltaUpdate, readonly) BOOL deltaUpdate;
/**
The dictionary representing the entire appcast item.
This is useful for querying custom extensions or elements from the appcast item.
*/
@property (readonly, copy) NSDictionary *propertiesDictionary;
- (instancetype)init NS_UNAVAILABLE;
/**
An empty appcast item.
This may be used as a potential return value in `-[SPUUpdaterDelegate bestValidUpdateInAppcast:forUpdater:]`
*/
+ (instancetype)emptyAppcastItem;
// Deprecated initializers
- (nullable instancetype)initWithDictionary:(NSDictionary *)dict __deprecated_msg("Properties that depend on the system or application version are not supported when used with this initializer. The designated initializer is available in SUAppcastItem+Private.h. Please first explore other APIs or contact us to describe your use case.");
- (nullable instancetype)initWithDictionary:(NSDictionary *)dict failureReason:(NSString * _Nullable __autoreleasing *_Nullable)error __deprecated_msg("Properties that depend on the system or application version are not supported when used with this initializer. The designated initializer is available in SUAppcastItem+Private.h. Please first explore other APIs or contact us to describe your use case.");
- (nullable instancetype)initWithDictionary:(NSDictionary *)dict relativeToURL:(NSURL * _Nullable)appcastURL failureReason:(NSString * _Nullable __autoreleasing *_Nullable)error __deprecated_msg("Properties that depend on the system or application version are not supported when used with this initializer. The designated initializer is available in SUAppcastItem+Private.h. Please first explore other APIs or contact us to describe your use case.");
@end
NS_ASSUME_NONNULL_END
#endif

View File

@ -0,0 +1,111 @@
//
// SUErrors.h
// Sparkle
//
// Created by C.W. Betts on 10/13/14.
// Copyright (c) 2014 Sparkle Project. All rights reserved.
//
#ifndef SUERRORS_H
#define SUERRORS_H
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#if defined(BUILDING_SPARKLE_TOOL) || defined(BUILDING_SPARKLE_TESTS)
// Ignore incorrect warning
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wquoted-include-in-framework-header"
#import "SUExport.h"
#pragma clang diagnostic pop
#else
#import <Sparkle/SUExport.h>
#endif
/**
* Error domain used by Sparkle
*/
SU_EXPORT extern NSString *const SUSparkleErrorDomain;
typedef NS_ENUM(OSStatus, SUError) {
// Configuration phase errors
SUNoPublicDSAFoundError = 0001,
SUInsufficientSigningError = 0002,
SUInsecureFeedURLError = 0003,
SUInvalidFeedURLError = 0004,
SUInvalidUpdaterError = 0005,
SUInvalidHostBundleIdentifierError = 0006,
SUInvalidHostVersionError = 0007,
// Appcast phase errors.
SUAppcastParseError = 1000,
SUNoUpdateError = 1001,
SUAppcastError = 1002,
SURunningFromDiskImageError = 1003,
SUResumeAppcastError = 1004,
SURunningTranslocated = 1005,
SUWebKitTerminationError = 1006,
// Download phase errors.
SUTemporaryDirectoryError = 2000,
SUDownloadError = 2001,
// Extraction phase errors.
SUUnarchivingError = 3000,
SUSignatureError = 3001,
SUValidationError = 3002,
// Installation phase errors.
SUFileCopyFailure = 4000,
SUAuthenticationFailure = 4001,
SUMissingUpdateError = 4002,
SUMissingInstallerToolError = 4003,
SURelaunchError = 4004,
SUInstallationError = 4005,
SUDowngradeError = 4006,
SUInstallationCanceledError = 4007,
SUInstallationAuthorizeLaterError = 4008,
SUNotValidUpdateError = 4009,
SUAgentInvalidationError = 4010,
// API misuse errors.
SUIncorrectAPIUsageError = 5000
};
/**
The reason why a new update is not available.
*/
typedef NS_ENUM(OSStatus, SPUNoUpdateFoundReason) {
/**
A new update is unavailable for an unknown reason.
*/
SPUNoUpdateFoundReasonUnknown,
/**
A new update is unavailable because the user is on the latest known version in the appcast feed.
*/
SPUNoUpdateFoundReasonOnLatestVersion,
/**
A new update is unavailable because the user is on a version newer than the latest known version in the appcast feed.
*/
SPUNoUpdateFoundReasonOnNewerThanLatestVersion,
/**
A new update is unavailable because the user's operating system version is too old for the update.
*/
SPUNoUpdateFoundReasonSystemIsTooOld,
/**
A new update is unavailable because the user's operating system version is too new for the update.
*/
SPUNoUpdateFoundReasonSystemIsTooNew
};
SU_EXPORT extern NSString *const SPUNoUpdateFoundReasonKey;
SU_EXPORT extern NSString *const SPULatestAppcastItemFoundKey;
SU_EXPORT extern NSString *const SPUNoUpdateFoundUserInitiatedKey;
#endif

View File

@ -0,0 +1,18 @@
//
// SUExport.h
// Sparkle
//
// Created by Jake Petroules on 2014-08-23.
// Copyright (c) 2014 Sparkle Project. All rights reserved.
//
#ifndef SUEXPORT_H
#define SUEXPORT_H
#ifdef BUILDING_SPARKLE
#define SU_EXPORT __attribute__((visibility("default")))
#else
#define SU_EXPORT
#endif
#endif

View File

@ -0,0 +1,70 @@
//
// SUStandardVersionComparator.h
// Sparkle
//
// Created by Andy Matuschak on 12/21/07.
// Copyright 2007 Andy Matuschak. All rights reserved.
//
#ifndef SUSTANDARDVERSIONCOMPARATOR_H
#define SUSTANDARDVERSIONCOMPARATOR_H
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#ifdef BUILDING_SPARKLE_TOOL
// Ignore incorrect warning
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wquoted-include-in-framework-header"
#import "SUExport.h"
#import "SUVersionComparisonProtocol.h"
#pragma clang diagnostic pop
#else
#import <Sparkle/SUExport.h>
#import <Sparkle/SUVersionComparisonProtocol.h>
#endif
NS_ASSUME_NONNULL_BEGIN
/**
Sparkle's default version comparator.
This comparator is adapted from MacPAD, by Kevin Ballard.
It's "dumb" in that it does essentially string comparison,
in components split by character type.
*/
SU_EXPORT @interface SUStandardVersionComparator : NSObject <SUVersionComparison>
/**
Initializes a new instance of the standard version comparator.
*/
- (instancetype)init;
/**
A singleton instance of the comparator.
*/
@property (nonatomic, class, readonly) SUStandardVersionComparator *defaultComparator;
/**
Compares two version strings through textual analysis.
These version strings should be in the format of x, x.y, or x.y.z where each component is a number.
For example, valid version strings include "1.5.3", "500", or "4000.1"
These versions that are compared correspond to the @c CFBundleVersion values of the updates.
@param versionA The first version string to compare.
@param versionB The second version string to compare.
@return A comparison result between @c versionA and @c versionB
*/
- (NSComparisonResult)compareVersion:(NSString *)versionA toVersion:(NSString *)versionB;
@end
NS_ASSUME_NONNULL_END
#endif

View File

@ -0,0 +1,47 @@
//
// SUUpdatePermissionResponse.h
// Sparkle
//
// Created by Mayur Pawashe on 2/8/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
/**
This class represents a response for permission to check updates.
*/
SU_EXPORT @interface SUUpdatePermissionResponse : NSObject<NSSecureCoding>
/**
Initializes a new update permission response instance.
@param automaticUpdateChecks Flag for whether to allow automatic update checks.
@param sendSystemProfile Flag for if system profile information should be sent to the server hosting the appcast.
*/
- (instancetype)initWithAutomaticUpdateChecks:(BOOL)automaticUpdateChecks sendSystemProfile:(BOOL)sendSystemProfile;
/*
Use -initWithAutomaticUpdateChecks:sendSystemProfile: instead.
*/
- (instancetype)init NS_UNAVAILABLE;
/**
A read-only property indicating whether automatic update checks are allowed or not.
*/
@property (nonatomic, readonly) BOOL automaticUpdateChecks;
/**
A read-only property indicating if system profile should be sent or not.
*/
@property (nonatomic, readonly) BOOL sendSystemProfile;
@end

View File

@ -0,0 +1,207 @@
//
// SUUpdater.h
// Sparkle
//
// Created by Andy Matuschak on 1/4/06.
// Copyright 2006 Andy Matuschak. All rights reserved.
//
#ifndef SUUPDATER_H
#define SUUPDATER_H
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
#import <Sparkle/SUVersionComparisonProtocol.h>
#import <Sparkle/SUVersionDisplayProtocol.h>
#import <Sparkle/SUUpdaterDelegate.h>
@class SUAppcastItem, SUAppcast, NSMenuItem;
@protocol SUUpdaterDelegate;
/**
The legacy API in Sparkle for controlling the update mechanism.
This class is now deprecated and acts as a thin wrapper around `SPUUpdater` and `SPUStandardUserDriver`.
If you are migrating to Sparkle 2, use `SPUStandardUpdaterController` instead, or `SPUUpdater` if you need more control.
*/
__deprecated_msg("Deprecated in Sparkle 2. Use SPUStandardUpdaterController instead, or SPUUpdater if you need more control.")
SU_EXPORT @interface SUUpdater : NSObject
@property (unsafe_unretained, nonatomic) IBOutlet id<SUUpdaterDelegate> delegate;
/*!
The shared updater for the main bundle.
This is equivalent to passing [NSBundle mainBundle] to SUUpdater::updaterForBundle:
*/
+ (SUUpdater *)sharedUpdater;
/*!
The shared updater for a specified bundle.
If an updater has already been initialized for the provided bundle, that shared instance will be returned.
*/
+ (SUUpdater *)updaterForBundle:(NSBundle *)bundle;
/*!
Designated initializer for SUUpdater.
If an updater has already been initialized for the provided bundle, that shared instance will be returned.
*/
- (instancetype)initForBundle:(NSBundle *)bundle;
/*!
Explicitly checks for updates and displays a progress dialog while doing so.
This method is meant for a main menu item.
Connect any menu item to this action in Interface Builder,
and Sparkle will check for updates and report back its findings verbosely
when it is invoked.
This will find updates that the user has opted into skipping.
*/
- (IBAction)checkForUpdates:(id)sender;
/*!
The menu item validation used for the -checkForUpdates: action
*/
- (BOOL)validateMenuItem:(NSMenuItem *)menuItem;
/*!
Checks for updates, but does not display any UI unless an update is found.
This is meant for programmatically initating a check for updates. That is,
it will display no UI unless it actually finds an update, in which case it
proceeds as usual.
If automatic downloading of updates it turned on and allowed, however,
this will invoke that behavior, and if an update is found, it will be downloaded
in the background silently and will be prepped for installation.
This will not find updates that the user has opted into skipping.
*/
- (void)checkForUpdatesInBackground;
/*!
A property indicating whether or not to check for updates automatically.
Setting this property will persist in the host bundle's user defaults.
The update schedule cycle will be reset in a short delay after the property's new value is set.
This is to allow reverting this property without kicking off a schedule change immediately
*/
@property (nonatomic) BOOL automaticallyChecksForUpdates;
/*!
A property indicating whether or not updates can be automatically downloaded in the background.
Note that automatic downloading of updates can be disallowed by the developer.
In this case, -automaticallyDownloadsUpdates will return NO regardless of how this property is set.
Setting this property will persist in the host bundle's user defaults.
*/
@property (nonatomic) BOOL automaticallyDownloadsUpdates;
/*!
A property indicating the current automatic update check interval.
Setting this property will persist in the host bundle's user defaults.
The update schedule cycle will be reset in a short delay after the property's new value is set.
This is to allow reverting this property without kicking off a schedule change immediately
*/
@property (nonatomic) NSTimeInterval updateCheckInterval;
/*!
Begins a "probing" check for updates which will not actually offer to
update to that version.
However, the delegate methods
SUUpdaterDelegate::updater:didFindValidUpdate: and
SUUpdaterDelegate::updaterDidNotFindUpdate: will be called,
so you can use that information in your UI.
Updates that have been skipped by the user will not be found.
*/
- (void)checkForUpdateInformation;
/*!
The URL of the appcast used to download update information.
Setting this property will persist in the host bundle's user defaults.
If you don't want persistence, you may want to consider instead implementing
SUUpdaterDelegate::feedURLStringForUpdater: or SUUpdaterDelegate::feedParametersForUpdater:sendingSystemProfile:
This property must be called on the main thread.
*/
@property (nonatomic, copy) NSURL *feedURL;
/*!
The host bundle that is being updated.
*/
@property (readonly, nonatomic) NSBundle *hostBundle;
/*!
The bundle this class (SUUpdater) is loaded into.
*/
@property (nonatomic, readonly) NSBundle *sparkleBundle;
/*!
The user agent used when checking for and downloading updates.
The default implementation can be overrided.
*/
@property (nonatomic, copy) NSString *userAgentString;
/*!
The HTTP headers used when checking for and downloading updates.
The keys of this dictionary are HTTP header fields (NSString) and values are corresponding values (NSString)
*/
@property (copy) NSDictionary<NSString *, NSString *> *httpHeaders;
/*!
A property indicating whether or not the user's system profile information is sent when checking for updates.
Setting this property will persist in the host bundle's user defaults.
*/
@property (nonatomic) BOOL sendsSystemProfile;
/*!
A property indicating the decryption password used for extracting updates shipped as Apple Disk Images (dmg)
*/
@property (nonatomic, copy) NSString *decryptionPassword;
/*!
Returns the date of last update check.
\returns \c nil if no check has been performed.
*/
@property (nonatomic, readonly, copy) NSDate *lastUpdateCheckDate;
/*!
Appropriately schedules or cancels the update checking timer according to
the preferences for time interval and automatic checks.
This call does not change the date of the next check,
but only the internal NSTimer.
*/
- (void)resetUpdateCycle;
/*!
A property indicating whether or not an update is in progress.
Note this property is not indicative of whether or not user initiated updates can be performed.
Use SUUpdater::validateMenuItem: for that instead.
*/
@property (nonatomic, readonly) BOOL updateInProgress;
@end
#endif

View File

@ -0,0 +1,344 @@
//
// SUUpdaterDelegate.h
// Sparkle
//
// Created by Mayur Pawashe on 3/12/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
@protocol SUVersionComparison, SUVersionDisplay;
@class SUUpdater, SUAppcast, SUAppcastItem;
NS_ASSUME_NONNULL_BEGIN
// -----------------------------------------------------------------------------
// SUUpdater Notifications for events that might be interesting to more than just the delegate
// The updater will be the notification object
// -----------------------------------------------------------------------------
SU_EXPORT extern NSString *const SUUpdaterDidFinishLoadingAppCastNotification;
SU_EXPORT extern NSString *const SUUpdaterDidFindValidUpdateNotification;
SU_EXPORT extern NSString *const SUUpdaterDidNotFindUpdateNotification;
SU_EXPORT extern NSString *const SUUpdaterWillRestartNotification;
#define SUUpdaterWillRelaunchApplicationNotification SUUpdaterWillRestartNotification;
#define SUUpdaterWillInstallUpdateNotification SUUpdaterWillRestartNotification;
// Key for the SUAppcastItem object in the SUUpdaterDidFindValidUpdateNotification userInfo
SU_EXPORT extern NSString *const SUUpdaterAppcastItemNotificationKey;
// Key for the SUAppcast object in the SUUpdaterDidFinishLoadingAppCastNotification userInfo
SU_EXPORT extern NSString *const SUUpdaterAppcastNotificationKey;
// -----------------------------------------------------------------------------
// SUUpdater Delegate:
// -----------------------------------------------------------------------------
/*!
Provides methods to control the behavior of an SUUpdater object.
*/
__deprecated_msg("Deprecated in Sparkle 2. See SPUUpdaterDelegate instead")
@protocol SUUpdaterDelegate <NSObject>
@optional
/*!
Returns whether to allow Sparkle to pop up.
For example, this may be used to prevent Sparkle from interrupting a setup assistant.
\param updater The SUUpdater instance.
*/
- (BOOL)updaterMayCheckForUpdates:(SUUpdater *)updater;
/*!
Returns additional parameters to append to the appcast URL's query string.
This is potentially based on whether or not Sparkle will also be sending along the system profile.
\param updater The SUUpdater instance.
\param sendingProfile Whether the system profile will also be sent.
\return An array of dictionaries with keys: "key", "value", "displayKey", "displayValue", the latter two being specifically for display to the user.
*/
- (NSArray<NSDictionary<NSString *, NSString *> *> *)feedParametersForUpdater:(SUUpdater *)updater sendingSystemProfile:(BOOL)sendingProfile;
/*!
Returns a custom appcast URL.
Override this to dynamically specify the entire URL.
An alternative may be to use SUUpdaterDelegate::feedParametersForUpdater:sendingSystemProfile:
and let the server handle what kind of feed to provide.
\param updater The SUUpdater instance.
*/
- (nullable NSString *)feedURLStringForUpdater:(SUUpdater *)updater;
/*!
Returns whether Sparkle should prompt the user about automatic update checks.
Use this to override the default behavior.
\param updater The SUUpdater instance.
*/
- (BOOL)updaterShouldPromptForPermissionToCheckForUpdates:(SUUpdater *)updater;
/*!
Called after Sparkle has downloaded the appcast from the remote server.
Implement this if you want to do some special handling with the appcast once it finishes loading.
\param updater The SUUpdater instance.
\param appcast The appcast that was downloaded from the remote server.
*/
- (void)updater:(SUUpdater *)updater didFinishLoadingAppcast:(SUAppcast *)appcast;
/*!
Returns the item in the appcast corresponding to the update that should be installed.
If you're using special logic or extensions in your appcast,
implement this to use your own logic for finding a valid update, if any,
in the given appcast.
\param appcast The appcast that was downloaded from the remote server.
\param updater The SUUpdater instance.
*/
- (nullable SUAppcastItem *)bestValidUpdateInAppcast:(SUAppcast *)appcast forUpdater:(SUUpdater *)updater;
/*!
Called when a valid update is found by the update driver.
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that is proposed to be installed.
*/
- (void)updater:(SUUpdater *)updater didFindValidUpdate:(SUAppcastItem *)item;
/*!
Called when a valid update is not found.
\param updater The SUUpdater instance.
*/
- (void)updaterDidNotFindUpdate:(SUUpdater *)updater;
/*!
Called immediately before downloading the specified update.
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that is proposed to be downloaded.
\param request The mutable URL request that will be used to download the update.
*/
- (void)updater:(SUUpdater *)updater willDownloadUpdate:(SUAppcastItem *)item withRequest:(NSMutableURLRequest *)request;
/*!
Called immediately after succesfull download of the specified update.
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that has been downloaded.
*/
- (void)updater:(SUUpdater *)updater didDownloadUpdate:(SUAppcastItem *)item;
/*!
Called after the specified update failed to download.
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that failed to download.
\param error The error generated by the failed download.
*/
- (void)updater:(SUUpdater *)updater failedToDownloadUpdate:(SUAppcastItem *)item error:(NSError *)error;
/*!
Called when the user clicks the cancel button while and update is being downloaded.
\param updater The SUUpdater instance.
*/
- (void)userDidCancelDownload:(SUUpdater *)updater;
/*!
Called immediately before extracting the specified downloaded update.
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that is proposed to be extracted.
*/
- (void)updater:(SUUpdater *)updater willExtractUpdate:(SUAppcastItem *)item;
/*!
Called immediately after extracting the specified downloaded update.
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that has been extracted.
*/
- (void)updater:(SUUpdater *)updater didExtractUpdate:(SUAppcastItem *)item;
/*!
Called immediately before installing the specified update.
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that is proposed to be installed.
*/
- (void)updater:(SUUpdater *)updater willInstallUpdate:(SUAppcastItem *)item;
/*!
Called when an update is skipped by the user.
\param updater The updater instance.
\param item The appcast item corresponding to the update that the user skipped.
*/
- (void)updater:(SUUpdater *)updater userDidSkipThisVersion:(SUAppcastItem *)item;
/*!
Returns whether the relaunch should be delayed in order to perform other tasks.
This is not called if the user didn't relaunch on the previous update,
in that case it will immediately restart.
This may also not be called if the application is not going to relaunch after it terminates.
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that is proposed to be installed.
\param invocation The invocation that must be completed with `[invocation invoke]` before continuing with the relaunch.
\return \c YES to delay the relaunch until \p invocation is invoked.
*/
- (BOOL)updater:(SUUpdater *)updater shouldPostponeRelaunchForUpdate:(SUAppcastItem *)item untilInvoking:(NSInvocation *)invocation;
/*!
Returns whether the relaunch should be delayed in order to perform other tasks.
This is not called if the user didn't relaunch on the previous update,
in that case it will immediately restart.
This method acts as a simpler alternative to SUUpdaterDelegate::updater:shouldPostponeRelaunchForUpdate:untilInvoking: avoiding usage of NSInvocation, which is not available in Swift environments.
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that is proposed to be installed.
\return \c YES to delay the relaunch.
*/
- (BOOL)updater:(SUUpdater *)updater shouldPostponeRelaunchForUpdate:(SUAppcastItem *)item;
/*!
Returns whether the application should be relaunched at all.
Some apps \b cannot be relaunched under certain circumstances.
This method can be used to explicitly prevent a relaunch.
\param updater The SUUpdater instance.
*/
- (BOOL)updaterShouldRelaunchApplication:(SUUpdater *)updater;
/*!
Called immediately before relaunching.
\param updater The SUUpdater instance.
*/
- (void)updaterWillRelaunchApplication:(SUUpdater *)updater;
/*!
Called immediately after relaunching. SUUpdater delegate must be set before applicationDidFinishLaunching: to catch this event.
\param updater The SUUpdater instance.
*/
- (void)updaterDidRelaunchApplication:(SUUpdater *)updater;
/*!
Returns an object that compares version numbers to determine their arithmetic relation to each other.
This method allows you to provide a custom version comparator.
If you don't implement this method or return \c nil,
the standard version comparator will be used. Note that the
standard version comparator may be used during installation for preventing
a downgrade, even if you provide a custom comparator here.
\sa SUStandardVersionComparator
\param updater The SUUpdater instance.
*/
- (nullable id<SUVersionComparison>)versionComparatorForUpdater:(SUUpdater *)updater;
/*!
Returns an object that formats version numbers for display to the user.
If you don't implement this method or return \c nil, the standard version formatter will be used.
\sa SUUpdateAlert
\param updater The SUUpdater instance.
*/
- (nullable id <SUVersionDisplay>)versionDisplayerForUpdater:(SUUpdater *)updater;
/*!
Returns the path to the application which is used to relaunch after the update is installed.
The installer also waits for the termination of the application at this path.
The default is the path of the host bundle.
\param updater The SUUpdater instance.
*/
- (nullable NSString *)pathToRelaunchForUpdater:(SUUpdater *)updater;
/*!
Called before an updater shows a modal alert window,
to give the host the opportunity to hide attached windows that may get in the way.
\param updater The SUUpdater instance.
*/
- (void)updaterWillShowModalAlert:(SUUpdater *)updater;
/*!
Called after an updater shows a modal alert window,
to give the host the opportunity to hide attached windows that may get in the way.
\param updater The SUUpdater instance.
*/
- (void)updaterDidShowModalAlert:(SUUpdater *)updater;
/*!
Called when an update is scheduled to be silently installed on quit.
This is after an update has been automatically downloaded in the background.
(i.e. SUUpdater::automaticallyDownloadsUpdates is YES)
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that is proposed to be installed.
\param invocation Can be used to trigger an immediate silent install and relaunch.
*/
- (void)updater:(SUUpdater *)updater willInstallUpdateOnQuit:(SUAppcastItem *)item immediateInstallationInvocation:(NSInvocation *)invocation;
/*!
Called when an update is scheduled to be silently installed on quit.
This is after an update has been automatically downloaded in the background.
(i.e. SUUpdater::automaticallyDownloadsUpdates is YES)
This method acts as a more modern alternative to SUUpdaterDelegate::updater:willInstallUpdateOnQuit:immediateInstallationInvocation: using a block instead of NSInvocation, which is not available in Swift environments.
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that is proposed to be installed.
\param installationBlock Can be used to trigger an immediate silent install and relaunch.
*/
- (void)updater:(SUUpdater *)updater willInstallUpdateOnQuit:(SUAppcastItem *)item immediateInstallationBlock:(void (^)(void))installationBlock;
/*!
Calls after an update that was scheduled to be silently installed on quit has been canceled.
\param updater The SUUpdater instance.
\param item The appcast item corresponding to the update that was proposed to be installed.
\deprecated This method is no longer invoked. The installer will try to its best ability to install the update.
*/
- (void)updater:(SUUpdater *)updater didCancelInstallUpdateOnQuit:(SUAppcastItem *)item __deprecated;
/*!
Called after an update is aborted due to an error.
\param updater The SUUpdater instance.
\param error The error that caused the abort
*/
- (void)updater:(SUUpdater *)updater didAbortWithError:(NSError *)error;
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,49 @@
//
// SUVersionComparisonProtocol.h
// Sparkle
//
// Created by Andy Matuschak on 12/21/07.
// Copyright 2007 Andy Matuschak. All rights reserved.
//
#ifndef SUVERSIONCOMPARISONPROTOCOL_H
#define SUVERSIONCOMPARISONPROTOCOL_H
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#ifdef BUILDING_SPARKLE_TOOL
// Ignore incorrect warning
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wquoted-include-in-framework-header"
#import "SUExport.h"
#pragma clang diagnostic pop
#else
#import <Sparkle/SUExport.h>
#endif
NS_ASSUME_NONNULL_BEGIN
/**
Provides version comparison facilities for Sparkle.
*/
@protocol SUVersionComparison
/**
An abstract method to compare two version strings.
Should return NSOrderedAscending if b > a, NSOrderedDescending if b < a,
and NSOrderedSame if they are equivalent.
*/
- (NSComparisonResult)compareVersion:(NSString *)versionA toVersion:(NSString *)versionB; // *** MAY BE CALLED ON NON-MAIN THREAD!
@end
NS_ASSUME_NONNULL_END
#endif

View File

@ -0,0 +1,32 @@
//
// SUVersionDisplayProtocol.h
// EyeTV
//
// Created by Uli Kusterer on 08.12.09.
// Copyright 2009 Elgato Systems GmbH. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
/**
Applies special display formatting to version numbers.
*/
SU_EXPORT @protocol SUVersionDisplay
/**
Formats two version strings.
Both versions are provided so that important distinguishing information
can be displayed while also leaving out unnecessary/confusing parts.
*/
- (void)formatVersion:(NSString *_Nonnull*_Nonnull)inOutVersionA andVersion:(NSString *_Nonnull*_Nonnull)inOutVersionB;
@end

View File

@ -0,0 +1,39 @@
//
// Sparkle.h
// Sparkle
//
// Created by Andy Matuschak on 3/16/06. (Modified by CDHW on 23/12/07)
// Copyright 2006 Andy Matuschak. All rights reserved.
//
#ifndef SPARKLE_H
#define SPARKLE_H
// This list should include the shared headers. It doesn't matter if some of them aren't shared (unless
// there are name-space collisions) so we can list all of them to start with:
#import <Sparkle/SUExport.h>
#import <Sparkle/SUAppcast.h>
#import <Sparkle/SUAppcastItem.h>
#import <Sparkle/SUStandardVersionComparator.h>
#import <Sparkle/SPUUpdater.h>
#import <Sparkle/SPUUpdaterDelegate.h>
#import <Sparkle/SPUUpdaterSettings.h>
#import <Sparkle/SUVersionComparisonProtocol.h>
#import <Sparkle/SUVersionDisplayProtocol.h>
#import <Sparkle/SUErrors.h>
#import <Sparkle/SPUUpdatePermissionRequest.h>
#import <Sparkle/SUUpdatePermissionResponse.h>
#import <Sparkle/SPUUserDriver.h>
#import <Sparkle/SPUDownloadData.h>
// UI bits
#import <Sparkle/SPUStandardUpdaterController.h>
#import <Sparkle/SPUStandardUserDriver.h>
#import <Sparkle/SPUStandardUserDriverDelegate.h>
// Deprecated bits
#import <Sparkle/SUUpdater.h>
#import <Sparkle/SUUpdaterDelegate.h>
#endif

View File

@ -0,0 +1,6 @@
framework module Sparkle {
umbrella header "Sparkle.h"
export *
module * { export * }
}

View File

@ -0,0 +1,37 @@
//
// SPUAppcastItemStateResolver.h
// Sparkle
//
// Created by Mayur Pawashe on 5/31/21.
// Copyright © 2021 Sparkle Project. All rights reserved.
//
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
#import <Sparkle/SUExport.h>
NS_ASSUME_NONNULL_BEGIN
@class SUStandardVersionComparator, SPUAppcastItemState;
@protocol SUVersionComparison;
/**
Private exposed class used to resolve Appcast Item properties that rely on external factors such as a host.
This resolver is used for constructing appcast items.
*/
SU_EXPORT @interface SPUAppcastItemStateResolver : NSObject
- (instancetype)init NS_UNAVAILABLE;
- (instancetype)initWithHostVersion:(NSString *)hostVersion applicationVersionComparator:(id<SUVersionComparison>)applicationVersionComparator standardVersionComparator:(SUStandardVersionComparator *)standardVersionComparator;
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,19 @@
//
// SPUInstallationType.h
// Sparkle
//
// Created by Mayur Pawashe on 7/24/16.
// Copyright © 2016 Sparkle Project. All rights reserved.
//
#ifndef SPUInstallationType_h
#define SPUInstallationType_h
#define SPUInstallationTypeApplication @"application" // the default installation type for ordinary application updates
#define SPUInstallationTypeGuidedPackage @"package" // the preferred installation type for package installations
#define SPUInstallationTypeInteractivePackage @"interactive-package" // the deprecated installation type; use guided package instead
#define SPUInstallationTypesArray (@[SPUInstallationTypeApplication, SPUInstallationTypeGuidedPackage, SPUInstallationTypeInteractivePackage])
#define SPUValidInstallationType(x) ((x != nil) && [SPUInstallationTypesArray containsObject:(NSString * _Nonnull)x])
#endif /* SPUInstallationType_h */

View File

@ -0,0 +1,20 @@
//
// SPUUserAgent+Private.h
// Sparkle
//
// Created by Mayur Pawashe on 11/12/21.
// Copyright © 2021 Sparkle Project. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <Sparkle/SUExport.h>
NS_ASSUME_NONNULL_BEGIN
@class SUHost;
SU_EXPORT NSString *SPUMakeUserAgentWithHost(SUHost *responsibleHost, NSString * _Nullable displayNameSuffix);
SU_EXPORT NSString *SPUMakeUserAgentWithBundle(NSBundle *responsibleBundle, NSString * _Nullable displayNameSuffix);
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,45 @@
//
// SUAppcastItem+Private.h
// Sparkle
//
// Created by Mayur Pawashe on 4/30/21.
// Copyright © 2021 Sparkle Project. All rights reserved.
//
#ifndef SUAppcastItem_Private_h
#define SUAppcastItem_Private_h
#if __has_feature(modules)
#if __has_warning("-Watimport-in-framework-header")
#pragma clang diagnostic ignored "-Watimport-in-framework-header"
#endif
@import Foundation;
#else
#import <Foundation/Foundation.h>
#endif
NS_ASSUME_NONNULL_BEGIN
// Available in SPUAppcastItemStateResolver.h (a private exposed header)
@class SPUAppcastItemStateResolver;
@interface SUAppcastItem (Private) <NSSecureCoding>
/**
Initializes with data from a dictionary provided by the RSS class and state resolver
This initializer method is intended to be marked "private" and discouraged from public usage.
This method is available however. Talk to us to describe your use case and if you need to construct appcast items yourself.
*/
- (nullable instancetype)initWithDictionary:(NSDictionary *)dict relativeToURL:(NSURL * _Nullable)appcastURL stateResolver:(SPUAppcastItemStateResolver *)stateResolver failureReason:(NSString * _Nullable __autoreleasing *_Nullable)error;
/**
The DSA and EdDSA signatures along with their statuses.
*/
@property (readonly, nullable) SUSignatures *signatures;
@end
NS_ASSUME_NONNULL_END
#endif /* SUAppcastItem_Private_h */

View File

@ -0,0 +1,29 @@
//
// SUInstallerLauncher+Private.h
// SUInstallerLauncher+Private
//
// Created by Mayur Pawashe on 8/21/21.
// Copyright © 2021 Sparkle Project. All rights reserved.
//
#ifndef SUInstallerLauncher_Private_h
#define SUInstallerLauncher_Private_h
#import <Sparkle/SUExport.h>
// Chances are clients will need this too
#import <Sparkle/SPUInstallationType.h>
@class NSString;
/**
Private API for determining if the system needs authorization access to update a bundle path
This API is not supported when used directly from a Sandboxed applications and will always return @c YES in that case.
@param bundlePath The bundle path to test if authorization is needed when performing an update that replaces this bundle.
@return @c YES if Sparkle thinks authorization is needed to update the @c bundlePath, otherwise @c NO.
*/
SU_EXPORT BOOL SPUSystemNeedsAuthorizationAccessForBundlePath(NSString *bundlePath);
#endif /* SUInstallerLauncher_Private_h */

View File

@ -0,0 +1,48 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>BuildMachineOSBuild</key>
<string>20G415</string>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleExecutable</key>
<string>Sparkle</string>
<key>CFBundleIdentifier</key>
<string>org.sparkle-project.Sparkle</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>Sparkle</string>
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>2.1.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleSupportedPlatforms</key>
<array>
<string>MacOSX</string>
</array>
<key>CFBundleVersion</key>
<string>2013</string>
<key>DTCompiler</key>
<string>com.apple.compilers.llvm.clang.1_0</string>
<key>DTPlatformBuild</key>
<string>13C100</string>
<key>DTPlatformName</key>
<string>macosx</string>
<key>DTPlatformVersion</key>
<string>12.1</string>
<key>DTSDKBuild</key>
<string>21C46</string>
<key>DTSDKName</key>
<string>macosx12.1</string>
<key>DTXcode</key>
<string>1321</string>
<key>DTXcodeBuild</key>
<string>13C100</string>
<key>LSMinimumSystemVersion</key>
<string>10.11</string>
</dict>
</plist>

View File

@ -0,0 +1,12 @@
@media (prefers-color-scheme: dark) {
html {
color: white;
background: transparent;
}
:link {
color: #419CFF;
}
:link:active {
color: #FF1919;
}
}

View File

@ -0,0 +1,314 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>ADP2,1</key>
<string>Developer Transition Kit</string>
<key>iMac1,1</key>
<string>iMac G3 (Rev A-D)</string>
<key>iMac4,1</key>
<string>iMac (Core Duo)</string>
<key>iMac4,2</key>
<string>iMac for Education (17 inch, Core Duo)</string>
<key>iMac5,1</key>
<string>iMac (Core 2 Duo, 17 or 20 inch, SuperDrive)</string>
<key>iMac5,2</key>
<string>iMac (Core 2 Duo, 17 inch, Combo Drive)</string>
<key>iMac6,1</key>
<string>iMac (Core 2 Duo, 24 inch, SuperDrive)</string>
<key>iMac7,1</key>
<string>iMac Intel Core 2 Duo (aluminum enclosure)</string>
<key>iMac8,1</key>
<string>iMac (Core 2 Duo, 20 or 24 inch, Early 2008 )</string>
<key>iMac9,1</key>
<string>iMac (Core 2 Duo, 20 or 24 inch, Early or Mid 2009 )</string>
<key>iMac10,1</key>
<string>iMac (Core 2 Duo, 21.5 or 27 inch, Late 2009 )</string>
<key>iMac11,1</key>
<string>iMac (Core i5 or i7, 27 inch Late 2009)</string>
<key>iMac11,2</key>
<string>21.5&quot; iMac (mid 2010)</string>
<key>iMac11,3</key>
<string>iMac (Core i5 or i7, 27 inch Mid 2010)</string>
<key>iMac12,1</key>
<string>iMac (Core i3 or i5 or i7, 21.5 inch Mid 2010 or Late 2011)</string>
<key>iMac12,2</key>
<string>iMac (Core i5 or i7, 27 inch Mid 2011)</string>
<key>iMac13,1</key>
<string>iMac (Core i3 or i5 or i7, 21.5 inch Late 2012 or Early 2013)</string>
<key>iMac13,2</key>
<string>iMac (Core i5 or i7, 27 inch Late 2012)</string>
<key>iMac14,1</key>
<string>iMac (Core i5, 21.5 inch Late 2013)</string>
<key>iMac14,2</key>
<string>iMac (Core i5 or i7, 27 inch Late 2013)</string>
<key>iMac14,3</key>
<string>iMac (Core i5 or i7, 21.5 inch Late 2013)</string>
<key>iMac14,4</key>
<string>iMac (Core i5, 21.5 inch Mid 2014)</string>
<key>iMac15,1</key>
<string>iMac (Retina 5K Core i5 or i7, 27 inch Late 2014 or Mid 2015)</string>
<key>iMac16,1</key>
<string>iMac (Core i5, 21,5 inch Late 2015)</string>
<key>iMac16,2</key>
<string>iMac (Retina 4K Core i5 or i7, 21.5 inch Late 2015)</string>
<key>iMac17,1</key>
<string>iMac (Retina 5K Core i5 or i7, 27 inch Late 2015)</string>
<key>MacBook1,1</key>
<string>MacBook (Core Duo)</string>
<key>MacBook2,1</key>
<string>MacBook (Core 2 Duo)</string>
<key>MacBook4,1</key>
<string>MacBook (Core 2 Duo Feb 2008)</string>
<key>MacBook5,1</key>
<string>MacBook (Core 2 Duo, Late 2008, Unibody)</string>
<key>MacBook5,2</key>
<string>MacBook (Core 2 Duo, Early 2009, White)</string>
<key>MacBook6,1</key>
<string>MacBook (Core 2 Duo, Late 2009, Unibody)</string>
<key>MacBook7,1</key>
<string>MacBook (Core 2 Duo, Mid 2010, White)</string>
<key>MacBook8,1</key>
<string>MacBook (Core M, 12 inch, Early 2015)</string>
<key>MacBookAir1,1</key>
<string>MacBook Air (Core 2 Duo, 13 inch, Early 2008)</string>
<key>MacBookAir2,1</key>
<string>MacBook Air (Core 2 Duo, 13 inch, Mid 2009)</string>
<key>MacBookAir3,1</key>
<string>MacBook Air (Core 2 Duo, 11 inch, Late 2010)</string>
<key>MacBookAir3,2</key>
<string>MacBook Air (Core 2 Duo, 13 inch, Late 2010)</string>
<key>MacBookAir4,1</key>
<string>MacBook Air (Core i5 or i7, 11 inch, Mid 2011)</string>
<key>MacBookAir4,2</key>
<string>MacBook Air (Core i5 or i7, 13 inch, Mid 2011)</string>
<key>MacBookAir5,1</key>
<string>MacBook Air (Core i5 or i7, 11 inch, Mid 2012)</string>
<key>MacBookAir5,2</key>
<string>MacBook Air (Core i5 or i7, 13 inch, Mid 2012)</string>
<key>MacBookAir6,1</key>
<string>MacBook Air (Core i5 or i7, 11 inch, Mid 2013 or Early 2014)</string>
<key>MacBookAir6,2</key>
<string>MacBook Air (Core i5 or i7, 13 inch, Mid 2013 or Early 2014)</string>
<key>MacBookAir7,1</key>
<string>MacBook Air (Core i5 or i7, 11 inch, Early 2015)</string>
<key>MacBookAir7,2</key>
<string>MacBook Air (Core i5 or i7, 13 inch, Early 2015)</string>
<key>MacBookPro1,1</key>
<string>MacBook Pro Core Duo (15-inch)</string>
<key>MacBookPro1,2</key>
<string>MacBook Pro Core Duo (17-inch)</string>
<key>MacBookPro2,1</key>
<string>MacBook Pro Core 2 Duo (17-inch)</string>
<key>MacBookPro2,2</key>
<string>MacBook Pro Core 2 Duo (15-inch)</string>
<key>MacBookPro3,1</key>
<string>MacBook Pro Core 2 Duo (15-inch LED, Core 2 Duo)</string>
<key>MacBookPro3,2</key>
<string>MacBook Pro Core 2 Duo (17-inch HD, Core 2 Duo)</string>
<key>MacBookPro4,1</key>
<string>MacBook Pro (Core 2 Duo Feb 2008)</string>
<key>MacBookPro5,1</key>
<string>MacBook Pro Intel Core 2 Duo (aluminum unibody)</string>
<key>MacBookPro5,2</key>
<string>MacBook Pro Intel Core 2 Duo (aluminum unibody)</string>
<key>MacBookPro5,3</key>
<string>MacBook Pro Intel Core 2 Duo (aluminum unibody)</string>
<key>MacBookPro5,4</key>
<string>MacBook Pro Intel Core 2 Duo (aluminum unibody)</string>
<key>MacBookPro5,5</key>
<string>MacBook Pro Intel Core 2 Duo (aluminum unibody)</string>
<key>MacBookPro6,1</key>
<string>MacBook Pro Intel Core i5, Intel Core i7 (mid 2010)</string>
<key>MacBookPro6,2</key>
<string>MacBook Pro Intel Core i5, Intel Core i7 (mid 2010)</string>
<key>MacBookPro7,1</key>
<string>MacBook Pro Intel Core 2 Duo (mid 2010)</string>
<key>MacBookPro8,1</key>
<string>MacBook Pro Intel Core i5, Intel Core i7, 13&quot; (early 2011)</string>
<key>MacBookPro8,2</key>
<string>MacBook Pro Intel Core i7, 15&quot; (early 2011)</string>
<key>MacBookPro8,3</key>
<string>MacBook Pro Intel Core i7, 17&quot; (early 2011)</string>
<key>MacBookPro9,1</key>
<string>MacBook Pro (15-inch, Mid 2012)</string>
<key>MacBookPro9,2</key>
<string>MacBook Pro (13-inch, Mid 2012)</string>
<key>MacBookPro10,1</key>
<string>MacBook Pro (Retina, Mid 2012)</string>
<key>MacBookPro10,2</key>
<string>MacBook Pro (Retina, 13-inch, Late 2012)</string>
<key>MacBookPro11,1</key>
<string>MacBook Pro (Retina, 13-inch, Late 2013)</string>
<key>MacBookPro11,2</key>
<string>MacBook Pro (Retina, 15-inch, Late 2013)</string>
<key>MacBookPro11,3</key>
<string>MacBook Pro (Retina, 15-inch, Late 2013)</string>
<key>MacbookPro11,4</key>
<string>MacBook Pro (Retina, 15-inch, Mid 2015)</string>
<key>MacbookPro11,5</key>
<string>MacBook Pro (Retina, 15-inch, Mid 2015)</string>
<key>MacbookPro12,1 </key>
<string>MacBook Pro (Retina, 13-inch, Early 2015)</string>
<key>Macmini1,1</key>
<string>Mac Mini (Core Solo/Duo)</string>
<key>Macmini2,1</key>
<string>Mac mini Intel Core</string>
<key>Macmini3,1</key>
<string>Mac mini Intel Core</string>
<key>Macmini4,1</key>
<string>Mac mini Intel Core (Mid 2010)</string>
<key>Macmini5,1</key>
<string>Mac mini (Core i5, Mid 2011)</string>
<key>Macmini5,2</key>
<string>Mac mini (Core i5 or Core i7, Mid 2011)</string>
<key>Macmini5,3</key>
<string>Mac mini (Core i7, Server, Mid 2011)</string>
<key>Macmini6,1</key>
<string>Mac mini (Core i5, Late 2012)</string>
<key>Macmini6,2</key>
<string>Mac mini (Core i7, Normal or Server, Late 2012)</string>
<key>Macmini7,1</key>
<string>Mac mini (Core i5 or Core i7, Late 2014)</string>
<key>MacPro1,1,Quad</key>
<string>Mac Pro</string>
<key>MacPro1,1</key>
<string>Mac Pro (four-core)</string>
<key>MacPro2,1</key>
<string>Mac Pro (eight-core)</string>
<key>MacPro3,1</key>
<string>Mac Pro (January 2008 4- or 8- core &quot;Harpertown&quot;)</string>
<key>MacPro4,1</key>
<string>Mac Pro (March 2009)</string>
<key>MacPro5,1</key>
<string>Mac Pro (2010 or 2012)</string>
<key>MacPro6,1</key>
<string>Mac Pro (Late 2013)</string>
<key>PowerBook1,1</key>
<string>PowerBook G3</string>
<key>PowerBook2,1</key>
<string>iBook G3</string>
<key>PowerBook2,2</key>
<string>iBook G3 (FireWire)</string>
<key>PowerBook2,3</key>
<string>iBook G3</string>
<key>PowerBook2,4</key>
<string>iBook G3</string>
<key>PowerBook3,1</key>
<string>PowerBook G3 (FireWire)</string>
<key>PowerBook3,2</key>
<string>PowerBook G4</string>
<key>PowerBook3,3</key>
<string>PowerBook G4 (Gigabit Ethernet)</string>
<key>PowerBook3,4</key>
<string>PowerBook G4 (DVI)</string>
<key>PowerBook3,5</key>
<string>PowerBook G4 (1GHz / 867MHz)</string>
<key>PowerBook4,1</key>
<string>iBook G3 (Dual USB, Late 2001)</string>
<key>PowerBook4,2</key>
<string>iBook G3 (16MB VRAM)</string>
<key>PowerBook4,3</key>
<string>iBook G3 Opaque 16MB VRAM, 32MB VRAM, Early 2003)</string>
<key>PowerBook5,1</key>
<string>PowerBook G4 (17 inch)</string>
<key>PowerBook5,2</key>
<string>PowerBook G4 (15 inch FW 800)</string>
<key>PowerBook5,3</key>
<string>PowerBook G4 (17-inch 1.33GHz)</string>
<key>PowerBook5,4</key>
<string>PowerBook G4 (15 inch 1.5/1.33GHz)</string>
<key>PowerBook5,5</key>
<string>PowerBook G4 (17-inch 1.5GHz)</string>
<key>PowerBook5,6</key>
<string>PowerBook G4 (15 inch 1.67GHz/1.5GHz)</string>
<key>PowerBook5,7</key>
<string>PowerBook G4 (17-inch 1.67GHz)</string>
<key>PowerBook5,8</key>
<string>PowerBook G4 (Double layer SD, 15 inch)</string>
<key>PowerBook5,9</key>
<string>PowerBook G4 (Double layer SD, 17 inch)</string>
<key>PowerBook6,1</key>
<string>PowerBook G4 (12 inch)</string>
<key>PowerBook6,2</key>
<string>PowerBook G4 (12 inch, DVI)</string>
<key>PowerBook6,3</key>
<string>iBook G4</string>
<key>PowerBook6,4</key>
<string>PowerBook G4 (12 inch 1.33GHz)</string>
<key>PowerBook6,5</key>
<string>iBook G4 (Early-Late 2004)</string>
<key>PowerBook6,7</key>
<string>iBook G4 (Mid 2005)</string>
<key>PowerBook6,8</key>
<string>PowerBook G4 (12 inch 1.5GHz)</string>
<key>PowerMac1,1</key>
<string>Power Macintosh G3 (Blue &amp; White)</string>
<key>PowerMac1,2</key>
<string>Power Macintosh G4 (PCI Graphics)</string>
<key>PowerMac2,1</key>
<string>iMac G3 (Slot-loading CD-ROM)</string>
<key>PowerMac2,2</key>
<string>iMac G3 (Summer 2000)</string>
<key>PowerMac3,1</key>
<string>Power Macintosh G4 (AGP Graphics)</string>
<key>PowerMac3,2</key>
<string>Power Macintosh G4 (AGP Graphics)</string>
<key>PowerMac3,3</key>
<string>Power Macintosh G4 (Gigabit Ethernet)</string>
<key>PowerMac3,4</key>
<string>Power Macintosh G4 (Digital Audio)</string>
<key>PowerMac3,5</key>
<string>Power Macintosh G4 (Quick Silver)</string>
<key>PowerMac3,6</key>
<string>Power Macintosh G4 (Mirrored Drive Door)</string>
<key>PowerMac4,1</key>
<string>iMac G3 (Early/Summer 2001)</string>
<key>PowerMac4,2</key>
<string>iMac G4 (Flat Panel)</string>
<key>PowerMac4,4</key>
<string>eMac</string>
<key>PowerMac4,5</key>
<string>iMac G4 (17-inch Flat Panel)</string>
<key>PowerMac5,1</key>
<string>Power Macintosh G4 Cube</string>
<key>PowerMac5,2</key>
<string>Power Mac G4 Cube</string>
<key>PowerMac6,1</key>
<string>iMac G4 (USB 2.0)</string>
<key>PowerMac6,3</key>
<string>iMac G4 (20-inch Flat Panel)</string>
<key>PowerMac6,4</key>
<string>eMac (USB 2.0, 2005)</string>
<key>PowerMac7,2</key>
<string>Power Macintosh G5</string>
<key>PowerMac7,3</key>
<string>Power Macintosh G5</string>
<key>PowerMac8,1</key>
<string>iMac G5</string>
<key>PowerMac8,2</key>
<string>iMac G5 (Ambient Light Sensor)</string>
<key>PowerMac9,1</key>
<string>Power Macintosh G5 (Late 2005)</string>
<key>PowerMac10,1</key>
<string>Mac Mini G4</string>
<key>PowerMac10,2</key>
<string>Mac Mini (Late 2005)</string>
<key>PowerMac11,2</key>
<string>Power Macintosh G5 (Late 2005)</string>
<key>PowerMac12,1</key>
<string>iMac G5 (iSight)</string>
<key>RackMac1,1</key>
<string>Xserve G4</string>
<key>RackMac1,2</key>
<string>Xserve G4 (slot-loading, cluster node)</string>
<key>RackMac3,1</key>
<string>Xserve G5</string>
<key>Xserve1,1</key>
<string>Xserve (Intel Xeon)</string>
<key>Xserve2,1</key>
<string>Xserve (January 2008 quad-core)</string>
<key>Xserve3,1</key>
<string>Xserve (early 2009)</string>
</dict>
</plist>

View File

@ -0,0 +1,17 @@
/* Class = "NSWindow"; title = "Software Update"; ObjectID = "5"; */
"5.title" = "Actualització del programari";
/* Class = "NSTextFieldCell"; title = "Release Notes:"; ObjectID = "170"; */
"170.title" = "Notes d'aquesta versió:";
/* Class = "NSButtonCell"; title = "Remind Me Later"; ObjectID = "171"; */
"171.title" = "Recorda-m'ho més tard";
/* Class = "NSButtonCell"; title = "Skip This Version"; ObjectID = "172"; */
"172.title" = "Omet aquesta versió";
/* Class = "NSButtonCell"; title = "Install Update"; ObjectID = "173"; */
"173.title" = "Instal·la l'actualització";
/* Class = "NSButtonCell"; title = "Automatically download and install updates in the future"; ObjectID = "175"; */
"175.title" = "Descarrega i instal·la les actualitzacions automàticament en el futur";

View File

@ -0,0 +1,17 @@
/* Class = "NSWindow"; title = "Software Update"; ObjectID = "5"; */
"5.title" = "Aktualizace aplikace";
/* Class = "NSTextFieldCell"; title = "Release Notes:"; ObjectID = "170"; */
"170.title" = "Poznámky k vydání:";
/* Class = "NSButtonCell"; title = "Remind Me Later"; ObjectID = "171"; */
"171.title" = "Připomenout později";
/* Class = "NSButtonCell"; title = "Skip This Version"; ObjectID = "172"; */
"172.title" = "Přeskočit tuto verzi";
/* Class = "NSButtonCell"; title = "Install Update"; ObjectID = "173"; */
"173.title" = "Instalovat aktualizaci";
/* Class = "NSButtonCell"; title = "Automatically download and install updates in the future"; ObjectID = "175"; */
"175.title" = "V budoucnu stahovat a instalovat aktualizace automaticky";

View File

@ -0,0 +1,23 @@
/* Class = "NSTextFieldCell"; title = "Text Cell"; ObjectID = "43"; */
"43.title" = "Text Cell";
/* Class = "NSTextFieldCell"; title = "Text Cell"; ObjectID = "45"; */
"45.title" = "Text Cell";
/* Class = "NSButtonCell"; title = "Check Automatically"; ObjectID = "176"; */
"OhZ-1K-DmA.title" = "Automaticky vyhledávat";
/* Class = "NSButtonCell"; title = "Dont Check"; ObjectID = "177"; */
"cCJ-V0-aTi.title" = "Nevyhledávat";
/* Class = "NSTextFieldCell"; title = "Check for updates automatically?"; ObjectID = "178"; */
"gmh-T4-BO0.title" = "Vyhledávat aktualizace automaticky?";
/* Class = "NSTextFieldCell"; title = "DO NOT LOCALIZE"; ObjectID = "179"; */
"179.title" = "DO NOT LOCALIZE";
/* Class = "NSButtonCell"; title = "Include anonymous system profile"; ObjectID = "180"; */
"gz7-LM-gNf.title" = "Odeslat anonymní systémový profil";
/* Class = "NSTextFieldCell"; title = "Anonymous system profile information is used to help us plan future development work.\nPlease contact us if you have any questions about this.\n\nThis is the information that would be sent:"; ObjectID = "183"; */
"183.title" = "Informace z anonymního systémového profilu pomáhají vývojářům lépe plánovat budoucí vývoj aplikace.\nBudete-li mít nějaký dotaz, obraťte se na nás.\n\nToto jsou informace, které budou odeslány:";

View File

@ -0,0 +1,18 @@
/* Class = "NSWindow"; title = "Software Update"; ObjectID = "5"; */
"5.title" = "Softwareupdate";
/* Class = "NSTextFieldCell"; title = "Release Notes:"; ObjectID = "170"; */
"170.title" = "Versionshinweise:";
/* Class = "NSButtonCell"; title = "Remind Me Later"; ObjectID = "171"; */
"171.title" = "Später erinnern";
/* Class = "NSButtonCell"; title = "Skip This Version"; ObjectID = "172"; */
"172.title" = "Diese Version überspringen";
/* Class = "NSButtonCell"; title = "Install Update"; ObjectID = "173"; */
"173.title" = "Installieren";
/* Class = "NSButtonCell"; title = "Automatically download and install updates in the future"; ObjectID = "175"; */
"175.title" = "Updates in Zukunft automatisch laden und installieren";

View File

@ -0,0 +1,21 @@
/* Class = "NSTextFieldCell"; title = "Text Cell"; ObjectID = "43"; */
"43.title" = "";
/* Class = "NSTextFieldCell"; title = "Text Cell"; ObjectID = "45"; */
"45.title" = "";
/* Class = "NSTextFieldCell"; title = "Anonymous system profile information is used to help us plan future development work. Please contact us if you have any questions about this.\n\nThis is the information that would be sent:"; ObjectID = "183"; */
"183.title" = "Das anonymisierte Systemprofil unterstützt uns bei der zukünftigen Entwicklung. Bitte kontaktiere uns, wenn du Fragen hierzu hast.\n\nDiese Informationen würden an uns gesendet werden:";
/* Class = "NSButtonCell"; title = "Dont Check"; ObjectID = "cCJ-V0-aTi"; */
"cCJ-V0-aTi.title" = "Nicht suchen";
/* Class = "NSTextFieldCell"; title = "Check for updates automatically?"; ObjectID = "gmh-T4-BO0"; */
"gmh-T4-BO0.title" = "Automatisch nach Updates suchen?";
/* Class = "NSButtonCell"; title = "Include anonymous system profile"; ObjectID = "gz7-LM-gNf"; */
"gz7-LM-gNf.title" = "Anonymisiertes Systemprofil übertragen";
/* Class = "NSButtonCell"; title = "Check Automatically"; ObjectID = "OhZ-1K-DmA"; */
"OhZ-1K-DmA.title" = "Automatisch suchen";

View File

@ -0,0 +1,18 @@
/* Class = "NSWindow"; title = "Software Update"; ObjectID = "5"; */
"5.title" = "Software Update";
/* Class = "NSTextFieldCell"; title = "Release Notes:"; ObjectID = "170"; */
"170.title" = "Release Notes:";
/* Class = "NSButtonCell"; title = "Remind Me Later"; ObjectID = "171"; */
"171.title" = "Remind Me Later";
/* Class = "NSButtonCell"; title = "Skip This Version"; ObjectID = "172"; */
"172.title" = "Skip This Version";
/* Class = "NSButtonCell"; title = "Install Update"; ObjectID = "173"; */
"173.title" = "Install Update";
/* Class = "NSButtonCell"; title = "Automatically download and install updates in the future"; ObjectID = "175"; */
"175.title" = "Automatically download and install updates in the future";

View File

@ -0,0 +1,24 @@
/* Class = "NSTextFieldCell"; title = "Text Cell"; ObjectID = "43"; */
"43.title" = "Text Cell";
/* Class = "NSTextFieldCell"; title = "Text Cell"; ObjectID = "45"; */
"45.title" = "Text Cell";
/* Class = "NSButtonCell"; title = "Check Automatically"; ObjectID = "176"; */
"OhZ-1K-DmA.title" = "Check Automatically";
/* Class = "NSButtonCell"; title = "Dont Check"; ObjectID = "177"; */
"cCJ-V0-aTi.title" = "Dont Check";
/* Class = "NSTextFieldCell"; title = "Check for updates automatically?"; ObjectID = "178"; */
"gmh-T4-BO0.title" = "Check for updates automatically?";
/* Class = "NSTextFieldCell"; title = "DO NOT LOCALIZE"; ObjectID = "179"; */
"179.title" = "DO NOT LOCALIZE";
/* Class = "NSButtonCell"; title = "Include anonymous system profile"; ObjectID = "180"; */
"gz7-LM-gNf.title" = "Include anonymous system profile";
/* Class = "NSTextFieldCell"; title = "Anonymous system profile information is used to help us plan future development work. Please contact us if you have any questions about this.\n\nThis is the information that would be sent:"; ObjectID = "183"; */
"183.title" = "Anonymous system profile information is used to help us plan future development work. Please contact us if you have any questions about this.\n\nThis is the information that would be sent:";

View File

@ -0,0 +1,18 @@
/* Class = "NSWindow"; title = "Software Update"; ObjectID = "5"; */
"5.title" = "עדכון תכנה";
/* Class = "NSTextFieldCell"; title = "Release Notes:"; ObjectID = "170"; */
"170.title" = "פרטי גרסה:";
/* Class = "NSButtonCell"; title = "Remind Me Later"; ObjectID = "171"; */
"171.title" = "הזכר לי מאוחר יותר";
/* Class = "NSButtonCell"; title = "Skip This Version"; ObjectID = "172"; */
"172.title" = "דלג על גרסה זו";
/* Class = "NSButtonCell"; title = "Install Update"; ObjectID = "173"; */
"173.title" = "התקן עדכון";
/* Class = "NSButtonCell"; title = "Automatically download and install updates in the future"; ObjectID = "175"; */
"175.title" = "הורד והתקן עדכונים אוטומטית גם בעתיד";

Some files were not shown because too many files have changed in this diff Show More