#1196 fix access to app from lock screen
This commit is contained in:
parent
fc04a1cf89
commit
4851b997cf
2 changed files with 1 additions and 2 deletions
|
@ -119,7 +119,6 @@
|
|||
android:label="@string/app_name"
|
||||
android:requestLegacyExternalStorage="true"
|
||||
android:roundIcon="@mipmap/ic_launcher_round"
|
||||
android:showWhenLocked="true"
|
||||
android:supportsRtl="true"
|
||||
tools:targetApi="tiramisu">
|
||||
<activity
|
||||
|
@ -128,7 +127,6 @@
|
|||
android:exported="true"
|
||||
android:hardwareAccelerated="true"
|
||||
android:launchMode="singleTop"
|
||||
android:showWhenLocked="true"
|
||||
android:supportsPictureInPicture="true"
|
||||
android:theme="@style/NormalTheme"
|
||||
android:windowSoftInputMode="adjustResize">
|
||||
|
|
|
@ -320,6 +320,7 @@ open class MainActivity : FlutterFragmentActivity() {
|
|||
|
||||
val keyguardManager = getSystemService(Context.KEYGUARD_SERVICE) as android.app.KeyguardManager
|
||||
val isLocked = keyguardManager.isKeyguardLocked
|
||||
setShowWhenLocked(isLocked)
|
||||
if (isLocked) {
|
||||
// device is locked, so access to content is limited to intent URI by default
|
||||
fields[INTENT_DATA_KEY_SECURE_URIS] = listOf(uri.toString())
|
||||
|
|
Loading…
Reference in a new issue