version:1.6.4
fix:修复U807设置默认桌面问题 update:没有安装设备信息可以直接打开应用
This commit is contained in:
@@ -3,7 +3,6 @@ package com.uiui.zyos.activity;
|
||||
import android.content.Context;
|
||||
import android.media.AudioAttributes;
|
||||
import android.media.SoundPool;
|
||||
import android.os.Build;
|
||||
import android.os.Bundle;
|
||||
import android.os.Handler;
|
||||
import android.provider.Settings;
|
||||
@@ -21,8 +20,7 @@ import com.tuo.customview.VerificationCodeView;
|
||||
import com.uiui.zyos.R;
|
||||
import com.uiui.zyos.base.BaseActivity;
|
||||
import com.uiui.zyos.config.CommonConfig;
|
||||
import com.uiui.zyos.manager.RemoteManager;
|
||||
import com.uiui.zyos.utils.ApkUtils;
|
||||
import com.uiui.zyos.utils.Utils;
|
||||
|
||||
import butterknife.BindView;
|
||||
import butterknife.ButterKnife;
|
||||
@@ -145,13 +143,13 @@ public class ExitActivity extends BaseActivity {
|
||||
String password = Settings.Global.getString(getContentResolver(), CommonConfig.LOCK_SCREEN_PASSWORD);
|
||||
if ((!TextUtils.isEmpty(content) && !TextUtils.isEmpty(password))) {
|
||||
if (password.equals(content)) {
|
||||
exitDesktop();
|
||||
Utils.exitDesktop(this);
|
||||
} else {
|
||||
setEmpty();
|
||||
tv_hint.setText("密码错误");
|
||||
}
|
||||
} else if (CommonConfig.DEFAULT_PASSWORD.equals(content)) {
|
||||
exitDesktop();
|
||||
Utils.exitDesktop(this);
|
||||
} else {
|
||||
setEmpty();
|
||||
tv_hint.setText("密码错误");
|
||||
@@ -189,19 +187,4 @@ public class ExitActivity extends BaseActivity {
|
||||
codeView.getEditText().setText(text);
|
||||
// soundPool.play(soundId, 1, 1, 0, 0, 1);
|
||||
}
|
||||
|
||||
private void exitDesktop() {
|
||||
RemoteManager.getInstance().setDefaultDesktop(ApkUtils.ANDROID_LAUNCHER3_PACKAGE_NAME);
|
||||
if (Build.VERSION.SDK_INT > Build.VERSION_CODES.Q) {
|
||||
if (!ApkUtils.openPackage(this, ApkUtils.ANDROID_LAUNCHER3_PACKAGE_NAME, ApkUtils.ANDROID_LAUNCHER3_Quickstep_CLASS_NAME)) {
|
||||
ApkUtils.gotoLauncher(this);
|
||||
}
|
||||
} else {
|
||||
if (!ApkUtils.openPackage(this, ApkUtils.ANDROID_LAUNCHER3_PACKAGE_NAME, ApkUtils.ANDROID_LAUNCHER3_CLASS_NAME)) {
|
||||
ApkUtils.gotoLauncher(this);
|
||||
}
|
||||
}
|
||||
this.finish();
|
||||
System.exit(0);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user