Commit graph

556 commits

Author SHA1 Message Date
Cheng Zhao
940d77b9a0 Fix typos and adjust sentences 2017-03-20 12:52:46 -07:00
Cheng Zhao
033aa16e04 test: Node integration in web workers 2017-03-20 12:52:46 -07:00
Cheng Zhao
a49af26e39 Add nodeIntegrationInWorker option 2017-03-20 12:52:46 -07:00
Cheng Zhao
e496e18f6e Make Archive thread safe 2017-03-20 12:52:46 -07:00
Cheng Zhao
c068285ff8 AtomBindings should not use default uv loop 2017-03-20 12:52:46 -07:00
Cheng Zhao
9c9c8ec5f1 WebWorkerObserver should be destroyed on exit 2017-03-20 12:52:46 -07:00
Cheng Zhao
d2f185bea5 Create new uv loop in each worker 2017-03-20 12:52:46 -07:00
Cheng Zhao
b467c3939e Add a new type of NodeBindings 2017-03-20 12:52:45 -07:00
Cheng Zhao
2cbdb6bac3 Wrap ContextCreated with context scope 2017-03-20 12:52:45 -07:00
Cheng Zhao
e017e157ba Insert node integrations into WebWorker 2017-03-20 12:52:45 -07:00
Thiago de Arruda
a6e4867111 Handle Buffer deserialization in sandboxed renderers
In sandboxed renderers we use browserify to provide a node-like environment. The
Buffer class used by browserify is actually just a wrapper around Uint8Array,
but to deserialize Buffer correctly we must expose the class as a hidden value
and use it in V8ValueConverter.
2017-03-16 13:20:09 -03:00
deepak1556
a4400dc549 add basic spec 2017-03-14 00:26:27 +05:30
deepak1556
e767c59da2 enable pdf plugin by default 2017-03-14 00:26:27 +05:30
deepak1556
fdd574cea5 browser: implement pdf renderer as webui 2017-03-14 00:25:59 +05:30
deepak1556
4281c73cf2 renderer: reset plugin cache when render frame is created 2017-03-12 00:53:39 +05:30
Thiago de Arruda
cd05834d96 Refactor sandboxed renderer init scripts
This change gives sandboxed renderer scripts a similar structure to what already
exists in the lib/{browser,renderer,common} directories.

It also allows sandboxed renderer initialization to share more code with
non-sandboxed renderers (ipcRenderer is now imported directly from
lib/renderer/api/ipc-renderer).
2017-03-09 20:39:14 -03:00
Thiago de Arruda
d78f3cae7b Expose builtin v8 modules to AtomSandboxedRendererClient
- Adapt node.cc code that implements `process.binding` to create a similar
  object in AtomSandboxedRendererClient.
- Replace the ipc binding object passed to `lib/sandboxed_renderer/init.js` by
  the new binding object.
- Refactor the initialization script to use this new object to fetch the ipc
  binding and store as a hidden value using the `v8_util` module.

This change also required applying a patch to node.js, so the submodule commit
was updated.
2017-03-09 20:39:14 -03:00
Cheng Zhao
aaa8e81cd4 Merge pull request #8811 from electron/clean-node-on-exit
Clean up node Environment on exit
2017-03-06 20:36:59 +09:00
Kevin Sawicki
7fb77ee1cb Set isolated world security origin 2017-03-02 08:49:18 -08:00
Cheng Zhao
1709e74958 Fix crash when the main frame is replaced 2017-03-02 17:19:00 +09:00
Cheng Zhao
24574f7299 Avoid touch an Environemnt after it gets destroyed 2017-03-02 17:19:00 +09:00
Cheng Zhao
29278e500b Destroy node environment when a JS context in renderer is destroyed 2017-03-02 17:19:00 +09:00
deepak1556
7a0aff2bae code cleanup 2017-02-12 01:48:24 +05:30
deepak1556
e3fe3cc490 map webframe zoom api to use HostZoomMap 2017-02-12 00:49:17 +05:30
deepak1556
07794a58aa use zoom factor webpreference option when required.
* When setzoomlevel is not called for the host.
* When there is no zoom preference for the host.
2017-02-12 00:49:17 +05:30
Cheng Zhao
81784827ff PrintWebViewHelper is attached to RenderFrame 2017-02-06 10:34:29 -08:00
Cheng Zhao
6d5339b74e insertText is deprecated 2017-02-06 10:34:29 -08:00
Kevin Sawicki
c374e37cc4 Leak IsolateData since Environment is also leaked 2017-01-19 09:05:59 +02:00
Kevin Sawicki
54e2c480cb Upgrade to node 7.4 2017-01-19 09:05:59 +02:00
Kevin Sawicki
602db2e04f 🎨 2017-01-19 09:05:59 +02:00
Kevin Sawicki
d6eb0d6629 Implement insertCSS on webFrame 2017-01-19 09:05:59 +02:00
Cheng Zhao
497f5a1199 Update files for Chrome 54 API changes 2017-01-19 09:05:59 +02:00
Kevin Sawicki
9ccc78c62f Use options constants for keys 2017-01-16 13:09:38 -08:00
Kevin Sawicki
b26428c43c 🎨 2017-01-16 12:38:16 -08:00
Kevin Sawicki
815cb1b31c Include atom_natives after builtin includes 2017-01-16 12:38:16 -08:00
Kevin Sawicki
dcf9a395c2 Only create isolated context in main frame 2017-01-16 12:38:16 -08:00
Kevin Sawicki
2e62d81c24 Access getter instead of variable 2017-01-16 12:38:16 -08:00
Kevin Sawicki
f35224b0e4 🎨 2017-01-16 12:38:16 -08:00
Kevin Sawicki
3f7b3c4bd7 Implement window overrides in main context 2017-01-16 12:38:16 -08:00
Kevin Sawicki
eef72647b4 Set human readable context name 2017-01-16 12:38:16 -08:00
Kevin Sawicki
ad3b837ad5 Rename option to contextIsolation 2017-01-16 12:38:16 -08:00
Kevin Sawicki
b56bdc83af 🎨 2017-01-16 12:38:16 -08:00
Kevin Sawicki
2e7dbe6c6b Use patch worldScriptContext to get isolated context 2017-01-16 12:38:16 -08:00
Kevin Sawicki
4f5c725dde 🎨 Use enum for world ids 2017-01-16 12:38:16 -08:00
Kevin Sawicki
5b6397aaa6 Store context that API is running in to deliver IPC events 2017-01-16 12:38:16 -08:00
Kevin Sawicki
5da4f032c3 Notify client each time main context is created 2017-01-16 12:38:16 -08:00
Kevin Sawicki
c5e68ec165 🎨 2017-01-16 12:38:16 -08:00
Kevin Sawicki
78e0b80dc7 Support IPC messages in isolated context 2017-01-16 12:38:16 -08:00
Kevin Sawicki
073d8c2177 Add world id constants 2017-01-16 12:38:16 -08:00
Kevin Sawicki
d194a84ae4 Setup isolated context from AtomRenderFrameObserver 2017-01-16 12:38:16 -08:00