Update ActivityKtx.kt
This commit is contained in:
@ -15,4 +15,9 @@ fun Activity.isAllowScreenCapture(isAllow: Boolean) {
|
|||||||
} else {
|
} else {
|
||||||
window?.clearFlags(WindowManager.LayoutParams.FLAG_SECURE)
|
window?.clearFlags(WindowManager.LayoutParams.FLAG_SECURE)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 判断当前 Activity 是否是 [Lifecycle.State.RESUMED]
|
||||||
|
*/
|
||||||
|
fun AppCompatActivity.isResumed(): Boolean = lifecycle.currentState == Lifecycle.State.RESUMED
|
||||||
|
|||||||
Reference in New Issue
Block a user