File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ shakaDemo.CloseButton = class extends shaka.ui.Element {
3636 window . documentPictureInPicture , 'enter' , ( ) => {
3737 this . button_ . style . display = 'none' ;
3838 const pipWindow = window . documentPictureInPicture . window ;
39- this . eventManager . listen ( pipWindow , 'unload ' , ( ) => {
39+ this . eventManager . listen ( pipWindow , 'pagehide ' , ( ) => {
4040 this . button_ . style . display = 'block' ;
4141 } ) ;
4242 } ) ;
Original file line number Diff line number Diff line change @@ -187,7 +187,7 @@ shaka.ui.PipButton = class extends shaka.ui.Element {
187187 this . onEnterPictureInPicture_ ( ) ;
188188
189189 // Listen for the PiP closing event to move the player back.
190- this . eventManager . listenOnce ( pipWindow , 'unload ' , ( ) => {
190+ this . eventManager . listenOnce ( pipWindow , 'pagehide ' , ( ) => {
191191 placeholder . replaceWith ( /** @type {!Node } */ ( pipPlayer ) ) ;
192192 } ) ;
193193 }
You can’t perform that action at this time.
0 commit comments