OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/media/media_stream_device_permissions.h" | 5 #include "chrome/browser/media/webrtc/media_stream_device_permissions.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include "base/values.h" | 9 #include "base/values.h" |
10 #include "chrome/browser/profiles/profile.h" | 10 #include "chrome/browser/profiles/profile.h" |
11 #include "components/content_settings/core/browser/host_content_settings_map.h" | 11 #include "components/content_settings/core/browser/host_content_settings_map.h" |
12 #include "components/content_settings/core/common/content_settings_pattern.h" | 12 #include "components/content_settings/core/common/content_settings_pattern.h" |
13 #include "components/prefs/pref_service.h" | 13 #include "components/prefs/pref_service.h" |
14 #include "content/public/browser/browser_thread.h" | 14 #include "content/public/browser/browser_thread.h" |
15 #include "content/public/common/origin_util.h" | 15 #include "content/public/common/origin_util.h" |
(...skipping 29 matching lines...) Expand all Loading... |
45 | 45 |
46 // If a match was not found, check if audio capture is otherwise disallowed | 46 // If a match was not found, check if audio capture is otherwise disallowed |
47 // or if the user should be prompted. Setting the policy value to "true" | 47 // or if the user should be prompted. Setting the policy value to "true" |
48 // is equal to not setting it at all, so from hereon out, we will return | 48 // is equal to not setting it at all, so from hereon out, we will return |
49 // either POLICY_NOT_SET (prompt) or ALWAYS_DENY (no prompt, no access). | 49 // either POLICY_NOT_SET (prompt) or ALWAYS_DENY (no prompt, no access). |
50 if (!prefs->GetBoolean(policy_name)) | 50 if (!prefs->GetBoolean(policy_name)) |
51 return ALWAYS_DENY; | 51 return ALWAYS_DENY; |
52 | 52 |
53 return POLICY_NOT_SET; | 53 return POLICY_NOT_SET; |
54 } | 54 } |
OLD | NEW |