version:1.6.0226
bugfixes: add:增加g128t平台,修复开发者问题
This commit is contained in:
@@ -29,8 +29,8 @@ android {
|
|||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId "com.aoleyun.sn"
|
applicationId "com.aoleyun.sn"
|
||||||
versionCode 200
|
versionCode 206
|
||||||
versionName "1.5.1216"
|
versionName "1.6.0226"
|
||||||
|
|
||||||
//There are no CERT files because If the mini sdk version is 23+, the AGP will ignore the V1 scheme signature.
|
//There are no CERT files because If the mini sdk version is 23+, the AGP will ignore the V1 scheme signature.
|
||||||
minSdkVersion 24
|
minSdkVersion 24
|
||||||
@@ -270,9 +270,32 @@ android {
|
|||||||
v1SigningEnabled true
|
v1SigningEnabled true
|
||||||
v2SigningEnabled true
|
v2SigningEnabled true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
G128T {
|
||||||
|
storeFile file("keystore/HuaruianG128T.jks")
|
||||||
|
storePassword "123456"
|
||||||
|
keyAlias "g128t"
|
||||||
|
keyPassword "123456"
|
||||||
|
v1SigningEnabled true
|
||||||
|
v2SigningEnabled true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
buildTypes {
|
buildTypes {
|
||||||
|
G128TDebug.initWith(debug)
|
||||||
|
G128TDebug {
|
||||||
|
buildConfigField "String", "platform", '"G128T"'
|
||||||
|
versionNameSuffix "-debug"
|
||||||
|
debuggable true
|
||||||
|
signingConfig signingConfigs.G128T
|
||||||
|
}
|
||||||
|
|
||||||
|
G128TRelease.initWith(release)
|
||||||
|
G128TRelease {
|
||||||
|
buildConfigField "String", "platform", '"G128T"'
|
||||||
|
signingConfig signingConfigs.G128T
|
||||||
|
}
|
||||||
|
|
||||||
MT6765Debug.initWith(debug)
|
MT6765Debug.initWith(debug)
|
||||||
MT6765Debug {
|
MT6765Debug {
|
||||||
buildConfigField "String", "platform", '"MT6765"'
|
buildConfigField "String", "platform", '"MT6765"'
|
||||||
|
|||||||
BIN
app/keystore/HuaruianG128T.jks
Normal file
BIN
app/keystore/HuaruianG128T.jks
Normal file
Binary file not shown.
@@ -160,10 +160,10 @@ public class MainActivity extends BaseMvvmActivity<MainViewModel, ActivityMainBi
|
|||||||
|
|
||||||
JgyUtils.startServices(MainActivity.this);
|
JgyUtils.startServices(MainActivity.this);
|
||||||
|
|
||||||
if (BuildConfig.DEBUG) {
|
// if (BuildConfig.DEBUG) {
|
||||||
Settings.Global.putInt(getContentResolver(), Settings.Global.DEVELOPMENT_SETTINGS_ENABLED, 1);
|
// Settings.Global.putInt(getContentResolver(), Settings.Global.DEVELOPMENT_SETTINGS_ENABLED, 1);
|
||||||
Settings.Global.putInt(getContentResolver(), Settings.Global.ADB_ENABLED, 1);
|
// Settings.Global.putInt(getContentResolver(), Settings.Global.ADB_ENABLED, 1);
|
||||||
}
|
// }
|
||||||
registerReceiver();
|
registerReceiver();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -182,5 +182,7 @@ public class CommonConfig {
|
|||||||
public final static String AOLE_ACTION_DISABLE_APP = "aole_disable_app_list";
|
public final static String AOLE_ACTION_DISABLE_APP = "aole_disable_app_list";
|
||||||
|
|
||||||
public final static String AOLE_ALL_APP_WHITE_LIST_KEY = "aole_all_app_white_list";
|
public final static String AOLE_ALL_APP_WHITE_LIST_KEY = "aole_all_app_white_list";
|
||||||
|
/*系统设置菜单选项*/
|
||||||
|
public final static String AOLE_SETTINGS_DISALLOW = "aole_settings_disallow";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1555,6 +1555,7 @@ public class NetInterfaceManager {
|
|||||||
}
|
}
|
||||||
Log.e("getDefaultDesktop", "UninstallAPP: " + s);
|
Log.e("getDefaultDesktop", "UninstallAPP: " + s);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (JgyUtils.getInstance().checkAppPlatform() == JgyUtils.AH6016Platform) {
|
if (JgyUtils.getInstance().checkAppPlatform() == JgyUtils.AH6016Platform) {
|
||||||
PackageManager pm = mContext.getPackageManager();
|
PackageManager pm = mContext.getPackageManager();
|
||||||
try {
|
try {
|
||||||
@@ -2826,21 +2827,23 @@ public class NetInterfaceManager {
|
|||||||
tagSets.add(JgyUtils.allwinner_U1302);
|
tagSets.add(JgyUtils.allwinner_U1302);
|
||||||
} else if (platform == JgyUtils.MT6765Platform) {
|
} else if (platform == JgyUtils.MT6765Platform) {
|
||||||
tagSets.add(JgyUtils.MT6765_TAG);
|
tagSets.add(JgyUtils.MT6765_TAG);
|
||||||
|
} else if (platform == JgyUtils.G128TPlatform) {
|
||||||
|
tagSets.add(JgyUtils.G128T_TAG);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
Log.e(TAG, "clearAndAppendTags: " + tagSets);
|
Log.e(TAG, "AliyunPush: " + tagSets);
|
||||||
String[] tag = new ArrayList<>(tagSets).toArray(new String[tagSets.size()]);
|
String[] tag = new ArrayList<>(tagSets).toArray(new String[tagSets.size()]);
|
||||||
CloudPushService pushService = PushServiceFactory.getCloudPushService();
|
CloudPushService pushService = PushServiceFactory.getCloudPushService();
|
||||||
pushService.bindTag(CloudPushService.DEVICE_TARGET, tag, null, new CommonCallback() {
|
pushService.bindTag(CloudPushService.DEVICE_TARGET, tag, null, new CommonCallback() {
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(String s) {
|
public void onSuccess(String s) {
|
||||||
Log.e("clearAndAppendTags", "bind tag " + Arrays.toString(tag) + " success\n");
|
Log.e("AliyunPush", "bind tag " + Arrays.toString(tag) + " success\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailed(String errorCode, String errorMsg) {
|
public void onFailed(String errorCode, String errorMsg) {
|
||||||
Log.e("clearAndAppendTags", "bind tag " + Arrays.toString(tag) + " failed." +
|
Log.e("AliyunPush", "bind tag " + Arrays.toString(tag) + " failed." +
|
||||||
"errorCode: " + errorCode + ", errorMsg:" + errorMsg + "\n");
|
"errorCode: " + errorCode + ", errorMsg:" + errorMsg + "\n");
|
||||||
BaseApplication.onTagOperatorResult(errorCode);
|
BaseApplication.onTagOperatorResult(errorCode);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -50,9 +50,13 @@ public class RemoteService extends Service {
|
|||||||
return locked == JGYActions.FRAME_CODE_LOCKED;
|
return locked == JGYActions.FRAME_CODE_LOCKED;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return 是否关闭
|
||||||
|
* @throws RemoteException
|
||||||
|
*/
|
||||||
@Override
|
@Override
|
||||||
public boolean isBrowserInput() throws RemoteException {
|
public boolean isBrowserInput() throws RemoteException {
|
||||||
int state = Settings.System.getInt(getContentResolver(), "qch_Browser_input", 1);
|
int state = Settings.System.getInt(getContentResolver(), "qch_Browser_input", 0);
|
||||||
return state == 0;
|
return state == 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ import android.os.Binder;
|
|||||||
import android.os.Build;
|
import android.os.Build;
|
||||||
import android.os.Handler;
|
import android.os.Handler;
|
||||||
import android.os.IBinder;
|
import android.os.IBinder;
|
||||||
|
import android.os.Looper;
|
||||||
import android.os.RemoteException;
|
import android.os.RemoteException;
|
||||||
import android.provider.Settings;
|
import android.provider.Settings;
|
||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
@@ -115,8 +116,8 @@ public class MainService extends Service implements MainSContact.MainView, Netwo
|
|||||||
if (!checkAoleyunApp()) {
|
if (!checkAoleyunApp()) {
|
||||||
mPresenter.checkAoleyunUpdate();
|
mPresenter.checkAoleyunUpdate();
|
||||||
}
|
}
|
||||||
mInternetConnected.onConnected(WiFiAlias);
|
|
||||||
}
|
}
|
||||||
|
mInternetConnected.onConnected(WiFiAlias);
|
||||||
}
|
}
|
||||||
|
|
||||||
private class TimeTask extends AsyncTask<String, Long, Long> {
|
private class TimeTask extends AsyncTask<String, Long, Long> {
|
||||||
@@ -494,7 +495,13 @@ public class MainService extends Service implements MainSContact.MainView, Netwo
|
|||||||
|
|
||||||
boolean reboot = mMMKV.decodeBool(CommonConfig.DEVICES_REBOOT, true);
|
boolean reboot = mMMKV.decodeBool(CommonConfig.DEVICES_REBOOT, true);
|
||||||
if (reboot) {
|
if (reboot) {
|
||||||
mPresenter.getLockedState();
|
new Handler(Looper.getMainLooper()).postDelayed(new Runnable() {
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
mPresenter.getLockedState();
|
||||||
|
}
|
||||||
|
}, 20000);
|
||||||
|
|
||||||
mMMKV.encode(CommonConfig.DEVICES_REBOOT, false);
|
mMMKV.encode(CommonConfig.DEVICES_REBOOT, false);
|
||||||
Log.e(TAG, "onCreate: device rebooted");
|
Log.e(TAG, "onCreate: device rebooted");
|
||||||
} else {
|
} else {
|
||||||
@@ -616,7 +623,7 @@ public class MainService extends Service implements MainSContact.MainView, Netwo
|
|||||||
.subscribe(killObserver);
|
.subscribe(killObserver);
|
||||||
|
|
||||||
Observable.create(networkSubscribe)
|
Observable.create(networkSubscribe)
|
||||||
.throttleLast(1, TimeUnit.HOURS)
|
.throttleFirst(1, TimeUnit.HOURS)
|
||||||
.subscribe(networkObserver);
|
.subscribe(networkObserver);
|
||||||
|
|
||||||
JgyUtils.getInstance().checkAoleyunApp();
|
JgyUtils.getInstance().checkAoleyunApp();
|
||||||
|
|||||||
@@ -165,6 +165,7 @@ public class JgyUtils {
|
|||||||
public static final int seewoPlatform = 25;
|
public static final int seewoPlatform = 25;
|
||||||
public static final int U1302Platform = 26;
|
public static final int U1302Platform = 26;
|
||||||
public static final int MT6765Platform = 28;
|
public static final int MT6765Platform = 28;
|
||||||
|
public static final int G128TPlatform = 29;
|
||||||
|
|
||||||
|
|
||||||
public static final String Other = "其他";
|
public static final String Other = "其他";
|
||||||
@@ -189,6 +190,7 @@ public class JgyUtils {
|
|||||||
public static final String seewoTag = "seewo";
|
public static final String seewoTag = "seewo";
|
||||||
public static final String allwinner_U1302 = "QZA15";
|
public static final String allwinner_U1302 = "QZA15";
|
||||||
public static final String MT6765_TAG = "MT6765";
|
public static final String MT6765_TAG = "MT6765";
|
||||||
|
public static final String G128T_TAG = "G128T";
|
||||||
|
|
||||||
|
|
||||||
private CacheHelper cacheHelper;
|
private CacheHelper cacheHelper;
|
||||||
@@ -337,6 +339,9 @@ public class JgyUtils {
|
|||||||
} else if (MT6765_TAG.equalsIgnoreCase(platform)) {
|
} else if (MT6765_TAG.equalsIgnoreCase(platform)) {
|
||||||
Log.i(TAG, "checkAppPlatform: " + "MT6765");
|
Log.i(TAG, "checkAppPlatform: " + "MT6765");
|
||||||
return MT6765Platform;
|
return MT6765Platform;
|
||||||
|
} else if (G128T_TAG.equalsIgnoreCase(platform)) {
|
||||||
|
Log.i(TAG, "checkAppPlatform: " + "G128T");
|
||||||
|
return G128TPlatform;
|
||||||
} else {
|
} else {
|
||||||
Log.i(TAG, "checkAppPlatform: " + "没有数据");
|
Log.i(TAG, "checkAppPlatform: " + "没有数据");
|
||||||
return UnknowPlatform;
|
return UnknowPlatform;
|
||||||
@@ -401,6 +406,8 @@ public class JgyUtils {
|
|||||||
getAppPlatformCallback.AppPlatform(U1302Platform);
|
getAppPlatformCallback.AppPlatform(U1302Platform);
|
||||||
} else if (MT6765_TAG.equalsIgnoreCase(platform)) {
|
} else if (MT6765_TAG.equalsIgnoreCase(platform)) {
|
||||||
getAppPlatformCallback.AppPlatform(MT6765Platform);
|
getAppPlatformCallback.AppPlatform(MT6765Platform);
|
||||||
|
} else if (G128T_TAG.equalsIgnoreCase(platform)) {
|
||||||
|
getAppPlatformCallback.AppPlatform(G128TPlatform);
|
||||||
} else {
|
} else {
|
||||||
getAppPlatformCallback.AppPlatform(UnknowPlatform);
|
getAppPlatformCallback.AppPlatform(UnknowPlatform);
|
||||||
}
|
}
|
||||||
@@ -1015,18 +1022,22 @@ public class JgyUtils {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void writeDeselectIDtoSystem(List<AppID> appIDList) {
|
public void writeDeselectIDtoSystem(List<AppID> appIDList) {
|
||||||
if (!"Ebox201".equals(Build.MODEL)&&!"Ebox201W".equals(Build.MODEL)){
|
if (!"Ebox201".equals(Build.MODEL) && !"Ebox201W".equals(Build.MODEL)) {
|
||||||
Log.e(TAG, "writeDeselectIDtoSystem: not match Ebox201 or Ebox201W" );
|
Log.e(TAG, "writeDeselectIDtoSystem: not match Ebox201 or Ebox201W");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (appIDList == null || appIDList.isEmpty()) {
|
if (appIDList == null || appIDList.isEmpty()) {
|
||||||
try {
|
if ("G10".equals(Build.MODEL) || "D1".equals(Build.MODEL)) {
|
||||||
Settings.System.putString(crv, CommonConfig.APP_VIEW_CLICK_DISABLED, null);
|
Settings.System.putString(mContext.getContentResolver(), CommonConfig.APP_VIEW_CLICK_DISABLED, "com.arivoc.wordhd:2131624676,2131624689;com.ttstd.utils:12345");
|
||||||
// TODO: 2024/9/11 修复1.4.0907版本数据为空系统报错
|
} else {
|
||||||
CmdUtil.Result result = CmdUtil.execute(" settings delete system app_view_click_disabled");
|
try {
|
||||||
Log.e(TAG, "writeDeselectIDtoSystem: " + result);
|
Settings.System.putString(crv, CommonConfig.APP_VIEW_CLICK_DISABLED, null);
|
||||||
} catch (Exception e) {
|
// TODO: 2024/9/11 修复1.4.0907版本数据为空系统报错
|
||||||
e.printStackTrace();
|
CmdUtil.Result result = CmdUtil.execute(" settings delete system app_view_click_disabled");
|
||||||
|
Log.e(TAG, "writeDeselectIDtoSystem: " + result);
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
String s = appIDList.stream().map(new Function<AppID, String>() {
|
String s = appIDList.stream().map(new Function<AppID, String>() {
|
||||||
@@ -1468,6 +1479,9 @@ public class JgyUtils {
|
|||||||
pkgSet.addAll(ApkUtils.desktopAPP);
|
pkgSet.addAll(ApkUtils.desktopAPP);
|
||||||
pkgSet.addAll(ApkUtils.aoleyunAPP);
|
pkgSet.addAll(ApkUtils.aoleyunAPP);
|
||||||
pkgSet.addAll(ApkUtils.mJxwApp);
|
pkgSet.addAll(ApkUtils.mJxwApp);
|
||||||
|
if (G128T_TAG.equals(BuildConfig.platform)) {
|
||||||
|
pkgSet.add("com.dmjc.xinhuo");
|
||||||
|
}
|
||||||
if ("K101".equals(Build.MODEL) || "AS001".equals(Build.MODEL)) {
|
if ("K101".equals(Build.MODEL) || "AS001".equals(Build.MODEL)) {
|
||||||
pkgSet.addAll(ApkUtils.aihuaApp);
|
pkgSet.addAll(ApkUtils.aihuaApp);
|
||||||
pkgSet.addAll(aihuaAppList);
|
pkgSet.addAll(aihuaAppList);
|
||||||
@@ -1581,7 +1595,7 @@ public class JgyUtils {
|
|||||||
jsonObject.addProperty("app_id", app_id);
|
jsonObject.addProperty("app_id", app_id);
|
||||||
jsonObject.addProperty("MD5", app_md5);
|
jsonObject.addProperty("MD5", app_md5);
|
||||||
long app_version_code = forceDownloadData.getApp_version_code();
|
long app_version_code = forceDownloadData.getApp_version_code();
|
||||||
Log.e("fht ", "packageName=" + app_package + ",URL= " + app_url + ",app_version_code=" + app_version_code);
|
Log.e("forceDownload", "packageName=" + app_package + ",URL= " + app_url + ",app_version_code=" + app_version_code);
|
||||||
if (BuildConfig.APPLICATION_ID.equals(data.get(i).getApp_package())) {
|
if (BuildConfig.APPLICATION_ID.equals(data.get(i).getApp_package())) {
|
||||||
continue;//为自身的跳过下载
|
continue;//为自身的跳过下载
|
||||||
}
|
}
|
||||||
@@ -2115,7 +2129,9 @@ public class JgyUtils {
|
|||||||
Log.e(TAG, "setDeveloperOptions: oldStatu = " + oldStatu + " no changed");
|
Log.e(TAG, "setDeveloperOptions: oldStatu = " + oldStatu + " no changed");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (MT8768Tag.equalsIgnoreCase(BuildConfig.platform)) {
|
if (MT8768Tag.equalsIgnoreCase(BuildConfig.platform)
|
||||||
|
|| G128T_TAG.equalsIgnoreCase(BuildConfig.platform)
|
||||||
|
) {
|
||||||
Settings.System.putInt(crv, CommonConfig.AOLE_ACTION_DEVELOPER_OPTIONS, state);
|
Settings.System.putInt(crv, CommonConfig.AOLE_ACTION_DEVELOPER_OPTIONS, state);
|
||||||
} else {
|
} else {
|
||||||
//这个需要反着来
|
//这个需要反着来
|
||||||
|
|||||||
@@ -73,6 +73,7 @@ public class SysSettingUtils {
|
|||||||
setNotification(context, jsonObject);
|
setNotification(context, jsonObject);
|
||||||
setPanelShow(context, jsonObject);
|
setPanelShow(context, jsonObject);
|
||||||
setDisAllowCamera(context, jsonObject);
|
setDisAllowCamera(context, jsonObject);
|
||||||
|
setSettingsMenuShow(context, jsonObject);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -100,7 +101,7 @@ public class SysSettingUtils {
|
|||||||
setWallpaper(context, 0);
|
setWallpaper(context, 0);
|
||||||
setCanReset(context, 0);
|
setCanReset(context, 0);
|
||||||
setAutoTime(context, 1);
|
setAutoTime(context, 1);
|
||||||
setBrowserInput(context, 1);
|
setBrowserInput(context, 0);
|
||||||
if (!BuildConfig.DEBUG) {
|
if (!BuildConfig.DEBUG) {
|
||||||
// JgyUtils.getInstance().setDeveloperOptions(0);
|
// JgyUtils.getInstance().setDeveloperOptions(0);
|
||||||
}
|
}
|
||||||
@@ -108,6 +109,8 @@ public class SysSettingUtils {
|
|||||||
setAdminApp(context, 1);
|
setAdminApp(context, 1);
|
||||||
setSystemAppDisable(context, 0);
|
setSystemAppDisable(context, 0);
|
||||||
setNotification(context, 0);
|
setNotification(context, 0);
|
||||||
|
setSettingsMenuShow(context);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -130,7 +133,7 @@ public class SysSettingUtils {
|
|||||||
setWallpaper(context, 0);
|
setWallpaper(context, 0);
|
||||||
setCanReset(context, 0);
|
setCanReset(context, 0);
|
||||||
setAutoTime(context, 0);
|
setAutoTime(context, 0);
|
||||||
setBrowserInput(context, 0);
|
setBrowserInput(context, 1);
|
||||||
// JgyUtils.getInstance().setDeveloperOptions(1);
|
// JgyUtils.getInstance().setDeveloperOptions(1);
|
||||||
setStatusBar(context, 0);
|
setStatusBar(context, 0);
|
||||||
setAdminApp(context, 0);
|
setAdminApp(context, 0);
|
||||||
@@ -1257,6 +1260,105 @@ public class SysSettingUtils {
|
|||||||
Log.e("setDisAllowCamera", "setDisAllowCamera: " + camera_ctrl);
|
Log.e("setDisAllowCamera", "setDisAllowCamera: " + camera_ctrl);
|
||||||
Settings.System.putInt(context.getContentResolver(), CommonConfig.AOLE_ACTION_DISALLOW_CAMERA, changeNum(camera_ctrl));
|
Settings.System.putInt(context.getContentResolver(), CommonConfig.AOLE_ACTION_DISALLOW_CAMERA, changeNum(camera_ctrl));
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param context
|
||||||
|
* @param jsonObject key的定义为:”wlan”:网络和互联网,”connected_devices”:已连接的设备,”apps”:应用,”notifications”:通知,”display”:显示,
|
||||||
|
* ”sound”:提示音,”storage”:存储,”battery”:电池,”wallpaper”:壁纸,”location”:位置信息,”system”:系统,”about”:关于。
|
||||||
|
*/
|
||||||
|
private static void setSettingsMenuShow(Context context, JsonObject jsonObject) {
|
||||||
|
List<String> menus = new ArrayList<>();
|
||||||
|
// OTA升级管控 (默认允许)
|
||||||
|
int ota_upgrade_control = jsonObject.get("ota_upgrade_control").getAsInt();
|
||||||
|
if (ota_upgrade_control == 0) {
|
||||||
|
menus.add("system_updates");
|
||||||
|
}
|
||||||
|
// 生物识别和密码 (默认允许)
|
||||||
|
int biometric_and_password = jsonObject.get("biometric_and_password").getAsInt();
|
||||||
|
if (biometric_and_password == 0) {
|
||||||
|
menus.add("biometrics_password");
|
||||||
|
}
|
||||||
|
// 省电模式 (默认允许)
|
||||||
|
int power_saving_mode = jsonObject.get("power_saving_mode").getAsInt();
|
||||||
|
if (power_saving_mode == 0) {
|
||||||
|
menus.add("battery");
|
||||||
|
}
|
||||||
|
// 安全 (默认允许)
|
||||||
|
int security = jsonObject.get("security").getAsInt();
|
||||||
|
if (security == 0) {
|
||||||
|
menus.add("security");
|
||||||
|
}
|
||||||
|
// 大屏特色功能 (默认允许)
|
||||||
|
int large_screen_features = jsonObject.get("large_screen_features").getAsInt();
|
||||||
|
if (large_screen_features == 0) {
|
||||||
|
// menus.add("");
|
||||||
|
}
|
||||||
|
// 辅助功能 (默认允许)
|
||||||
|
int accessibility = jsonObject.get("accessibility").getAsInt();
|
||||||
|
if (accessibility == 0) {
|
||||||
|
menus.add("accessibility");
|
||||||
|
}
|
||||||
|
// 隐私 (默认允许)
|
||||||
|
int privacy = jsonObject.get("privacy").getAsInt();
|
||||||
|
if (privacy == 0) {
|
||||||
|
menus.add("privacy");
|
||||||
|
}
|
||||||
|
// 更多链接 (默认允许)
|
||||||
|
int more_links = jsonObject.get("more_links").getAsInt();
|
||||||
|
if (more_links == 0) {
|
||||||
|
menus.add("more_connections");
|
||||||
|
}
|
||||||
|
// 通知和状态栏 (默认允许)
|
||||||
|
int notification_and_status_bar = jsonObject.get("notification_and_status_bar").getAsInt();
|
||||||
|
if (notification_and_status_bar == 0) {
|
||||||
|
menus.add("notifications");
|
||||||
|
}
|
||||||
|
// 应用管理 (默认允许)
|
||||||
|
int app_management_general = jsonObject.get("app_management_general").getAsInt();
|
||||||
|
if (app_management_general == 0) {
|
||||||
|
menus.add("apps");
|
||||||
|
}
|
||||||
|
// 荣耀账号登录 (默认禁止)
|
||||||
|
int honor_account_login = jsonObject.get("honor_account_login").getAsInt();
|
||||||
|
if (honor_account_login == 0) {
|
||||||
|
menus.add("honor_id");
|
||||||
|
}
|
||||||
|
// 智慧互联 (默认禁止)
|
||||||
|
int smart_interconnect = jsonObject.get("smart_interconnect").getAsInt();
|
||||||
|
if (smart_interconnect == 0) {
|
||||||
|
menus.add("super_device");
|
||||||
|
}
|
||||||
|
// VPN管控 (默认禁止)
|
||||||
|
int vpn_control = jsonObject.get("vpn_control").getAsInt();
|
||||||
|
if (vpn_control == 0) {
|
||||||
|
menus.add("vpn_settings");
|
||||||
|
}
|
||||||
|
// 默认应用 (默认禁止)
|
||||||
|
int default_applications = jsonObject.get("default_applications").getAsInt();
|
||||||
|
if (default_applications == 0) {
|
||||||
|
// menus.add("");
|
||||||
|
}
|
||||||
|
// 应用分身 (默认禁止)
|
||||||
|
int app_cloning = jsonObject.get("app_cloning").getAsInt();
|
||||||
|
if (app_cloning == 0) {
|
||||||
|
menus.add("apps_clone");
|
||||||
|
}
|
||||||
|
// 应用启动管理 (默认禁止)
|
||||||
|
int app_startup_management = jsonObject.get("app_startup_management").getAsInt();
|
||||||
|
if (app_startup_management == 0) {
|
||||||
|
menus.add("apps_startup_management");
|
||||||
|
}
|
||||||
|
// 应用管理 (默认禁止)
|
||||||
|
int app_management_control = jsonObject.get("app_management_control").getAsInt();
|
||||||
|
if (app_management_control == 0) {
|
||||||
|
menus.add("apps_management");
|
||||||
|
menus.add("apps_honor_tips");
|
||||||
|
}
|
||||||
|
// Settings.System.putString(context.getContentResolver(), CommonConfig.AOLE_SETTINGS_DISALLOW, String.join(",", menus));
|
||||||
|
}
|
||||||
|
|
||||||
|
private static void setSettingsMenuShow(Context context) {
|
||||||
|
// Settings.System.putString(context.getContentResolver(), CommonConfig.AOLE_SETTINGS_DISALLOW, "");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1833,6 +1833,7 @@ public class Utils {
|
|||||||
|| JgyUtils.getInstance().checkAppPlatform() == JgyUtils.seewoPlatform
|
|| JgyUtils.getInstance().checkAppPlatform() == JgyUtils.seewoPlatform
|
||||||
|| JgyUtils.getInstance().checkAppPlatform() == JgyUtils.U1302Platform
|
|| JgyUtils.getInstance().checkAppPlatform() == JgyUtils.U1302Platform
|
||||||
|| JgyUtils.getInstance().checkAppPlatform() == JgyUtils.MT6765Platform
|
|| JgyUtils.getInstance().checkAppPlatform() == JgyUtils.MT6765Platform
|
||||||
|
|| JgyUtils.getInstance().checkAppPlatform() == JgyUtils.G128TPlatform
|
||||||
) {
|
) {
|
||||||
return Utils.getProperty("ro.build.display.id", "获取失败");
|
return Utils.getProperty("ro.build.display.id", "获取失败");
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user