com.facebook.soloader.SoLoader Java Examples

The following examples show how to use com.facebook.soloader.SoLoader. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: DiffingTreePropTestActivity.java    From litho with Apache License 2.0 5 votes vote down vote up
@Override
protected void onCreate(Bundle savedInstanceState) {
  super.onCreate(savedInstanceState);

  SoLoader.init(this, false);

  final ComponentContext c = new ComponentContext(this);
  final LithoView lithoView = LithoView.create(c, RootDiffingComponent.create(c).build());
  setContentView(lithoView);
}
 
Example #2
Source File: MainApplication.java    From Instabug-React-Native with MIT License 5 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  new RNInstabugReactnativePackage.Builder("YOUR_TOKEN", MainApplication.this)
          .setInvocationEvent("button")
          .setPrimaryColor("#1D82DC")
          .setFloatingEdge("left")
          .setFloatingButtonOffsetFromTop(250)
          .build();
  SoLoader.init(this, /* native exopackage */ false);
}
 
Example #3
Source File: ReactInstanceManager.java    From react-native-GPay with MIT License 5 votes vote down vote up
private static void initializeSoLoaderIfNecessary(Context applicationContext) {
  // Call SoLoader.initialize here, this is required for apps that does not use exopackage and
  // does not use SoLoader for loading other native code except from the one used by React Native
  // This way we don't need to require others to have additional initialization code and to
  // subclass android.app.Application.

  // Method SoLoader.init is idempotent, so if you wish to use native exopackage, just call
  // SoLoader.init with appropriate args before initializing ReactInstanceManager
  SoLoader.init(applicationContext, /* native exopackage */ false);
}
 
Example #4
Source File: ReactImagePropertyTest.java    From react-native-GPay with MIT License 5 votes vote down vote up
@Before
public void setup() {
  SoLoader.setInTestMode();
  mContext = new ReactApplicationContext(RuntimeEnvironment.application);
  mCatalystInstanceMock = ReactTestHelper.createMockCatalystInstance();
  mContext.initializeWithInstance(mCatalystInstanceMock);
  mThemeContext = new ThemedReactContext(mContext, mContext);
  Fresco.initialize(mContext);
  DisplayMetricsHolder.setWindowDisplayMetrics(new DisplayMetrics());
}
 
Example #5
Source File: MainApplication.java    From react-native-android-activity with MIT License 5 votes vote down vote up
/**
 * Called when the application is starting, before any activity, service,
 * or receiver objects (excluding content providers) have been created.
 *
 * <p>This implementation loads the React Native JNI libraries.</p>
 */
@Override
@CallSuper
public void onCreate() {
    super.onCreate();
    SoLoader.init(this, false);
}
 
Example #6
Source File: MainApplication.java    From photo-viewer with Apache License 2.0 5 votes vote down vote up
@Override
    public void onCreate() {
        super.onCreate();
        SoLoader.init(this, /* native exopackage */ false);
        ImagePipelineConfig config = ImagePipelineConfig.newBuilder(this)
                .setProgressiveJpegConfig(new SimpleProgressiveJpegConfig())
                .setResizeAndRotateEnabledForNetwork(true)
                .setDownsampleEnabled(true)
                .build();
//        debug
//        DraweeConfig draweeConfig = DraweeConfig.newBuilder()
//                .setDrawDebugOverlay(true)
//                .build();
        Fresco.initialize(this, config);
    }
 
Example #7
Source File: LithoLabApplication.java    From litho with Apache License 2.0 5 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();

  SoLoader.init(this, false);
  Fresco.initialize(this);
}
 
Example #8
Source File: MainApplication.java    From native-navigation with MIT License 5 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);

  ReactNavigationCoordinator coordinator = ReactNavigationCoordinator.sharedInstance;
  coordinator.injectReactInstanceManager(mReactNativeHost.getReactInstanceManager());
  coordinator.start(this);
}
 
Example #9
Source File: MainApplication.java    From react-native-download-button with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
  initializeFlipper(this); // Remove this line if you don't want Flipper enabled
}
 
Example #10
Source File: InstrumentationApp.java    From litho with Apache License 2.0 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();

  SoLoader.init(this, false);
}
 
Example #11
Source File: MainApplication.java    From react-native-tesseract-ocr with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
}
 
Example #12
Source File: MainApplication.java    From react-native-screens with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
  initializeFlipper(this, getReactNativeHost().getReactInstanceManager());
}
 
Example #13
Source File: MainApplication.java    From react-native-SmartRefreshLayout with Apache License 2.0 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
}
 
Example #14
Source File: MainApplication.java    From react-native-text-gradient with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
}
 
Example #15
Source File: MainApplication.java    From react-native-twitterkit with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
    super.onCreate();
    SoLoader.init(this, /* native exopackage */ false);
    registerActivityLifecycleCallbacks(this);
}
 
Example #16
Source File: MainApplication.java    From react-native-line with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
}
 
Example #17
Source File: MainApplication.java    From react-native-splash-screen with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
  initializeFlipper(this, getReactNativeHost().getReactInstanceManager());
}
 
Example #18
Source File: MainApplication.java    From react-native-selection-menu with Apache License 2.0 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
  initializeFlipper(this, getReactNativeHost().getReactInstanceManager());
}
 
Example #19
Source File: MainApplication.java    From react-native-photo-editor with Apache License 2.0 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
  initializeFlipper(this); // Remove this line if you don't want Flipper enabled
}
 
Example #20
Source File: MainApplication.java    From react-native-bluetooth-status with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
  initializeFlipper(this); // Remove this line if you don't want Flipper enabled
}
 
Example #21
Source File: MainApplication.java    From react-native-shine-button with Apache License 2.0 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
  initializeFlipper(this); // Remove this line if you don't want Flipper enabled
}
 
Example #22
Source File: MainApplication.java    From react-native-android-wifi with ISC License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
}
 
Example #23
Source File: MainApplication.java    From react-native-google-fitness with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
    super.onCreate();
    SoLoader.init(this, /* native exopackage */ false);
}
 
Example #24
Source File: NativeCodeInitializer.java    From fresco with MIT License 4 votes vote down vote up
/** Initialize NativeLoader and SoLoader */
@DoNotStrip
public static void init(Context context) throws IOException {
  SoLoader.init(context, 0);
}
 
Example #25
Source File: MainApplication.java    From react-native-dev-menu with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
  initializeFlipper(this, getReactNativeHost().getReactInstanceManager());
}
 
Example #26
Source File: MainApplication.java    From react-native-voice-recorder with Apache License 2.0 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
  initializeFlipper(this); // Remove this line if you don't want Flipper enabled
}
 
Example #27
Source File: MainApplication.java    From react-native-appmetrica with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
  initializeFlipper(this); // Remove this line if you don't want Flipper enabled
}
 
Example #28
Source File: MainApplication.java    From react-native-webview-android-file-upload with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
}
 
Example #29
Source File: MainApplication.java    From ReactNative-AndAndroid with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
}
 
Example #30
Source File: MainApplication.java    From ReactNative-AndAndroid with MIT License 4 votes vote down vote up
@Override
public void onCreate() {
  super.onCreate();
  SoLoader.init(this, /* native exopackage */ false);
}