Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 0.14.1 #324

Merged
merged 8 commits into from
Nov 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog

## [0.14.1] (2023-11-16)

### Fixed

- Android: `PlayerView` destroys attached `Player` instance on destroy. `Player` lifecycle must be handled on the creation side

## [0.14.0] (2023-11-14)

### Added
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,7 @@ class RNPlayerView(

private var _playerView: PlayerView? = null
set(value) {
field?.removeOnLayoutChangeListener(this)
field = value
viewEventRelay.eventEmitter = field
playerEventRelay.eventEmitter = field?.player
Expand All @@ -157,8 +158,7 @@ class RNPlayerView(
/**
* Associated Bitmovin's `PlayerView`.
*/
val playerView: PlayerView?
get() = _playerView
val playerView: PlayerView? get() = _playerView

private var subtitleView: SubtitleView? = null

Expand Down Expand Up @@ -186,11 +186,15 @@ class RNPlayerView(
* Cleans up the resources and listeners produced by this view.
*/
fun dispose() {
viewEventRelay.eventEmitter = null
playerEventRelay.eventEmitter = null
playerView?.removeOnLayoutChangeListener(this)
playerView?.onDestroy()
activityLifecycle.removeObserver(activityLifecycleObserver)

val playerView = _playerView ?: return
_playerView = null
// The `RNPlayerView` should not take care of the player lifecycle.
// As a different component is creating the player instance, the other component
// is responsible for destroying the player in the end.
playerView.player = null
playerView.onDestroy()
}

/**
Expand Down
4 changes: 2 additions & 2 deletions example/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ PODS:
- React-jsi (= 0.69.6-2)
- React-logger (= 0.69.6-2)
- React-perflogger (= 0.69.6-2)
- RNBitmovinPlayer (0.14.0):
- RNBitmovinPlayer (0.14.1):
- BitmovinPlayer (= 3.48.0)
- GoogleAds-IMA-iOS-SDK (= 3.18.4)
- GoogleAds-IMA-tvOS-SDK (= 4.8.2)
Expand Down Expand Up @@ -574,7 +574,7 @@ SPEC CHECKSUMS:
React-RCTText: f72442f7436fd8624494963af4906000a5465ce6
React-runtimeexecutor: f1383f6460ea3d66ed122b4defb0b5ba664ee441
ReactCommon: 7857ab475239c5ba044b7ed946ba564f2e7f1626
RNBitmovinPlayer: 7b30750994923ebfe825e82f9182cd0e03e1b708
RNBitmovinPlayer: e2436bccf53ed596ece178e6553ea7268d792163
RNCPicker: 0250e95ad170569a96f5b0555cdd5e65b9084dca
RNScreens: 4a1af06327774490d97342c00aee0c2bafb497b7
SocketRocket: f32cd54efbe0f095c4d7594881e52619cfe80b17
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "bitmovin-player-react-native",
"version": "0.14.0",
"version": "0.14.1",
"description": "Official React Native bindings for Bitmovin's mobile Player SDKs.",
"main": "lib/index.js",
"module": "lib/index.mjs",
Expand Down