[App] Start ACTION_SHOW_APP_INFO from backend (#679)

Co-authored-by: tehcneko <7764726+tehcneko@users.noreply.github.com>
This commit is contained in:
LoveSy 2021-05-25 21:38:04 +08:00 committed by GitHub
parent d67b34fd16
commit ca80fd9446
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 10 deletions

View File

@ -289,11 +289,7 @@ public class ScopeAdapter extends RecyclerView.Adapter<ScopeAdapter.ViewHolder>
var intent = new Intent(Intent.ACTION_SHOW_APP_INFO);
intent.putExtra(Intent.EXTRA_PACKAGE_NAME, module.packageName);
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
try {
activity.startActivity(intent);
} catch (Exception e) {
e.printStackTrace();
}
ConfigManager.startActivityAsUserWithFeature(intent, module.userId);
} else if (itemId == R.id.menu_app_info) {
ConfigManager.startActivityAsUserWithFeature(new Intent(ACTION_APPLICATION_DETAILS_SETTINGS, Uri.fromParts("package", info.packageName, null)), module.userId);
} else if (itemId == R.id.menu_force_stop) {

View File

@ -295,11 +295,7 @@ public class ModulesActivity extends BaseActivity implements ModuleUtil.ModuleLi
var intent = new Intent(Intent.ACTION_SHOW_APP_INFO);
intent.putExtra(Intent.EXTRA_PACKAGE_NAME, selectedModule.packageName);
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
try {
startActivity(intent);
} catch (Exception e) {
e.printStackTrace();
}
ConfigManager.startActivityAsUserWithFeature(intent, selectedModule.userId);
return true;
} else if (itemId == R.id.menu_app_info) {
ConfigManager.startActivityAsUserWithFeature(new Intent(ACTION_APPLICATION_DETAILS_SETTINGS, Uri.fromParts("package", selectedModule.packageName, null)), selectedModule.userId);