title: How to lock app in recent apps programmatically in android studio
body: <p>I want the app to be unclosable. I noticed that it can be done if im pressing on the lock button in the recent app screen. Is there any way to lock it programmatically when the app is running?</p>
  
  <p><a href="https://i.stack.imgur.com/kBiWx.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/kBiWx.jpg" alt="enter image description here"></a></p>