react-native-vlc-player
Advanced tools
Comparing version 0.0.6 to 0.0.7
{ | ||
"name": "react-native-vlc-player", | ||
"version": "0.0.6", | ||
"version": "0.0.7", | ||
"description": "VLC Player for react-native", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -16,8 +16,2 @@ ### React-Native-VLC-Player | ||
##### Configure vlc library | ||
Download file [here](https://github.com/ghondar/react-native-vlc-player/raw/master/android/libvlc/libvlc.aar) | ||
And put libvlc.aar on `node_modules/react-native-vlc-player/android/libvlc` | ||
##### Add dependency to `android/settings.gradle` | ||
@@ -41,3 +35,3 @@ ``` | ||
``` | ||
##### Register module in `MainActivity.java` | ||
##### Register module in `MainApplication.java` | ||
```Java | ||
@@ -47,20 +41,8 @@ import com.ghondar.vlcplayer.*; // <--- import | ||
@Override | ||
protected void onCreate(Bundle savedInstanceState) { | ||
super.onCreate(savedInstanceState); | ||
mReactRootView = new ReactRootView(this); | ||
mReactInstanceManager = ReactInstanceManager.builder() | ||
.setApplication(getApplication()) | ||
.setBundleAssetName("index.android.bundle") | ||
.setJSMainModuleName("index.android") | ||
.addPackage(new VLCPlayerPackage()) // <------- here | ||
.addPackage(new MainReactPackage()) | ||
.setUseDeveloperSupport(BuildConfig.DEBUG) | ||
.setInitialLifecycleState(LifecycleState.RESUMED) | ||
.build(); | ||
mReactRootView.startReactApplication(mReactInstanceManager, "doubanbook", null); | ||
setContentView(mReactRootView); | ||
} | ||
protected List<ReactPackage> getPackages() { | ||
return Arrays.<ReactPackage>asList( | ||
new VLCPlayerPackage(), // <------- here | ||
new MainReactPackage() | ||
); | ||
} | ||
``` | ||
@@ -67,0 +49,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
148992
29
460
88