Commit graph

55 commits

Author SHA1 Message Date
Samuel Attard
682f78b9a8
test: add more auto updater tests for squirrel.mac (#24611) 2020-07-20 09:51:33 -07:00
Jeremy Rose
9bd0fc5348
refactor: ginify BrowserView (#23578) 2020-07-09 08:48:39 -07:00
Samuel Attard
ad16e6c647
build: update linting deps (#24461) 2020-07-08 21:19:49 -07:00
Jeremy Rose
1f23807271
chore: tsify web-contents (#24325) 2020-07-06 10:50:03 -07:00
Robo
d330c6f9fe
feat: expose sessionId in debugger module (#24170) 2020-07-02 13:04:20 -07:00
Eryk Rakowski
04be1ac4a1
fix: assign session to remote webContents (#23989)
* fix: assign session to remote webContents

* fix: test name
2020-06-11 12:57:51 +09:00
Charles Kerr
980e592271
chore: ensure release notes always come from Clerk (#23777)
* chore: ensure release notes always come from Clerk

Now with tests!

* chore: move sinon devDependency into `spec-main`

* refactor: tweak note-spec variable for readability
2020-06-08 11:39:44 -07:00
Cheng Zhao
5de6adfb84
test: load page with some content when testing extension (#23901)
* test: load page with some content when testing extension

* test: use dom-ready to wait for page loaded with extension
2020-06-03 16:56:28 +09:00
Cheng Zhao
5918dd6e65
test: wait for beforeunload handler to be installed (#23874) 2020-06-02 11:32:39 +09:00
Electron Bot
a4de915b74
chore: bump chromium to d66c2e32380bf5d1eb5e1fe37faef (master) (#23791)
* chore: bump chromium in DEPS to db7d7b3e7cb2bc925f2abfde526280cfdfc21a41

* Update patches

* chore: bump chromium in DEPS to 5613e1b99a44fcbe22f3910f803ca76903a77ec1

* Update patches

* Network service: Remove primary_network_context bool.

https://chromium-review.googlesource.com/c/chromium/src/+/2204678

* WebContentsObserver now implements OnRendererResponsive

https://chromium-review.googlesource.com/c/chromium/src/+/2211066

* update patches

* Fixup printing patch

* chore: bump chromium in DEPS to e387b972cdd7160c416fa6c64a724e2258aa0218

* update patches

* [printing] Move PrintHostMsg_DidPrintContent_Params to print.mojom

https://chromium-review.googlesource.com/c/chromium/src/+/2212110

* [XProto] Move items from ::x11::XProto to ::x11

https://chromium-review.googlesource.com/c/chromium/src/+/2218476

* revert Add IChromeAccessible

This was added in https://chromium-review.googlesource.com/c/chromium/src/+/2206224 but it breaks WOA builds because third_party/win_build_output/midl/ui/accessibility/platform/arm64 does not exist. The link above says that the new interface is behind a feature flag which is disabled by default so it is safe to remove for now.

* rebaseline ichromeaccessible for Windows arm64

This patch will not be needed once we get the next roll.

* Update to 1b9e01844e8bf1aaafc4a52c0c62af7f56d9637b to get arm64 fix

* update patches

* chore: bump chromium in DEPS to 096aefa04092ea00f7b68d8d19345883f20db3c3

* chore: bump chromium in DEPS to a524a45ffd1d6fd46a7a86138fe2b22df5b6651a

* chore: update patches

* Window Placement: Gate cross-screen fullscreen behavior on permission

https://chromium-review.googlesource.com/c/chromium/src/+/2203268

* chore: add spec for https://crbug.com/1085836

* chore: bump chromium in DEPS to ff6c4f4b826d66c2e32380bf5d1eb5e1fe37faef

* update patches

Co-authored-by: John Kleinschmidt <jkleinsc@github.com>
Co-authored-by: Electron Bot <anonymous@electronjs.org>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2020-06-01 16:34:34 -04:00
Electron Bot
dc72f74020
chore: bump chromium to 580fe983e138952553cd6af11ee8b (master) (#23379)
* chore: bump chromium in DEPS to 5ce64b91b4d6a78c97480059f15ff6469fc0918e

* chore: bump chromium in DEPS to e74c73d0000f81b3f40a513176c8d024bba57d28

* chore: bump chromium in DEPS to 501640e650d4657ba63db65fa257e4a899168de7

* chore: bump chromium in DEPS to 00db20e1bc3d77706723a87ada3c1c647a1c37b7

* chore: update patches

* refactor: AddNewContents now takes a target_url

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2167732

* chore: SetHostCleanupFinalizationGroupCallback has been removed from V8

* refactor: use WebInputEvent::Namespace types directly

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2160523

* refactor: FollowRedirect takes in cors exempt headers now

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2129787

* refactor: printing::DuplexMode moved to mojo

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2162388

* refactor: use MessagePortDescriptor instead of raw mojo::MessagePipeHandles

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/1952124

* chore: update patches

* chore: bump chromium in DEPS to f1537676d613f3567cfb43adf577b3847fba4bc3

* chore: update patches

* refactor: service_manager::BinderMapWithContext merged into mojo::BinderMap

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2174654

* chore: unused argument removed from ReadAvailableTypes in ui::Clipboard

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2173666

* chore: bump chromium in DEPS to 949888433ab935dd6125c107226a4c9d6da9bf48

* chore: update patches

* update patches

* chore: update sysroots

* chore: bump chromium in DEPS to eaac5b5035fe189b6706e1637122e37134206059

* chore: bump chromium in DEPS to 258b54b903d33dab963adf59016691e6537f8b70

* build: update patches

* refactor: cursor.mojom and cursor_types.mojom moved to //ui/base/cursor/mojom

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2172874

* chore: DesktopWindowTreeHostLinux becomes DesktopWindowTreeHostPlatform

Refs:

* refactor: LogErrorEventDescription moved from ui to x11

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2164245

* chore: update patches

* chore: bump chromium in DEPS to bd06abcfe807d4461683479237cdd920dafa52ca

* chore: bump chromium in DEPS to 1afb0891e56f1e79d204db43ca053a46d0974511

* chore: bump chromium in DEPS to 5cb0f794bf7f155bf8c0a241b94e01c9d90c2744

* chore: bump chromium in DEPS to 37327ba3303234e1a3cd3310ca11a68e81b95123

* update patches

* remove ClientSideDetectionService from browser_process

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2175320

* refactor: shuttle cursor changed event to WebContentsObserver

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2172779

* chore: bump chromium in DEPS to 1d97904bb6936e106df13705208b73e47367c2b9

* avoid IPC crash introduced earlier in the roll

Refs: b67334e781 (diff-607f4e8f7c5686aa09af98c783925babR128)

* remove WebContentsView::SizeContents

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2188931

* chore: bump chromium in DEPS to 87066d1db0546a9de33952ba964e1e42f76f1dae

* update patches

* adapt to //content creating NetworkContexts

https://chromium-review.googlesource.com/c/chromium/src/+/2195196

* WIP temporarily ignore mojo-ified PrintHostMsg_PrintPreviewFailed

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2195343

* add checkout_pgo_profiles to DEPS

* chore: bump chromium in DEPS to a095318bec1dedf580d676f408eaeefdbd9956b1

* add blink's execution_context to electron_lib deps

Refs:
b67334e781#, https://chromium-review.googlesource.com/c/chromium/src/+/1952124

* update patches

* update patches

* refactor: use newly mojo-ified PrintPreviewFailed

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2195343
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* chore: update patches

* chore: remove NOTIFICATION_EXTENSIONS_READY_DEPRECATED

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2199874

* avoid a call to Profile::FromBrowserContext in printing

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2195757

* chore: bump chromium in DEPS to 8f5c6a46861a991e12ffd80554b6bd41a11b0b65

* chore: bump chromium in DEPS to ab66134739ff3b6bdb8de53bbc58a97d1b7b5d8a

* chore: bump chromium in DEPS to dd08df9f6c8d6198f0a7b931ca9e845e27dae033

* chore: update patches

* [printing] Mojofy PrintHostMsg_PrintPreviewCancelled

https://chromium-review.googlesource.com/c/chromium/src/+/2198331

* [printing] Mojofy PrintHostMsg_PrintPreviewInvalidPrinterSettings

https://chromium-review.googlesource.com/c/chromium/src/+/2200556

* [printing] Mojofy PrintHostMsg_DidPrepareDocumentForPreview

https://chromium-review.googlesource.com/c/chromium/src/+/2201496

* fix: inherit base network context params

* fix: use message handle api specific to embedders

* update patches

* chore: update v8 headers

* fixup! avoid a call to Profile::FromBrowserContext in printing

* chore: bump chromium in DEPS to f198bc3276828d992b6202d75a9da6a8363164ea

* chore: update patches

* Remove cors_exempt_headers.h

https://chromium-review.googlesource.com/c/chromium/src/+/2203759

* Supply speech recognition sandbox from service_sandbox_type.h

https://chromium-review.googlesource.com/c/chromium/src/+/2206918

* [content] Remove unused methods from WebContents

https://chromium-review.googlesource.com/c/chromium/src/+/2199113

* [XProto] Replace XAtom with x11::Atom

https://chromium-review.googlesource.com/c/chromium/src/+/2202789

* chore: bump chromium in DEPS to 5df37fabaaed09f3ea511f4ef49203d8ebee7b68

* [UI] Support secondary labels in dropdown menus

https://chromium-review.googlesource.com/c/chromium/src/+/2208976

* chore: update patches

* refactor: GetSublabelAt => GetSecondaryLabelAt

* Revert "[printing] Mojofy PrintHostMsg_DidPrepareDocumentForPreview"

This reverts commit 44ed0892a0c81716229638f17253bbb2cf8f037d.

https://chromium-review.googlesource.com/c/chromium/src/+/2208778

* Unnest CanonicalCookie::CookieInclusionStatus

https://chromium-review.googlesource.com/c/chromium/src/+/2203171

* update print-to-pdf.html with latest html data

https://bugs.chromium.org/p/chromium/issues/detail?id=1085667

* chore: bump chromium in DEPS to 5dfa8d5f706580fe983e138952553cd6af11ee8b

* fix crash in x server when setting window icon

* chore: update patches

* Use a normal return value for WebContentsView::GetContainerBounds.

https://chromium-review.googlesource.com/c/chromium/src/+/2212481

* fix build on windows

* chore: bump chromium in DEPS to 9d15054f4cba060901e43deecf74002f11f47be3

* chore: update patches

* [printing] Mojofy PrintHostMsg_CheckForCancel

https://chromium-review.googlesource.com/c/chromium/src/+/2212181

Co-authored-by: Samuel Attard <samuel.r.attard@gmail.com>
Co-authored-by: Electron Bot <anonymous@electronjs.org>
Co-authored-by: Andy Locascio <andy@slack-corp.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2020-05-26 13:06:26 -07:00
Cheng Zhao
08f288faf1
test: use WebContents event to test beforeunload (#23699) 2020-05-26 09:21:38 -04:00
Milan Burda
7656480247
test: remove usage of the remote module from tests (#23571) 2020-05-14 00:33:37 +02:00
Milan Burda
fc468cce3b
test: skip remote module related tests when enable_remote_module = false (#23557) 2020-05-13 20:05:44 +02:00
Samuel Attard
091f45b879
chore: fix linting (#23473) 2020-05-08 11:30:37 -07:00
Samuel Attard
21900fe4f4
fix: do not initialize any extension related logic in OffTheRecord contexts (#22772) 2020-05-08 11:17:28 -07:00
Jeremy Apthorp
06bf0d08dc
fix: crashReporter incompatible with sandbox on Linux (#23265) 2020-05-07 13:31:26 -07:00
Cheng Zhao
cb6a1e2c5e
fix: set default menu in will-finish-launching event (#23214) 2020-04-23 10:51:31 -07:00
Jeremy Apthorp
6fa05dd123
test: refactor crashReporter tests (#23178) 2020-04-22 15:53:12 -07:00
loc
aca2e4f968
refactor: improve feature string parsing (#23130)
* test: add pre-change snapshot of new-window event

* move to .ts file for easier diff

* refactor: improve feature string parsing logic

* test: update snapshots

* update type names per review

* update comma-separated parse test

* use for loop instead of reduce per review

* tighten up types

* avoid variable guest contents id returnValue in test snapshot
2020-04-21 16:23:00 -04:00
loc
a041882192
test: add test for datalist autofills (#23110)
* test: add test for datalist autofills

* address style nits

* move fixture to spec-main
2020-04-21 12:28:31 -07:00
Jeremy Apthorp
2541d62486
chore: remove disable_user_gesture... patch (#23066) 2020-04-16 15:22:39 -07:00
Electron Bot
3e8d77d564
chore: bump chromium to 98ebf6c3f0b7bd96bdb1a4b42208f (master) (#22999)
Co-authored-by: deepak1556 <hop2deep@gmail.com>
Co-authored-by: Electron Bot <anonymous@electronjs.org>
Co-authored-by: Jeremy Apthorp <nornagon@nornagon.net>
2020-04-13 16:39:26 -07:00
Cheng Zhao
ca947307db
chore: make WebContentsView take webPreferences as parameter (#22997)
* chore: add WebContentsView.webContents helper

* chore: no need to handle webContents option

* chore: Create WebContentsView in C++

* chore: make WebContentsView accept web_preferences

* fix: nativeWindowOpen still passes WebContents to BrowserWindow

* chore: no more need of WebContentsViewRelay

* test: WebContentsView now takes options

* fix: avoid creating 2 constructors
2020-04-09 16:01:16 +09:00
Robo
bac1c7f532
fix: ensure standard schemes are registered in nw service process (#22867)
* fix: ensure standard schemes are registered in nw service process

Refs https://github.com/electron/electron/pull/20546

* chore: add test

* chore: apply suggestions from code review

Co-Authored-By: Jeremy Apthorp <jeremya@chromium.org>

Co-authored-by: Jeremy Apthorp <jeremya@chromium.org>
2020-03-31 19:33:16 -07:00
Samuel Attard
5d657dece4
build: enable JS semicolons (#22783) 2020-03-20 13:28:31 -07:00
Cheng Zhao
47e27aee5b
test: no need to loadURL in menu test (#22737) 2020-03-19 10:49:40 +09:00
John Kleinschmidt
0201b3e571
feat(extensions): add chrome.tabs.connect API (#22457)
* feat(extensions): add chrome.tabs.connect API

* test(extensions): verify that chrome.tabs.connect port communication works
2020-03-05 09:59:32 -05:00
John Kleinschmidt
d6701ff435
feat(extensions): add chrome.i18n API (#22455)
* feat(extensions): implement chrome.i18n API

* refactor(extensions): use forward declaration for ScriptExecutor

* fix(extensions): add message filter to handle i18n GetMessageBundle

* test(extensions): add chrome.i18n tests

* fix(extensions): message filter lint error

* fix: remove exclusive test

* fix(extensions): format api feature arrays

Co-Authored-By: Jeremy Apthorp <nornagon@nornagon.net>

* fix(extensions): uncomment chrome.i18n usage in old extensions test

Co-authored-by: Jeremy Apthorp <nornagon@nornagon.net>
2020-03-05 09:56:21 -05:00
Samuel Attard
4323b6d618
chore: add tests for the spellchecker (#22099)
* chore: add tests for the spellchecker

* chore: do not run spellchecker tests on windows
2020-02-26 17:29:19 -08:00
Samuel Attard
e7b0a9ca8f
feat: add API for receiving logs from service workers (#20624)
* feat: add API for receiving logs from service workers

* feat: add new serviceWorkerContext APIs

* chore: add missing #include's

* refactor: rename serviceWorkerContext to serviceWorkers

* chore: clean up based on review

* chore: remove native_mate

* chore: add tests for the service worker module

* Update spec-main/api-service-workers-spec.ts

Co-Authored-By: Jeremy Apthorp <jeremya@chromium.org>

* chore: fix linting

* chore: handle renames

Co-authored-by: Jeremy Apthorp <nornagon@nornagon.net>
2020-02-20 15:19:06 -08:00
Jeremy Apthorp
d590f2efe3
feat: enable pdf viewer (#21794) 2020-02-12 16:39:12 -08:00
Cheng Zhao
c608d6d7fb
fix: make webRequest work with WebSocket (#22040)
* fix: web request support proxying websocket

* fix: make tests work

* chore: do not use api:: code outside api/ folder

* chore: do not create proxy when no listener

* test: use separate session to avoid conflicts

* chore: address review
2020-02-11 14:56:09 +09:00
Jeremy Apthorp
9107157073
feat: [extensions] support extension.getBackgroundPage (#21951)
* feat: [extensions] support extension.getBackgroundPage

* cleanup

* how does c++

* tests

* test for runtime.getBackgroundPage too
2020-02-06 16:42:34 -05:00
Charles Kerr
c83f836faf
refactor: prefer using app.whenReady() (#21972)
* docs: add references to app.whenReady() in isReady

* refactor: prefer app.whenReady()

In the docs, specs, and lib, replace instances of `app.once('ready')`
(seen occasionally) and `app.on('ready')` (extremely common) with
`app.whenReady()`.

It's better to encourage users to use whenReady():
1. it handles the edge case of registering for 'ready' after it's fired
2. it avoids the minor wart of leaving an active listener alive for
an event that wll never fire again
2020-02-03 22:43:22 +00:00
Jeremy Apthorp
a061c87e56
feat: enable native extensions support (#21814) 2020-02-03 14:01:10 -08:00
Shelley Vohr
23382e6e08
test: check actual output generated from printToPDF (#21949) 2020-01-30 20:12:35 +00:00
Jeremy Apthorp
b9eb68c0b4
feat: [extensions] implement a couple of tabs APIs (#21779) 2020-01-15 15:11:51 -08:00
Jeremy Apthorp
55368e4d97
feat: just enough //extensions to load a simple devtools extension (#19515) 2020-01-14 16:20:30 -08:00
Jeremy Apthorp
8bc0c92137
feat: [extensions] background pages (#21591) 2020-01-13 14:55:58 -08:00
Jeremy Apthorp
768a6ace1b
test: move some fixtures from spec/ to spec-main/ (#21403) 2020-01-09 11:50:56 -08:00
Cheng Zhao
f9a1dc10fe
fix: quit after Chromium is fully started (#21488)
* fix: quit when chromium is fully started

* test: remove hacks on app.quit

* chore: RunUntilIdle is unnecessary
2019-12-13 18:57:02 +09:00
Cheng Zhao
3cb0ed306b fix: hiding window menu should work on startup (#21436)
* fix: menu visibility should not be overwritten on startup

* fix: removing menu for window without global menubar

* test: setMenu tests are not for mac
2019-12-09 11:17:36 -08:00
Jeremy Apthorp
7f6b308bf1
test: move remote specs to main process (#21387) 2019-12-09 10:27:30 -08:00
Jeremy Apthorp
26ecf63ab4
test: remove a bunch of usage of the remote module (#21119) 2019-11-14 14:09:03 -08:00
Jeremy Apthorp
ecd9e1f26e
chore: lint spec-main (#20835) 2019-11-01 13:37:02 -07:00
Jeremy Apthorp
baaf058380 test: remove last usages of spec/window-helpers (#20792)
* test: remove last usages of spec/window-helpers

* move fixture
2019-10-29 13:16:42 +09:00
Milan Burda
ba8f80267c fix: send ELECTRON_BROWSER_CONTEXT_RELEASE asynchronously (#20632)
* fix: send ELECTRON_BROWSER_CONTEXT_RELEASE asynchronously

* test: remote references should be able to be cleared for all cases
2019-10-23 13:44:21 +09:00
Samuel Attard
0090616f7b
feat: add a new contextBridge module (#20307)
* feat: add a new contextBridge module

* chore: fix docs linting

* feat: add support for function arguments being proxied

* chore: ensure that contextBridge can only be used when contextIsolation is enabled

* docs: getReverseBinding can be null

* docs: fix broken links in md file

* feat: add support for promises in function parameters

* fix: linting failure for explicit constructor

* Update atom_api_context_bridge.cc

* chore: update docs and API design as per feedback

* refactor: remove reverse bindings and handle GC'able functions across the bridge

* chore: only expose debugGC in testing builds

* fix: do not proxy promises as objects

* spec: add complete spec coverage for contextBridge

* spec: add tests for null/undefined and the anti-overwrite logic

* chore: fix linting

* spec: add complex nested back-and-forth function calling

* fix: expose contextBridge in sandboxed renderers

* refactor: improve security of default_app using the new contextBridge module

* s/bindAPIInMainWorld/exposeInMainWorld

* chore: sorry for this commit, its a big one, I fixed like everything and refactored a lot

* chore: remove PassedValueCache as it is unused now

Values transferred from context A to context B are now cachde in the RenderFramePersistenceStore

* chore: move to anonymous namespace

* refactor: remove PassValueToOtherContextWithCache

* chore: remove commented unused code blocks

* chore: remove .only

* chore: remote commented code

* refactor: extract RenderFramePersistenceStore

* spec: ensure it works with numbered keys

* fix: handle number keys correctly

* fix: sort out the linter

* spec: update default_app asar spec for removed file

* refactor: change signatures to return v8 objects directly rather than the mate dictionary handle

* refactor: use the v8 serializer to support cloneable buffers and other object types

* chore: fix linting

* fix: handle hash collisions with a linked list in the map

* fix: enforce a recursion limit on the context bridge

* chore: fix linting

* chore: remove TODO

* chore: adapt for PR feedback

* chore: remove .only

* chore: clean up docs and clean up the proxy map when objects are released

* chore: ensure we cache object values that are cloned through the V8 serializer
2019-10-18 12:57:09 -07:00
Jeremy Apthorp
8de925c4c2
test: move module tests to main process (#20419) 2019-10-09 16:33:15 -07:00