Merge branch 'master' into ui-separation-and-xpc

This commit is contained in:
Zorg committed 2016-12-26 11:04:56 -05:00
commit 55bc22b1ae
3 files changed
+53 -40

No files matched your search

-16
View File
@@ -202,20 +202,4 @@ SU_EXPORT @interface SUUpdater : NSObject
@end
// -----------------------------------------------------------------------------
// 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;
#endif
+30 -24
View File
@@ -51,7 +51,7 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
For example, this may be used to prevent Sparkle from interrupting a setup assistant.
\param updater The updater instance.
\param updater The SUUpdater instance.
*/
- (BOOL)updaterMayCheckForUpdates:(SUUpdater *)updater;
@@ -60,7 +60,7 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
This is potentially based on whether or not Sparkle will also be sending along the system profile.
\param updater The updater instance.
\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.
@@ -72,7 +72,10 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
Override this to dynamically specify the entire URL.
\param updater The updater instance.
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;
@@ -81,7 +84,7 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
Use this to override the default behavior.
\param updater The updater instance.
\param updater The SUUpdater instance.
*/
- (BOOL)updaterShouldPromptForPermissionToCheckForUpdates:(SUUpdater *)updater;
@@ -90,7 +93,7 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
Implement this if you want to do some special handling with the appcast once it finishes loading.
\param updater The updater instance.
\param updater The SUUpdater instance.
\param appcast The appcast that was downloaded from the remote server.
*/
- (void)updater:(SUUpdater *)updater didFinishLoadingAppcast:(SUAppcast *)appcast;
@@ -103,14 +106,14 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
in the given appcast.
\param appcast The appcast that was downloaded from the remote server.
\param updater The updater instance.
\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 updater instance.
\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;
@@ -118,14 +121,14 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
/*!
Called when a valid update is not found.
\param updater The updater instance.
\param updater The SUUpdater instance.
*/
- (void)updaterDidNotFindUpdate:(SUUpdater *)updater;
/*!
Called immediately before downloading the specified update.
\param updater The updater instance.
\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.
*/
@@ -134,7 +137,7 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
/*!
Called after the specified update failed to download.
\param updater The updater instance.
\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.
*/
@@ -143,14 +146,14 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
/*!
Called when the user clicks the cancel button while and update is being downloaded.
\param updater The updater instance.
\param updater The SUUpdater instance.
*/
- (void)userDidCancelDownload:(SUUpdater *)updater;
/*!
Called immediately before installing the specified update.
\param updater The updater instance.
\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;
@@ -163,9 +166,9 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
This may also not be called if the application is not going to relaunch after it terminates.
\param updater The updater instance.
\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 before continuing with the relaunch.
\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.
*/
@@ -177,14 +180,14 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
Some apps \b cannot be relaunched under certain circumstances.
This method can be used to explicitly prevent a relaunch.
\param updater The updater instance.
\param updater The SUUpdater instance.
*/
- (BOOL)updaterShouldRelaunchApplication:(SUUpdater *)updater;
/*!
Called immediately before relaunching.
\param updater The updater instance.
\param updater The SUUpdater instance.
*/
- (void)updaterWillRelaunchApplication:(SUUpdater *)updater;
@@ -199,7 +202,7 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
\sa SUStandardVersionComparator
\param updater The updater instance.
\param updater The SUUpdater instance.
*/
- (nullable id<SUVersionComparison>)versionComparatorForUpdater:(SUUpdater *)updater;
@@ -208,7 +211,7 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
If you don't implement this method or return \c nil, the standard version formatter will be used.
\sa SUUpdateAlert
\param updater The updater instance.
\param updater The SUUpdater instance.
*/
- (nullable id <SUVersionDisplay>)versionDisplayerForUpdater:(SUUpdater *)updater;
@@ -219,7 +222,7 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
The default is the path of the host bundle.
\param updater The updater instance.
\param updater The SUUpdater instance.
*/
- (nullable NSString *)pathToRelaunchForUpdater:(SUUpdater *)updater;
@@ -227,7 +230,7 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
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 updater instance.
\param updater The SUUpdater instance.
*/
- (void)updaterWillShowModalAlert:(SUUpdater *)updater;
@@ -235,14 +238,17 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
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 updater instance.
\param updater The SUUpdater instance.
*/
- (void)updaterDidShowModalAlert:(SUUpdater *)updater;
/*!
Called when an update is scheduled to be silently installed on quit.
\param updater The updater instance.
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.
*/
@@ -251,7 +257,7 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
/*!
Calls after an update that was scheduled to be silently installed on quit has been canceled.
\param updater The updater instance.
\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.
@@ -261,7 +267,7 @@ __deprecated_msg("See SPUUpdaterDelegate instead")
/*!
Called after an update is aborted due to an error.
\param updater The updater instance.
\param updater The SUUpdater instance.
\param error The error that caused the abort
*/
- (void)updater:(SUUpdater *)updater didAbortWithError:(NSError *)error;
+23
View File
@@ -0,0 +1,23 @@
//
// SUUpdaterPrivate.h
// Sparkle
//
// Created by Andy Matuschak on 5/9/11.
// Copyright 2011 Andy Matuschak. All rights reserved.
//
@protocol SUUpdaterDelegate;
@protocol SUUpdaterPrivate <NSObject>
@property (unsafe_unretained) IBOutlet id<SUUpdaterDelegate> delegate;
@property (nonatomic, copy) NSString *userAgentString;
@property (copy) NSDictionary *httpHeaders;
@property (nonatomic, copy) NSString *decryptionPassword;
@property (strong, readonly) NSBundle *sparkleBundle;
@end