| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CONTENT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ | 5 #ifndef CONTENT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ |
| 6 #define CONTENT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ | 6 #define CONTENT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 class Destroyer { | 49 class Destroyer { |
| 50 public: | 50 public: |
| 51 inline void operator()(void* media_source_delegate) const { | 51 inline void operator()(void* media_source_delegate) const { |
| 52 static_cast<MediaSourceDelegate*>(media_source_delegate)->Destroy(); | 52 static_cast<MediaSourceDelegate*>(media_source_delegate)->Destroy(); |
| 53 } | 53 } |
| 54 }; | 54 }; |
| 55 | 55 |
| 56 MediaSourceDelegate(RendererDemuxerAndroid* demuxer_client, | 56 MediaSourceDelegate(RendererDemuxerAndroid* demuxer_client, |
| 57 int demuxer_client_id, | 57 int demuxer_client_id, |
| 58 const scoped_refptr<base::MessageLoopProxy>& media_loop, | 58 const scoped_refptr<base::MessageLoopProxy>& media_loop, |
| 59 media::MediaLog* media_log); | 59 const scoped_refptr<media::MediaLog> media_log); |
| 60 | 60 |
| 61 // Initialize the MediaSourceDelegate. |media_source| will be owned by | 61 // Initialize the MediaSourceDelegate. |media_source| will be owned by |
| 62 // this object after this call. | 62 // this object after this call. |
| 63 void InitializeMediaSource( | 63 void InitializeMediaSource( |
| 64 const MediaSourceOpenedCB& media_source_opened_cb, | 64 const MediaSourceOpenedCB& media_source_opened_cb, |
| 65 const media::Demuxer::NeedKeyCB& need_key_cb, | 65 const media::Demuxer::NeedKeyCB& need_key_cb, |
| 66 const media::SetDecryptorReadyCB& set_decryptor_ready_cb, | 66 const media::SetDecryptorReadyCB& set_decryptor_ready_cb, |
| 67 const UpdateNetworkStateCB& update_network_state_cb, | 67 const UpdateNetworkStateCB& update_network_state_cb, |
| 68 const DurationChangeCB& duration_change_cb); | 68 const DurationChangeCB& duration_change_cb); |
| 69 | 69 |
| (...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 239 base::WeakPtrFactory<MediaSourceDelegate> main_weak_factory_; | 239 base::WeakPtrFactory<MediaSourceDelegate> main_weak_factory_; |
| 240 base::WeakPtrFactory<MediaSourceDelegate> media_weak_factory_; | 240 base::WeakPtrFactory<MediaSourceDelegate> media_weak_factory_; |
| 241 base::WeakPtr<MediaSourceDelegate> main_weak_this_; | 241 base::WeakPtr<MediaSourceDelegate> main_weak_this_; |
| 242 | 242 |
| 243 DISALLOW_COPY_AND_ASSIGN(MediaSourceDelegate); | 243 DISALLOW_COPY_AND_ASSIGN(MediaSourceDelegate); |
| 244 }; | 244 }; |
| 245 | 245 |
| 246 } // namespace content | 246 } // namespace content |
| 247 | 247 |
| 248 #endif // CONTENT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ | 248 #endif // CONTENT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ |
| OLD | NEW |