| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 WEBKIT_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ | 5 #ifndef WEBKIT_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ |
| 6 #define WEBKIT_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ | 6 #define WEBKIT_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ |
| 7 | 7 |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 68 size_t key_length, | 68 size_t key_length, |
| 69 const unsigned char* init_data, | 69 const unsigned char* init_data, |
| 70 size_t init_data_length, | 70 size_t init_data_length, |
| 71 const WebKit::WebString& session_id); | 71 const WebKit::WebString& session_id); |
| 72 WebKit::WebMediaPlayer::MediaKeyException CancelKeyRequest( | 72 WebKit::WebMediaPlayer::MediaKeyException CancelKeyRequest( |
| 73 const WebKit::WebString& key_system, | 73 const WebKit::WebString& key_system, |
| 74 const WebKit::WebString& session_id); | 74 const WebKit::WebString& session_id); |
| 75 | 75 |
| 76 void Seek(base::TimeDelta time); | 76 void Seek(base::TimeDelta time); |
| 77 | 77 |
| 78 void CancelPendingSeek(); |
| 79 |
| 78 // Called when DemuxerStreamPlayer needs to read data from ChunkDemuxer. | 80 // Called when DemuxerStreamPlayer needs to read data from ChunkDemuxer. |
| 79 // If it's the first request after the seek, |seek_done| will be true. | 81 // If it's the first request after the seek, |seek_done| will be true. |
| 80 void OnReadFromDemuxer(media::DemuxerStream::Type type, bool seek_done); | 82 void OnReadFromDemuxer(media::DemuxerStream::Type type, bool seek_done); |
| 81 | 83 |
| 82 private: | 84 private: |
| 83 // Methods inherited from DemuxerHost. | 85 // Methods inherited from DemuxerHost. |
| 84 virtual void SetTotalBytes(int64 total_bytes) OVERRIDE; | 86 virtual void SetTotalBytes(int64 total_bytes) OVERRIDE; |
| 85 virtual void AddBufferedByteRange(int64 start, int64 end) OVERRIDE; | 87 virtual void AddBufferedByteRange(int64 start, int64 end) OVERRIDE; |
| 86 virtual void AddBufferedTimeRange(base::TimeDelta start, | 88 virtual void AddBufferedTimeRange(base::TimeDelta start, |
| 87 base::TimeDelta end) OVERRIDE; | 89 base::TimeDelta end) OVERRIDE; |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 157 scoped_ptr<media::MediaPlayerHostMsg_ReadFromDemuxerAck_Params> video_params_; | 159 scoped_ptr<media::MediaPlayerHostMsg_ReadFromDemuxerAck_Params> video_params_; |
| 158 | 160 |
| 159 bool seeking_; | 161 bool seeking_; |
| 160 | 162 |
| 161 DISALLOW_COPY_AND_ASSIGN(MediaSourceDelegate); | 163 DISALLOW_COPY_AND_ASSIGN(MediaSourceDelegate); |
| 162 }; | 164 }; |
| 163 | 165 |
| 164 } // namespace webkit_media | 166 } // namespace webkit_media |
| 165 #endif // WEBKIT_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ | 167 #endif // WEBKIT_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ |
| 166 | 168 |
| OLD | NEW |