Commit graph

3,930 commits

Author SHA1 Message Date
trop[bot]
35ed9f6c6a
fix: restore window's canHide property on macOS (#48902)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: bill.shen <15865969+cucbin@users.noreply.github.com>
2025-11-13 15:22:10 -05:00
trop[bot]
dc5681ed79
feat: add app.isHardwareAccelerationEnabled() (#48679)
* feat: add app.isHardwareAccelerationEnabled()

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* chore: address review feedback

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-11-13 10:30:30 -05:00
trop[bot]
6a03d14055
feat: Focus DevTools when breakpoint is triggered (#48703)
`bringToFront` DevTools message is sent when breakpoint is triggered
or inspect is called and Chromium upon this message activates DevTools
via `DevToolsUIBindings::Delegate::ActivateWindow`:
```
void DevToolsWindow::ActivateWindow() {
  if (life_stage_ != kLoadCompleted)
    return;
\#if BUILDFLAG(IS_ANDROID)
  NOTIMPLEMENTED();
\#else
  if (is_docked_ && GetInspectedBrowserWindow())
    main_web_contents_->Focus();
  else if (!is_docked_ && browser_ && !browser_->window()->IsActive())
    browser_->window()->Activate();
\#endif
}
```
which implements: `DevToolsUIBindings::Delegate::ActivateWindow`.

Electron also implements this interface in:
`electron::InspectableWebContents`. However it was only setting
a zoom level, therefore this commit extends it with activation
of the DevTools.

Only supported for DevTools manged by `electron::InspectableWebContents`.

Closes: #37388

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Michał Pichliński <michal.pichlinski@here.io>
2025-11-10 16:40:13 -05:00
trop[bot]
6a303cb19f
fix: revert allow disabling all NSMenuItems, fix menu crash (#48803)
Revert "fix: allow disabling all `NSMenuItems` (#48598)"

This reverts commit 0cb4fdd0f2ae28d7bf3cd753cd2b641947e637aa.

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
2025-11-06 19:18:24 -08:00
trop[bot]
e93f04b23e
fix: draw smoothing round rect corner (#48783)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Bill Shen <15865969+cucbin@users.noreply.github.com>
2025-11-05 18:25:42 -05:00
trop[bot]
800bfde80f
fix: allow disabling all NSMenuItems (#48712)
fix: allow disabling all NSMenuItems

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-10-29 09:25:39 +01:00
trop[bot]
92cbc042e8
feat: enable more granular a11y feature management (#48627)
* feat: enable more granular a11y feature management

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* Update docs/api/app.md

Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-10-28 09:06:59 +01:00
trop[bot]
441e317400
fix: trafficLightPosition incorrect with customButtonsOnHover (#48622)
fix: trafficLightPosition incorrect with customButtonsOnHover

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-10-27 11:24:32 +01:00
trop[bot]
45aa5396a9
fix: crash on empty dialog extensions array on Windows (#48659)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-10-27 09:16:59 +01:00
trop[bot]
b0dea2f1c1
feat: dynamic ESM import in preload without context isolation (#48487)
* Dynamic ESM import in non-context-isolated preload

Extend `HostImportModuleWithPhaseDynamically`'s routing to support
Node.js import resolution in non-context-isolated preloads through
`v8_host_defined_options` length check. The length of host defined
options is distinct between Blink and Node.js and we can use it to
determine which resolver to use.

Co-authored-by: Fedor Indutny <indutny@signal.org>

* chore: update patches

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Fedor Indutny <indutny@signal.org>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-10-21 15:13:05 -04:00
trop[bot]
b56d95d214
fix: broken transparent window styles on resizable change (#48500)
* fix: wrong api call

Co-authored-by: zoy <zoy-l@outlook.com>

* fix: consistency of the resize state

Co-authored-by: zoy <zoy-l@outlook.com>

* fix: edge cases

Co-authored-by: zoy <zoy-l@outlook.com>

* chore: add detailed comments

Co-authored-by: zoy <zoy-l@outlook.com>

* fix: lint

Co-authored-by: zoy <zoy-l@outlook.com>

* chore: only windows

Co-authored-by: zoy <zoy-l@outlook.com>

* chore: use transparent

Co-authored-by: zoy <zoy-l@outlook.com>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: zoy <zoy-l@outlook.com>
2025-10-21 07:28:55 +02:00
trop[bot]
80b1defd81
fix: background hover contrast for WCO buttons (#48596)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-10-21 07:26:57 +02:00
trop[bot]
5a1d521a1d
fix: fixed white flash on call to BrowserWindow.show (#48558)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Cezary Kulakowski <cezary@openfin.co>
2025-10-16 14:49:09 +02:00
trop[bot]
8265537daf
fix: auth required websocket crash (#48540)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-10-14 14:45:16 +02:00
trop[bot]
7449f3f376
fix: dialog.showMessageBox defaultid on Windows (#48520)
* fix: dialog.showMessageBox defaultid on Windows

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* Update shell/browser/ui/message_box_win.cc

Co-authored-by: Robo <hop2deep@gmail.com>

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-10-11 10:02:20 +02:00
trop[bot]
d3d2877b65
fix: accentColor set distinguishes the frame (#48449)
* fix: accentColor set distinguishes the frame

Co-authored-by: zoy <zoy-l@outlook.com>

* chore: invalid change

Co-authored-by: zoy <zoy-l@outlook.com>

* fix: lint

Co-authored-by: zoy <zoy-l@outlook.com>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: zoy <zoy-l@outlook.com>
2025-10-04 04:12:01 +02:00
trop[bot]
7059e38293
fix: snapped window restoring to correct position (#48439)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-10-03 20:08:04 +02:00
trop[bot]
3a9ca3234e
fix: runtime JS error that crashes GetPackageJSON (#48423)
We overriden the `GetPackageJSON` in Node.js to let us read files
straight from the ASAR file instead of disk. The override works by
providing a JS method with the limitation that it should not throw a
runtime error. However, this invariant was accidentally violated by
`asar.splitPath` that sometimes contrary to its' TypeScript definition
returned `false`.

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Fedor Indutny <indutny@signal.org>
2025-10-02 21:00:06 -05:00
trop[bot]
9a2b4f84be
fix: MacOS 26 Tahoe - stop overriding private cornerMask API to fix WindowServer GPU load (#48400)
fix: MacOS 26 Tahoe - stop overriding private cornerMask API to fix WindowServer GPU load (#48376)

fix: macOS stop overriding private cornerMask API to fix WindowServer GPU load spike

Electron fetched a custom `_cornerMask` for `ElectronNSWindow` to smooth
vibrancy corners. On macOS 15 (Tahoe) that private hook forces the window
shadow to be rendered from a fully transparent surface, causing the
WindowServer GPU load regression. Remove the `cornerMask` property and
the `_cornerMask` override so we stay on Apple’s default shadow path.

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: avarayr <7735415+avarayr@users.noreply.github.com>
2025-09-27 10:30:52 -07:00
trop[bot]
b5c8dc159f
feat: add fileSystem to ses.setPermissionCheckHandler (#48328)
feat: add fileSystem to ses.setPermissionCheckHandler

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-09-26 10:23:05 -04:00
trop[bot]
e7ff3d4254
fix: showMessageDialog should center dialog to parent (#48213)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-09-05 10:22:33 +02:00
trop[bot]
d4ac255c5a
fix: ensure dragging works again after emitting contextmenu event (#48226)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-08-29 13:13:39 -04:00
BILL SHEN
3bacb67783
feat: add fileBacked and purgeable fields to process.getSystemMemoryInfo() for macOS (#48143)
feat: add fileBacked and purgeable fields to process.getSystemMemoryInfo() for macOS
2025-08-28 10:56:02 -07:00
trop[bot]
cfdd0a3640
fix: snapped restoration after minimization (#48156)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-08-25 09:57:03 +02:00
trop[bot]
68e5a3199b
fix: net.isOnline always true in utility processes (#48152)
* fix: net.isOnline always true in utilityProcesses

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* Update shell/services/node/node_service.cc

Co-authored-by: Robo <hop2deep@gmail.com>

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-08-22 11:02:55 -04:00
Shelley Vohr
ce91f050d4
feat: allow macOS tray to maintain position (#48076) 2025-08-21 10:41:30 +02:00
trop[bot]
efb54324a4
fix: system accent color parsing hex order (#48107)
fix: system accent color parsing

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-08-19 12:45:43 +02:00
Keeley Hammond
23a0293451
fix: ensure snapshot is valid (#48103)
feat: add support for embedder snapshot validation
2025-08-18 14:37:38 -07:00
Shelley Vohr
beee3737a9
fix: offscreen mode under window.open creation (#48070)
fix: offscreen mode under window.open creation
2025-08-18 16:17:22 -04:00
trop[bot]
a11d4eb03c
fix: avoid deprecated login item methods (#48096)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Samuel Attard <sattard@anthropic.com>
2025-08-18 12:00:14 +02:00
trop[bot]
edbe9cbbda
fix: shell.openPath should be non-blocking (#48088)
fix: shell.openPath should be non-blocking

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-08-17 20:19:14 +02:00
trop[bot]
dbd11d7806
fix: app.accessibilitySupportEnabled (#48061)
fix: app.accessibilitySupportEnabled on macOS

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-08-13 16:21:20 +02:00
trop[bot]
d053f2e4f9
fix: re-entrancy issues in webContents.loadURL() (#48045) 2025-08-12 13:42:52 +02:00
trop[bot]
4b46b6e2f2
feat: add {get|set}AccentColor on Windows (#48017)
* feat: add setAccentColor on Windows

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* refactor: unify GetSystemAccentColor

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* refactor: remove redundant parsing

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* chore: fixup documentation

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* Update docs/api/browser-window.md

Co-authored-by: Will Anderson <andersonw@dropbox.com>

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* Update docs/api/base-window.md

Co-authored-by: Will Anderson <andersonw@dropbox.com>

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-08-11 11:17:43 -04:00
trop[bot]
a0a315aa7a
fix: window accentColor should adhere to native window behavior (#48011)
* fix: window accentColor should adhere to native window behavior

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* fix: address review feedback

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* chore: remove duplicate UpdateWindowAccentColor call in ctor

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* refactor: add NativeWindow::IsActive() (#47148)

this was already present on macOS; use in NativeWindowViews too

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-08-09 09:44:16 +02:00
trop[bot]
f409eb0d7a
fix: compilation error when disabling extensions and pdf_viewer (#47994)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Jinli Wu <wujinli@bytedance.com>
2025-08-07 17:01:43 -04:00
trop[bot]
4f426daeca
feat: Use DIR_ASSETS path to locate resource bundles (#47951)
* feat: Use DIR_ASSETS path to locate resource bundles

Co-authored-by: Will Anderson <andersonw@dropbox.com>

* Use DIR_ASSETS for calculating ASAR relative paths

Co-authored-by: Will Anderson <andersonw@dropbox.com>

* Add test to verify 'assets' matches parent dir of 'exe'

Co-authored-by: Will Anderson <andersonw@dropbox.com>

* Add Mac-specific test for assets path (but it is failing)

Co-authored-by: Will Anderson <andersonw@dropbox.com>

* test: Update app.getPath('assets') to expect an exception on Mac

Co-authored-by: Will Anderson <andersonw@dropbox.com>

* docs: Update docs for 'assets' path to indicate that it's only available on Windows + Linux

Co-authored-by: Will Anderson <andersonw@dropbox.com>

* fix: Don't define 'assets' mapping on macOS

Co-authored-by: Will Anderson <andersonw@dropbox.com>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Will Anderson <andersonw@dropbox.com>
2025-08-06 19:40:07 +02:00
trop[bot]
e83b0f6c23
feat: add app.getRecentDocuments() (#47923)
feat: add app.getRecentDocuments()

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-08-06 19:35:15 +02:00
Shelley Vohr
c7ae20c4f2
fix: abnormal behavior of windows background material (#47956)
* fix: abnormal behavior of windows background material

* chore: update patches

---------

Co-authored-by: patchup[bot] <73610968+patchup[bot]@users.noreply.github.com>
2025-08-04 11:17:00 -04:00
trop[bot]
99b9516a68
fix: crash on window.close() with webContents on blur (#47954)
fix: crash on window.close with WebContentsView on blur

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-08-04 14:28:03 +02:00
trop[bot]
ee8290e707
fix: webContents.downloadURL() did not support referer header (#47865)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: xufuhang <576484918@qq.com>
2025-07-31 14:30:15 +02:00
trop[bot]
46dec46a82
fix: dark mode on Linux default themeing (#47920)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-07-31 14:29:39 +02:00
Shelley Vohr
e17cbc96e2
fix: default to system accent color on invalid user color (#47800)
fix: default to system accent color on invalid user color"
2025-07-31 11:10:24 +02:00
trop[bot]
45899d1cd7
fix: window content protection on older Windows versions (#47887)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-07-31 10:53:28 +02:00
trop[bot]
d49515db3e
fix: dialog file filters and macOS app bundles (#47839)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-07-21 16:29:52 +02:00
Shelley Vohr
2e460c0ffb
refactor: reduce scope of temporaries when getting dictionary values (#47799)
refactor: reduce scale of temporaries when getting dictionary values

Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-07-19 10:42:19 +02:00
trop[bot]
d5c68c2f6d
fix: handle missing NativeWindowMac in ElectronNSWindow (#47813)
fix: handle missing NativeWindowMac in ElectronNSWindow

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-07-18 10:09:35 +02:00
trop[bot]
5ba1597340
fix: deprecation warning crash when no Node.js environment available (#47771)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-07-17 10:09:13 +02:00
Calvin
e845d20789
fix: corner smoothing feature gate crash (37-x-y) (#47792)
fix: corner smoothing feature gate crash (#47759)
2025-07-16 12:03:26 -07:00
trop[bot]
6e9a46042d
fix: fullscreen for windows without rounded corners (#47682)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-07-08 15:22:52 +02:00