Commit graph

2297 commits

Author SHA1 Message Date
Jeremy Apthorp
fd8b9450ee
test: untangle a chromium-spec test (#16456) 2019-01-22 13:26:32 -08:00
Samuel Attard
f3e30c7ae3
Merge remote-tracking branch 'origin/chromium-upgrade/72' 2019-01-22 12:01:18 -08:00
Samuel Attard
0b85fb7ea2
Revert "feat: upgrade to Chromium 72.0.3626.52 (#16334)"
This reverts commit 1918e76913.
2019-01-22 12:01:04 -08:00
Samuel Attard
58a6fe13d6
feat: preloads and nodeIntegration in iframes (#16425)
* feat: add support for node / preloads in subframes

This feature has delibrately been built / implemented in such a way
that it has minimum impact on existing apps / code-paths.
Without enabling the new "nodeSupportInSubFrames" option basically none of this
new code will be hit.

The things that I believe need extra scrutiny are:

* Introduction of `event.reply` for IPC events and usage of `event.reply` instead of `event.sender.send()`
* Usage of `node::FreeEnvironment(env)` when the new option is enabled in order to avoid memory leaks.  I have tested this quite a bit and haven't managed to cause a crash but it is still feature flagged behind the "nodeSupportInSubFrames" flag to avoid potential impact.

Closes #10569
Closes #10401
Closes #11868
Closes #12505
Closes #14035

* feat: add support preloads in subframes for sandboxed renderers

* spec: add tests for new nodeSupportInSubFrames option

* spec: fix specs for .reply and ._replyInternal for internal messages

* chore: revert change to use flag instead of environment set size

* chore: clean up subframe impl

* chore: apply suggestions from code review

Co-Authored-By: MarshallOfSound <samuel.r.attard@gmail.com>

* chore: clean up reply usage

* chore: fix TS docs generation

* chore: cleanup after rebase

* chore: rename wrap to add in event fns
2019-01-22 11:24:46 -08:00
Jeremy Apthorp
92b9525cfd
feat: enable mixed-sandbox mode by default (#15894) 2019-01-22 10:44:28 -08:00
Jeremy Apthorp
1918e76913 feat: upgrade to Chromium 72.0.3626.52 (#16334) 2019-01-22 10:39:32 -08:00
Jeremy Apthorp
8c1b5311fd robustify async webview test 2019-01-22 10:32:06 -08:00
deepak1556
d2c0f9f754 Implicitly bypass localhost when proxying requests.
https://chromium-review.googlesource.com/c/chromium/src/+/1303626
2019-01-22 10:32:06 -08:00
Jeremy Apthorp
ded316cd5e wait for window to be focused in openDevTools test 2019-01-22 10:32:06 -08:00
Jeremy Apthorp
8fa33ba120 disable visibilitychange tests as the functionality is broken upstream
https://crbug.com/920839
2019-01-22 10:32:06 -08:00
Milan Burda
6cba2c50a2 feat: make ipc-message and ipc-message-sync events public (#16468) 2019-01-22 08:47:58 -08:00
Milan Burda
b965e54efc fix: <webview> not working with contextIsolation + sandbox (#16469) 2019-01-22 10:08:16 +09:00
Shelley Vohr
3ca87d205f
feat: make zoomLevel/zoomFactor sync (#16410)
* feat: make zoomLevel/zoomFactor sync

* update ts defs dep
2019-01-20 23:40:27 -08:00
Shelley Vohr
441c9ce376
feat: promisify desktopCapturer.getSources (#16427)
* feat: promisify desktopCapturer.getSources

* fix doc

* fix docs lint error
2019-01-18 15:29:32 -08:00
Milan Burda
7d4a1223fd feat: add preload-error event to webContents (#16411) 2019-01-18 12:03:43 +01:00
Shelley Vohr
f105c84349
test: ensure legacy callback functions work (#16436)
* test: test legacy callback functions

* add TODO removal comments

* fix callback spec
2019-01-17 14:17:16 -08:00
Shelley Vohr
1f2b02c18f
feat: promisify protocol.isProtocolHandled() (#16423)
* feat: promisify protocol

* fix base::Bind and specs

* update documentation

* make callback-compatible

* async awaitify tests
2019-01-17 09:05:10 -08:00
Milan Burda
23d44e322d feat: use default-app behavior in packaged apps (#16310)
Unify the behavior between default app and packaged apps:
- create default application menu unless the app has one
- default window-all-closed handling unless the app handles the event
2019-01-15 21:35:53 +01:00
Shelley Vohr
0881fd6397
feat: split openExternal into sync and async (#16176)
* feat: split openExternal into sync and async

* v8::Locker => mate::Locker

* fix: enter js env when resolving promise
2019-01-14 20:35:21 -08:00
Milan Burda
52e257668d fix: windowmenu did not show the window list on macOS (#16387) 2019-01-14 17:27:52 +01:00
Alex Garbutt
dcb670fa46 fix: emit IPC event in correct context if isolation and sandbox enabled (#16352)
* fix: emit IPC event in correct context if isolation and sandbox enabled

IPC events were not being delivered to renderer processes when both
`contextIsolation` and `sandbox` were enabled. This is because the
`AtomSandboxedRenderFrameObserver` class was incorrectly using the
`MainWorldScriptContext`, rather than conditionally selecting the
context based on if isolation was enabled.

Fixes #11922
2019-01-12 14:19:20 +01:00
Robo
52fe92d02e feat: Upgrade to Chromium 71.0.3578.98 (#15966) 2019-01-11 17:00:43 -08:00
Alexey Kuzmin
3cb9aadb80 build: fix the build with enable_run_as_node disabled (#15711) 2019-01-11 08:02:06 -08:00
Shelley Vohr
ca218b6395
test: allow retries for flaky mas loginitem specs (#16347) 2019-01-10 14:15:47 -08:00
Milan Burda
eb02a422de feat: add fileMenu / viewMenu / appMenu roles (#16328) 2019-01-10 14:32:03 +01:00
Milan Burda
349a3c20ae feat: add additional remote APIs filtering (#16293) 2019-01-08 14:27:56 -08:00
Shelley Vohr
434f1368a0
test: add specs to version bump utils (#16315) 2019-01-08 12:04:27 -08:00
Milan Burda
fade3eb679 chore: make "nodeIntegration" and "webviewTag" default to false (#16235) 2019-01-07 22:19:27 +03:00
Milan Burda
6f117b8e0c feat: add app.commandLine.hasSwitch() / app.commandLine.getSwitchValue() (#16282)
* feat: add app.commandLine.hasSwitch() / app.commandLine.getSwitchValue()

* add more tests

* refactor: move appendSwitch / appendArgument to command_line module

* replace AppendSwitchASCII with AppendSwitchNative

* remove castArgs
2019-01-07 07:48:27 -08:00
Milan Burda
3f1d22759a refactor: use helpers for command-line parsing in renderer/init.js (#16239) 2019-01-03 11:22:34 -05:00
Vladimir
5ae3d1a1b2 feat: add multi BrowserView support to BrowserWindow (#16148)
* feat: add multi BrowserView support to BrowserWindow

Add functions addBrowserView, removeBroserView, getBrowserViews to
BrowserWindow class. Existing API as setBrowserView and
getBrowserView code replaced to use new api inside.

* fix: for lint and osx compile errors

* fix: lint error in test code

* feat: add multi BrowserView support to BrowserWindow

Add functions addBrowserView, removeBroserView, getBrowserViews to
BrowserWindow class. Existing API as setBrowserView and
getBrowserView code replaced to use new api inside.

* fix: for lint and osx compile errors

* fix: lint error in test code

* fix: method to be accessible on mac api impl

* fix: missed function declarations for mac impl

* fix: use base class reset function
2018-12-22 10:49:26 +09:00
Zac Walker
51cfb5cff1 fix: extend tracing startRecording API to take a full tracing config (#13914)
This allows memory-infra to be traced correctly.
Fixes #12506.
2018-12-20 15:11:17 +03:00
Cheng Zhao
4ff7976060
fix: add missing require in chromium-spec (#16153) 2018-12-20 16:58:46 +09:00
Milan Burda
547097b036 security: allow to block desktopCapturer.getSources() calls (#15964)
* security: allow to block desktopCapturer.getSources() calls

* return empty instead of error

* fix: release resources of DesktopCapturer on exit
2018-12-20 11:44:30 +09:00
Pedro Pontes
9c783f53ba fix: do not allow the window to grab focus when tabbing / shift+tabbing (#16042)
* fix: do not allow the window to grab focus when tabbing / shift+tabbing

* test: add tests.
2018-12-18 23:44:51 -07:00
Jeremy Apthorp
ed3e5739dc test: promisify a bunch of tests (#16051)
* test: promisify a bunch of tests

* fix lint

* fix affinity tests

* more cowbell^Wawait

* less done
2018-12-18 23:44:03 -07:00
David Baker
cc85946f55 feat: Support response headers in File protocol handler (#16098)
* feat: Support response headers in File protocol handler

* bugfix: Null check headers value & fix tests

* refactor: Use non-deprecated FindKeyOfType
2018-12-18 23:17:02 -07:00
Alex Greenland
dc93d94bc8 fix: support async child process methods without callback in asar (#15927)
* fix: support async child process methods without callback in asar

* fix: support async child process methods without callback in asar (improved)
2018-12-18 16:27:39 +09:00
Cheng Zhao
8584c2f14b
fix: register webview in main world when using contextIsolation (#16067) 2018-12-14 15:38:35 +09:00
Simone Cattaneo
649633bbb7 fix: make 'setParentWindow' compatible under Windows (#15775) 2018-12-12 16:05:16 -08:00
Jeremy Apthorp
1152fecb75
test: fix flaky before-input-event test (#16027) 2018-12-11 17:01:48 -08:00
Cheng Zhao
624ade2c25 fix: return pointer instead of pointer's content (#16014) 2018-12-11 12:45:55 -05:00
Shelley Vohr
163361ee6a chore: disable bump-version on arm32 (#15994) 2018-12-10 10:57:44 -08:00
Shelley Vohr
4b18a38e9f
chore: simplify promisify helper (#15952)
chore: simplify promisify helper
2018-12-10 08:13:09 -08:00
Jeremy Apthorp
442c1b22e3
feat: webContents.loadURL returns a promise (#15855) 2018-12-06 12:16:19 -08:00
Shelley Vohr
1b8c11121f
chore: convert bump script to js (#15820) 2018-12-06 11:00:10 -08:00
Jeremy Apthorp
2845267c18
feat: support mixed-sandbox mode on linux (#15870) 2018-12-05 17:42:12 -08:00
Shelley Vohr
3f15f51615
feat: promisify app.getFileIcon() (#15742) 2018-12-05 08:50:12 -08:00
Milan Burda
d561c5531b feat: deprecate modules internally using remote.require in sandboxed renderer context (#15145) 2018-12-05 10:34:09 +01:00
Pedro Pontes
d5d1fa8290 fix: use appropriate site instance for cross-site nav's (#15821)
* fix: use Chromium's determined new site instance as candidate when navigating.

When navigating to a new address, consider using Chromium's determined site instance
for the new page as it should belong to an existing browsing instance when the
navigation was triggered by window.open().

fixes 8100.

* Revert "fix: use Chromium's determined new site instance as candidate when navigating."

This reverts commit eb95f935654a2c4d4457821297670836c10fdfd5.

* fix: delegate site instance creation back to content when sandboxed.

* fix: ensure site isolation is on

* test: adapt ut for cross-site navigation

* fix: register pending processes during a navigation.

* refactor: dont call loadURL for a window constructed from an existing webContents.

* test: add sandboxed affinity UT's.

* fix: check affinity before deciding if to force a new site instance.

* chore: adapt subsequent patch.

* refactor: constify logically const methods.

* fix: do not reuse site instances when navigation redirects cross-site.

* test: ensure localStorage accessible after x-site redirect.

* test: adapt localStorage acess denied UT for site isolation.

* fix: do not send render-view-deleted for speculative frames.

* chore: amend tests after rebase.

* test: add ut for webContents' render-view-deleted emission

* fix: introduce current-render-view-deleted for current RVH's deletions.

Revert render-view-deleted to being emitted with any RVH's deletion.
current-render-view-deleted is emitted only when the RVH being deleted
is the current one.

* refactor: style and comments fixed.
2018-12-05 17:03:39 +09:00