修改后台或用户打开下载后不会再回到关闭下载的状态

This commit is contained in:
huangzhuanghua
2016-11-14 14:08:42 +08:00
parent 22e51f1216
commit 3f5a94e710
2 changed files with 11 additions and 3 deletions

View File

@ -220,7 +220,9 @@ public class SplashScreenActivity extends BaseActivity {
}
// 获取下载按钮状态、开启or关闭
getDownloadStatus();
if (sp.getBoolean("isCheckShow", true)) {
getDownloadStatus();
}
getUISetting();
@ -330,7 +332,10 @@ public class SplashScreenActivity extends BaseActivity {
try {
String status = response.getString("status");
if ("on".equals(status)) {
sp.edit().putBoolean("isShow", true).apply();
Editor editor = sp.edit();
editor.putBoolean("isShow", true);
editor.putBoolean("isCheckShow", false);
editor.apply();
} else {
sp.edit().putBoolean("isShow", false).apply();
}