mirror of
https://github.com/ImranR98/Obtainium.git
synced 2025-10-29 12:33:28 +01:00
Shizuku logic 2: Determination of installation
This commit is contained in:
@@ -41,20 +41,26 @@ class UpdateNotification extends ObtainiumNotification {
|
||||
}
|
||||
|
||||
class SilentUpdateNotification extends ObtainiumNotification {
|
||||
SilentUpdateNotification(List<App> updates, {int? id})
|
||||
SilentUpdateNotification(List<App> updates, bool succeeded, {int? id})
|
||||
: super(
|
||||
id ?? 3,
|
||||
tr('appsUpdated'),
|
||||
succeeded
|
||||
? tr('appsUpdated')
|
||||
: tr('appsNotUpdated'),
|
||||
'',
|
||||
'APPS_UPDATED',
|
||||
tr('appsUpdatedNotifChannel'),
|
||||
tr('appsUpdatedNotifDescription'),
|
||||
Importance.defaultImportance) {
|
||||
message = updates.length == 1
|
||||
? tr('xWasUpdatedToY',
|
||||
args: [updates[0].finalName, updates[0].latestVersion])
|
||||
: plural('xAndNMoreUpdatesInstalled', updates.length - 1,
|
||||
args: [updates[0].finalName, (updates.length - 1).toString()]);
|
||||
? tr(succeeded
|
||||
? 'xWasUpdatedToY'
|
||||
: 'xWasNotUpdatedToY',
|
||||
args: [updates[0].finalName, updates[0].latestVersion])
|
||||
: plural(succeeded
|
||||
? 'xAndNMoreUpdatesInstalled'
|
||||
: "xAndNMoreUpdatesFailed",
|
||||
updates.length - 1, args: [updates[0].finalName, (updates.length - 1).toString()]);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user