Richard Pospesel pushed to branch android-components-102.0.14-11.5-1 at The Tor Project / Applications / android-components
Commits: 311598f4 by Pier Angelo Vendrame at 2022-11-28T18:45:37+01:00 fixup! Bug 40007: Port external helper app prompting
Bug 41481: Updated PendingIntent for API 31.
- - - - -
1 changed file:
- components/support/utils/src/main/java/mozilla/components/support/utils/TorUtils.kt
Changes:
===================================== components/support/utils/src/main/java/mozilla/components/support/utils/TorUtils.kt ===================================== @@ -7,6 +7,7 @@ package mozilla.components.support.utils import android.app.PendingIntent import android.content.Context import android.content.Intent +import mozilla.components.support.utils.PendingIntentUtils
object TorUtils { const val TORBROWSER_START_ACTIVITY_PROMPT = "torbrowser_start_activity_prompt" @@ -19,7 +20,7 @@ object TorUtils { fun startActivityPrompt(context: Context, intent: Intent) { val intentContainer = Intent() intentContainer.setPackage(context.applicationContext.packageName) - intentContainer.putExtra(TORBROWSER_START_ACTIVITY_PROMPT, PendingIntent.getActivity(context, 0, intent, 0)) + intentContainer.putExtra(TORBROWSER_START_ACTIVITY_PROMPT, PendingIntent.getActivity(context, 0, intent, PendingIntentUtils.defaultFlags)) intentContainer.flags = Intent.FLAG_ACTIVITY_NEW_TASK context.startActivity(intentContainer) }
View it on GitLab: https://gitlab.torproject.org/tpo/applications/android-components/-/commit/3...