File tree Expand file tree Collapse file tree
UniGetUI.PackageEngine.PackageLoader
UniGetUI/Pages/SoftwarePages Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -55,6 +55,7 @@ protected override IReadOnlyList<IPackage> LoadPackagesFromManager(IPackageManag
5555 {
5656 return manager . GetAvailableUpdates ( ) ;
5757 }
58+
5859 protected override Task WhenAddingPackage ( IPackage package )
5960 {
6061 package . GetAvailablePackage ( ) ? . SetTag ( PackageTag . IsUpgradable ) ;
Original file line number Diff line number Diff line change @@ -350,14 +350,17 @@ protected override async void WhenPackagesLoaded(ReloadReason reason)
350350 NetworkInformation . GetInternetConnectionProfile ( ) ? . GetConnectionCost ( ) . NetworkCostType is NetworkCostType . Fixed or NetworkCostType . Variable )
351351 {
352352 Logger . Warn ( "Updates will not be installed automatically because the current internet connection is metered." ) ;
353+ await ShowAvailableUpdatesNotification ( upgradablePackages ) ;
353354 }
354355 else if ( Settings . Get ( Settings . K . DisableAUPOnBattery ) && PowerManager . PowerSupplyStatus is PowerSupplyStatus . NotPresent )
355356 {
356357 Logger . Warn ( "Updates will not be installed automatically because the device is on battery." ) ;
358+ await ShowAvailableUpdatesNotification ( upgradablePackages ) ;
357359 }
358360 else if ( Settings . Get ( Settings . K . DisableAUPOnBatterySaver ) && PowerManager . EnergySaverStatus is EnergySaverStatus . On )
359361 {
360362 Logger . Warn ( "Updates will not be installed automatically because battery saver is enabled." ) ;
363+ await ShowAvailableUpdatesNotification ( upgradablePackages ) ;
361364 }
362365 else if ( Settings . Get ( Settings . K . AutomaticallyUpdatePackages ) )
363366 {
You can’t perform that action at this time.
0 commit comments