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

Unified Diff: content/renderer/video_capture_message_filter_creator.h

Issue 7058055: create one video capture message filter per renderer process (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: from code review Created 9 years, 6 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_creator.h
===================================================================
--- content/renderer/video_capture_message_filter_creator.h (revision 0)
+++ content/renderer/video_capture_message_filter_creator.h (revision 0)
@@ -0,0 +1,35 @@
+// 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_RENDERER_VIDEO_CAPTURE_MESSAGE_FILTER_CREATOR_H_
+#define CONTENT_RENDERER_VIDEO_CAPTURE_MESSAGE_FILTER_CREATOR_H_
+
+#include "base/memory/ref_counted.h"
+#include "base/memory/singleton.h"
+
+class VideoCaptureMessageFilter;
+
+// VideoCaptureMessageFilterCreator is to be used as a singleton so we can get
+// access to a shared VideoCaptureMessageFilter.
+// Example usage:
+// VideoCaptureMessageFilter* filter =
+// VideoCaptureMessageFilterCreator::SharedFilter();
+
+class VideoCaptureMessageFilterCreator {
+ public:
+ static VideoCaptureMessageFilter* SharedFilter();
+ static VideoCaptureMessageFilterCreator* GetInstance();
+
+ private:
+ VideoCaptureMessageFilterCreator();
+ ~VideoCaptureMessageFilterCreator();
+ friend struct DefaultSingletonTraits<VideoCaptureMessageFilterCreator>;
+
+ scoped_refptr<VideoCaptureMessageFilter> filter_;
+
+ DISALLOW_COPY_AND_ASSIGN(VideoCaptureMessageFilterCreator);
+};
+
+#endif // CONTENT_RENDERER_VIDEO_CAPTURE_MESSAGE_FILTER_CREATOR_H_
+
Property changes on: content/renderer/video_capture_message_filter_creator.h
___________________________________________________________________
Added: svn:eol-style
+ LF
« no previous file with comments | « content/renderer/video_capture_message_filter.cc ('k') | content/renderer/video_capture_message_filter_creator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698