forked from jens/Automation
bug when picking app to start
This commit is contained in:
parent
52a10fe626
commit
3f36c4c6b3
@ -378,7 +378,7 @@ public class ActivityManageActionStartActivity extends Activity
|
||||
public void onClick(View v)
|
||||
{
|
||||
int targetSdkVersion = getApplicationContext().getApplicationInfo().targetSdkVersion;
|
||||
if(Build.VERSION.SDK_INT >= Build.VERSION_CODES.M && targetSdkVersion >= 30)
|
||||
if(Build.VERSION.SDK_INT >= Build.VERSION_CODES.M && targetSdkVersion >= 30 && shouldShowRequestPermissionRationale(Manifest.permission.QUERY_ALL_PACKAGES))
|
||||
{
|
||||
requestPermissions(new String[] {Manifest.permission.QUERY_ALL_PACKAGES}, requestCodeForRequestQueryAllPackagesPermission);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user