| Index: media/blink/webmediaplayer_impl.h
|
| diff --git a/media/blink/webmediaplayer_impl.h b/media/blink/webmediaplayer_impl.h
|
| index 16f3bbdbec91f6973d68da6e9dcb52e15f4c662f..c3965bf134c05870bbcc9ad5201de95dba8c1fa0 100644
|
| --- a/media/blink/webmediaplayer_impl.h
|
| +++ b/media/blink/webmediaplayer_impl.h
|
| @@ -21,6 +21,7 @@
|
| #include "base/timer/elapsed_timer.h"
|
| #include "base/timer/timer.h"
|
| #include "build/build_config.h"
|
| +#include "media/base/media_observer.h"
|
| #include "media/base/media_tracks.h"
|
| #include "media/base/pipeline_impl.h"
|
| #include "media/base/renderer_factory.h"
|
| @@ -181,6 +182,10 @@ class MEDIA_BLINK_EXPORT WebMediaPlayerImpl
|
| void enteredFullscreen() override;
|
| void exitedFullscreen() override;
|
|
|
| + // These are called when any ancestor enters/exits full screen.
|
| + void ancestorEnteredFullscreen() override;
|
| + void ancestorExitedFullscreen() override;
|
| +
|
| // WebMediaPlayerDelegate::Observer implementation.
|
| void OnHidden() override;
|
| void OnShown() override;
|
| @@ -210,6 +215,11 @@ class MEDIA_BLINK_EXPORT WebMediaPlayerImpl
|
| // TODO(hubbe): WMPI_CAST make private.
|
| void OnPipelineSeeked(bool time_updated);
|
|
|
| + // Restart the player/pipeline as soon as possible. This will destroy the
|
| + // current renderer, if any, and create a new one via the RendererFactory; and
|
| + // then seek to resume playback at the current position.
|
| + void ScheduleRestart();
|
| +
|
| // Distinct states that |delegate_| can be in.
|
| // TODO(sandersd): This should move into WebMediaPlayerDelegate.
|
| // (Public for testing.)
|
| @@ -253,9 +263,6 @@ class MEDIA_BLINK_EXPORT WebMediaPlayerImpl
|
| // |time_updated| is false.
|
| void DoSeek(base::TimeDelta time, bool time_updated);
|
|
|
| - // Ask for the renderer to be restarted (destructed and recreated).
|
| - void ScheduleRestart();
|
| -
|
| // Called after |defer_load_cb_| has decided to allow the load. If
|
| // |defer_load_cb_| is null this is called immediately.
|
| void DoLoad(LoadType load_type,
|
| @@ -548,6 +555,9 @@ class MEDIA_BLINK_EXPORT WebMediaPlayerImpl
|
| int underflow_count_;
|
| std::unique_ptr<base::ElapsedTimer> underflow_timer_;
|
|
|
| + // Monitors the player events.
|
| + base::WeakPtr<MediaObserver> observer_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl);
|
| };
|
|
|
|
|