Use ClassMaps to prevent errors

This commit is contained in:
topjohnwu
2018-09-16 00:08:13 -04:00
parent 2fba3f213b
commit 47c860142e
11 changed files with 63 additions and 26 deletions
@@ -10,13 +10,12 @@ import com.topjohnwu.magisk.asyncs.CheckUpdates;
import com.topjohnwu.magisk.asyncs.UpdateRepos;
import com.topjohnwu.magisk.components.BaseActivity;
import com.topjohnwu.magisk.database.RepoDatabaseHelper;
import com.topjohnwu.magisk.receivers.ShortcutReceiver;
import com.topjohnwu.magisk.utils.Download;
import com.topjohnwu.magisk.utils.LocaleManager;
import com.topjohnwu.magisk.utils.Utils;
import com.topjohnwu.superuser.Shell;
import a.l;
public class SplashActivity extends BaseActivity {
@Override
@@ -45,7 +44,7 @@ public class SplashActivity extends BaseActivity {
}
// Setup shortcuts
sendBroadcast(new Intent(this, l.class));
sendBroadcast(new Intent(this, Data.classMap.get(ShortcutReceiver.class)));
if (Download.checkNetworkStatus(this)) {
// Fire update check
@@ -59,7 +58,7 @@ public class SplashActivity extends BaseActivity {
mm.hasInit = true;
Intent intent = new Intent(this, a.b.class);
Intent intent = new Intent(this, Data.classMap.get(MainActivity.class));
intent.putExtra(Const.Key.OPEN_SECTION, getIntent().getStringExtra(Const.Key.OPEN_SECTION));
intent.putExtra(BaseActivity.INTENT_PERM, getIntent().getStringExtra(BaseActivity.INTENT_PERM));
startActivity(intent);