diff --git a/android/constants.gradle b/android/constants.gradle index 2b7800f..dc0d520 100644 --- a/android/constants.gradle +++ b/android/constants.gradle @@ -1,6 +1,6 @@ project.ext { BRIGHTCOVE_VERSION = '6.17.3' - PLAY_SERVICES_VERSION = '19.2.0' + PLAY_SERVICES_VERSION = '20.3.0' GOOGLE_IMA_SDK_VERSION = '3.19.4' ANDROIDX_LEGACY_SUPPORT_V4 = '1.0.0' ANDROIDX_MEDIA = '1.1.0' diff --git a/example/android/build.gradle b/example/android/build.gradle index 18b0313..4eed942 100644 --- a/example/android/build.gradle +++ b/example/android/build.gradle @@ -12,7 +12,7 @@ buildscript { jcenter() } dependencies { - classpath('com.android.tools.build:gradle:3.5.3') + classpath('com.android.tools.build:gradle:3.5.4') // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files diff --git a/example/ios/Podfile.lock b/example/ios/Podfile.lock index a571c3b..83be479 100644 --- a/example/ios/Podfile.lock +++ b/example/ios/Podfile.lock @@ -30,38 +30,54 @@ PODS: - DoubleConversion - glog - glog (0.3.5) - - Google-Mobile-Ads-SDK (7.55.1): - - GoogleAppMeasurement (~> 6.0) + - Google-Mobile-Ads-SDK (8.11.0): + - GoogleAppMeasurement (< 9.0, >= 7.0) + - GoogleUserMessagingPlatform (>= 1.1) - GoogleAds-IMA-iOS-SDK (3.14.4) - - GoogleAppMeasurement (6.9.0): - - GoogleUtilities/AppDelegateSwizzler (~> 6.7) - - GoogleUtilities/MethodSwizzler (~> 6.7) - - GoogleUtilities/Network (~> 6.7) - - "GoogleUtilities/NSData+zlib (~> 6.7)" - - nanopb (~> 1.30906.0) - - GoogleUtilities/AppDelegateSwizzler (6.7.2): + - GoogleAppMeasurement (8.12.0): + - GoogleAppMeasurement/AdIdSupport (= 8.12.0) + - GoogleUtilities/AppDelegateSwizzler (~> 7.7) + - GoogleUtilities/MethodSwizzler (~> 7.7) + - GoogleUtilities/Network (~> 7.7) + - "GoogleUtilities/NSData+zlib (~> 7.7)" + - nanopb (~> 2.30908.0) + - GoogleAppMeasurement/AdIdSupport (8.12.0): + - GoogleAppMeasurement/WithoutAdIdSupport (= 8.12.0) + - GoogleUtilities/AppDelegateSwizzler (~> 7.7) + - GoogleUtilities/MethodSwizzler (~> 7.7) + - GoogleUtilities/Network (~> 7.7) + - "GoogleUtilities/NSData+zlib (~> 7.7)" + - nanopb (~> 2.30908.0) + - GoogleAppMeasurement/WithoutAdIdSupport (8.12.0): + - GoogleUtilities/AppDelegateSwizzler (~> 7.7) + - GoogleUtilities/MethodSwizzler (~> 7.7) + - GoogleUtilities/Network (~> 7.7) + - "GoogleUtilities/NSData+zlib (~> 7.7)" + - nanopb (~> 2.30908.0) + - GoogleUserMessagingPlatform (2.0.0) + - GoogleUtilities/AppDelegateSwizzler (7.7.0): - GoogleUtilities/Environment - GoogleUtilities/Logger - GoogleUtilities/Network - - GoogleUtilities/Environment (6.7.2): - - PromisesObjC (~> 1.2) - - GoogleUtilities/Logger (6.7.2): + - GoogleUtilities/Environment (7.7.0): + - PromisesObjC (< 3.0, >= 1.2) + - GoogleUtilities/Logger (7.7.0): - GoogleUtilities/Environment - - GoogleUtilities/MethodSwizzler (6.7.2): + - GoogleUtilities/MethodSwizzler (7.7.0): - GoogleUtilities/Logger - - GoogleUtilities/Network (6.7.2): + - GoogleUtilities/Network (7.7.0): - GoogleUtilities/Logger - "GoogleUtilities/NSData+zlib" - GoogleUtilities/Reachability - - "GoogleUtilities/NSData+zlib (6.7.2)" - - GoogleUtilities/Reachability (6.7.2): + - "GoogleUtilities/NSData+zlib (7.7.0)" + - GoogleUtilities/Reachability (7.7.0): - GoogleUtilities/Logger - - nanopb (1.30906.0): - - nanopb/decode (= 1.30906.0) - - nanopb/encode (= 1.30906.0) - - nanopb/decode (1.30906.0) - - nanopb/encode (1.30906.0) - - PromisesObjC (1.2.12) + - nanopb (2.30908.0): + - nanopb/decode (= 2.30908.0) + - nanopb/encode (= 2.30908.0) + - nanopb/decode (2.30908.0) + - nanopb/encode (2.30908.0) + - PromisesObjC (2.0.0) - RCTRequired (0.63.4) - RCTTypeSafety (0.63.4): - FBLazyVector (= 0.63.4) @@ -228,9 +244,9 @@ PODS: - React-cxxreact (= 0.63.4) - React-jsi (= 0.63.4) - React-jsinspector (0.63.4) - - react-native-brightcove-ima-player (2.0.0): + - react-native-brightcove-ima-player (2.1.1): - Brightcove-Player-IMA (= 6.10.2) - - Google-Mobile-Ads-SDK (~> 7.55.0) + - Google-Mobile-Ads-SDK (~> 8.11.0) - React-Core - React-RCTActionSheet (0.63.4): - React-Core/RCTActionSheetHeaders (= 0.63.4) @@ -334,6 +350,7 @@ SPEC REPOS: - Google-Mobile-Ads-SDK - GoogleAds-IMA-iOS-SDK - GoogleAppMeasurement + - GoogleUserMessagingPlatform - GoogleUtilities - nanopb - PromisesObjC @@ -403,12 +420,13 @@ SPEC CHECKSUMS: FBReactNativeSpec: f2c97f2529dd79c083355182cc158c9f98f4bd6e Folly: b73c3869541e86821df3c387eb0af5f65addfab4 glog: 40a13f7840415b9a77023fbcae0f1e6f43192af3 - Google-Mobile-Ads-SDK: f206aff290f26fde422495c6cd187e50efbed57e + Google-Mobile-Ads-SDK: be2192b51b74d74a6ed70590c2e8275412f1b71e GoogleAds-IMA-iOS-SDK: c190284044e9a28b3e7422ba9886db015c71a84f - GoogleAppMeasurement: a6a3a066369828db64eda428cb2856dc1cdc7c4e - GoogleUtilities: 7f2f5a07f888cdb145101d6042bc4422f57e70b3 - nanopb: 59317e09cf1f1a0af72f12af412d54edf52603fc - PromisesObjC: 3113f7f76903778cf4a0586bd1ab89329a0b7b97 + GoogleAppMeasurement: ae033c3aad67e68294369373056b4d74cc8ae0d6 + GoogleUserMessagingPlatform: ab890ce5f6620f293a21b6bdd82e416a2c73aeca + GoogleUtilities: e0913149f6b0625b553d70dae12b49fc62914fd1 + nanopb: a0ba3315591a9ae0a16a309ee504766e90db0c96 + PromisesObjC: 68159ce6952d93e17b2dfe273b8c40907db5ba58 RCTRequired: 082f10cd3f905d6c124597fd1c14f6f2655ff65e RCTTypeSafety: 8c9c544ecbf20337d069e4ae7fd9a377aadf504b React: b0a957a2c44da4113b0c4c9853d8387f8e64e615 @@ -419,7 +437,7 @@ SPEC CHECKSUMS: React-jsi: a0418934cf48f25b485631deb27c64dc40fb4c31 React-jsiexecutor: 93bd528844ad21dc07aab1c67cb10abae6df6949 React-jsinspector: 58aef7155bc9a9683f5b60b35eccea8722a4f53a - react-native-brightcove-ima-player: 2af8b65ce3d07d20f622978aab38ccb37f59e38c + react-native-brightcove-ima-player: 0c6c39b1a1d8d5e9c9be6ec73f4a4940a86e4725 React-RCTActionSheet: 89a0ca9f4a06c1f93c26067af074ccdce0f40336 React-RCTAnimation: 1bde3ecc0c104c55df246eda516e0deb03c4e49b React-RCTBlob: a97d378b527740cc667e03ebfa183a75231ab0f0 diff --git a/example/src/App.tsx b/example/src/App.tsx index 0ab063f..5055fbb 100644 --- a/example/src/App.tsx +++ b/example/src/App.tsx @@ -1,6 +1,6 @@ import * as React from 'react'; -import { StyleSheet, View, Text } from 'react-native'; +import { StyleSheet, View, Text, Button } from 'react-native'; import { BrightcoveIMAPlayer, BrightcoveIMAPlayerPoster, @@ -24,6 +24,12 @@ const gam_video_url = 'https://pubads.g.doubleclick.net/gampad/ads?sz=640x480&iu=/124319096/external/ad_rule_samples&ciu_szs=300x250&ad_rule=1&impl=s&gdfp_req=1&env=vp&output=vmap&unviewed_position_start=1&cust_params=deployment%3Ddevsite%26sample_ar%3Dpremidpost&cmsid=496&vid=short_onecue&correlator='; export default function App() { + const videoPlayer = React.useRef(null); + + function stopPlayback() { + videoPlayer?.current?.stopPlayback(); + } + return ( @@ -39,6 +45,7 @@ export default function App() { +