Add update manager which performs no update action

This is to be used in cases where updates are handled by an external
means. See
https://github.com/flathub/flathub/pull/2619#issuecomment-969731305 for
initial usage.
This commit is contained in:
Dean Herbert
2021-11-16 12:11:11 +09:00
parent 83fea71580
commit 3fe89293af
5 changed files with 108 additions and 23 deletions

View File

@ -93,6 +93,11 @@ namespace osu.Desktop
protected override UpdateManager CreateUpdateManager()
{
string packageManaged = Environment.GetEnvironmentVariable("OSU_EXTERNAL_UPDATE_PROVIDER");
if (!string.IsNullOrEmpty(packageManaged))
return new NoActionUpdateManager();
switch (RuntimeInfo.OS)
{
case RuntimeInfo.Platform.Windows: