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

setCurrentTime fails silently for Vimeo iframe embeds in iOS Safari #117

Closed
ehmorris opened this issue Feb 8, 2017 · 11 comments
Closed
Labels
bug Something isn't working

Comments

@ehmorris
Copy link

ehmorris commented Feb 8, 2017

Expected Behavior

For setCurrentTime to seek the Vimeo player and display the frame at the passed timestamp. Or for setCurrentTime to return an error in the catch method.

For comparison, the YouTube iframe player will display the frame at the passed timestamp in iOS Safari when seekTo is called via the iframe API.

Actual Behavior

The player does not seek and does not return an error in iOS Safari.

Steps to Reproduce

CodePen debug view | CodePen editor view

Correct behavior on desktop
  1. Open the linked debug view on a desktop browser.
  2. Scroll up/down.
  3. Note the video scrubbing in the background, also note the console logging setCurrentTime invocation, and success or failure.
Incorrect behavior on mobile
  1. Open the linked debug view in iOS Safari.
  2. Scroll up/down.
  3. Note the video not responding, also note the console logging setCurrentTime invocation but never logging success or failure.

Compare to YouTube

CodePen debug view | CodePen editor view

Correct behavior on mobile
  1. Open the linked debug view in iOS Safari.
  2. Scroll up/down.
  3. Note the video scrubbing successfully.

Additional Note

I think this may be resolved by enabling the new playsinline feature within the iframe embed.

@ehmorris
Copy link
Author

@bdougherty do you think I can expect this behavior to be added to the vimeo player on mobile?

@bdougherty
Copy link
Member

@ehmorris can you try adding a listener for the error event? There is a bug right now that prevents the method-specific error response messages from going out if you aren't listening for error events. I hope to have a fix for that soon.

We don't have any plans at the moment to add support for inline playback on iOS.

@ksolberg
Copy link

Are there any workarounds for this?

@enoziak
Copy link

enoziak commented Oct 31, 2017

Did this ever get worked out? I'm running into the same issue.

@ehmorris
Copy link
Author

Afaik there are no workarounds for my use-case.

Also worth noting that since I posted this, YouTube/iOS behavior has changed such that the mobile player autoplays the video from the scrubbed timestamp.

@luwes
Copy link
Contributor

luwes commented Feb 22, 2018

#210 will add a playsinline parameter

@luwes luwes added the bug Something isn't working label Mar 2, 2018
@luwes
Copy link
Contributor

luwes commented Mar 2, 2018

@ehmorris would you mind having a look if this issue persists? We recently had several fixes go out, including the throwing errors correctly in catch.

@ehmorris
Copy link
Author

ehmorris commented Mar 2, 2018

@luwes thanks for coming back to this. I went through my reproduction steps and noticed that before I initiate playback, I get the error Error: The viewer must initiate playback first., and after I initiate playback it seeks to the time and continues to play.

@luwes luwes marked this as a duplicate of #166 Mar 2, 2018
@luwes luwes closed this as completed Mar 2, 2018
@luwes luwes marked this as not a duplicate of #166 Mar 2, 2018
@luwes luwes reopened this Mar 2, 2018
@luwes
Copy link
Contributor

luwes commented Mar 2, 2018

(^^ scusi, was in the wrong window)

I think currently that is the best we can do. setCurrentTime() internally calls play() which will fail because it's done without user interaction. Only for muted videos this can be done I believe.

Would you like to see different behaviour in this case?

@ehmorris
Copy link
Author

ehmorris commented Mar 2, 2018

@luwes sorry, to clarify I think my issue is resolved.

It would be awesome if I could set the time on a muted, uninitialized video though.

@luwes
Copy link
Contributor

luwes commented Mar 2, 2018

Awesome! I will reference #20 here to keep that in mind when adding a start time option.
Thanks for your feedback!

@luwes luwes closed this as completed Mar 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants