Skip to content

Commit

Permalink
Merge branch 'feature/split-tunneling-system-apps' into staging-2.10.5
Browse files Browse the repository at this point in the history
  • Loading branch information
jurajhilje committed Dec 7, 2023
2 parents b4bd9b3 + 5f5447b commit 5fdd58a
Showing 1 changed file with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -93,8 +93,10 @@ public void selectAll() {
}

public void deselectAll() {
disallowAllApps(new HashSet<>(apps));
disallowAllApps(new HashSet<>(systemApps));
ObservableArrayList<ApplicationItem> allApps = new ObservableArrayList<>();
allApps.addAll(apps);
allApps.addAll(systemApps);
disallowAllApps(new HashSet<>(allApps));
menuHandler.deselectAll();
reloadDisallowedApps();
}
Expand Down Expand Up @@ -165,9 +167,10 @@ protected List<ApplicationItem> doInBackground(Void... voids) {
for (ApplicationInfo info : applicationInfoList) {
try {
if (PackageManager.PERMISSION_GRANTED == packageManager.checkPermission(Manifest.permission.INTERNET, info.packageName)) {
if (null != packageManager.getLaunchIntentForPackage(info.packageName) ||
if ((null != packageManager.getLaunchIntentForPackage(info.packageName) ||
null != packageManager.getLeanbackLaunchIntentForPackage(info.packageName) ||
null != packageManager.getInstallerPackageName(info.packageName)
null != packageManager.getInstallerPackageName(info.packageName) &&
(info.flags & ApplicationInfo.FLAG_SYSTEM) == 0)
) {
if (packageNames.add(info.loadLabel(packageManager).toString())) {
items.add(new ApplicationItem(info.loadLabel(packageManager).toString(), info.packageName,
Expand Down

0 comments on commit 5fdd58a

Please sign in to comment.