| 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_BROWSER_MEDIA_ANDROID_BROWSER_DEMUXER_ANDROID_H_ | 5 #ifndef CONTENT_BROWSER_MEDIA_ANDROID_BROWSER_DEMUXER_ANDROID_H_ |
| 6 #define CONTENT_BROWSER_MEDIA_ANDROID_BROWSER_DEMUXER_ANDROID_H_ | 6 #define CONTENT_BROWSER_MEDIA_ANDROID_BROWSER_DEMUXER_ANDROID_H_ |
| 7 | 7 |
| 8 #define DISABLE_NON_THREAD_SAFE |
| 8 #include "base/id_map.h" | 9 #include "base/id_map.h" |
| 10 #undef DISABLE_NON_THREAD_SAFE |
| 11 |
| 12 #include "base/synchronization/lock.h" |
| 9 #include "content/public/browser/browser_message_filter.h" | 13 #include "content/public/browser/browser_message_filter.h" |
| 10 #include "media/base/android/demuxer_android.h" | 14 #include "media/base/android/demuxer_android.h" |
| 11 | 15 |
| 12 namespace content { | 16 namespace content { |
| 13 | 17 |
| 14 // Represents the browser process half of an IPC-based demuxer proxy. | 18 // Represents the browser process half of an IPC-based demuxer proxy. |
| 15 // It vends out media::DemuxerAndroid instances that are registered with an | 19 // It vends out media::DemuxerAndroid instances that are registered with an |
| 16 // end point in the renderer process. | 20 // end point in the renderer process. |
| 17 // | 21 // |
| 18 // Refer to RendererDemuxerAndroid for the renderer process half. | 22 // Refer to RendererDemuxerAndroid for the renderer process half. |
| (...skipping 27 matching lines...) Expand all Loading... |
| 46 // IPC message handlers. | 50 // IPC message handlers. |
| 47 void OnDemuxerReady(int demuxer_client_id, | 51 void OnDemuxerReady(int demuxer_client_id, |
| 48 const media::DemuxerConfigs& configs); | 52 const media::DemuxerConfigs& configs); |
| 49 void OnReadFromDemuxerAck(int demuxer_client_id, | 53 void OnReadFromDemuxerAck(int demuxer_client_id, |
| 50 const media::DemuxerData& data); | 54 const media::DemuxerData& data); |
| 51 void OnDemuxerSeekDone(int demuxer_client_id, | 55 void OnDemuxerSeekDone(int demuxer_client_id, |
| 52 const base::TimeDelta& actual_browser_seek_time); | 56 const base::TimeDelta& actual_browser_seek_time); |
| 53 void OnDurationChanged(int demuxer_client_id, | 57 void OnDurationChanged(int demuxer_client_id, |
| 54 const base::TimeDelta& duration); | 58 const base::TimeDelta& duration); |
| 55 | 59 |
| 60 media::DemuxerAndroidClient* Lookup(int demuxer_client_id); |
| 61 |
| 62 |
| 56 IDMap<media::DemuxerAndroidClient> demuxer_clients_; | 63 IDMap<media::DemuxerAndroidClient> demuxer_clients_; |
| 64 base::Lock lock_; |
| 65 bool enable_media_thread_for_media_playback_; |
| 57 | 66 |
| 58 DISALLOW_COPY_AND_ASSIGN(BrowserDemuxerAndroid); | 67 DISALLOW_COPY_AND_ASSIGN(BrowserDemuxerAndroid); |
| 59 }; | 68 }; |
| 60 | 69 |
| 61 } // namespace content | 70 } // namespace content |
| 62 | 71 |
| 63 #endif // CONTENT_BROWSER_MEDIA_ANDROID_BROWSER_DEMUXER_ANDROID_H_ | 72 #endif // CONTENT_BROWSER_MEDIA_ANDROID_BROWSER_DEMUXER_ANDROID_H_ |
| OLD | NEW |