Milan Burda
2c65060ec8
chore: make raw requires type-safe ( #29006 )
...
* chore: make raw requires type-safe
* refactor: no need for separate webViewImplModule
* refactor: no need for separate guestViewInternalModule
2021-05-05 18:05:01 -07:00
Milan Burda
2086e1903c
refactor: 'focus-change' does not need guestInstanceId ( #29001 )
...
* refactor: 'focus-change' does not need guestInstanceId
* refactor: rename internal 'focus-change' event to '-focus-change'
2021-05-05 11:37:40 -07:00
Milan Burda
476e908269
fix: <webview> focus / blur events don't work with contextIsolation enabled ( #29004 )
2021-05-05 11:31:44 -07:00
Milan Burda
42e5421276
refactor: remove unnecessary setupDialogProperties ( #28982 )
2021-05-05 16:00:41 +09:00
Milan Burda
961b74b2ac
refactor: use "as const" for constant mappings ( #28980 )
2021-05-04 14:12:49 -07:00
Samuel Attard
e5e8ab4eea
refactor: remove more dead code post render process reuse ( #28983 )
...
* Overrides for window.history.*
* Node environment cleanup / creation logic
* Options and switches that are now static values
2021-05-04 11:30:29 -07:00
Milan Burda
a0589ca5d7
chore: remove unused element_instance_id_to_guest_map_ from WebViewManager ( #28979 )
2021-05-04 09:59:44 -04:00
Samuel Attard
791eddd541
fix: provide no-op implementation of app.setUserModelId ( #28915 )
2021-04-28 18:41:03 -07:00
Samuel Attard
0a1b26b1d5
refactor: remove internal navigation controller ( #28839 )
2021-04-27 16:11:18 -07:00
Samuel Attard
79077f6df9
chore: remove app.allowRendererProcessReuse ( #26874 )
2021-04-21 13:59:11 -07:00
Jeremy Rose
4ca518468d
feat: remove BrowserWindow option inheritance ( #28550 )
2021-04-21 10:55:17 -07:00
Shelley Vohr
11199d8824
feat: add BrowserWindow.isFocusable() ( #28642 )
2021-04-21 12:32:19 +02:00
Jeremy Rose
e12a3cb59c
feat: remove deprecated additionalFeatures ( #28548 )
2021-04-19 15:46:54 -07:00
Samuel Attard
b8c2481edb
fix: do not handle write errors after request is aborted ( #28682 )
...
This fixes a flake on linux CI which started recently where the "write"
promise is being rejected after the request has been aborted /
cancelled. In this case we should drop the error to the floor but
instead we pass it down the stack where it eventually emits a now
unhandled error event.
Example failure: https://app.circleci.com/pipelines/github/electron/electron/38072/workflows/c1faf19b-aa41-4f99-a564-165729222859/jobs/838813
Verified fix by running the test that caused it 10000 times before fix
and 10000 times after. ~50 failures before, 0 after.
2021-04-19 09:50:14 -04:00
Jeremy Rose
dba4df9326
feat: add more info in setWindowOpenHandler details ( #28518 )
...
* fix: invoke the window open handler for _blank links
* feat: add disposition to setWindowOpenHandler details
* fix: pass postData to new-window event
* postData can be heterogeneous
* fix type of postBody
* fix type of UploadFile and UploadRawData to be discriminated unions
* exclude the empty string from additionalFeatures
* add a test
* add postBody and referrer to setWindowOpenHandler args
* appease typescript
* Update api-browser-window-spec.ts
* update snapshots
2021-04-13 15:35:27 -04:00
Samuel Attard
6df2680cb6
refactor: clean up webFrame implementation to use gin wrappers ( #28497 )
...
* refactor: clean up webFrame implementation to use gin wrappers
The previous implementation of webFrame in the renderer process leaked
sub-frame contexts and global objects across the context boundaries thus
making it possible for apps to either maliciously or accidentally
violate the contextIsolation boundary.
This re-implementation binds all methods in native code directly to
content::RenderFrame instances instead of relying on JS to provide a
"window" with every method request. This is much more consistent with
the rest of the Electron codebase and is substantially safer.
* chore: un-re-order for ease of review
* chore: pass isolate around instead of ErrorThrower
* chore: fix rebase typo
* chore: remove unused variables
2021-04-12 16:35:18 -07:00
Shelley Vohr
95e26e2fd4
refactor: use URL API ( #28583 )
2021-04-09 14:22:18 -07:00
Milan Burda
da8c35e3b2
chore: remove deprecated worldSafeExecuteJavaScript option ( #28456 )
2021-04-08 12:03:57 -04:00
Jeremy Rose
77dcf1020a
fix: pass postData to new-window event ( #28513 )
2021-04-06 09:54:05 -07:00
Jeremy Rose
62b38812b6
fix: invoke the window open handler for _blank links ( #28498 )
...
* fix: invoke the window open handler for _blank links
* add test
2021-04-06 01:04:14 -07:00
Milan Burda
55c66e3e92
chore: add types for electron_renderer_web_frame binding ( #28455 )
...
* chore: add types for electron_renderer_web_frame binding
* chore: use keyof for getWebPreference type
Co-authored-by: Samuel Attard <sattard@slack-corp.com>
2021-04-02 14:34:28 -07:00
Erick Zhao
f55aa78883
chore: update Community link in default menu ( #28449 )
2021-03-30 23:22:55 -07:00
Shelley Vohr
7c36463085
fix: window.print() in pdf plugin ( #28328 )
2021-03-23 10:40:37 -04:00
Jeremy Rose
502d4c19ce
feat: allow omitting submitURL when uploadToServer is false ( #28105 )
2021-03-18 14:15:19 -07:00
Milan Burda
485fa5bea9
feat: add process.contextId used by @electron/remote ( #28007 )
2021-03-17 11:23:03 -07:00
Jeremy Rose
d27ad0d182
fix: revert "refactor: mmap asar files ( #24470 )" ( #28137 )
...
This reverts commit 01a2e23194
.
2021-03-15 11:42:54 -07:00
Samuel Attard
089ac8180f
fix: ensure child window transparency works ( #28054 )
...
* fix: ensure child window transparency works
Windows opened via window.open and intecepted via setWindowOpenHandler
or the `new-window` event should (a) have the correct background color
and (b) that background color should be transparent if specified.
The changes in api_web_contents fix (a) and the changes in
web_contents_preferences fix (b).
Notes: Child windows with specified background colors or transpency now
work as intended
* fix: set background_color in blink prefs apply logic
* chore: update for PR comments
2021-03-10 12:44:36 -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
liulun
54bc71da34
chore: Add a condition to crashReporter deprecate log ( #27953 )
...
* Add a condition to crashReporter deprecate log
When developer set submitURL to '' crash reports will be saved at `...\AppData\Roaming\...\Crashpad\reports`, will not be uploaded to the server.
So at this time `deprecate.log('Sending uncompressed crash reports....')` is unnecessary.
* Update lib/browser/api/crash-reporter.ts
change to check uploadToServer
Co-authored-by: Jeremy Rose <nornagon@nornagon.net>
Co-authored-by: Jeremy Rose <nornagon@nornagon.net>
2021-03-05 10:13:17 +09:00
Electron Bot
ca75bca667
chore: bump chromium to 90.0.4415.0 (master) ( #27694 )
...
* chore: bump chromium in DEPS to 520c02b46668fc608927e0fcd79b6a90885a48bf
* chore: bump chromium in DEPS to 90.0.4414.0
* resolve chromium conflicts
* resolve v8 conflicts
* fix node gn files
* 2673502: Remove RenderViewCreated use from ExtensionHost.
https://chromium-review.googlesource.com/c/chromium/src/+/2673502
* 2676903: [mojo] Remove most legacy Binding classes.
https://chromium-review.googlesource.com/c/chromium/src/+/2676903
* 2644847: Move self-deleting URLLoaderFactory base into //services/network.
https://chromium-review.googlesource.com/c/chromium/src/+/2644847
* 2664006: Remove from mojo::DataPipe.
https://chromium-review.googlesource.com/c/chromium/src/+/2664006
* 2674530: Remove CertVerifierService feature
https://chromium-review.googlesource.com/c/chromium/src/+/2674530
* 2668748: Move OnSSLCertificateError to a new interface.
https://chromium-review.googlesource.com/c/chromium/src/+/2668748
* 2672923: Remove RAPPOR reporting infrastructure.
https://chromium-review.googlesource.com/c/chromium/src/+/2672923
* 2673502: Remove RenderViewCreated use from ExtensionHost.
https://chromium-review.googlesource.com/c/chromium/src/+/2673502
* 2655126: Convert FrameHostMsg_ContextMenu and FrameMsg_ContextMenuClosed|CustomContextMenuAction to Mojo
https://chromium-review.googlesource.com/c/chromium/src/+/2655126
* 2628705: Window Placement: Implement screen.isExtended and change event
https://chromium-review.googlesource.com/c/chromium/src/+/2628705
* 2643161: Refactor storage::kFileSystem*Native*
https://chromium-review.googlesource.com/c/chromium/src/+/2643161
* fix build
* only remove the biggest subdir of //ios
* chore: bump chromium in DEPS to 90.0.4415.0
* update patches
* update sysroots
* 2686147: Remove WebContentsObserver::RenderViewCreated().
https://chromium-review.googlesource.com/c/chromium/src/+/2686147
* 2596429: Fixing how extension's split and spanning modes affect OriginAccessList.
https://chromium-review.googlesource.com/c/chromium/src/+/2596429
* 2686026: [mojo] Delete AssociatedInterfacePtr (replaced by AssociatedRemote)
https://chromium-review.googlesource.com/c/chromium/src/+/2686026
* 2651705: Move ui/base/dragdrop/file_info to ui/base/clipboard
https://chromium-review.googlesource.com/c/chromium/src/+/2651705
* 358217: drawBitmap is deprecated
https://skia-review.googlesource.com/c/skia/+/358217
* fix gn check
* 2678098: Use gen/front_end as input to generate_devtools_grd
https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2678098
* 2674530: Remove CertVerifierService feature
https://chromium-review.googlesource.com/c/chromium/src/+/2674530
* fixup 2664006: Remove from mojo::DataPipe.
https://chromium-review.googlesource.com/c/chromium/src/+/2664006
* fixup build_add_electron_tracing_category.patch
* 2673415: [base] Prepare CrashReporterClient for string16 switch
https://chromium-review.googlesource.com/c/chromium/src/+/2673415
* 2673413: Add CursorFactoryWin to handle Cursors on Windows
https://chromium-review.googlesource.com/c/chromium/src/+/2673413
* 2668748: Move OnSSLCertificateError to a new interface.
https://chromium-review.googlesource.com/c/chromium/src/+/2668748
* fix mas gn check
* update patch after merge
* Update node for .mjs files
* build: load v8_prof_processor dependencies as ESM
* chore: add patch to fix linux 32bit
Co-authored-by: Jeremy Rose <nornagon@nornagon.net>
Co-authored-by: Jeremy Rose <jeremya@chromium.org>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: Samuel Attard <samuel.r.attard@gmail.com>
2021-03-04 09:27:05 -08:00
Milan Burda
bf7e445883
fix: warning when worldSafeExecuteJavaScript is disabled ( #27928 )
2021-03-02 09:45:27 -08:00
Erick Zhao
2d0ad0b96a
fix: make TouchBarPopover and TouchBarGroup work ( #27901 )
...
* fix: use correct `orderedItem` touchbar property
* fix: correct parent in touchbar group and popover
* fix: preserve property hook order
2021-03-01 13:34:00 -08:00
Emil Pettersson
a9b25dda85
fix: race-condition in electron.net ( #27898 )
2021-02-26 13:18:46 -08:00
Tony
b181dae146
fix: isFullScreen typo ( #27823 )
...
* fix isFullScreen typo
* Update lib/browser/api/base-window.ts
Co-authored-by: John Kleinschmidt <jkleinsc@github.com>
Co-authored-by: Tony Wu <tonywoo@fb.com>
Co-authored-by: John Kleinschmidt <jkleinsc@github.com>
2021-02-22 15:33:46 -05:00
Shelley Vohr
599f398ddc
fix: enableBlinkFeatures warning in webviews ( #27753 )
2021-02-18 11:11:35 -08:00
Jeremy Rose
706d9ede9b
refactor: only allow internal messages from the main process ( #27676 )
2021-02-09 17:12:26 -08:00
Shelley Vohr
e46446e7e4
chore: bump chromium to e836cbe709f3cd703f233de8eb6cc6ec99b72c9d ( #27475 )
...
Co-authored-by: deepak1556 <hop2deep@gmail.com>
Co-authored-by: Jeremy Rose <nornagon@nornagon.net>
2021-02-09 12:16:21 -08:00
Milan Burda
bc7c290601
refactor: load preload script directly as a string ( #27546 )
2021-02-08 09:32:20 -08:00
Michaela Laurencin
c175d41ae8
fix: remove windowName set as title for native window.open() ( #27481 )
2021-02-05 11:20:58 -08:00
Milan Burda
79b3393768
chore: remove bunch of usages of any ( #27512 )
2021-01-29 12:41:59 -08:00
Michaela Laurencin
357becd113
fix: replace default frameName title with null check ( #27521 )
...
* refactor: replace default frameName title with null check
* add isNativeWindowOpen check in makeBrowserWindowOptions
* modify snapshot test files
* replace title with frame-name again for proxy - not native open
* modify proxy snapshot title key-value to come after height key-value
2021-01-29 07:24:30 -06:00
Milan Burda
64b7be751a
fix: CSP with unsafe-eval
detection with Trusted Types ( #27446 )
2021-01-25 10:31:25 +09:00
Milan Burda
4a5c5843c4
fix: <webview> not working with Trusted Types ( #27445 )
2021-01-25 10:29:25 +09:00
Milan Burda
70190ec2b1
chore: update to latest TypeScript, which has built-in WeakRef declarations ( #27425 )
2021-01-22 11:25:47 -08:00
Milan Burda
8b74361b0c
refactor: store WeakMaps in CallbacksRegistry / ObjectsRegistry ( #27037 )
2021-01-20 14:03:10 -08:00
Milan Burda
2be3d03630
feat: add webFrameMain.send() / webFrameMain.postMessage() ( #26807 )
2021-01-15 09:00:37 +09:00
Milan Burda
a55e028b12
fix: handle _sendToFrameInternal() throwing an exception in remote/server.ts ( #27046 )
2020-12-17 14:28:40 -08:00
Jeremy Rose
da3d21e5e3
fix: make webContents.id work even after destroy ( #27038 )
2020-12-17 12:10:29 -08:00
Jeremy Rose
6a3679dc55
fix: memory leak in desktopCapturer.getSources ( #27031 )
2020-12-16 16:11:39 -08:00
Cheng Zhao
998f17ee59
fix: make protocol wrapper remote-friendly again ( #27009 )
2020-12-16 16:56:53 +09:00
Milan Burda
6932e17088
chore: remove deprecated systemPreferences methods ( #26849 )
2020-12-16 08:34:24 +09:00
Avi Vahl
9b02d94e97
fix(asar): readdir(withFileTypes) fails on deep directory ( #26865 )
...
when using readdirSync on a deep directory within the archive, the code fails to get the stats of child paths.
2020-12-15 11:21:49 +09:00
Milan Burda
cec6378881
feat: add event.senderFrame property returning the originating webFrameMain ( #26764 )
2020-12-09 15:34:06 -08:00
Jeremy Rose
07a1c2a3e5
fix: restrict sendToFrame to same-process frames by default ( #26875 )
2020-12-09 12:48:16 -08:00
Milan Burda
c41b8d536b
refactor: move IPC handlers from navigation-controller to rpc-server ( #26846 )
2020-12-08 10:46:08 -08:00
Milan Burda
ee0550efca
fix: systemPreferences.effectiveAppearance returning systemPreferences.getAppLevelAppearance() ( #26852 )
2020-12-08 16:07:04 +09:00
Shelley Vohr
b788ceb7bd
fix: screen EventEmitter methods with remote ( #26809 )
...
* fix: screen EventEmitter methods with remote
* Review feedback
2020-12-08 13:47:48 +09:00
Samuel Attard
3db4e612f4
fix: handle security warnings promise when JS is disabled ( #26837 )
2020-12-07 10:58:00 -08:00
Alexey Kuzmin
e89b3ca1d1
fix: add a "set" trap to the "screen" module proxy ( #26818 )
2020-12-07 09:20:50 -08:00
Jeremy Rose
d3b1566181
chore: remove unused _replyInternal method ( #26825 )
2020-12-07 09:19:26 -08:00
Nikita Kot
7672aa9525
feat: exposeInMainWorld allow to expose non-object APIs ( #26594 )
2020-12-04 09:43:20 -08:00
Milan Burda
b111bba387
fix: send IPC_MESSAGES.RENDERER_RELEASE_CALLBACK as internal message ( #26808 )
2020-12-04 19:09:08 +03:00
Milan Burda
b37982987a
chore: remove unused sendToAll + related APIs ( #26771 )
...
* chore: remove unused sendToAll + related APIs
* refactor: no need to args.ShallowClone() anymore
2020-12-03 15:55:50 +09:00
Vadim
efca7007b6
fix: internalModuleReadJSON for unpacked JSON ( #26749 )
2020-12-01 21:33:39 -08:00
Milan Burda
19954126e0
chore: remove deprecated extension APIs ( #26696 )
2020-11-30 14:40:56 -08:00
Milan Burda
09d7b2bc91
chore: remove deprecated shell.moveItemToTrash() ( #26723 )
2020-11-30 23:25:03 +03:00
Milan Burda
022bafc485
chore: remove deprecated crashReporter APIs ( #26695 )
2020-11-26 22:07:40 +03:00
Milan Burda
c8d77cae4a
refactor: replace V8 hidden values with WeakMap / WeakSet ( #26659 )
2020-11-24 16:11:39 -05:00
Anders Kaseorg
b1b25607ee
fix: make screen wrapper remote-friendly again ( #26620 )
...
This restores accessibility of screen methods via remote.screen.
Fixes #26610 .
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2020-11-23 16:44:54 -05:00
Milan Burda
6932e02eb8
refactor: use getWebPreference() for all options ( #26531 )
2020-11-23 22:39:08 +03:00
LuoJinghua
e1cc78f275
feat: allow setting the Origin header and Sec-Fetch-* headers in net.request() ( #26135 )
2020-11-17 14:25:41 -08:00
Jeremy Rose
92643a5a1c
refactor: consolidate WebContents::{Create,New} ( #26521 )
2020-11-17 14:14:33 -08:00
Jeremy Rose
a303813d15
refactor: move GetPrinterList off WebContents ( #26518 )
2020-11-17 14:14:09 -08:00
Jeremy Rose
7c2ac6b7c1
fix: BrowserWindow.fromBrowserView in multiple-BrowserView windows ( #26493 )
2020-11-17 11:12:02 -08:00
Jeremy Rose
a9924e1c32
feat: add powerMonitor.onBatteryPower ( #26494 )
2020-11-16 16:31:46 -08:00
Milan Burda
5ee9cc202b
fix: ensure that internal messages are sent from the main process ( #26429 )
2020-11-12 06:20:01 +03:00
Cheng Zhao
bb3fb548d8
feat: add APIs to enable/disable spell checker ( #26276 )
...
* feat: add APIs to enable/disable bulitin spell checker
* feat: add togglespellchecker menu item role
2020-11-11 10:29:18 -05:00
loc
0b85fdf26c
feat: add webContents.setWindowOpenHandler API ( #24517 )
...
Co-authored-by: Jeremy Rose <jeremya@chromium.org>
2020-11-10 09:06:03 -08:00
Jeremy Rose
34156c424c
fix: [webview] fix missing properties on events when contextIsolation: true ( #26289 )
2020-11-04 11:15:20 +09:00
Milan Burda
d25fa7b075
refactor: store <webview> attributes as typed Map ( #26307 )
2020-11-03 15:02:23 -08:00
Abhishek Shingane
d16e61dc85
fix: window.open not accepting size values with "px" at the end ( #26104 )
...
* fix: use parseInt to parse sizes
* fix: pass radix to parseInt
Co-authored-by: Samuel Attard <samuel.r.attard@gmail.com>
Co-authored-by: Cheng Zhao <github@zcbenz.com>
Co-authored-by: Samuel Attard <samuel.r.attard@gmail.com>
2020-11-02 18:55:59 +09:00
Milan Burda
0c2e2bca92
refactor: don't send ipcRenderer.sendSync() returnValue as an array ( #26178 )
2020-10-28 18:48:20 +03:00
Fabio Spampinato
d4191c4a26
fix: optimized asar paths checks ( #26024 )
...
* fix: optimized asar paths checks
* fix: ensuring the linter is happy
2020-10-26 12:19:35 +09:00
Shelley Vohr
e89abed924
fix: disable use of the vm module in the renderer ( #26087 )
2020-10-23 11:49:52 -07:00
Milan Burda
df1432a315
feat: add net.online / net.isOnline() ( #21004 )
2020-10-20 19:55:06 -07:00
Cheng Zhao
6b6ffbdd10
feat: add support for share menu on macOS ( #25629 )
2020-10-19 18:33:06 -07:00
Milan Burda
321395d96e
refactor: use Map instead of Object for better semantics ( #25982 )
2020-10-19 03:24:51 +03:00
Matt Kane
dfbb88c5f6
fix: pass module resolution paths to wrapped function ( #25891 )
2020-10-14 10:13:45 -07:00
Milan Burda
2c68bad631
refactor: create IPC_MESSAGES enum for IPC message channels ( #25694 )
2020-10-14 00:11:06 +03:00
David Sanders
b194030a34
chore: cleanup some typos in comments ( #25770 )
2020-10-13 10:25:21 -07:00
Milan Burda
f827acc3be
chore: convert guest-view-manager.js to TypeScript ( #25825 )
2020-10-13 04:29:08 +03:00
Milan Burda
83bb065b4f
refactor: wrap Object.prototype.hasOwnProperty.call ( #25834 )
2020-10-10 03:45:08 +03:00
Jeremy Rose
b8f414f4da
feat: hide electron links in default help menu when packaged ( #25831 )
2020-10-09 13:42:44 -07:00
Samuel Maddock
704d69a8f9
feat: add webFrameMain API to the main process ( #25464 )
2020-10-09 09:50:46 -07:00
Milan Burda
fb11a12d5b
refactor: replace a few any-s with proper types ( #25681 )
2020-10-08 03:01:23 +02:00
Milan Burda
db911f29ad
refactor: remove duplicate <webview> event list ( #25697 )
2020-10-06 15:11:26 +02:00
Milan Burda
b33f22601e
refactor: check ELECTRON_ENABLE_LOGGING via native implementation ( #25623 )
2020-10-06 09:58:31 +09:00
Keeley Hammond
6356cd4018
fix: allow ClientRequest responses to be throttled ( #25531 )
...
* fix: allow net streams to be throttled [WIP]
* fix: handle resume throttling within IncomingMessage [WIP]
* fix: fix urlLoader typing, add throttle test
* fix: fix lint and increase test timeout for Linux
* fix: increase test chunk limit to 20 and timeout to 2000
Co-authored-by: Jeremy Rose <nornagon@nornagon.net>
2020-10-06 09:47:41 +09:00
Cheng Zhao
57dc170e81
fix: no more need to hijack process.stdout on Win32 ( #25765 )
2020-10-05 10:10:38 -07:00
Milan Burda
e1a19d735e
chore: convert guest-window-manager.js to TypeScript ( #25709 )
2020-10-02 20:18:42 +02:00