mirror of
https://codeberg.org/timelimit/timelimit-android.git
synced 2025-10-06 03:50:23 +02:00
Show status notification without delay at Android 12
This commit is contained in:
parent
70f04bf49f
commit
3d5a5a338f
2 changed files with 2 additions and 1 deletions
|
@ -160,6 +160,7 @@ dependencies {
|
|||
implementation fileTree(dir: 'libs', include: ['*.jar'])
|
||||
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
|
||||
implementation 'androidx.appcompat:appcompat:1.3.1'
|
||||
implementation 'androidx.core:core:1.7.0-beta01'
|
||||
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
|
||||
implementation 'androidx.cardview:cardview:1.0.0'
|
||||
implementation 'androidx.gridlayout:gridlayout:1.0.0'
|
||||
|
|
|
@ -82,7 +82,7 @@ class BackgroundService: Service() {
|
|||
.setOngoing(true)
|
||||
.setPriority(NotificationCompat.PRIORITY_LOW)
|
||||
.setVisibility(NotificationCompat.VISIBILITY_SECRET)
|
||||
// TODO: Use setForegroundServiceBehavior() when this builder supports it
|
||||
.setForegroundServiceBehavior(NotificationCompat.FOREGROUND_SERVICE_IMMEDIATE)
|
||||
.let { builder ->
|
||||
if (appStatusMessage.showSwitchToDefaultUserOption) {
|
||||
builder.addAction(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue