summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Dan Sandler <dsandler@android.com> 2025-04-29 18:34:25 -0400
committer Android Build Coastguard Worker <android-build-coastguard-worker@google.com> 2025-04-30 11:36:01 -0700
commit0c43bd6c1571f19d8b6f5ffe628dcc970f1176b5 (patch)
treef7b49afb924941846a747af90f6edae1c8da787a
parentcca74a405828413607ac8c9539f817d67bf97834 (diff)
Silence easter egg notifications.
Bug: 412622628 Flag: EXEMPT bugfix Test: adb shell am start -n com.android.egg/.landroid.MainActivity (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:21fb0e179ff72dfe2ba3aa36b980616c0e8d38a3) Merged-In: Id27b0b244580e97a00fa6269e4abd9424329e7be Change-Id: Id27b0b244580e97a00fa6269e4abd9424329e7be
-rw-r--r--packages/EasterEgg/src/com/android/egg/landroid/UniverseProgressNotifier.kt4
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/EasterEgg/src/com/android/egg/landroid/UniverseProgressNotifier.kt b/packages/EasterEgg/src/com/android/egg/landroid/UniverseProgressNotifier.kt
index 705d9e1cf442..da96c3c45beb 100644
--- a/packages/EasterEgg/src/com/android/egg/landroid/UniverseProgressNotifier.kt
+++ b/packages/EasterEgg/src/com/android/egg/landroid/UniverseProgressNotifier.kt
@@ -39,7 +39,7 @@ fun lerpRange(range: ClosedFloatingPointRange<Float>, x: Float): Float =
class UniverseProgressNotifier(val context: Context, val universe: Universe) {
private val notificationId = universe.randomSeed.toInt()
private val chan =
- NotificationChannel(CHANNEL_ID, CHANNEL_NAME, NotificationManager.IMPORTANCE_DEFAULT)
+ NotificationChannel(CHANNEL_ID, CHANNEL_NAME, NotificationManager.IMPORTANCE_LOW)
.apply { lockscreenVisibility = Notification.VISIBILITY_PUBLIC }
private val noman =
context.getSystemService(NotificationManager::class.java)?.apply {
@@ -83,7 +83,7 @@ class UniverseProgressNotifier(val context: Context, val universe: Universe) {
PendingIntent.FLAG_UPDATE_CURRENT or PendingIntent.FLAG_IMMUTABLE,
)
)
- .setPriority(Notification.PRIORITY_DEFAULT)
+ .setFlag(Notification.FLAG_ONLY_ALERT_ONCE, true)
.setColorized(true)
.setOngoing(true)
.setColor(Colors.Eigengrau2.toArgb())