Get rid of StatusService.
StatusService was only used to handle `signalEvent:` from status-go. This commit simplifies this interaction and getting rid of the service and all the problems that come with it. Signed-off-by: Igor Mandrigin <i@mandrigin.ru>
This commit is contained in:
@@ -1,36 +1,39 @@
|
||||
package im.status.ethereum;
|
||||
|
||||
import android.support.multidex.MultiDexApplication;
|
||||
|
||||
import com.AlexanderZaytsev.RNI18n.RNI18nPackage;
|
||||
import com.aakashns.reactnativedialogs.ReactNativeDialogsPackage;
|
||||
import org.devio.rn.splashscreen.SplashScreenReactPackage;
|
||||
import com.facebook.react.ReactApplication;
|
||||
import io.invertase.firebase.RNFirebasePackage;
|
||||
import io.invertase.firebase.messaging.RNFirebaseMessagingPackage;
|
||||
import io.invertase.firebase.notifications.RNFirebaseNotificationsPackage;
|
||||
import net.rhogan.rnsecurerandom.RNSecureRandomPackage;
|
||||
import com.ocetnik.timer.BackgroundTimerPackage;
|
||||
import com.horcrux.svg.SvgPackage;
|
||||
import com.lugg.ReactNativeConfig.ReactNativeConfigPackage;
|
||||
import com.facebook.react.ReactNativeHost;
|
||||
import com.facebook.react.ReactPackage;
|
||||
import com.facebook.react.shell.MainReactPackage;
|
||||
import com.facebook.soloader.SoLoader;
|
||||
import com.github.alinz.reactnativewebviewbridge.WebViewBridgePackage;
|
||||
import com.AlexanderZaytsev.RNI18n.RNI18nPackage;
|
||||
import org.reactnative.camera.RNCameraPackage;
|
||||
import com.horcrux.svg.SvgPackage;
|
||||
import com.lugg.ReactNativeConfig.ReactNativeConfigPackage;
|
||||
import com.oblador.keychain.KeychainPackage;
|
||||
import com.ocetnik.timer.BackgroundTimerPackage;
|
||||
import com.reactnative.ivpusic.imagepicker.PickerPackage;
|
||||
import com.rnfs.RNFSPackage;
|
||||
import fr.bamlab.rnimageresizer.ImageResizerPackage;
|
||||
import im.status.ethereum.module.StatusPackage;
|
||||
import im.status.ethereum.keycard.RNStatusKeycardPackage;
|
||||
import io.realm.react.RealmReactPackage;
|
||||
import me.alwx.HttpServer.HttpServerReactPackage;
|
||||
import com.oblador.keychain.KeychainPackage;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import net.rhogan.rnsecurerandom.RNSecureRandomPackage;
|
||||
|
||||
import org.devio.rn.splashscreen.SplashScreenReactPackage;
|
||||
import org.reactnative.camera.RNCameraPackage;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
import fr.bamlab.rnimageresizer.ImageResizerPackage;
|
||||
import im.status.ethereum.function.Function;
|
||||
import im.status.ethereum.keycard.RNStatusKeycardPackage;
|
||||
import im.status.ethereum.module.StatusPackage;
|
||||
import io.invertase.firebase.RNFirebasePackage;
|
||||
import io.invertase.firebase.messaging.RNFirebaseMessagingPackage;
|
||||
import io.invertase.firebase.notifications.RNFirebaseNotificationsPackage;
|
||||
import io.realm.react.RealmReactPackage;
|
||||
import me.alwx.HttpServer.HttpServerReactPackage;
|
||||
|
||||
public class MainApplication extends MultiDexApplication implements ReactApplication {
|
||||
|
||||
@@ -42,19 +45,9 @@ public class MainApplication extends MultiDexApplication implements ReactApplica
|
||||
|
||||
@Override
|
||||
protected List<ReactPackage> getPackages() {
|
||||
boolean devCluster = false;
|
||||
if (BuildConfig.ETHEREUM_DEV_CLUSTER == "1") {
|
||||
devCluster = true;
|
||||
}
|
||||
|
||||
boolean webViewDebugEnabled = false;
|
||||
if (BuildConfig.DEBUG_WEBVIEW == "1") {
|
||||
webViewDebugEnabled = true;
|
||||
}
|
||||
|
||||
StatusPackage statusPackage = new StatusPackage(BuildConfig.DEBUG, devCluster, RootUtil.isDeviceRooted());
|
||||
StatusPackage statusPackage = new StatusPackage(RootUtil.isDeviceRooted());
|
||||
Function<String, String> callRPC = statusPackage.getCallRPC();
|
||||
List<ReactPackage> packages = new ArrayList<ReactPackage>(Arrays.asList(
|
||||
return Arrays.asList(
|
||||
new MainReactPackage(),
|
||||
new RNFirebasePackage(),
|
||||
new RNFirebaseMessagingPackage(),
|
||||
@@ -73,11 +66,9 @@ public class MainApplication extends MultiDexApplication implements ReactApplica
|
||||
new ReactNativeDialogsPackage(),
|
||||
new ImageResizerPackage(),
|
||||
new PickerPackage(),
|
||||
new WebViewBridgePackage(webViewDebugEnabled, callRPC),
|
||||
new WebViewBridgePackage(BuildConfig.DEBUG_WEBVIEW == "1", callRPC),
|
||||
new ReactNativeConfigPackage(),
|
||||
new KeychainPackage()));
|
||||
|
||||
return packages;
|
||||
new KeychainPackage());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user