Closed Bug 1301043 Opened 3 years ago Closed 3 years ago

HLS video player overlaps other tabs once played

Categories

(Firefox for Android :: Audio/Video, defect, P1)

51 Branch
ARM
Android
defect

Tracking

()

VERIFIED FIXED
Firefox 52
Tracking Status
fennec 51+ ---
firefox50 --- verified
firefox51 --- verified
firefox52 --- verified

People

(Reporter: u549602, Assigned: snorp)

References

Details

(Keywords: qablocker)

Attachments

(1 file)

Environment: Nightly 51.0a1 
Device: Xiaomi mi Pad2  (Android 5.1 );
Build: Nightly 51.0a1 (2016-09-07);

Steps to reproduce:
1. Go to https://people.mozilla.org/~jwillcox/hls.apk and play HLS video
2. Switch to other tab

Expected result:
Video player should not overlap the content from other tabs

Actual result:
HLS Video player overlaps other tabs when played

Notes:
Please note that on Aurora (50.0a2 07-09-2016) this issue cannot be reproduced since the video is played in fullscreen and the user doesn't have access to the fullscreen option in the video control bar

For further details please check : https://www.youtube.com/watch?v=Jc5EtrUyLkg&feature=youtu.be
Assignee: nobody → snorp
tracking-fennec: ? → 51+
Priority: -- → P1
Duplicate of this bug: 1303672
Duplicate of this bug: 1301050
Comment on attachment 8792929 [details] [diff] [review]
Remove HLS player if you switch tabs in Fennec

Review of attachment 8792929 [details] [diff] [review]:
-----------------------------------------------------------------

I'm not hugely familiar with this code, but this seems reasonable.

Just to make sure: this would completely kill video (at least the visual playback part) when switching tabs, is that expected? I'm not sure if Gecko keeps playing the stream (i.e. the audio component) in the background: if it does, do we need to restart the video-player part if we switch back to this tab?
Attachment #8792929 - Flags: review?(ahunt) → review+
(In reply to Andrzej Hunt :ahunt from comment #4)
> Comment on attachment 8792929 [details] [diff] [review]
> Remove HLS player if you switch tabs in Fennec
> 
> Review of attachment 8792929 [details] [diff] [review]:
> -----------------------------------------------------------------
> 
> I'm not hugely familiar with this code, but this seems reasonable.
> 
> Just to make sure: this would completely kill video (at least the visual
> playback part) when switching tabs, is that expected? I'm not sure if Gecko
> keeps playing the stream (i.e. the audio component) in the background: if it
> does, do we need to restart the video-player part if we switch back to this
> tab?

This is only for our modal external HLS player. Normally Gecko would be playing the media, but this is a special out-of-band thing.
Pushed by jwillcox@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/a6975f404e1d
Remove HLS player if you switch tabs in Fennec r=ahunt
https://hg.mozilla.org/mozilla-central/rev/a6975f404e1d
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 52
Hi :snorp,
Since this bug also affects 51, do you think it's worth uplifting to 51 if this patch is not too risky?
Flags: needinfo?(snorp)
Verified as fixed on the latest Nightly build 52.0a1 (2016-09-28) on a Samsung Galaxy S6 EDGE (Android 6.0).
When switching to another tab, the video stops playing and upon returning to the HLS tab, the video is stopped, and the bug 1301055 (A HLS video cannot be played twice without reloading the whole page) is triggered. 

My main concern now is that the behavior when switching to another tab should pause the HLS video or should it cancel it. 
Any thoughts?
Flags: needinfo?(bbermes)
Comment on attachment 8792929 [details] [diff] [review]
Remove HLS player if you switch tabs in Fennec

Approval Request Comment
[Feature/regressing bug #]: Bug 1286133
[User impact if declined]: Bustage if you try to switch tabs while playing a HLS video
[Describe test coverage new/current, TreeHerder]: Nightly
[Risks and why]: Low, only affects the special one-off HLS playback
[String/UUID change made/needed]: None
Flags: needinfo?(snorp)
Attachment #8792929 - Flags: approval-mozilla-beta?
Attachment #8792929 - Flags: approval-mozilla-aurora?
(In reply to Mihai Ninu {:Ninu} from comment #9)
> Verified as fixed on the latest Nightly build 52.0a1 (2016-09-28) on a
> Samsung Galaxy S6 EDGE (Android 6.0).
> When switching to another tab, the video stops playing and upon returning to
> the HLS tab, the video is stopped, and the bug 1301055 (A HLS video cannot
> be played twice without reloading the whole page) is triggered. 
> 
> My main concern now is that the behavior when switching to another tab
> should pause the HLS video or should it cancel it. 
> Any thoughts?

Ideally it would continue playing and reappear when you switched back to that tab.
Status: RESOLVED → VERIFIED
Comment on attachment 8792929 [details] [diff] [review]
Remove HLS player if you switch tabs in Fennec

Fix was verified on Nightly52, Aurora51+, Beta50+
Attachment #8792929 - Flags: approval-mozilla-beta?
Attachment #8792929 - Flags: approval-mozilla-beta+
Attachment #8792929 - Flags: approval-mozilla-aurora?
Attachment #8792929 - Flags: approval-mozilla-aurora+
Snorp, fyi status-50 was unaffected but I think you do want the fix on 50 as well. Please let me know if I was mistaken here.
Flags: needinfo?(snorp)
I do want 50 because I also uplifted the bug that caused this to 50 :)
Flags: needinfo?(snorp)
Verified as fixed on both Aurora (51.0a2 - 2016-10-05) build and Beta 50.0b4, using a Nexus 9 tablet with Android 6.0
Flags: needinfo?(bbermes)
You need to log in before you can comment on or make changes to this bug.