Magisk Update checker use prefs listener

This commit is contained in:
topjohnwu
2016-09-28 18:05:55 +08:00
parent cb5187fd8d
commit 0acc5e33b3
11 changed files with 411 additions and 276 deletions

View File

@@ -68,12 +68,15 @@ public class SplashActivity extends AppCompatActivity {
defaultPrefs.edit()
.putBoolean("module_done", false)
.putBoolean("repo_done", false)
.putBoolean("update_check_done", false)
.apply();
new Async.CheckUpdates(this).executeOnExecutor(AsyncTask.SERIAL_EXECUTOR);
new Async.LoadModules(this).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
new Async.LoadRepos(this).executeOnExecutor(AsyncTask.SERIAL_EXECUTOR);
new Async.CheckUpdates(this).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
new Async.constructEnv(this).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
new Async.LoadModules(this).executeOnExecutor(AsyncTask.SERIAL_EXECUTOR);
new Async.LoadRepos(this).executeOnExecutor(AsyncTask.SERIAL_EXECUTOR);
// Start main activity
Intent intent = new Intent(this, MainActivity.class);
startActivity(intent);