OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef MEDIA_BASE_MEDIA_OBSERVER_H_ | |
6 #define MEDIA_BASE_MEDIA_OBSERVER_H_ | |
7 | |
8 #include "base/callback.h" | |
xhwang
2016/10/04 06:30:29
nit: not needed?
xjz
2016/10/04 19:21:29
Done.
| |
9 #include "media/base/cdm_context.h" | |
10 #include "media/base/pipeline_metadata.h" | |
11 | |
12 namespace media { | |
13 | |
14 // This class is an observer of media player events. | |
15 class MEDIA_EXPORT MediaObserver { | |
16 public: | |
17 MediaObserver(); | |
18 virtual ~MediaObserver(); | |
19 | |
20 // Called when the media element or its ancestor is entered/exited fullscreen. | |
21 virtual void OnEnteredFullscreen() = 0; | |
22 virtual void OnExitedFullscreen() = 0; | |
23 | |
24 // Called when CDM is attached to the media element. The |cdm_context| is | |
25 // only guaranteed to be valid in this call. | |
26 virtual void OnSetCdm(CdmContext* cdm_context) = 0; | |
27 | |
28 // Called after demuxer is initialized. | |
29 virtual void OnMetadata(const PipelineMetadata& metadata) = 0; | |
30 }; | |
31 | |
32 } // namespace media | |
33 | |
34 #endif // MEDIA_BASE_MEDIA_OBSERVER_H_ | |
OLD | NEW |