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

Unified Diff: content/browser/renderer_host/media/media_log_host.h

Issue 7480032: Plumb media data from renderers up to MediaInternals in the browser process. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Much cleanup and making MediaLog thread safe. Created 9 years, 5 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
Index: content/browser/renderer_host/media/media_log_host.h
diff --git a/content/browser/renderer_host/media/media_log_host.h b/content/browser/renderer_host/media/media_log_host.h
new file mode 100644
index 0000000000000000000000000000000000000000..99f0d206eb5a1606cc5dd547ee3e0891af5d452d
--- /dev/null
+++ b/content/browser/renderer_host/media/media_log_host.h
@@ -0,0 +1,39 @@
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CONTENT_BROWSER_RENDERER_HOST_MEDIA_MEDIA_LOG_HOST_H_
+#define CONTENT_BROWSER_RENDERER_HOST_MEDIA_MEDIA_LOG_HOST_H_
+#pragma once
+
+#include "base/values.h"
+#include "content/browser/browser_message_filter.h"
+#include "media/base/media_log.h"
+
+namespace content {
+class ResourceContext;
+} // namespace content
+
+class MediaLogHost : public BrowserMessageFilter {
+public:
jam 2011/07/29 16:08:55 nit: spacing
+ MediaLogHost(const content::ResourceContext* resource_context);
+
+ // BrowserMessageFilter implementation.
+ virtual void OnChannelClosing();
+ virtual void OnDestruct() const;
+ virtual bool OnMessageReceived(const IPC::Message& message,
+ bool* message_was_ok);
+private:
+ friend class BrowserThread;
+ friend class DeleteTask<MediaLogHost>;
+ virtual ~MediaLogHost();
+
+ // Handle MediaLogMsg_MediaEvent, passing the event off to the MediaObserver.
jam 2011/07/29 16:08:55 nit: we usually don't comment message handlers. es
+ virtual void OnMediaEvent(const media::MediaLog::Event& event);
+
+ const content::ResourceContext* resource_context_;
+
+ DISALLOW_COPY_AND_ASSIGN(MediaLogHost);
+};
+
+#endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_MEDIA_LOG_HOST_H_

Powered by Google App Engine
This is Rietveld 408576698