Small minor updates

This commit is contained in:
topjohnwu
2017-07-20 02:54:34 +08:00
parent 668d85d14e
commit 5ac6a8cb4a
4 changed files with 17 additions and 6 deletions

View File

@ -372,7 +372,11 @@ public class MagiskFragment extends Fragment
if (!Shell.rootAccess()) {
installText.setText(R.string.download);
} else {
installText.setText(R.string.download_install);
if (magiskManager.remoteMagiskVersionCode > magiskManager.magiskVersionCode) {
installText.setText(R.string.update);
} else {
installText.setText(R.string.reinstall);
}
List<String> items = new ArrayList<>();
if (magiskManager.bootBlock != null) {

View File

@ -33,11 +33,8 @@ public class SplashActivity extends Activity{
magiskManager.remoteMagiskVersionString = getIntent().getStringExtra(MagiskManager.INTENT_VERSION);
magiskManager.magiskLink = getIntent().getStringExtra(MagiskManager.INTENT_LINK);
// Now fire all async tasks
new LoadModules(this)
.setCallBack(() -> new LoadRepos(this).exec())
.exec();
new LoadApps(this).exec();
LoadModules loadModuleTask = new LoadModules(this);
if (Utils.checkNetworkStatus(this)) {
// Initialize the update check service, notify every 8 hours
@ -51,8 +48,13 @@ public class SplashActivity extends Activity{
JobScheduler scheduler = (JobScheduler) getSystemService(Context.JOB_SCHEDULER_SERVICE);
scheduler.schedule(jobInfo);
}
loadModuleTask.setCallBack(() -> new LoadRepos(this).exec());
}
// Now fire all async tasks
loadModuleTask.exec();
new LoadApps(this).exec();
Intent intent = new Intent(this, MainActivity.class);
String section = getIntent().getStringExtra(MagiskManager.INTENT_SECTION);
if (section != null) {