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

Unified Diff: content/renderer/video_capture_message_filter.h

Issue 6962006: Undo mistaken revert. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 7 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/renderer/video_capture_message_filter.h
diff --git a/content/renderer/video_capture_message_filter.h b/content/renderer/video_capture_message_filter.h
index 2a885e9bb0383968be522794fa1718e065695492..c476616495a3b75770dc4073f594462fbc7e1536 100644
--- a/content/renderer/video_capture_message_filter.h
+++ b/content/renderer/video_capture_message_filter.h
@@ -34,6 +34,10 @@ class VideoCaptureMessageFilter : public IPC::ChannelProxy::MessageFilter {
virtual void OnDeviceInfoReceived(
const media::VideoCaptureParams& device_info) = 0;
+ // Called when the delegate has been added to filter's delegate list.
+ // |device_id| is the device id for the delegate.
+ virtual void OnDelegateAdded(int32 device_id) = 0;
+
protected:
virtual ~Delegate() {}
};
@@ -41,14 +45,14 @@ class VideoCaptureMessageFilter : public IPC::ChannelProxy::MessageFilter {
explicit VideoCaptureMessageFilter(int32 route_id);
virtual ~VideoCaptureMessageFilter();
- // Add a delegate to the map and return id of the entry.
- int32 AddDelegate(Delegate* delegate);
+ // Add a delegate to the map.
+ void AddDelegate(Delegate* delegate);
// Remove a delegate from the map.
void RemoveDelegate(Delegate* delegate);
// Send a message asynchronously.
- bool Send(IPC::Message* message);
+ virtual bool Send(IPC::Message* message);
void AddFilter();
@@ -79,6 +83,7 @@ class VideoCaptureMessageFilter : public IPC::ChannelProxy::MessageFilter {
// A map of device ids to delegates.
Delegates delegates_;
+ Delegates pending_delegates_;
int32 last_device_id_;
int32 route_id_;
« no previous file with comments | « content/renderer/media/video_capture_impl_unittest.cc ('k') | content/renderer/video_capture_message_filter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698