Commit graph

3484 commits

Author SHA1 Message Date
Samuel Maddock
ef4954fa1f
docs: systemPreferences.subscribeWorkspaceNotification return type (#28588) 2021-04-11 14:02:58 -07:00
Milan Burda
da8c35e3b2
chore: remove deprecated worldSafeExecuteJavaScript option (#28456) 2021-04-08 12:03:57 -04:00
Germain
2865d161b7
docs: remove checkbox options in dialog.showMessageBoxSync (#28418) 2021-04-07 00:18:19 -07:00
Shelley Vohr
7d04f729d8
fix: beforeunload and unload firing in BrowserViews (#28382)
* fix: beforeunload and unload firing in BrowserViews

* Ensure UserGesture is sent for BV webContents

* spec: add tests

* refactor: clean up logic

* spec: fixup specs

* docs: document event behavior for BrowserViews
2021-04-07 00:16:10 -07:00
Jeremy Rose
77dcf1020a
fix: pass postData to new-window event (#28513) 2021-04-06 09:54:05 -07:00
Michaela Laurencin
19d7a6b761
fix: enable system maximization for frameless windows except if transparent (#28207)
* fix: move widget maximization check

* fix linting error

* change workaround to only effect transparent windows

* disable menu maximize and restore for transparent windows

* disable double clicking title bar max/unmax for transparent windows

* add docs change and address review
2021-04-06 08:53:59 +09:00
SushiJackal
82ea8ea68c
fix: reject task append to JumpList when description exceeds 260 characters (#28485)
* fix: reject task when description exceeds 260 characters

* Switched out wcslen() for size() [linear -> constant time]

* Included comment describing the need for the additional check

* Added information about character limit to documentation

* Added newline character to end of jump-list-category.md
2021-04-06 08:50:39 +09:00
Michaela Laurencin
2a55ae4b85
docs: add frameName note for window.open (#28435) 2021-03-31 13:57:39 -07:00
Saúl Ibarra Corretgé
2632564ccf
feat: initialize field trials from command line arguments (#28305)
Fixes: #27877
2021-03-26 09:49:00 +09:00
Alexander Prinzhorn
521146f71e
docs: add missing line in web-contents.md (#28376)
* Update web-contents.md

The text block was rendered as part of the `features` property, not the `handler`

* fix linting
2021-03-26 09:46:59 +09:00
Will Anderson
8c3165434a
docs: update Node global symbols example to use contextBridge (#28245)
* docs: update Node global symbols example to use contextBridge

* Trigger Build

* docs: change Node API example to show how to expose a crypto API

Co-authored-by: Jeremy Rose <nornagon@nornagon.net>

* docs: Fix lint warning for crypto code sample

* docs: update node API example description to emphasize APIs instead of symbols

Co-authored-by: Jeremy Rose <nornagon@nornagon.net>
2021-03-22 11:01:12 +09:00
Jeremy Rose
502d4c19ce
feat: allow omitting submitURL when uploadToServer is false (#28105) 2021-03-18 14:15:19 -07:00
Samuel Attard
f35fc93080
chore: rename process.contextIsolation to process.contextIsolated (#28259)
* chore: rename process.contextIsolation to process.contextIsolated

* thing
2021-03-18 14:00:19 -07:00
Milan Burda
fc7f2042ec
feat: add process.contextIsolation property (#28030) 2021-03-17 11:23:29 -07:00
Milan Burda
485fa5bea9
feat: add process.contextId used by @electron/remote (#28007) 2021-03-17 11:23:03 -07:00
Samuel Attard
b045d42b0e
docs: document the parameter structure of hookWindowMessage (#28189)
Fixes #28178
2021-03-16 17:54:41 +09:00
Gerrit Niezen
45c4dd529f
docs: remove unnecessary enableBlinkFeatures (#28129)
* docs: remove unnecessary enableBlinkFeatures

* docs: remove trailing comma
2021-03-15 10:29:10 +09:00
Binyamin Aron Green
a442f11574
fixed typo in docs/api/window-open.md (#28117) 2021-03-13 10:47:33 +09:00
Samuel Attard
74e7f98572
docs: fix cookies event documentation for type generation (#28115) 2021-03-11 12:14:16 -08:00
Milan Burda
5b205731f6
chore: remove deprecated remote module (#25734)
Co-authored-by: Jeremy Rose <jeremya@chromium.org>
2021-03-09 17:12:40 -08:00
Shelley Vohr
d9997c303f
fix: capturePage not resolving with hidden windows (#27883) 2021-03-09 05:51:44 -08:00
Konstantin Pschera
5b50c88508
docs: auto update downloading multiple times (#27888) 2021-03-08 10:03:34 +09:00
Erick Zhao
9ccb8f5910
docs: update WebPreferences default values for Electron 12 (#27984)
Updates the values for `contextIsolation` and `worldSafeExecuteJavaScript` for Electron 12.
2021-03-08 09:56:50 +09:00
Domenic Horner
46cfb347d7
docs: setWindowOpenHandler should show object return (#28015)
* Should use object return

* Fix lint

Co-authored-by: Cheng Zhao <github@zcbenz.com>
2021-03-08 09:56:07 +09:00
Stathis Siatras
d92bab0e29
docs: suspend and resume are available on Linux (#27958)
* docs: suspend and resume are available on Linux

* docs: suspend and resume are available on Linux
2021-03-05 10:11:36 +09:00
Keeley Hammond
84d0e827a3
chore: revert webFrameMain.executeJavaScriptInIsolatedWorld method (#27926) 2021-03-01 10:07:25 -05:00
Jeremy Rose
2e13ce58c0
docs: fix header level of some events in app.md (#27860) 2021-02-24 18:04:41 +09:00
Michaela Laurencin
0dd283a7a6
docs: update menu item '&' escaping (#27770) 2021-02-19 15:41:16 +09:00
Dennis Keil
8a88799ce2
docs: transparent window opaque while dev tools opened (#27705)
* Transparent window disabled while dev tools opened

Read that on some external website. I think this should be added to the official docs.

* Update frameless-window.md

Co-authored-by: Cheng Zhao <github@zcbenz.com>
2021-02-15 11:59:40 +09:00
Samuel Maddock
3250ef551c
feat: support registering MV3 extension service workers (#27562)
* feat: support registering MV3 extension service workers

* feat: load chrome extension APIs in worker context

* feat: add more ContentRendererClient service worker overrides

* fix: lint error

* refactor: emit object for 'registration-completed'

* docs: clarify when registration-completed emits
2021-02-11 10:58:03 -05:00
Stewart Lord
5f5afaae27
feat: add win.setTopBrowserView() so that BrowserViews can be raised (#27007)
* feat: Raise a browser view via `BrowserWindow.setTopBrowserView()`.

This is similar to removing and re-adding a browser view, but avoids a visible flicker as the browser view is not removed from the window when using `setTopBrowserView`. Note: if the given browser view is not attached to the window, it will be added.

This commit contains the macOS implementation.

* feat: setTopBrowserView support for Windows and Linux

* docs: add info about setTopBrowserView

* docs: Clarify behavior when browserView is not yet attached.

* fix: throw en error when browserView is not attached to the window

* fix: build error

* fix: test

* fix: add test case

* fix: tests

* fix: reparenting

* fix: close second window in tests

Co-authored-by: sentialx <sentialx@gmail.com>
2021-02-10 16:23:35 +09:00
Cheng Zhao
af4a050a1b
feat: add roundedCorners option for BrowserWindow (#27572)
* feat: add roundedCorner option for BrowserWindow

* Make roundedCorner work with vibrancy views

* roundedCorner => roundedCorners
2021-02-09 08:38:35 -08:00
Jeremy Rose
28599e5e7c
feat: add exit code to render-process-gone details (#27580) 2021-02-08 17:08:11 -08:00
Erick Zhao
affbf1b3e6
docs: remove v5 and v6 modernization docs (#27498)
* docs: remove v5 and v6 modernization docs

* typo

* run script/gen-filenames.ts
2021-02-03 15:57:33 +09:00
Cyrus Roshan
444ad26f89
feat: add option to not transform processes on win.SetVisibleOnAllWorkspaces (#27200)
* fix: optionally transform processes on win.SetVisibleOnAllWorkspaces on macOS, making it backwards-compatible with v9.2.1 (#27101)

* fix: optionally transform processes on win.SetVisibleOnAllWorkspaces on macOS, making it backwards-compatible with v9.2.1 (#27101)

Co-authored-by: Cyrus Roshan <cyrusroshan@users.noreply.github.com>
2021-02-02 21:24:04 +09:00
Ahmed Elshafey
272611cc82
docs: Update ipcMain.handle() docs in ipc-main.md for error-handling details (#27461)
* Update ipc-main.md

Include information about ipcMain.handle() error handling and workaround included in issue #24427

* Update ipc-main.md

fixed a typo

* Update ipc-main.md

Remove the exception passing workaround from ipcMain.handle() and refer to open issue only.

* Remove trailing spaces

Co-authored-by: Cheng Zhao <github@zcbenz.com>
2021-02-02 21:22:20 +09:00
Сковорода Никита Андреевич
a5e9af330f
feat: implement allowFileAccess loadExtension option (#25198)
Co-authored-by: Samuel Maddock <samuel.maddock@gmail.com>
Co-authored-by: Jeremy Rose <jeremya@chromium.org>
2021-02-01 14:41:08 -08:00
Cheng Zhao
8bf66f8974
fix: clean up implementations of titleBarStyle (#27489)
* Rewrite titleBarStyle impls with WindowButtonsView

* Remove fullscreenWindowTitle option

* Make buttons show correctly under RTL

* Fix docs about traffic lights position

* Fix test on fullscreen resizable

* Fix button states with closabe/minimizable/fullscreenable

* Fix typo

* Deprecate the fullscreenWindowTitle option
2021-01-30 17:15:10 -06:00
Erick Zhao
78d4cb9f5c
docs: update verb tenses for structured clone notes (#27483) 2021-01-26 14:14:44 -08:00
John Kleinschmidt
c5a41defbd
fix: enable navigator.setAppBadge/clearAppBadge (#27067) 2021-01-21 14:45:06 +09:00
Cheng Zhao
c3091c3a70
fix: make SetWindowButtonVisibility work for customButtonsOnHover (#27073) 2021-01-19 19:12:09 +09:00
Milan Burda
2be3d03630
feat: add webFrameMain.send() / webFrameMain.postMessage() (#26807) 2021-01-15 09:00:37 +09:00
Jeremy Rose
088f2e625f
feat: add frame and webContents to webRequest details (#27078)
* feat: add frame and webContents to webRequest details

* chore: use frame_converter.h

Co-authored-by: Cheng Zhao <zcbenz@gmail.com>
2021-01-11 12:20:43 +09:00
AHFriedman
1ef766c4a6
docs: correct meaning of DesktopCapturerSource.id (#27255)
* docs: correction meaning of DesktopCapturerSource.id

Corrected the meaning of the id string to match observed behavior
(verified on Windows 10 and Ubuntu).

* chore: adjust wordings

Co-authored-by: Cheng Zhao <zcbenz@gmail.com>
2021-01-11 12:20:00 +09:00
Jim Fisher
01b7ceac17
docs: coordinate system of badly named method getCursorScreenPoint (#27156)
* Document coordinate system of badly named method getCursorScreenPoint

[Electron inherits this confusing name from Chromium](99314be815/ui/display/win/screen_win.cc (L677-L681)). We can also see there that the return value is a DIPPoint, due to `ScreenToDIPPoint` call:

    gfx::Point ScreenWin::GetCursorScreenPoint() {
      POINT pt;
      ::GetCursorPos(&pt);
      return gfx::ToFlooredPoint(ScreenToDIPPoint(gfx::PointF(gfx::Point(pt))));
    }

I lost over a day due to debugging this. I don't think we can change the method name due to backwards compatibility, but we can at least make amends in the documentation.

* Remove advice

* Softer wording

Co-authored-by: Cheng Zhao <zcbenz@gmail.com>
2021-01-11 12:19:48 +09:00
Jim Fisher
0f8b5ab606
docs: coordinate system of Display.bounds and Display.workArea (#27157)
They are in DIP points (rather than screen points). We can use
screen.dipToScreen* to convert to screen points.
2021-01-07 19:49:45 +09:00
theLMGN
b531123b4d
docs: NSVisualEffectMaterialDark has been deprecated and removed as of macOS 10.15 (#27125)
* NSVisualEffectMaterialDark has been deprecated and removed as of macOS 10.15.

* Update browser-window.md
2021-01-05 13:39:07 -08:00
Milan Burda
3d59aa5609
feat: add webFrameMain.executeJavaScriptInIsolatedWorld() (#26913) 2021-01-05 17:18:38 +09:00
Cheng Zhao
5f99569b6c
feat: make win.setAspectRatio() work on Windows (#26941)
* feat: make win.setAspectRatio() work on Windows

* update patches

Co-authored-by: Electron Bot <electron@github.com>
2021-01-05 17:17:33 +09:00
Milan Burda
16c864a932
docs: webFrameMain.fromId() can return undefined (#27068)
* docs: webFrameMain.fromId() can return undefined

* docs: webFrameMain.fromId() can return undefined
2021-01-05 11:31:21 +09:00