feat: make zoomLevel/zoomFactor sync (#16410)

* feat: make zoomLevel/zoomFactor sync

* update ts defs dep
This commit is contained in:
Shelley Vohr 2019-01-20 23:40:27 -08:00 committed by GitHub
parent dacf7f8bdc
commit 3ca87d205f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
14 changed files with 112 additions and 124 deletions

View file

@ -977,13 +977,9 @@ Returns `Boolean` - Whether audio is currently playing.
Changes the zoom factor to the specified factor. Zoom factor is
zoom percent divided by 100, so 300% = 3.0.
#### `contents.getZoomFactor(callback)`
#### `contents.getZoomFactor()`
* `callback` Function
* `zoomFactor` Number
Sends a request to get current zoom factor, the `callback` will be called with
`callback(zoomFactor)`.
Returns `Number` - the current zoom factor.
#### `contents.setZoomLevel(level)`
@ -994,13 +990,9 @@ increment above or below represents zooming 20% larger or smaller to default
limits of 300% and 50% of original size, respectively. The formula for this is
`scale := 1.2 ^ level`.
#### `contents.getZoomLevel(callback)`
#### `contents.getZoomLevel()`
* `callback` Function
* `zoomLevel` Number
Sends a request to get current zoom level, the `callback` will be called with
`callback(zoomLevel)`.
Returns `Number` - the current zoom level.
#### `contents.setVisualZoomLevelLimits(minimumLevel, maximumLevel)`