allow the app be ran over lockscreen
This commit is contained in:
parent
f73f8ad1c5
commit
b55ebb669c
|
@ -14,6 +14,7 @@
|
|||
|
||||
<uses-permission android:name="android.permission.RECORD_AUDIO"/>
|
||||
<uses-permission android:name="android.permission.CAMERA"/>
|
||||
<uses-permission android:name="android.permission.DISABLE_KEYGUARD"/>
|
||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
|
||||
<uses-permission
|
||||
android:name="android.permission.USE_FINGERPRINT"
|
||||
|
@ -40,6 +41,7 @@
|
|||
<activity
|
||||
android:name=".activities.MainActivity"
|
||||
android:screenOrientation="portrait"
|
||||
android:showOnLockScreen="true"
|
||||
android:theme="@style/FullScreenTheme">
|
||||
|
||||
<intent-filter>
|
||||
|
|
|
@ -51,6 +51,11 @@ class MainActivity : SimpleActivity(), PreviewListener, PhotoProcessor.MediaSave
|
|||
lateinit var mOrientationEventListener: OrientationEventListener
|
||||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
window.addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON or
|
||||
WindowManager.LayoutParams.FLAG_DISMISS_KEYGUARD or
|
||||
WindowManager.LayoutParams.FLAG_SHOW_WHEN_LOCKED or
|
||||
WindowManager.LayoutParams.FLAG_TURN_SCREEN_ON)
|
||||
|
||||
useDynamicTheme = false
|
||||
super.onCreate(savedInstanceState)
|
||||
appLaunched()
|
||||
|
|
|
@ -3,7 +3,6 @@ package com.simplemobiletools.camera.receivers
|
|||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
|
||||
import com.simplemobiletools.camera.activities.MainActivity
|
||||
|
||||
class HardwareShutterReceiver : BroadcastReceiver() {
|
||||
|
|
Loading…
Reference in New Issue