12 Commits

Author SHA1 Message Date
Robo
f6dc41a911 refactor: gin_helper::Promise managed by cppgc (#51386)
* refactor: gin_helper::Promise managed by cppgc

* fix: broken liveness test

* refactor: move handle dependent members to base class
2026-04-30 09:48:39 -04:00
Robo
350de668e2 refactor: api::autoUpdater managed by cppgc (#51241) 2026-04-23 05:38:47 +09:00
Robo
23d95ea9f8 refactor: api::cookies managed by cppgc (#51196)
* refactor: api::cookies managed by cppgc

* chore: remove unused header
2026-04-22 05:28:31 +09:00
Robo
b9e462f397 refactor: api::utilityProcessWrapper managed by cppgc (#50955)
* refactor: api::utilityProcessWrapper managed by cppgc

* chore: fix lint
2026-04-13 10:46:51 +02:00
Samuel Attard
2c94aac330 build: add oxfmt for JS/TS formatting and import sorting (#50692)
* build: add oxfmt for code formatting and import sorting

Adds oxfmt as a devDependency alongside oxlint and wires it into the
lint pipeline. The .oxfmtrc.json config matches Electron's current JS
style (single quotes, semicolons, 2-space indent, trailing commas off,
printWidth 100) and configures sortImports with custom groups that
mirror the import/order pathGroups previously enforced by ESLint:
@electron/internal, @electron/*, and {electron,electron/**} each get
their own ordered group ahead of external modules.

- `yarn lint:fmt` runs `oxfmt --check` over JS/TS sources and is
  chained into `yarn lint` so CI enforces it automatically.
- `yarn format` runs `oxfmt --write` for local fix-up.
- lint-staged invokes `oxfmt --write` on staged .js/.ts/.mjs/.cjs
  files before oxlint, so formatting is applied at commit time.

The next commit applies the formatter to the existing codebase so the
check actually passes.

* chore: apply oxfmt formatting to JS and TS sources

Runs `yarn format` across lib/, spec/, script/, build/, default_app/,
and npm/ to bring the codebase in line with the .oxfmtrc.json settings
added in the previous commit. This is a pure formatting pass: import
statements are sorted into the groups defined by the config, method
chains longer than printWidth are broken, single-quoted strings
containing apostrophes are switched to double quotes, and a handful of
single-statement `if` bodies are re-wrapped and get braces added by
`oxlint --fix` to satisfy the `curly: multi-line` rule.

No behavior changes.
2026-04-12 02:03:04 -07:00
Robo
05f1cb553d fix: shutdown crash when unregistering power notification on windows (#50878)
* fix: crash on shutdown when unregistering power notification

Refs https://learn.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-unregistersuspendresumenotification
the handle should be the return value of registeration api
not the window handle.

* chore: remove redundant selfkeepalive

Followup to 7c0cb61b3c

* chore: fix lint

* chore: address review feedback
2026-04-11 00:47:05 +09:00
Robo
5f820b7f69 test: add cppgc backed menu leak regression test (#50879)
* spec: add menu leak regression test

* spec: reduce menu count to remove CI flakiness
2026-04-10 20:48:28 +09:00
Charles Kerr
a189425373 fix: dangling raw_ptr api::Session::browser_context_ (#50784)
* fix: dangling raw_ptr api::Session::browser_context_

* fix: address code review feedback
2026-04-08 15:04:29 +09:00
Robo
542ff828ab refactor: SafeV8Function to be backed by cppgc (#50397)
* refactor: SafeV8Function to be backed by cppgc

* spec: focus renderer before attempting paste

* spec: remove listeners to prevent leak on failed tests
2026-03-24 16:59:32 -05:00
Robo
e0db4046b2 refactor: allocate gin_helper::internal::Event on cpp heap (#48161) 2025-08-27 09:30:50 +09:00
Robo
3ccb1bc0a8 refactor: allocate api::Session on cpp heap (#48141) 2025-08-25 18:52:06 +09:00
Robo
dd54e84a58 refactor: allocate api::App on cpp heap (#48118) 2025-08-20 20:35:08 +09:00