mirror of
https://github.com/bitwarden/android.git
synced 2026-03-11 20:54:58 -05:00
PM-17910 Prevent back events from system when coach mark tour is in progress. (#4674)
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
package com.x8bit.bitwarden.ui.platform.components.coachmark
|
||||
|
||||
import androidx.activity.compose.BackHandler
|
||||
import androidx.compose.foundation.background
|
||||
import androidx.compose.foundation.gestures.detectTapGestures
|
||||
import androidx.compose.foundation.layout.Box
|
||||
@@ -132,6 +133,14 @@ fun <T : Enum<T>> CoachMarkContainer(
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Consume system back event when the scrim is visible.
|
||||
BackHandler(
|
||||
enabled = state.isVisible.value,
|
||||
onBack = {
|
||||
// No-op
|
||||
},
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user