Commit Graph

1668 Commits

Author SHA1 Message Date
Samuel Attard
0d2e967960 feat: expose electron/{process} typed modules (#22937)
* feat: expose electron/{process} typed modules

* chore: update imports for common modules

* chore: update typescript generator

* chore: remap electron/* to the internal packages
2020-04-06 17:04:09 -07:00
Jeremy Apthorp
0a78ab4b98 refactor: ginify DownloadItem (#22924) 2020-04-02 17:22:46 -07:00
Jeremy Apthorp
6159066c26 refactor: ginify Menu (#22916) 2020-04-02 16:07:56 -07:00
Shelley Vohr
da67cbf551 feat: add property support for remainder of BrowserWindow (#22771)
Adds property-based support for the remainder of primitive gette/setter pairs on `BrowserWindow`.

Namely:
- `win.simpleFullScreen`
- `win.title`
- `win.visibleOnAllWorkspaces`
- `win.documentEdited`
- `win.representedFilename`
- `win.shadow`
- `win.kiosk`
- `win.menuBarVisible`
2020-04-01 08:22:32 -07:00
Cheng Zhao
d74ad631e7 chore: there is no need to define _init (#22882) 2020-03-31 14:50:03 -07:00
Jeremy Apthorp
765c08c600 refactor: ginify Notification (#22821) 2020-03-31 11:42:32 -07:00
Jeremy Apthorp
a3e28788ce refactor: ginify Tray (#22822)
* refactor: ginify Tray

* lint

* improve argument parsing logic

* remove redundant imports from tray.js

* new Tray produces an instanceof Tray

* make Constructible generic

* lint

* clean up on exit
2020-03-30 10:32:02 +09:00
Cheng Zhao
76ae3b7ecb chore: remove unused classes of views API (#22861)
* chore: remove unused views API classes

* chore: remove LayoutManager code

* chore: no more need to make View inherit from TrackabeObject

* chore: make enable_view_api default to true

* chore: enable_view_api => enable_views_api
2020-03-28 15:44:57 +09:00
Heilig Benedek
74372d65ae feat: enhance native window.open to match the custom implementation's behavior (#19703)
Co-authored-by: Andy Locascio <andy@slack-corp.com>
2020-03-26 11:05:45 -07:00
Jeremy Apthorp
e73d5e3db5 refactor: ginify protocol (#22812) 2020-03-26 10:34:32 -07:00
Jeremy Apthorp
222022556f refactor: ginify Cookies (#22823) 2020-03-25 15:34:53 -07:00
Jeremy Apthorp
b327478cf0 fix: prevent remote from messing with constructor names (#22820) 2020-03-25 13:13:10 -07:00
Jeremy Apthorp
07cd70a37e refactor: ginify powerMonitor (#22751) 2020-03-24 09:03:29 -07:00
Samuel Attard
6b41d86032 Revert "fix: better window hierarchy checks"
This reverts commit 8e368a046d.
2020-03-23 19:34:52 -07:00
Samuel Attard
8e368a046d fix: better window hierarchy checks 2020-03-23 14:13:12 -07:00
Jeremy Apthorp
decbca734f refactor: ginify net.request (#22779) 2020-03-23 13:09:45 -07:00
Cheng Zhao
341f643b81 feat: add ImageView (#22738) 2020-03-22 19:11:43 +09:00
Samuel Attard
60bd52880f feat: add support for net requests to use the session cookie store (#22704) 2020-03-20 15:56:02 -07:00
Jeremy Apthorp
22c17bcc5b refactor: ginify ServiceWorkerContext (#22756) 2020-03-20 14:15:14 -07:00
Samuel Attard
5d657dece4 build: enable JS semicolons (#22783) 2020-03-20 13:28:31 -07:00
Samuel Attard
b87b501161 build: update eslint + eslint plugins (#22777)
* build: run eslint --fix

* chore: manually fix all hasOwnProperty errors

* chore: manually fix all void 0 vs undefined errors

* chore: manually fix all async-in-promise errors

* chore: manually fix lexical declaration in case block
2020-03-20 11:12:18 -04:00
Samuel Attard
aa15a2cc03 build: update typescript and webpack (#22776) 2020-03-19 16:55:49 -07:00
Jeremy Apthorp
a824e12275 refactor: ginify desktopCapturer (#22746) 2020-03-19 11:35:11 -07:00
Jeremy Apthorp
c4a7eade28 refactor: ginify session.netLog (#22732) 2020-03-18 16:46:05 -07:00
Jeremy Apthorp
232ca8af39 refactor: EventEmitters without gin_helper (#22726) 2020-03-18 12:57:08 -07:00
Shelley Vohr
fc661ec56b chore: update app module property support (#22713) 2020-03-18 10:06:41 -07:00
Shelley Vohr
674e4a9fdd chore: more modules to dual prop/fn support (#22688) 2020-03-17 18:06:52 -07:00
Samuel Attard
5e4e50c5eb fix: remove bad usages of for-in and guard against it (#22616)
* fix: remove bad usages of for-in and guard against it

* Apply suggestions from code review

Co-Authored-By: Samuel Maddock <samuel.maddock@gmail.com>

* Apply suggestions from code review

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

* Update remote.js

Co-authored-by: Samuel Maddock <samuel.maddock@gmail.com>
Co-authored-by: Jeremy Apthorp <jeremya@chromium.org>
2020-03-17 13:17:55 -07:00
Shelley Vohr
97d8caa1e0 chore: support props/fns for BrowserWindow (#22686) 2020-03-16 14:03:35 -07:00
Shelley Vohr
1b353d1ed3 chore: revert deprecated WebContents properties (#22640)
* chore: revert deprecated WebContents properties

* Fix failing zoomFactor test
2020-03-13 10:16:08 -07:00
Jeremy Apthorp
b4d07f76d3 feat: MessagePorts in the main process (#22404) 2020-03-11 18:07:54 -07:00
Shelley Vohr
efc11563e8 fix: properly forward properties to webview (#22485) 2020-03-03 22:25:14 +00:00
Erick Zhao
85ef762269 fix: guard against duplicate TouchBarItem IDs (#22272)
* feat: Add OtherItemsProxy touchbar item

* review!

* fix: guard against duplicate TouchBarItem IDs

* add spec
2020-02-26 22:12:56 +00:00
Samuel Attard
12c1d4411d chore: add deprecation warning on setting app.allowRendererProcessReuse to false (#22337)
* chore: add deprecation warning on setting app.allowRendererProcessReuse to false

* fix: no deprecation warnings in process reuse spec

* chore: add test for new deprecate removeProperty behavior
2020-02-26 14:03:52 -08:00
Samuel Attard
360c1cad1b chore: do not override history methods when rendererprocessreuse is enabled (#22335) 2020-02-24 12:14:11 -08:00
Erick Zhao
1848e3f658 feat: Add OtherItemsProxy TouchBar item (#22270)
* feat: Add OtherItemsProxy touchbar item

* review!
2020-02-24 17:55:06 +09:00
Syed Umair
e965703e62 fix: typo in crash reporter constructor (#22274) 2020-02-21 16:32:45 +00: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
602913cb4c chore: rename node bindings atom => electron (#22176) 2020-02-14 06:25:39 -05:00
Shelley Vohr
5e7c594691 fix: no-arg console.log is undefined (#22165) 2020-02-12 09:25:11 -08:00
Cheng Zhao
9ad6f06831 fix: remove cyclic references of BrowserWindow (#22006)
* fix: remove cyclic references in BrowserWindow

* fix: prevent TopLevelWindow from garbage collection

* test: garbage collection of BrowserWindow

* chore: createIDWeakMap is used in tests
2020-02-11 09:37:46 +09:00
Jeremy Apthorp
b77f701aeb feat: disable the remote module by default (#22091) 2020-02-10 10:49:09 -08:00
Jeremy Apthorp
ea89120c9e chore: remove debugging log (#22093) 2020-02-07 12:31:08 -08:00
Shelley Vohr
928175bdfe feat: allow specifying pageSize for print (#22014) 2020-02-05 04:25:02 +00: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
1c6d8f5af6 fix: return path from netLog.stopLogging (#21985) 2020-01-31 10:43:02 -08:00
Hye Sung Jung
0bd8a97f38 update (#21915) 2020-01-29 18:42:25 +09:00
Shelley Vohr
548b290ea7 feat: add more options to printToPDF (#21906) 2020-01-28 20:47:24 +00:00
Charles Kerr
1b4eb0b679 fix: use powerMonitor.on() only after app is ready (#21927)
* fix: use powerMonitor.on() only after app is ready

powerMonitor can't be used until the app is ready; however, on Linux,
powerMonitor.on() was called as soon as lib/browser/api/power-monitor.ts
was loaded.

This patch takes @vladimiry's suggestion of wrapping that in an
app.on('ready') handler to prevent powerMonitor.on() from being called
prematurely.

Fixes #21716
2020-01-28 12:19:44 -06:00
Jeremy Apthorp
acb5b75057 chore: [extensions] support old APIs when enable_electron_extensions = true (#21812) 2020-01-21 09:42:55 -08:00