Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(653)

Unified Diff: media/blink/buffered_data_source.h

Issue 495353003: Move WebMediaPlayerImpl and its dependencies to media/blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/blink/active_loader.cc ('k') | media/blink/buffered_data_source.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/blink/buffered_data_source.h
diff --git a/content/renderer/media/buffered_data_source.h b/media/blink/buffered_data_source.h
similarity index 92%
rename from content/renderer/media/buffered_data_source.h
rename to media/blink/buffered_data_source.h
index c2fd174c62139492990fdd1b56d18130557bded0..5ae7d935c622931f27fff2682aadb30f8e182565 100644
--- a/content/renderer/media/buffered_data_source.h
+++ b/media/blink/buffered_data_source.h
@@ -2,18 +2,18 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef CONTENT_RENDERER_MEDIA_BUFFERED_DATA_SOURCE_H_
-#define CONTENT_RENDERER_MEDIA_BUFFERED_DATA_SOURCE_H_
+#ifndef MEDIA_BLINK_BUFFERED_DATA_SOURCE_H_
+#define MEDIA_BLINK_BUFFERED_DATA_SOURCE_H_
#include <string>
#include "base/callback.h"
#include "base/memory/scoped_ptr.h"
#include "base/synchronization/lock.h"
-#include "content/common/content_export.h"
-#include "content/renderer/media/buffered_resource_loader.h"
#include "media/base/data_source.h"
+#include "media/base/media_export.h"
#include "media/base/ranges.h"
+#include "media/blink/buffered_resource_loader.h"
#include "url/gurl.h"
namespace base {
@@ -22,11 +22,8 @@ class SingleThreadTaskRunner;
namespace media {
class MediaLog;
-}
-
-namespace content {
-class CONTENT_EXPORT BufferedDataSourceHost {
+class MEDIA_EXPORT BufferedDataSourceHost {
public:
// Notify the host of the total size of the media file.
virtual void SetTotalBytes(int64 total_bytes) = 0;
@@ -45,7 +42,7 @@ class CONTENT_EXPORT BufferedDataSourceHost {
//
// BufferedDataSource must be created and initialized on the render thread
// before being passed to other threads. It may be deleted on any thread.
-class CONTENT_EXPORT BufferedDataSource : public media::DataSource {
+class MEDIA_EXPORT BufferedDataSource : public DataSource {
public:
// Used to specify video preload states. They are "hints" to the browser about
// how aggressively the browser should load and buffer data.
@@ -69,7 +66,7 @@ class CONTENT_EXPORT BufferedDataSource : public media::DataSource {
BufferedResourceLoader::CORSMode cors_mode,
const scoped_refptr<base::SingleThreadTaskRunner>& task_runner,
blink::WebFrame* frame,
- media::MediaLog* media_log,
+ MediaLog* media_log,
BufferedDataSourceHost* host,
const DownloadingCB& downloading_cb);
virtual ~BufferedDataSource();
@@ -108,12 +105,12 @@ class CONTENT_EXPORT BufferedDataSource : public media::DataSource {
// Returns true if the resource is local.
bool assume_fully_buffered() { return !url_.SchemeIsHTTPOrHTTPS(); }
- // media::DataSource implementation.
+ // DataSource implementation.
// Called from demuxer thread.
virtual void Stop() OVERRIDE;
virtual void Read(int64 position, int size, uint8* data,
- const media::DataSource::ReadCB& read_cb) OVERRIDE;
+ const DataSource::ReadCB& read_cb) OVERRIDE;
virtual bool GetSize(int64* size_out) OVERRIDE;
virtual bool IsStreaming() OVERRIDE;
virtual void SetBitrate(int bitrate) OVERRIDE;
@@ -225,7 +222,7 @@ class CONTENT_EXPORT BufferedDataSource : public media::DataSource {
// Current playback rate.
float playback_rate_;
- scoped_refptr<media::MediaLog> media_log_;
+ scoped_refptr<MediaLog> media_log_;
// Host object to report buffered byte range changes to.
BufferedDataSourceHost* host_;
@@ -238,6 +235,6 @@ class CONTENT_EXPORT BufferedDataSource : public media::DataSource {
DISALLOW_COPY_AND_ASSIGN(BufferedDataSource);
};
-} // namespace content
+} // namespace media
-#endif // CONTENT_RENDERER_MEDIA_BUFFERED_DATA_SOURCE_H_
+#endif // MEDIA_BLINK_BUFFERED_DATA_SOURCE_H_
« no previous file with comments | « media/blink/active_loader.cc ('k') | media/blink/buffered_data_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698