Merge branch 'master' into fix-NSInternalInconsistencyException
This commit is contained in:
		| @@ -1,13 +1,17 @@ | |||||||
| ## Changelog | ## Changelog | ||||||
|  |  | ||||||
| ### Version 5.0.1 | ### Version 5.0.2 | ||||||
| * Fix crash when RCTVideo's superclass doesn't observe the keyPath 'frame' (iOS) [#1720](https://github.com/react-native-community/react-native-video/pull/1720) | * Fix crash when RCTVideo's superclass doesn't observe the keyPath 'frame' (iOS) [#1720](https://github.com/react-native-community/react-native-video/pull/1720) | ||||||
|  |  | ||||||
| ### Version 5.0.0 | ### Version 5.0.1 | ||||||
|  | * Fix AndroidX Support bad merge | ||||||
|  |  | ||||||
|  | ### Version 5.0.0 [Deprecated] | ||||||
| * AndroidX Support | * AndroidX Support | ||||||
|  |  | ||||||
| ### Version 4.4.4 | ### Version 4.4.4 | ||||||
| * Handle racing conditions when props are setted on exoplayer | * Handle racing conditions when props are setted on exoplayer | ||||||
|  |  | ||||||
| ### Version 4.4.3 | ### Version 4.4.3 | ||||||
| * Fix mute/unmute when controls are present (iOS) [#1654](https://github.com/react-native-community/react-native-video/pull/1654) | * Fix mute/unmute when controls are present (iOS) [#1654](https://github.com/react-native-community/react-native-video/pull/1654) | ||||||
| * Fix Android videos being able to play with background music/audio from other apps. | * Fix Android videos being able to play with background music/audio from other apps. | ||||||
|   | |||||||
							
								
								
									
										63
									
								
								README.md
									
									
									
									
									
								
							
							
						
						
									
										63
									
								
								README.md
									
									
									
									
									
								
							| @@ -3,10 +3,16 @@ | |||||||
| A `<Video>` component for react-native, as seen in | A `<Video>` component for react-native, as seen in | ||||||
| [react-native-login](https://github.com/brentvatne/react-native-login)! | [react-native-login](https://github.com/brentvatne/react-native-login)! | ||||||
|  |  | ||||||
|  | Version 5.x recommends react-native >= 0.60.0 for Android 64bit builds and Android X support. | ||||||
|  |  | ||||||
| Version 4.x requires react-native >= 0.57.0 | Version 4.x requires react-native >= 0.57.0 | ||||||
|  |  | ||||||
| Version 3.x requires react-native >= 0.40.0 | Version 3.x requires react-native >= 0.40.0 | ||||||
|  |  | ||||||
|  | ### Version 5.0.0 breaking changes | ||||||
|  |  | ||||||
|  | Version 5 introduces breaking changes on Android, please check carefully the steps described there: [Android Installation](#Android-installation) | ||||||
|  |  | ||||||
| ### Version 4.0.0 breaking changes | ### Version 4.0.0 breaking changes | ||||||
| Version 4.0.0 changes some behaviors and may require updates to your Gradle files.  See [Updating](#updating) for details. | Version 4.0.0 changes some behaviors and may require updates to your Gradle files.  See [Updating](#updating) for details. | ||||||
|  |  | ||||||
| @@ -20,6 +26,11 @@ Version 3.0 features a number of changes to existing behavior. See [Updating](#u | |||||||
| ## Table of Contents | ## Table of Contents | ||||||
|  |  | ||||||
| * [Installation](#installation) | * [Installation](#installation) | ||||||
|  |   * [iOS](#ios-installation) | ||||||
|  |   * [tvOS](#tvos-installation) | ||||||
|  |   * [Android](#android-installation) | ||||||
|  |   * [Windows](#windows-installation) | ||||||
|  |   * [react-native-dom](#react-native-dom-installation) | ||||||
| * [Usage](#usage) | * [Usage](#usage) | ||||||
| * [iOS App Transport Security](#ios-app-transport-security) | * [iOS App Transport Security](#ios-app-transport-security) | ||||||
| * [Audio Mixing](#audio-mixing) | * [Audio Mixing](#audio-mixing) | ||||||
| @@ -42,12 +53,18 @@ yarn add react-native-video | |||||||
|  |  | ||||||
| Then follow the instructions for your platform to link react-native-video into your project: | Then follow the instructions for your platform to link react-native-video into your project: | ||||||
|  |  | ||||||
| ### iOS | ### iOS installation | ||||||
| <details> | <details> | ||||||
|   <summary>iOS details</summary> |   <summary>iOS details</summary> | ||||||
|  |  | ||||||
| #### Standard Method | #### Standard Method | ||||||
|  |  | ||||||
|  | **React Native 0.60 and above** | ||||||
|  |  | ||||||
|  | Run `pod install` in the `ios` directory. Linking is not required in React Native 0.60 and above. | ||||||
|  |  | ||||||
|  | **React Native 0.59 and below** | ||||||
|  |  | ||||||
| Run `react-native link react-native-video` to link the react-native-video library. | Run `react-native link react-native-video` to link the react-native-video library. | ||||||
|  |  | ||||||
| #### Using CocoaPods (required to enable caching) | #### Using CocoaPods (required to enable caching) | ||||||
| @@ -74,7 +91,7 @@ end | |||||||
|  |  | ||||||
| </details> | </details> | ||||||
|  |  | ||||||
| ### tvOS | ### tvOS installation | ||||||
|   <details> |   <details> | ||||||
|   <summary>tvOS details</summary> |   <summary>tvOS details</summary> | ||||||
|    |    | ||||||
| @@ -97,7 +114,7 @@ Select RCTVideo-tvOS | |||||||
| <img src="./docs/tvOS-step-4.jpg" width="40%"> | <img src="./docs/tvOS-step-4.jpg" width="40%"> | ||||||
| </details> | </details> | ||||||
|  |  | ||||||
| ### Android | ### Android installation | ||||||
| <details> | <details> | ||||||
|   <summary>Android details</summary> |   <summary>Android details</summary> | ||||||
|  |  | ||||||
| @@ -121,7 +138,6 @@ include ':react-native-video' | |||||||
| project(':react-native-video').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-video/android') | project(':react-native-video').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-video/android') | ||||||
| ``` | ``` | ||||||
|  |  | ||||||
|  |  | ||||||
| #### **android/app/build.gradle** | #### **android/app/build.gradle** | ||||||
|  |  | ||||||
| From version >= 5.0.0, you have to apply this changes: | From version >= 5.0.0, you have to apply this changes: | ||||||
| @@ -130,7 +146,8 @@ From version >= 5.0.0, you have to apply this changes: | |||||||
| dependencies { | dependencies { | ||||||
|    ... |    ... | ||||||
|     compile project(':react-native-video') |     compile project(':react-native-video') | ||||||
|     implementation "com.android.support:appcompat-v7:${rootProject.ext.supportLibVersion}" | +   implementation "androidx.appcompat:appcompat:1.0.0" | ||||||
|  | -   implementation "com.android.support:appcompat-v7:${rootProject.ext.supportLibVersion}" | ||||||
|  |  | ||||||
| } | } | ||||||
| ``` | ``` | ||||||
| @@ -165,7 +182,7 @@ protected List<ReactPackage> getPackages() { | |||||||
| ``` | ``` | ||||||
| </details> | </details> | ||||||
|  |  | ||||||
| ### Windows | ### Windows installation | ||||||
| <details> | <details> | ||||||
|   <summary>Windows details</summary> |   <summary>Windows details</summary> | ||||||
|  |  | ||||||
| @@ -215,7 +232,7 @@ using System.Collections.Generic; | |||||||
| ``` | ``` | ||||||
| </details> | </details> | ||||||
|  |  | ||||||
| ### react-native-dom | ### react-native-dom installation | ||||||
| <details> | <details> | ||||||
|   <summary>react-native-dom details</summary> |   <summary>react-native-dom details</summary> | ||||||
|  |  | ||||||
| @@ -1286,6 +1303,38 @@ To enable audio to play in background on iOS the audio session needs to be set t | |||||||
|  |  | ||||||
| ## Updating | ## Updating | ||||||
|  |  | ||||||
|  | ### Version 5.0.0 | ||||||
|  |  | ||||||
|  | Probably you want to update your gradle version: | ||||||
|  | #### gradle-wrapper.properties | ||||||
|  | ```diff | ||||||
|  | - distributionUrl=https\://services.gradle.org/distributions/gradle-3.3-all.zip | ||||||
|  | + distributionUrl=https\://services.gradle.org/distributions/gradle-5.1.1-all.zip | ||||||
|  | ``` | ||||||
|  |  | ||||||
|  | #### **android/app/build.gradle** | ||||||
|  |  | ||||||
|  | From version >= 5.0.0, you have to apply this changes: | ||||||
|  |  | ||||||
|  | ```diff | ||||||
|  | dependencies { | ||||||
|  |    ... | ||||||
|  |     compile project(':react-native-video') | ||||||
|  | +   implementation "androidx.appcompat:appcompat:1.0.0" | ||||||
|  | -   implementation "com.android.support:appcompat-v7:${rootProject.ext.supportLibVersion}" | ||||||
|  |  | ||||||
|  | } | ||||||
|  | ``` | ||||||
|  |  | ||||||
|  | #### **android/gradle.properties** | ||||||
|  |  | ||||||
|  | Migrating to AndroidX (needs version >= 5.0.0): | ||||||
|  |  | ||||||
|  | ```gradle.properties | ||||||
|  | android.useAndroidX=true | ||||||
|  | android.enableJetifier=true | ||||||
|  | ``` | ||||||
|  |  | ||||||
| ### Version 4.0.0 | ### Version 4.0.0 | ||||||
|  |  | ||||||
| #### Gradle 3 and target SDK 26 requirement | #### Gradle 3 and target SDK 26 requirement | ||||||
|   | |||||||
| @@ -2,7 +2,7 @@ package com.brentvatne.exoplayer; | |||||||
|  |  | ||||||
| import android.annotation.TargetApi; | import android.annotation.TargetApi; | ||||||
| import android.content.Context; | import android.content.Context; | ||||||
| import android.support.v4.content.ContextCompat; | import androidx.core.content.ContextCompat; | ||||||
| import android.util.AttributeSet; | import android.util.AttributeSet; | ||||||
| import android.util.Log; | import android.util.Log; | ||||||
| import android.view.Gravity; | import android.view.Gravity; | ||||||
|   | |||||||
| @@ -1,6 +1,6 @@ | |||||||
| package com.brentvatne.exoplayer; | package com.brentvatne.exoplayer; | ||||||
|  |  | ||||||
| import android.support.annotation.IntDef; | import androidx.annotation.IntDef; | ||||||
|  |  | ||||||
| import java.lang.annotation.Retention; | import java.lang.annotation.Retention; | ||||||
|  |  | ||||||
|   | |||||||
| @@ -1,6 +1,6 @@ | |||||||
| package com.brentvatne.exoplayer; | package com.brentvatne.exoplayer; | ||||||
|  |  | ||||||
| import android.support.annotation.StringDef; | import androidx.annotation.StringDef; | ||||||
| import android.view.View; | import android.view.View; | ||||||
|  |  | ||||||
| import com.facebook.react.bridge.Arguments; | import com.facebook.react.bridge.Arguments; | ||||||
|   | |||||||
| @@ -111,6 +111,7 @@ android { | |||||||
|         release { |         release { | ||||||
|             signingConfig signingConfigs.debug |             signingConfig signingConfigs.debug | ||||||
|             minifyEnabled enableProguardInReleaseBuilds |             minifyEnabled enableProguardInReleaseBuilds | ||||||
|  |             matchingFallbacks = ['release', 'debug'] | ||||||
|             proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro" |             proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro" | ||||||
|         } |         } | ||||||
|     } |     } | ||||||
|   | |||||||
| @@ -18,3 +18,5 @@ | |||||||
| # org.gradle.parallel=true | # org.gradle.parallel=true | ||||||
|  |  | ||||||
| android.useDeprecatedNdk=true | android.useDeprecatedNdk=true | ||||||
|  | android.useAndroidX=true | ||||||
|  | android.enableJetifier=true | ||||||
| @@ -1,6 +1,6 @@ | |||||||
| { | { | ||||||
|     "name": "react-native-video", |     "name": "react-native-video", | ||||||
|     "version": "5.0.0", |     "version": "5.0.1", | ||||||
|     "description": "A <Video /> element for react-native", |     "description": "A <Video /> element for react-native", | ||||||
|     "main": "Video.js", |     "main": "Video.js", | ||||||
|     "license": "MIT", |     "license": "MIT", | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user