| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 // This file was generated by: | 5 // This file was generated by: |
| 6 // ./tools/json_schema_compiler/compiler.py. | 6 // ./tools/json_schema_compiler/compiler.py. |
| 7 // NOTE: The format of types has changed. 'FooType' is now | 7 // NOTE: The format of types has changed. 'FooType' is now |
| 8 // 'chrome.system.display.FooType'. | 8 // 'chrome.system.display.FooType'. |
| 9 // Please run the closure compiler before committing changes. | 9 // Please run the closure compiler before committing changes. |
| 10 // See https://chromium.googlesource.com/chromium/src/+/master/docs/closure_comp
ilation.md | 10 // See https://chromium.googlesource.com/chromium/src/+/master/docs/closure_comp
ilation.md |
| (...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 110 chrome.system.display.DisplayLayout; | 110 chrome.system.display.DisplayLayout; |
| 111 | 111 |
| 112 /** | 112 /** |
| 113 * @typedef {{ | 113 * @typedef {{ |
| 114 * id: string, | 114 * id: string, |
| 115 * name: string, | 115 * name: string, |
| 116 * mirroringSourceId: string, | 116 * mirroringSourceId: string, |
| 117 * isPrimary: boolean, | 117 * isPrimary: boolean, |
| 118 * isInternal: boolean, | 118 * isInternal: boolean, |
| 119 * isEnabled: boolean, | 119 * isEnabled: boolean, |
| 120 * isUnified: boolean, |
| 120 * dpiX: number, | 121 * dpiX: number, |
| 121 * dpiY: number, | 122 * dpiY: number, |
| 122 * rotation: number, | 123 * rotation: number, |
| 123 * bounds: !chrome.system.display.Bounds, | 124 * bounds: !chrome.system.display.Bounds, |
| 124 * overscan: !chrome.system.display.Insets, | 125 * overscan: !chrome.system.display.Insets, |
| 125 * workArea: !chrome.system.display.Bounds, | 126 * workArea: !chrome.system.display.Bounds, |
| 126 * modes: !Array<!chrome.system.display.DisplayMode>, | 127 * modes: !Array<!chrome.system.display.DisplayMode>, |
| 127 * hasTouchSupport: boolean | 128 * hasTouchSupport: boolean |
| 128 * }} | 129 * }} |
| 129 * @see https://developer.chrome.com/extensions/system.display#type-DisplayUnitI
nfo | 130 * @see https://developer.chrome.com/extensions/system.display#type-DisplayUnitI
nfo |
| 130 */ | 131 */ |
| 131 chrome.system.display.DisplayUnitInfo; | 132 chrome.system.display.DisplayUnitInfo; |
| 132 | 133 |
| 133 /** | 134 /** |
| 134 * @typedef {{ | 135 * @typedef {{ |
| 136 * isUnified: (boolean|undefined), |
| 135 * mirroringSourceId: (string|undefined), | 137 * mirroringSourceId: (string|undefined), |
| 136 * isPrimary: (boolean|undefined), | 138 * isPrimary: (boolean|undefined), |
| 137 * overscan: (!chrome.system.display.Insets|undefined), | 139 * overscan: (!chrome.system.display.Insets|undefined), |
| 138 * rotation: (number|undefined), | 140 * rotation: (number|undefined), |
| 139 * boundsOriginX: (number|undefined), | 141 * boundsOriginX: (number|undefined), |
| 140 * boundsOriginY: (number|undefined), | 142 * boundsOriginY: (number|undefined), |
| 141 * displayMode: (!chrome.system.display.DisplayMode|undefined) | 143 * displayMode: (!chrome.system.display.DisplayMode|undefined) |
| 142 * }} | 144 * }} |
| 143 * @see https://developer.chrome.com/extensions/system.display#type-DisplayPrope
rties | 145 * @see https://developer.chrome.com/extensions/system.display#type-DisplayPrope
rties |
| 144 */ | 146 */ |
| 145 chrome.system.display.DisplayProperties; | 147 chrome.system.display.DisplayProperties; |
| 146 | 148 |
| 147 /** | 149 /** |
| 148 * Get the information of all attached display devices. | 150 * @typedef {{ |
| 151 * singleUnified: (boolean|undefined) |
| 152 * }} |
| 153 * @see https://developer.chrome.com/extensions/system.display#type-GetInfoFlags |
| 154 */ |
| 155 chrome.system.display.GetInfoFlags; |
| 156 |
| 157 /** |
| 158 * Requests the information for all attached display devices. |
| 159 * @param {!chrome.system.display.GetInfoFlags} flags Options affecting how the |
| 160 * information is returned. |
| 149 * @param {function(!Array<!chrome.system.display.DisplayUnitInfo>):void} | 161 * @param {function(!Array<!chrome.system.display.DisplayUnitInfo>):void} |
| 150 * callback | 162 * callback The callback to invoke with the results. |
| 151 * @see https://developer.chrome.com/extensions/system.display#method-getInfo | 163 * @see https://developer.chrome.com/extensions/system.display#method-getInfo |
| 152 */ | 164 */ |
| 153 chrome.system.display.getInfo = function(callback) {}; | 165 chrome.system.display.getInfo = function(flags, callback) {}; |
| 154 | 166 |
| 155 /** | 167 /** |
| 156 * Get the layout info for all displays. NOTE: This is only available to Chrome | 168 * Requests the layout info for all displays. NOTE: This is only available to |
| 157 * OS Kiosk apps and Web UI. | 169 * Chrome OS Kiosk apps and Web UI. |
| 158 * @param {function(!Array<!chrome.system.display.DisplayLayout>):void} callback | 170 * @param {function(!Array<!chrome.system.display.DisplayLayout>):void} callback |
| 171 * The callback to invoke with the results. |
| 159 * @see https://developer.chrome.com/extensions/system.display#method-getDisplay
Layout | 172 * @see https://developer.chrome.com/extensions/system.display#method-getDisplay
Layout |
| 160 */ | 173 */ |
| 161 chrome.system.display.getDisplayLayout = function(callback) {}; | 174 chrome.system.display.getDisplayLayout = function(callback) {}; |
| 162 | 175 |
| 163 /** | 176 /** |
| 164 * Updates the properties for the display specified by |id|, according to the | 177 * Updates the properties for the display specified by |id|, according to the |
| 165 * information provided in |info|. On failure, $(ref:runtime.lastError) will be | 178 * information provided in |info|. On failure, $(ref:runtime.lastError) will be |
| 166 * set. NOTE: This is only available to Chrome OS Kiosk apps and Web UI. | 179 * set. NOTE: This is only available to Chrome OS Kiosk apps and Web UI. |
| 167 * @param {string} id The display's unique identifier. | 180 * @param {string} id The display's unique identifier. |
| 168 * @param {!chrome.system.display.DisplayProperties} info The information about | 181 * @param {!chrome.system.display.DisplayProperties} info The information about |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 231 | 244 |
| 232 /** | 245 /** |
| 233 * Complete overscan adjustments for a display by saving the current values and | 246 * Complete overscan adjustments for a display by saving the current values and |
| 234 * hiding the overlay. | 247 * hiding the overlay. |
| 235 * @param {string} id The display's unique identifier. | 248 * @param {string} id The display's unique identifier. |
| 236 * @see https://developer.chrome.com/extensions/system.display#method-overscanCa
librationComplete | 249 * @see https://developer.chrome.com/extensions/system.display#method-overscanCa
librationComplete |
| 237 */ | 250 */ |
| 238 chrome.system.display.overscanCalibrationComplete = function(id) {}; | 251 chrome.system.display.overscanCalibrationComplete = function(id) {}; |
| 239 | 252 |
| 240 /** | 253 /** |
| 241 * Starts native touch calibration for a display. This will show an overlay on | 254 * Displays the native touch calibration UX for the display with |id| as display |
| 242 * the screen and initialize the UX for touch calibration. If another native | 255 * id. This will show an overlay on the screen with required instructions on how |
| 243 * touch calibration is already in progress this will throw an error. | 256 * to proceed. The callback will be invoked in case of successful calibraion |
| 257 * only. If the calibration fails, this will throw an error. |
| 244 * @param {string} id The display's unique identifier. | 258 * @param {string} id The display's unique identifier. |
| 259 * @param {function(boolean):void=} callback Optional callback to inform the |
| 260 * caller that the touch calibration has ended. The argument of the |
| 261 * callback informs if the calibration was a success or not. |
| 245 * @see https://developer.chrome.com/extensions/system.display#method-showNative
TouchCalibration | 262 * @see https://developer.chrome.com/extensions/system.display#method-showNative
TouchCalibration |
| 246 */ | 263 */ |
| 247 chrome.system.display.showNativeTouchCalibration = function(id) {}; | 264 chrome.system.display.showNativeTouchCalibration = function(id, callback) {}; |
| 248 | 265 |
| 249 /** | 266 /** |
| 250 * Starts custom touch calibration for a display. This should be called when | 267 * Starts custom touch calibration for a display. This should be called when |
| 251 * using a custom UX for collecting calibration data. If another touch | 268 * using a custom UX for collecting calibration data. If another touch |
| 252 * calibration is already in progress this will throw an error. | 269 * calibration is already in progress this will throw an error. |
| 253 * @param {string} id The display's unique identifier. | 270 * @param {string} id The display's unique identifier. |
| 254 * @see https://developer.chrome.com/extensions/system.display#method-startCusto
mTouchCalibration | 271 * @see https://developer.chrome.com/extensions/system.display#method-startCusto
mTouchCalibration |
| 255 */ | 272 */ |
| 256 chrome.system.display.startCustomTouchCalibration = function(id) {}; | 273 chrome.system.display.startCustomTouchCalibration = function(id) {}; |
| 257 | 274 |
| 258 /** | 275 /** |
| 259 * Sets the touch calibration pairs for a display. These |pairs| would be used | 276 * Sets the touch calibration pairs for a display. These |pairs| would be used |
| 260 * to calibrate the touch screen for display with |id| called in | 277 * to calibrate the touch screen for display with |id| called in |
| 261 * startCustomTouchCalibration(). Always call |startCustomTouchCalibration| | 278 * startCustomTouchCalibration(). Always call |startCustomTouchCalibration| |
| 262 * before calling this method. If another touch calibration is already in | 279 * before calling this method. If another touch calibration is already in |
| 263 * progress this will throw an error. | 280 * progress this will throw an error. |
| 264 * @param {!chrome.system.display.TouchCalibrationPairQuad} pairs The pairs of | 281 * @param {!chrome.system.display.TouchCalibrationPairQuad} pairs The pairs of |
| 265 * point used to calibrate the display. | 282 * point used to calibrate the display. |
| 266 * @param {!chrome.system.display.Bounds} bounds Bounds of the display when the | 283 * @param {!chrome.system.display.Bounds} bounds Bounds of the display when the |
| 267 * touch calibration was performed. |bounds.left| and |bounds.top| | 284 * touch calibration was performed. |bounds.left| and |bounds.top| |
| 268 * values are ignored. | 285 * values are ignored. |
| 269 * @see https://developer.chrome.com/extensions/system.display#method-completeCu
stomTouchCalibration | 286 * @see https://developer.chrome.com/extensions/system.display#method-completeCu
stomTouchCalibration |
| 270 */ | 287 */ |
| 271 chrome.system.display.completeCustomTouchCalibration = function(pairs, bounds) {
}; | 288 chrome.system.display.completeCustomTouchCalibration = function(pairs, bounds) {
}; |
| 272 | 289 |
| 273 /** | 290 /** |
| 274 * Resets the touch calibration for the display and removes the saved | 291 * Resets the touch calibration for the display and brings it back to its |
| 275 * calibration data. | 292 * default state by clearing any touch calibration data associated with the |
| 293 * display. |
| 276 * @param {string} id The display's unique identifier. | 294 * @param {string} id The display's unique identifier. |
| 277 * @see https://developer.chrome.com/extensions/system.display#method-clearTouch
Calibration | 295 * @see https://developer.chrome.com/extensions/system.display#method-clearTouch
Calibration |
| 278 */ | 296 */ |
| 279 chrome.system.display.clearTouchCalibration = function(id) {}; | 297 chrome.system.display.clearTouchCalibration = function(id) {}; |
| 280 | 298 |
| 281 /** | 299 /** |
| 282 * Fired when anything changes to the display configuration. | 300 * Fired when anything changes to the display configuration. |
| 283 * @type {!ChromeEvent} | 301 * @type {!ChromeEvent} |
| 284 * @see https://developer.chrome.com/extensions/system.display#event-onDisplayCh
anged | 302 * @see https://developer.chrome.com/extensions/system.display#event-onDisplayCh
anged |
| 285 */ | 303 */ |
| 286 chrome.system.display.onDisplayChanged; | 304 chrome.system.display.onDisplayChanged; |
| OLD | NEW |