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

Unified Diff: chrome/browser/media/media_stream_devices_util.h

Issue 483523006: Check all settings when checking mic and camera access (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Code review fixes. Created 6 years, 4 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: chrome/browser/media/media_stream_devices_util.h
diff --git a/chrome/browser/media/media_stream_devices_util.h b/chrome/browser/media/media_stream_devices_util.h
new file mode 100644
index 0000000000000000000000000000000000000000..9196c3d7c39cc9efec39aa8246c5104f3e1eb136
--- /dev/null
+++ b/chrome/browser/media/media_stream_devices_util.h
@@ -0,0 +1,28 @@
+// Copyright 2014 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 CHROME_BROWSER_MEDIA_MEDIA_STREAM_DEVICES_UTIL_H_
+#define CHROME_BROWSER_MEDIA_MEDIA_STREAM_DEVICES_UTIL_H_
perkj_chrome 2014/08/29 09:38:10 CHROME_BROWSER_MEDIA_MEDIA_STREAM_DEVICE_PERMISSIO
Henrik Grunell 2014/08/29 11:20:08 Yeah, sgtm. I changed it to your suggestion, I thi
+
+class GURL;
+class Profile;
+
+enum MediaStreamDevicePolicy {
+ POLICY_NOT_SET,
+ ALWAYS_DENY,
+ ALWAYS_ALLOW,
+};
+
+// Returns true if security origin is from internal objects like
+// chrome://URLs, otherwise returns false.
+bool CheckAllowAllMediaStreamContentForOrigin(Profile* profile,
+ const GURL& security_origin);
+
+// Get the device policy for |security_origin| and |profile|.
+MediaStreamDevicePolicy GetDevicePolicy(Profile* profile,
+ const GURL& security_origin,
+ const char* policy_name,
+ const char* whitelist_policy_name);
+
+#endif // CHROME_BROWSER_MEDIA_MEDIA_STREAM_DEVICES_UTIL_H_

Powered by Google App Engine
This is Rietveld 408576698