| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef CHROME_BROWSER_MEDIA_MEDIA_STREAM_DEVICES_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_MEDIA_MEDIA_STREAM_DEVICES_CONTROLLER_H_ |
| 6 #define CHROME_BROWSER_MEDIA_MEDIA_STREAM_DEVICES_CONTROLLER_H_ | 6 #define CHROME_BROWSER_MEDIA_MEDIA_STREAM_DEVICES_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 public: | 27 public: |
| 28 MediaStreamDevicesController(content::WebContents* web_contents, | 28 MediaStreamDevicesController(content::WebContents* web_contents, |
| 29 const content::MediaStreamRequest& request, | 29 const content::MediaStreamRequest& request, |
| 30 const content::MediaResponseCallback& callback); | 30 const content::MediaResponseCallback& callback); |
| 31 | 31 |
| 32 ~MediaStreamDevicesController() override; | 32 ~MediaStreamDevicesController() override; |
| 33 | 33 |
| 34 // Registers the prefs backing the audio and video policies. | 34 // Registers the prefs backing the audio and video policies. |
| 35 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry); | 35 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry); |
| 36 | 36 |
| 37 // Public methods to be called by MediaStreamInfoBarDelegate; | 37 bool IsAllowedForAudio() const; |
| 38 bool IsAllowedForVideo() const; |
| 38 bool IsAskingForAudio() const; | 39 bool IsAskingForAudio() const; |
| 39 bool IsAskingForVideo() const; | 40 bool IsAskingForVideo() const; |
| 40 const std::string& GetSecurityOriginSpec() const; | 41 const std::string& GetSecurityOriginSpec() const; |
| 41 | 42 |
| 42 // PermissionBubbleRequest: | 43 // PermissionBubbleRequest: |
| 43 int GetIconId() const override; | 44 int GetIconId() const override; |
| 44 base::string16 GetMessageText() const override; | 45 base::string16 GetMessageText() const override; |
| 45 base::string16 GetMessageTextFragment() const override; | 46 base::string16 GetMessageTextFragment() const override; |
| 46 bool HasUserGesture() const override; | 47 bool HasUserGesture() const override; |
| 47 GURL GetRequestingHostname() const override; | 48 GURL GetRequestingHostname() const override; |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 112 | 113 |
| 113 // The callback that needs to be Run to notify WebRTC of whether access to | 114 // The callback that needs to be Run to notify WebRTC of whether access to |
| 114 // audio/video devices was granted or not. | 115 // audio/video devices was granted or not. |
| 115 content::MediaResponseCallback callback_; | 116 content::MediaResponseCallback callback_; |
| 116 | 117 |
| 117 | 118 |
| 118 DISALLOW_COPY_AND_ASSIGN(MediaStreamDevicesController); | 119 DISALLOW_COPY_AND_ASSIGN(MediaStreamDevicesController); |
| 119 }; | 120 }; |
| 120 | 121 |
| 121 #endif // CHROME_BROWSER_MEDIA_MEDIA_STREAM_DEVICES_CONTROLLER_H_ | 122 #endif // CHROME_BROWSER_MEDIA_MEDIA_STREAM_DEVICES_CONTROLLER_H_ |
| OLD | NEW |