Merge pull request #391 from wirsnow/master

可以在project.json中使用权限的小写字符串配置打包的启用权限
This commit is contained in:
SuperMonster003
2025-05-25 23:02:05 +08:00
committed by GitHub

View File

@@ -536,7 +536,12 @@ public class BuildActivity extends BaseActivity implements ApkBuilder.ProgressCa
checkBox.setTextSize(12);
int marginInPixels = (int) (8 * getResources().getDisplayMetrics().density);
checkBox.setPadding(marginInPixels, 0, 0, 0);
checkBox.setChecked(false);
if (mProjectConfig != null) {
boolean checked = mProjectConfig.getPermissions().stream().anyMatch(p -> ("android.permission." + p.toUpperCase()).equals(permission));
checkBox.setChecked(checked);
} else {
checkBox.setChecked(false);
}
mFlexboxPermissionsView.addView(checkBox);
});
}