Closed Bug 1582378 Opened 5 years ago Closed 5 years ago

[Twitch] Play/Pause button is no longer functional in the PiP window after clicking them for the first them


(Toolkit :: Video/Audio Controls, defect, P2)

Windows 10



Tracking Status
firefox69 --- disabled
firefox70 --- affected
firefox71 --- affected
firefox72 --- affected


(Reporter: tbabos, Unassigned)




(1 file)

Attached video Video of the issue

Affected versions:
Nightly 71.0a1 (2019-09-18)
Beta 70.bb7

Affected platforms:
Windows 7/10

Steps to reproduce:

  • Launch Nightly or Beta
  • Go to
  • Play any twitch stream (try to find one without extension or disable the extension - due to Bug 1543805)
  • Toggle video into PiP window
  • Click on the Play/Pause button in the PiP window

Expected result:
The video should be paused and un-paused in the PiP window

Actual Result:
The Play button is no longer functional and the user has to click on the Play button from the main browser window

Priority: -- → P2

I'll note that Opera has a similar problem with their own built-in Picture-in-Picture feature.

The issue appears to be a rather complicated mechanism where a network request needs to be made and bounced around inside of a Worker with some WASM inside of it before the HLS stream can be resumed properly. I haven't yet worked out what the Worker is doing yet.

So from what I can tell, this WASM module is part of Twitch's "SureStream" product, and ultimately what it appears to do is make it really difficult to block ads on Twitch. The WASM code seems to be doing a bunch of work to generate a long string that's sent to Twitch in order to get the m3u8 manifest for the stream.

Off the top of my head, I don't think there's a really general solution to this. This is likely one of the main motivators for the PiP API from Twitch's end - they want to have the PiP functionality, but they want to be able to hook in their Worker when the "play" button is clicked.

astevenson - I don't believe there's a great technical solution here, unless we special-case Twitch (and that'll be brittle). Thoughts?

Flags: needinfo?(astevenson)

Hi Mike the wasm module is part of the twitch video player. We don't currently support interaction through video element controls (play/pause) but only our own UI controls which uses our internal player API. This is something we will look further into thanks!

Hi Nikhil,

Thanks for reaching out! The way the Play/Pause control from our Picture-in-Picture player window works is by calling the play() and pause() methods on the <video> element directly. My understanding from what you've written so far is that this is not currently supported. Is this something that might someday become supported?

If so, this will also fix a similar issue that Opera experiences with their Picture-in-Player feature, and for users of the FrankerFaceZ Twitch enhancement suite WebExtension.

Flags: needinfo?(purushen)

Hi Mike,
Thanks for confirming, that definitely is the problem. This is something we're looking at supporting don't have a concrete date but we'll keep this issue updated.

Flags: needinfo?(purushen)

Thank you Nikhil!

Flags: needinfo?(astevenson)
Blocks: 1532675
No longer blocks: 1527926

Reproduced on latest Nightly build 72.0a1 (2019-11-06) using Windows 8.

Hi all we released a new player version (2.20.6) that we believe will address this change. Can you confirm?

Yes, this works perfectly! Thank you so much!

Closed: 5 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.