| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 // This file was generated by: |
| 6 // ./tools/json_schema_compiler/compiler.py. |
| 7 // NOTE: The format of types has changed. 'FooType' is now |
| 8 // 'chrome.settingsPrivate.FooType'. |
| 9 // Please run the closure compiler before committing changes. |
| 10 // See https://code.google.com/p/chromium/wiki/ClosureCompilation. |
| 11 |
| 1 /** @fileoverview Externs generated from namespace: settingsPrivate */ | 12 /** @fileoverview Externs generated from namespace: settingsPrivate */ |
| 2 | 13 |
| 3 /** | 14 /** |
| 4 * @const | 15 * @const |
| 5 */ | 16 */ |
| 6 chrome.settingsPrivate = {}; | 17 chrome.settingsPrivate = {}; |
| 7 | 18 |
| 8 /** | 19 /** |
| 9 * @enum {string} | 20 * @enum {string} |
| 10 * @see https://developer.chrome.com/extensions/settingsPrivate#type-PrefType | 21 * @see https://developer.chrome.com/extensions/settingsPrivate#type-PrefType |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 /** | 49 /** |
| 39 * @typedef {{ | 50 * @typedef {{ |
| 40 * key: string, | 51 * key: string, |
| 41 * type: !chrome.settingsPrivate.PrefType, | 52 * type: !chrome.settingsPrivate.PrefType, |
| 42 * value: *, | 53 * value: *, |
| 43 * policySource: (!chrome.settingsPrivate.PolicySource|undefined), | 54 * policySource: (!chrome.settingsPrivate.PolicySource|undefined), |
| 44 * policyEnforcement: (!chrome.settingsPrivate.PolicyEnforcement|undefined) | 55 * policyEnforcement: (!chrome.settingsPrivate.PolicyEnforcement|undefined) |
| 45 * }} | 56 * }} |
| 46 * @see https://developer.chrome.com/extensions/settingsPrivate#type-PrefObject | 57 * @see https://developer.chrome.com/extensions/settingsPrivate#type-PrefObject |
| 47 */ | 58 */ |
| 48 var PrefObject; | 59 chrome.settingsPrivate.PrefObject; |
| 49 | 60 |
| 50 /** | 61 /** |
| 51 * Sets a settings value. | 62 * Sets a settings value. |
| 52 * @param {string} name The name of the pref. | 63 * @param {string} name The name of the pref. |
| 53 * @param {*} value The new value of the pref. | 64 * @param {*} value The new value of the pref. |
| 54 * @param {string} pageId The user metrics identifier or null. | 65 * @param {string} pageId The user metrics identifier or null. |
| 55 * @param {function(boolean):void} callback The callback for whether the pref | 66 * @param {function(boolean):void} callback The callback for whether the pref |
| 56 * was set or not. | 67 * was set or not. |
| 57 * @see https://developer.chrome.com/extensions/settingsPrivate#method-setPref | 68 * @see https://developer.chrome.com/extensions/settingsPrivate#method-setPref |
| 58 */ | 69 */ |
| 59 chrome.settingsPrivate.setPref = function(name, value, pageId, callback) {}; | 70 chrome.settingsPrivate.setPref = function(name, value, pageId, callback) {}; |
| 60 | 71 |
| 61 /** | 72 /** |
| 62 * Gets an array of all the prefs. | 73 * Gets an array of all the prefs. |
| 63 * @param {function(!Array<PrefObject>):void} callback | 74 * @param {function(!Array<!chrome.settingsPrivate.PrefObject>):void} callback |
| 64 * @see https://developer.chrome.com/extensions/settingsPrivate#method-getAllPre
fs | 75 * @see https://developer.chrome.com/extensions/settingsPrivate#method-getAllPre
fs |
| 65 */ | 76 */ |
| 66 chrome.settingsPrivate.getAllPrefs = function(callback) {}; | 77 chrome.settingsPrivate.getAllPrefs = function(callback) {}; |
| 67 | 78 |
| 68 /** | 79 /** |
| 69 * Gets the value of a specific pref. | 80 * Gets the value of a specific pref. |
| 70 * @param {string} name | 81 * @param {string} name |
| 71 * @param {function(PrefObject):void} callback | 82 * @param {function(!chrome.settingsPrivate.PrefObject):void} callback |
| 72 * @see https://developer.chrome.com/extensions/settingsPrivate#method-getPref | 83 * @see https://developer.chrome.com/extensions/settingsPrivate#method-getPref |
| 73 */ | 84 */ |
| 74 chrome.settingsPrivate.getPref = function(name, callback) {}; | 85 chrome.settingsPrivate.getPref = function(name, callback) {}; |
| 75 | 86 |
| 76 /** | 87 /** |
| 77 * <p>Fired when a set of prefs has changed.</p><p>|prefs| The prefs that | 88 * <p>Fired when a set of prefs has changed.</p><p>|prefs| The prefs that |
| 78 * changed.</p> | 89 * changed.</p> |
| 79 * @type {!ChromeEvent} | 90 * @type {!ChromeEvent} |
| 80 * @see https://developer.chrome.com/extensions/settingsPrivate#event-onPrefsCha
nged | 91 * @see https://developer.chrome.com/extensions/settingsPrivate#event-onPrefsCha
nged |
| 81 */ | 92 */ |
| 82 chrome.settingsPrivate.onPrefsChanged; | 93 chrome.settingsPrivate.onPrefsChanged; |
| OLD | NEW |