| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 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 | 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 // Use the <code>chrome.settingsPrivate</code> API to get or set preferences | 5 // Use the <code>chrome.settingsPrivate</code> API to get or set preferences |
| 6 // from the settings UI. | 6 // from the settings UI. |
| 7 namespace settingsPrivate { | 7 namespace settingsPrivate { |
| 8 // Type of a pref. | 8 // Type of a pref. |
| 9 enum PrefType { BOOLEAN, NUMBER, STRING, URL, LIST }; | 9 enum PrefType { BOOLEAN, NUMBER, STRING, URL, LIST, DICTIONARY }; |
| 10 | 10 |
| 11 // Source of a restricted pref, either by policy or other source. | 11 // Source of a restricted pref, either by policy or other source. |
| 12 enum PolicySource { | 12 enum PolicySource { |
| 13 DEVICE_POLICY, | 13 DEVICE_POLICY, |
| 14 USER_POLICY, | 14 USER_POLICY, |
| 15 OWNER, | 15 OWNER, |
| 16 PRIMARY_USER, | 16 PRIMARY_USER, |
| 17 EXTENSION | 17 EXTENSION |
| 18 }; | 18 }; |
| 19 | 19 |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 74 static void getPref(DOMString name, GetPrefCallback callback); | 74 static void getPref(DOMString name, GetPrefCallback callback); |
| 75 }; | 75 }; |
| 76 | 76 |
| 77 interface Events { | 77 interface Events { |
| 78 // Fired when a set of prefs has changed. | 78 // Fired when a set of prefs has changed. |
| 79 // | 79 // |
| 80 // |prefs| The prefs that changed. | 80 // |prefs| The prefs that changed. |
| 81 static void onPrefsChanged(PrefObject[] prefs); | 81 static void onPrefsChanged(PrefObject[] prefs); |
| 82 }; | 82 }; |
| 83 }; | 83 }; |
| OLD | NEW |