mirror of
https://github.com/electron/electron.git
synced 2026-01-08 23:18:06 -05:00
fix: dipToScreenRect / screenToDipRect - window can be null (#13903)
This commit is contained in:
committed by
Samuel Attard
parent
03293d78a2
commit
fceed0fcbc
@@ -136,7 +136,7 @@ The DPI scale is performed relative to the display containing the DIP point.
|
||||
|
||||
### `screen.screenToDipRect(window, rect)` _Windows_
|
||||
|
||||
* `window` [BrowserWindow](browser-window.md)
|
||||
* `window` [BrowserWindow](browser-window.md) | null
|
||||
* `rect` [Rectangle](structures/rectangle.md)
|
||||
|
||||
Returns [`Rectangle`](structures/rectangle.md)
|
||||
@@ -147,7 +147,7 @@ If `window` is null, scaling will be performed to the display nearest to `rect`.
|
||||
|
||||
### `screen.dipToScreenRect(window, rect)` _Windows_
|
||||
|
||||
* `window` [BrowserWindow](browser-window.md)
|
||||
* `window` [BrowserWindow](browser-window.md) | null
|
||||
* `rect` [Rectangle](structures/rectangle.md)
|
||||
|
||||
Returns [`Rectangle`](structures/rectangle.md)
|
||||
|
||||
Reference in New Issue
Block a user