NotificationUtil: Rename general channel to downloads

Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
This commit is contained in:
Aayush Gupta
2024-10-06 22:56:00 +05:30
parent 8abb358f6c
commit ddfa99ec6d
54 changed files with 8 additions and 59 deletions

View File

@@ -38,7 +38,7 @@ object Constants {
const val UPDATE_URL_NIGHTLY = "https://auroraoss.com/downloads/AuroraStore/Feeds/nightly_feed.json"
const val NOTIFICATION_CHANNEL_ALERT = "NOTIFICATION_CHANNEL_ALERT"
const val NOTIFICATION_CHANNEL_GENERAL = "NOTIFICATION_CHANNEL_GENERAL"
const val NOTIFICATION_CHANNEL_DOWNLOADS = "NOTIFICATION_CHANNEL_DOWNLOADS"
const val NOTIFICATION_CHANNEL_UPDATES = "NOTIFICATION_CHANNEL_UPDATES"
const val GITLAB_URL = "https://gitlab.com/AuroraOSS/AuroraStore"

View File

@@ -43,8 +43,8 @@ object NotificationUtil {
)
channels.add(
NotificationChannel(
Constants.NOTIFICATION_CHANNEL_GENERAL,
context.getString(R.string.notification_channel_general),
Constants.NOTIFICATION_CHANNEL_DOWNLOADS,
context.getString(R.string.notification_channel_downloads),
NotificationManager.IMPORTANCE_MIN
)
)
@@ -62,7 +62,7 @@ object NotificationUtil {
}
fun getDownloadNotification(context: Context): Notification {
return NotificationCompat.Builder(context, Constants.NOTIFICATION_CHANNEL_GENERAL)
return NotificationCompat.Builder(context, Constants.NOTIFICATION_CHANNEL_DOWNLOADS)
.setSmallIcon(android.R.drawable.stat_sys_download)
.setContentTitle(context.getString(R.string.app_updater_service_notif_title))
.setContentText(context.getString(R.string.app_updater_service_notif_text))
@@ -76,7 +76,7 @@ object NotificationUtil {
workID: UUID,
largeIcon: Bitmap? = null
): Notification {
val builder = NotificationCompat.Builder(context, Constants.NOTIFICATION_CHANNEL_GENERAL)
val builder = NotificationCompat.Builder(context, Constants.NOTIFICATION_CHANNEL_DOWNLOADS)
builder.setContentTitle(download.displayName)
builder.setContentIntent(getContentIntentForDownloads(context))
builder.setLargeIcon(largeIcon)