docs: note that visual zoom is disabled by default (#16130)

This commit is contained in:
Jeremy Apthorp 2018-12-18 19:40:42 -08:00 committed by Shelley Vohr
parent 5cc4a30207
commit 03f876470e
2 changed files with 12 additions and 0 deletions

View file

@ -948,6 +948,12 @@ Sends a request to get current zoom level, the `callback` will be called with
Sets the maximum and minimum pinch-to-zoom level.
> **NOTE**: Visual zoom is disabled by default in Electron. To re-enable it, call:
>
> ```js
> contents.setVisualZoomLevelLimits(1, 3)
> ```
#### `contents.setLayoutZoomLevelLimits(minimumLevel, maximumLevel)`
* `minimumLevel` Number

View file

@ -50,6 +50,12 @@ Returns `Number` - The current zoom level.
Sets the maximum and minimum pinch-to-zoom level.
> **NOTE**: Visual zoom is disabled by default in Electron. To re-enable it, call:
>
> ```js
> webFrame.setVisualZoomLevelLimits(1, 3)
> ```
### `webFrame.setLayoutZoomLevelLimits(minimumLevel, maximumLevel)`
* `minimumLevel` Number