Chromium Code Reviews| Index: chrome/browser/resources/settings/site_settings/site_settings_prefs_browser_proxy.js |
| diff --git a/chrome/browser/resources/settings/site_settings/site_settings_prefs_browser_proxy.js b/chrome/browser/resources/settings/site_settings/site_settings_prefs_browser_proxy.js |
| index e70d087a3a670e2979d3c085a709350e0349762b..3948530c1d1341cd9c42232ce5b8de1640575931 100644 |
| --- a/chrome/browser/resources/settings/site_settings/site_settings_prefs_browser_proxy.js |
| +++ b/chrome/browser/resources/settings/site_settings/site_settings_prefs_browser_proxy.js |
| @@ -34,6 +34,12 @@ var ExceptionListPref; |
| */ |
| var SiteSettingsPref; |
| +/** |
| + * @typedef {{name: string, |
| + * id: string}} |
| + */ |
| +var MediaPickerEntry; |
| + |
| cr.define('settings', function() { |
| /** @interface */ |
| function SiteSettingsPrefsBrowserProxy() {} |
| @@ -89,6 +95,20 @@ cr.define('settings', function() { |
| * @return {!Promise<boolean>} True if the pattern is valid. |
| */ |
| isPatternValid: function(pattern) {}, |
| + |
| + /** |
| + * Gets the list of default capture devices for a given type of media. List |
| + * is returned through a JS call to updateDevicesMenu. |
| + * @param {string} type The type to look up. |
| + */ |
| + getDefaultCaptureDevices: function(type) {}, |
| + |
| + /** |
| + * Gets a default devices for a given type of media. |
|
michaelpg
2016/06/08 16:02:32
"gets a default devices" => "sets the default devi
Finnur
2016/06/08 21:15:45
Done.
|
| + * @param {string} type The type of media to configure. |
| + * @param {string} defaultValue The id of the media device to set. |
| + */ |
| + setDefaultCaptureDevice: function(type, defaultValue) {}, |
| }; |
| /** |
| @@ -136,6 +156,15 @@ cr.define('settings', function() { |
| return cr.sendWithPromise('isPatternValid', pattern); |
| }, |
| + /** @override */ |
| + getDefaultCaptureDevices: function(type) { |
| + chrome.send('getDefaultCaptureDevices', [type]); |
| + }, |
| + |
| + /** @override */ |
| + setDefaultCaptureDevice: function(type, defaultValue) { |
| + chrome.send('setDefaultCaptureDevice', [type, defaultValue]); |
| + }, |
| }; |
| return { |