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

[BUG] Chromecast(ios, android) and onTime event (ios) #16

Open
leinnus opened this issue May 13, 2024 · 3 comments
Open

[BUG] Chromecast(ios, android) and onTime event (ios) #16

leinnus opened this issue May 13, 2024 · 3 comments
Labels
bug Something isn't working Groomed JWP team has reviewed the ticket and deemed it necessary

Comments

@leinnus
Copy link

leinnus commented May 13, 2024

IOS onTimeEvent
ontime event does not work. but android work.

sample source
onTime={event => onTime(event)}

const onTime = async e => {
console.log('onTime', e);
const {position, duration} = e.nativeEvent;
}

IOS Exit Chromecast
After Chromecast ends, there is no video on the screen, only audio.
It plays, but only a black screen appears.

after chromecast ends.
20240514_024247
20240514_024249

ANDROID Chromecast
When Chromecast starts, the screen will be black.
On iOS, the screen image before playback is displayed, but on Android, it is only displayed in black.
And the screen subtitles and quality setting menu disappear. only speed setting menu appear.

android setting menu & black screen(chromecast)
IMG_2820

additionally iOS setting menu work!!(chromecast)
20240514_015704

** Device**

  • iOS: iPhone 14, 17.4.1
  • Android : Samsung Galaxy Z Fold 3, android 14
@Jmilham21 Jmilham21 added needs-grooming Has not been reviewed by codeowners for scope/validation bug Something isn't working Groomed JWP team has reviewed the ticket and deemed it necessary and removed needs-grooming Has not been reviewed by codeowners for scope/validation labels May 13, 2024
@Jmilham21
Copy link
Collaborator

@leinnus We agree that the IOS onTimeEvent not firing while casting is a bug. This will be prioritized and taken care of soon. From our first glance, we believe this is an issue in this codebase and not a Native SDK issue, so it is actionable by you or the open-source community if it's a blocking problem.

The second issue you raised here must be separated into a separate issue to be actioned. Also, I'm unsure if I understand the Bug you are raising. Please clearly state your expectation versus actual in a new Issue so we can determine if it is a bug.

@jmurth1234
Copy link

For the iOS onTimeEvent we have a local patch applied on the previous version of this library:

--- a/ios/RNJWPlayer/RNJWPlayerViewController.swift
+++ b/ios/RNJWPlayer/RNJWPlayerViewController.swift
@@ -170,12 +170,12 @@ class RNJWPlayerViewController : JWPlayerViewController, JWPlayerViewControllerD
 
     // MARK: Time events
 
-    func onAdTimeEvent(time:JWTimeData) {
+    override func onAdTimeEvent(_ time:JWTimeData) {
         super.onAdTimeEvent(time)
         parentView?.onAdTime?(["position": time.position, "duration": time.duration])
     }
 
-    func onMediaTimeEvent(time:JWTimeData) {
+    override func onMediaTimeEvent(_ time:JWTimeData) {
         super.onMediaTimeEvent(time)
         parentView?.onTime?(["position": time.position, "duration": time.duration])
     }

@Jmilham21
Copy link
Collaborator

For the iOS onTimeEvent we have a local patch applied on the previous version of this library:

--- a/ios/RNJWPlayer/RNJWPlayerViewController.swift
+++ b/ios/RNJWPlayer/RNJWPlayerViewController.swift
@@ -170,12 +170,12 @@ class RNJWPlayerViewController : JWPlayerViewController, JWPlayerViewControllerD
 
     // MARK: Time events
 
-    func onAdTimeEvent(time:JWTimeData) {
+    override func onAdTimeEvent(_ time:JWTimeData) {
         super.onAdTimeEvent(time)
         parentView?.onAdTime?(["position": time.position, "duration": time.duration])
     }
 
-    func onMediaTimeEvent(time:JWTimeData) {
+    override func onMediaTimeEvent(_ time:JWTimeData) {
         super.onMediaTimeEvent(time)
         parentView?.onTime?(["position": time.position, "duration": time.duration])
     }

@rymate1234 This will be resolved in 1.0.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Groomed JWP team has reviewed the ticket and deemed it necessary
Projects
None yet
Development

No branches or pull requests

3 participants