新版apk package过滤机制
This commit is contained in:
@ -178,26 +178,21 @@ public class SplashScreenActivity extends BaseActivity {
|
||||
isFirst = false;
|
||||
|
||||
// 第一次启动,把package.txt文件内容加载进数据库
|
||||
FilterManager filterManager = null;
|
||||
if (!sp.getBoolean("isLoadFilter", false)) {
|
||||
filterManager = new FilterManager(getApplicationContext());
|
||||
FilterManager filterManager = new FilterManager(getApplicationContext());
|
||||
if (!sp.getBoolean("isLoadFilterV2d4", false)) {
|
||||
filterManager.loadFilter();
|
||||
}
|
||||
// 获取过滤包
|
||||
filterManager.getFilterFromServer(0);
|
||||
|
||||
// 检查是否存在旧版本光环助手包
|
||||
checkOldGhFile();
|
||||
|
||||
// 更新过滤表,获取自动刷新的cd,获取版本对应表
|
||||
String time = sp.getString("filter_time", null);
|
||||
String time = sp.getString("refresh_time", null);
|
||||
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd", Locale.getDefault());
|
||||
String today = format.format(new Date());
|
||||
if (!today.equals(time)) {
|
||||
// 获取过滤包
|
||||
if (filterManager == null) {
|
||||
filterManager = new FilterManager(getApplicationContext());
|
||||
}
|
||||
filterManager.getFilterFromServer(today);
|
||||
|
||||
// 获取版本代码、名称
|
||||
PlatformUtils.getInstance(getApplicationContext()).getPlatform();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user