Commit Graph

34 Commits

Author SHA1 Message Date
Zorg 411360deb2 Allow check for updates menu item to be invoked outside of settings
Previously check for updates was only in responder chain of the settings window controller. Now it's in responder chain of the entire application.
2021-04-25 15:48:20 -07:00
Zorg 2066cd7232 Migrate canCheckForUpdates property from user driver -> updater 2021-01-17 17:01:48 -08:00
Philippe Casgrain a10a99ce1a Fixed build issue
Added missing semi-colon that prevented a `make release` build.
2020-02-20 22:59:44 -05:00
Bryan Jones e5e4c6c2e1 Remove most production-reachable instances of abort(). 2020-02-05 23:25:07 -08:00
Zorg 6f337aa6f3 Remove outdated comment about command key being held down in test app 2016-08-26 22:32:49 -04:00
Zorg 46a75cde97 Terminate application in the progress agent instead of user driver
This allows us to remove SPUUserDriverUIComponent and remove a bunch of logic in the user driver regarding termination. The user drivers generally don't need to know about the application bundle anymore, and strictly now only show UI events.

This has another advantage of the agent being able to quit multiple instances of an application even if the application to update is sandboxed.

We enforce the logic that an application can only be relaunched if it was running initially.
2016-08-25 23:46:42 -04:00
Zorg bbfcd564d2 Detect if shift key is held down ASAP when launching test app 2016-08-14 13:44:10 -04:00
Zorg af7952b773 Hold down shift instead of command to use popup titlebar user driver 2016-08-13 14:33:09 -04:00
Zorg 29d790c63c Pass application bundle into SPUUpdater instead of relying on delegate method 2016-08-13 12:57:26 -04:00
Zorg 5114cd9d83 Distinguish between application and host bundle in user drivers 2016-08-13 11:21:15 -04:00
Zorg 92b94343f4 Remove delegate property from SPUStandardUserDriverProtocol
Also remove delegate from user driver core component and popup titlebar user driver.
2016-08-13 09:00:51 -04:00
Zorg b58773cb5e Allow popup titlebar user driver to update other bundles 2016-08-13 08:49:47 -04:00
Zorg 6fb7b4a18b Use popup title user driver when holding down command at launch 2016-08-13 08:39:55 -04:00
Zorg c9f673cda8 Use SPU prefix in many places 2016-08-05 19:10:21 -04:00
Zorg b22d2c2568 Make menu item validation work in the test app 2016-04-03 20:06:56 -04:00
Zorg db4e8a9946 s/SUUpdaterController/SUStandardUpdaterController.m/ 2016-03-04 19:25:25 -05:00
Zorg 15b4d1adf3 Add a "Updater NIB" object for standard sparkle UI
I may consider  extending SUUpdater instead of another controller..
2016-02-28 20:18:06 -05:00
Zorg dccce32beb Temporary fix for running the test application 2016-02-28 15:18:09 -05:00
Zorg 3bf91e795e Move delegate protocol to SUUserUpdaterDriver protocol 2016-02-27 19:59:39 -05:00
Zorg bea00a99e8 Update SULoggerUpdateDriver example 2016-02-27 19:40:09 -05:00
Zorg 3230fd982b Change SUUserUpdaterDriver so that every reply block must get a response
These changes are to make XPC environment more friendly. Every reply block must
get a response and is not optional to respond to. For example we can no longer have
a reply block that is just "cancelUpdate()"; it must now take an option whether
we are done now or if we want to cancel, and the receiver should now be aware
when canceling doesn't make sense (i.e, if update already aborted). Furthermore,
a reply block must get exactly *one* response.
2016-02-27 14:00:28 -05:00
Zorg 14f56c519b Move modal alert delegation to user updater driver 2016-02-23 21:56:14 -05:00
Zorg a6d6e31b2c Remove asking user updater driver if it's showing alerts modally
non-void/synchronous calls over XPC don't work properly, and
these methods don't seem very proper architecture wise anyway.
A proper solution will be needed for notifying the delegate of modal alerts
2016-02-22 23:21:27 -05:00
Zorg 0e97f0b4b6 Handle app termination in the user driver
If an automatic update needs to be applied at termination,
the app delegate will need to hold responsibility of delaying
termination until Sparkle is ready to relaunch
2016-02-21 13:24:54 -05:00
Zorg c3824b4c20 Making dismissUpdateInstallation independent of installation type
Also clean up warnings/temporary comments
2016-02-21 00:26:51 -05:00
Zorg 6b5a3547e7 Cleaning up SUUserUpdateDriver protocol 2016-02-20 23:52:24 -05:00
Zorg 1fad56c4c3 Add user driver methods for automatic updating
Note that the protocol API for the user updater driver can still be improved.

applicationWillTerminate: is done from the user driver because that's the only way that will
function across different processes.
2016-02-20 19:39:48 -05:00
Zorg e6ac015dde Remove opening info URL from being an update alert choice
This option is really "do something in user driver & remind me later"
2016-02-19 21:00:54 -05:00
Zorg 0bb5de196a Remove initializer taking SUHost from SUUserUpdaterDriver 2016-02-19 17:27:44 -05:00
Zorg 1cfbffa74c Making Sparkle more XPC friendly
We support NSSecureCoding for SUAppcastItem and SUHost

Callbacks from XPC <-> Host app now async to main GCD queue.
This is needed for everything to be thread safe.

Todo: NSDate parsing sucks and is temporarily disabled.
In particular, we're using deprecated methods to read the dates,
which don't support NSSecureCoding. The other problem is that the dates are
really useless technically and we shouldn't sort by them.
2016-02-15 00:00:01 -05:00
Zorg 46a2485d9c Created custom user update driver protocol
Everything related to the protocol is intended for showing & dismissing progress,
as well as making UI actions such as canceling, installing, confirming update permissions
2016-02-14 20:57:32 -05:00
Zorg 2ef497afcd Added delegate methods to all UI bits
This is still incomplete and not perfect yet.

In particular, these delegate methods ought to perhaps be grouped in a separate class.

The UI code that is currently done should be treated the same manner as a custom UI

Relaunching Sparkle should give customization over showing the UI of the autoupdater app
2016-02-13 23:09:01 -05:00
Zorg dcd50d54e1 Move build settings to xcconfig
Also enable -Wobjc-missing-property-synthesis because I can't figure out how to turn it off for just the test application
2015-07-26 13:39:41 -04:00
Zorg b165a419d5 Rewrite test app so it works again, and locally
This creates and signs the update on the fly, so
we can alter the test app without too much hassle.
This also starts up a local web server.
Refs #564
2015-07-25 17:02:22 -04:00