[PM-12711] Auto-Fill selection bug fix (#3981)

This commit is contained in:
Dave Severns 2024-09-27 11:31:34 -04:00 committed by GitHub
parent aaa541dd19
commit 70e75b910c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -36,7 +36,10 @@ fun createAutofillSelectionIntent(
): Intent =
Intent(context, MainActivity::class.java)
.apply {
setFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
// This helps prevent a crash when using the accessibility framework
if (framework == AutofillSelectionData.Framework.ACCESSIBILITY) {
setFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
}
putExtra(
AUTOFILL_BUNDLE_KEY,
bundleOf(