Commit graph

29193 commits

Author SHA1 Message Date
Keeley Hammond
8ca091251f
chore: cherry-pick 2 changes from 1-M137 (#47369)
* chore: cherry-pick 45eb42cd398e from v8

* chore: cherry-pick f1e6422a355c from chromium

* chore: update patches
2025-06-05 10:00:38 +02:00
Keeley Hammond
6b08d83af7
chore: cherry-pick 1 changes from 1-M137 (#47354)
* chore: [35-x-y] cherry-pick 1 changes from 1-M137

* 7bc0a67ebfbf from v8

* chore: run `e patches all` (#47360)

`e patches all`

---------

Co-authored-by: Erick Zhao <ezhao@slack-corp.com>
2025-06-04 02:21:30 +02:00
trop[bot]
71233a4517
fix: addChildView() crashes when adding a closed WebContentsView (#47339)
fix: addChildView() crashes when add a closed WebContentsView

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Sida Zhu <zhusida@bytedance.com>
2025-06-03 15:29:36 +02:00
trop[bot]
f370a19e36
docs: correct 'select-bluetooth-device' requirement (#47335)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-06-03 10:54:06 +02:00
trop[bot]
a7fd8872bf
fix: Squirrel.Mac crash when zip extraction fails (#47299)
* fix: Squirrel.Mac crash when zip extraction process fails to launch

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

* chore: add end-to-end test

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Niklas Wenzel <dev@nikwen.de>
2025-05-30 10:47:11 -04:00
trop[bot]
7f5e6c54bc
ci: add a problem matcher for ESLint output (#47306)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-05-30 11:02:04 +02:00
Robo
fadec9ac65
fix: crash due to incorrect debug scope information (#47286)
* fix: crash due to incorrect debug scope information

* chore: update patches

---------

Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-05-29 16:52:43 +09:00
David Sanders
a8cdd60c88
chore: update @electron/lint-roller to 3.1.1 (#47273) 2025-05-27 16:59:13 -04:00
trop[bot]
6280172ee9
build: migrate to new chromium git auth (#47253)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-05-27 12:50:32 -04:00
trop[bot]
94f6e16871
fix: regression with directory selection in macOS dialogs (#47276)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-05-27 11:18:36 -04:00
trop[bot]
5fde5696d0
fix: titlebar showing in content protected window (#47265)
Closes https://github.com/electron/electron/issues/47152.

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-27 14:24:45 +02:00
trop[bot]
73605f97ee
chore: debug crash on DevTools SetOwnerWindow (#47261)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-27 14:24:09 +02:00
Charles Kerr
72d3d359c3
fix: backgroundMaterial on initial activate (35-x-y) (#47236)
fix: backgroundMaterial on initial activate

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-23 21:37:54 -05:00
trop[bot]
0b026d261e
refactor: use base::fixed_flat_set in NativeWindowViews::SetAlwaysOnTop() (#47238)
refactor: use base::fixed_flat_set in NativeWindowViews::SetAlwaysOnTop()

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-05-23 12:58:32 -05:00
Charles Kerr
0954ac7843
fix: possible crash in shell.readShortcutLink (35-x-y) (#47226)
fix: possible crash in shell.readShortcutLink

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-23 12:45:56 +02:00
Charles Kerr
feab959781
refactor: make NativeWindow::pending_transitions_ a base::queue (35-x-y) (#47235)
refactor: make `NativeWindow::pending_transitions_` a `base::queue` (#47157)

refactor: make NativeWindow::pending_transitions a base::queue

Follow the base/containers/README.md advice that "Chromium code should
always use `base::circular_deque` or `base::queue` in preference to
`std::deque` or `std::queue` due to memory usage and platform variation."
2025-05-23 09:53:19 +02:00
John Kleinschmidt
282903e7b8
build: fix depot tool pathing on Windows (#47194) (#47227)
build: properly set depot_tools pathing for Windows
(cherry picked from commit b2d0074cc6)
2025-05-22 11:57:23 -07:00
trop[bot]
15d6344b6a
ci: add problem matcher for patch conflict output (#47223)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-05-22 11:54:35 -07:00
trop[bot]
fcb576566a
ci: add problem matcher for clang output (#47218)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-05-22 11:53:12 -07:00
trop[bot]
64a07ffc3f
fix: remove extra 'suspend'/'resume' handling from powerMonitor (#47190)
fix: remove extra 'suspend'/'resume' handling from powerMonitor

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-22 13:31:19 -05:00
trop[bot]
720684c766
refactor: make NativeWindow::transparent_ const (#47197)
* refactor: use in-class member initialization for NativeWindow::widget_

* refactor: make NativeWindow::transparent_ const

refactor: make NativeWindow::enable_larger_than_screen_ const

* chore: make linter happy after rebase

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-05-22 11:16:43 -05:00
Charles Kerr
b626829f71
refactor: add gin_helper::Dictionary::ValueOrDefault() (35-x-y) (#47203)
refactor: add `gin_helper::Dictionary::ValueOrDefault()` (#46939)

* feat: add gin_helper::Dictionary::ValueOrDefault()

A convenience function for using a default value if the
specified key isn't present in the dictionary.

* refactor: use ValueOrDefault() in native_window.cc

* refactor: use ValueOrDefault() in native_window_mac.mm

* refactor: use ValueOrDefault() in native_window_views.cc

* refactor: use ValueOrDefault() in electron_api_native_image.cc
2025-05-22 12:35:57 +02:00
trop[bot]
2fb93ed6cb
refactor: prefer base::circular_deque over std::deque (#47191)
* refactor: use base::circular_deque in ResolveProxyHelper

Co-authored-by: Charles Kerr <charles@charleskerr.com>

* refactor: use base::circular_deque in GetExtraCrashKeys()

refactor: reduce visibility of kMaxCrashKeyValueSize

This change is to match Chromium's usage advice from
base/containers/README.md: `base:circular_deque` is preferred over
`std::deque` to provide consistent performance across platforms.

Co-authored-by: Charles Kerr <charles@charleskerr.com>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-05-21 15:49:38 -05:00
Robo
45f84be0b8
feat: support dip <-> screen conversion on Linux (#47124)
* feat: support dip <-> screen conversion on Linux

* chore: fix build
2025-05-21 09:58:24 -07:00
Keeley Hammond
2bf22b53f1
chore: cherry-pick 1 changes from 0-M136 (#47069)
* chore: [35-x-y] cherry-pick 1 changes from 0-M136

* 22ac8acf3508 from v8

* chore: update patches
2025-05-21 10:32:26 +02:00
Keeley Hammond
853392e0f0
chore: cherry-pick 2 changes from 2-M136 (#47175)
* chore: [35-x-y] cherry-pick 2 changes from 2-M136

* 295a4a1b14b8 from chromium
* c3568ceda9d8 from chromium

* chore: update patches
2025-05-21 10:27:16 +02:00
trop[bot]
2b96789b23
refactor: make NativeWindow::has_client_frame_ const (#47178)
* refactor: make NativeWindow::has_client_frame_ const

Co-authored-by: Charles Kerr <charles@charleskerr.com>

* refactor: make NativeWindow::has_client_frame_ const but not constexpr

Co-authored-by: Charles Kerr <charles@charleskerr.com>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-05-20 19:39:15 -05:00
trop[bot]
406f4eded6
build: update_depot_tools on initial install (#47167)
this ensures that python is setup for proper use from depot_tools

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-05-20 20:56:01 +02:00
trop[bot]
535d9fb1c8
fix: prevent gc monitor 2nd pass crash (#47164)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: reito <cnschwarzer@qq.com>
2025-05-20 11:14:42 -05:00
electron-roller[bot]
caf1c1faf2
chore: bump node to v22.15.1 (35-x-y) (#47102)
* chore: bump node in DEPS to v22.15.1

* chore: fixup patch indices

* src: fix error handling on async crypto operations

https://github.com/nodejs-private/node-private/pull/709

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-20 13:32:48 +02:00
trop[bot]
ed71d0733e
refactor: NativeWindows should prefer widget() over GetWidget() for internal use (#47154)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-05-19 21:40:21 -05:00
trop[bot]
d03a12aef4
perf: don't create unused menuitem icons (#47127)
GTK >= 3.90.0 removed support for menuitem icons. When Electron is
built with GTK >= 3.90.0, our code builds these icons and then throws
them away unused. Instead, let's just not build them.

Our gtk_util::GdkPixbufFromSkBitmap utility uses BGRAToRGBA and is
expensive to call.

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-05-16 10:46:21 -05:00
trop[bot]
458fa5f421
test: fix desktopCapturer mocha syntax (#47112)
do not nest `it` calls in desktopCapturer specs

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-05-15 19:41:15 -05:00
trop[bot]
f872b431fe
fix: opening package paths as directory on macOS (#47110)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-05-15 19:39:32 -05:00
trop[bot]
af31ce0135
refactor: decouple NativeWindowViews and GlobalMenuBarX11 (#47117)
The GlobalMenuBar used to hold a raw_ptr reference to its NativeWindow;
but since it doesn't use it & only wants the gfx::AcceleratedWidget info,
let's remove the NativeWindowViews reference.

AFAICT, GlobalMenuBarX11::window_ has never been used

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-05-15 19:38:44 -05:00
trop[bot]
f9bcea3bfc
feat: add support for --experimental-network-inspection (#47029)
* feat: add support for `--experimental-network-inspection`

Co-authored-by: Aman Karmani <aman@tmm1.net>

* docs: fix minor formatting issues

visible on both GH[1] and the docs site[2]

[1] https://github.com/electron/electron/blob/main/docs/api/command-line-switches.md#nodejs-flags
[2] https://www.electronjs.org/docs/latest/api/command-line-switches#--inspect-brkhostport

Co-authored-by: Aman Karmani <aman@tmm1.net>

* docs: add entry for new nodejs flag

Co-authored-by: Aman Karmani <aman@tmm1.net>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Aman Karmani <aman@tmm1.net>
2025-05-15 12:24:33 -07:00
trop[bot]
b8e4d3650e
feat: enable secondary label for macOS menu (#47041)
* feat: enable secondary label for macOS menu

Co-authored-by: Michaela Laurencin <mlaurencin@electronjs.org>

* Update shell/browser/ui/cocoa/electron_menu_controller.mm

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

Co-authored-by: Michaela Laurencin <35157522+mlaurencin@users.noreply.github.com>

* fix for lint

Co-authored-by: Michaela Laurencin <mlaurencin@electronjs.org>

* update docs for sublabel

Co-authored-by: Michaela Laurencin <mlaurencin@electronjs.org>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Michaela Laurencin <mlaurencin@electronjs.org>
Co-authored-by: Michaela Laurencin <35157522+mlaurencin@users.noreply.github.com>
2025-05-15 12:22:19 -07:00
Michaela Laurencin
24fcd14cdc
feat: enable innerWidth and innerHeight for window open (#46749) (#47045)
* feat: enable innerWidth and innerHeight for window open

* update comment for added special innerWidth and innerHeight

* update 100 min spec requirement handling

* update testing to include getContentSize

* update macOS min requirement handling

* adjust refactored consts

* update const values from nativewindowviews
2025-05-15 12:21:56 -07:00
trop[bot]
dec69bb61b
refactor: use kKeyModifiers in IsAltModifier() (#47091)
We probably didn't use this before because IsAltModifier() was written
two years before the KeyModifiers mask was added upstream in 98ec378a.

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-05-14 12:17:26 -05:00
electron-roller[bot]
9f4e0b9343
chore: bump node to v22.15.0 (35-x-y) (#46740)
* chore: bump node in DEPS to v22.15.0

* inspector: fix GN build

https://github.com/nodejs/node/pull/56798

* test: search cctest files

https://github.com/nodejs/node/pull/56791

* crypto: fix missing OPENSSL_NO_ENGINE guard

https://github.com/nodejs/node/pull/57012

* test,crypto: make tests work for BoringSSL

https://github.com/nodejs/node/pull/57021

* module: use synchronous hooks for preparsing in import(cjs)

https://github.com/nodejs/node/pull/55698

* deps: update simdjson to 3.12.0

https://github.com/nodejs/node/pull/56874

* build: remove explicit linker call to libm on macOS

https://github.com/nodejs/node/pull/56901

* test: make eval snapshot comparison more flexible

https://github.com/nodejs/node/pull/57020

* src: allow embedder customization of OOMErrorHandler

https://github.com/nodejs/node/pull/57325

* src: do not pass nullptr to std::string ctor

https://github.com/nodejs/node/pull/57354

* build: fix GN build failure

* build: fix patch indices

* crypto: expose security levels

https://github.com/nodejs/node/pull/56601

* zlib: add zstd support

https://github.com/nodejs/node/pull/52100

* test: move crypto related common utilities in common/crypto

https://github.com/nodejs/node/pull/56714

* test: disable test-https-client-renegotiation-limit

BoringSSL doesn't support caller-initiated renegotiation - see
https://source.chromium.org/chromium/chromium/src/+/main:third_party/boringssl/src/ssl/ssl_lib.cc;l=1627-1631

* chore: fixup indices

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-13 21:56:52 +09:00
trop[bot]
b8712a35db
fix: webview crash on focus (#47035)
* fix: webview crash on focus

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

* fixup! fix: webview crash on focus

chore: fix .patches shear

---------

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-05-11 21:18:17 -05:00
trop[bot]
db3b0e01c1
fix: white window flicker on window creation (#47052)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-11 13:25:24 -05:00
trop[bot]
f87950a371
fix: restore previous Windows screenshotting (#47034)
Fixes https://github.com/electron/electron/issues/45990

We previously made a change in https://github.com/electron/electron/pull/45868
to fix content protection being lost on hide and re-show. However, this
cause a breaking change where protected windows were made opaque black
instead of being hidden as before. This overrides relevant methods in
ElectronDesktopWindowTreeHostWin to restore the previous behavior.
without regressing the original issue.

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-09 17:47:36 -05:00
trop[bot]
d341a523e5
fix: use-after-move of bus connection in xdg portal detection (#47025)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-05-09 09:27:44 -04:00
trop[bot]
a2b954c8f3
build: update hasher return value (#47010)
Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
2025-05-09 09:36:33 +02:00
trop[bot]
8696da7de8
test: enable hasShadow tests on Linux (#46999)
refactor: enable hasShadow tests on Linux

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-05-08 15:00:07 -05:00
trop[bot]
8e0f91f93f
build: move release script to new hasher function (#46994)
build: move to new hasher function

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Keeley Hammond <vertedinde@electronjs.org>
2025-05-08 11:09:36 +02:00
Robo
5104001067
feat: support system-context-menu on Linux (#46977)
* feat: support system-context-menu on Linux

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

* chore: backport linux native window controls menu

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-08 18:08:16 +09:00
trop[bot]
102457bbd5
test: test menu rendering accelerators (#46967)
* test: test menu rendering accelerators

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

* Update spec/api-menu-spec.ts

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-05-06 18:52:46 -05:00
trop[bot]
0630744f5b
fix: crash on macOS dialog after window-all-closed (#46953)
fix: crash on dialog after window-all-closed

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-06 14:11:49 -05:00