chore: bump chromium to 124.0.6359.0 (main) (#41584)

* chore: bump chromium in DEPS to 124.0.6355.0

* 5341411: view-transition: Ensure resources are cleaned up in all cases.

5341411

* chore: fixup patch indices

* 5354013: Return nullopt on error from ProcessMetrics CPU measurements

5354013

* chore: bump chromium in DEPS to 124.0.6357.0

* chore: update patches

* 5368769: Reland "[mojo] Use large worker for mojom_parser action"

5368769

* 5336171: [Extensions] Introduce a CoreExtensionsRendererAPIProvider

5336171

* 5367334: [FS Shortcut] Refactor ExclusiveAccessManager

5367334

* 5354161: Rename GeolocationManager to GeolocationSystemPermissionManager

5354161

* fixup: [Extensions] Introduce a CoreExtensionsRendererAPIProvider

* chore: bump chromium in DEPS to 124.0.6359.0

* chore: update patches

* 5371370: [Extensions] Move core NativeHandler registration

5371370

* 5370702: [Extensions] Introduce ShellExtensionsRendererAPIProvider

5370702

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: PatchUp <73610968+patchup[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
This commit is contained in:
electron-roller[bot] 2024-03-15 14:03:42 -04:00 committed by GitHub
parent 3759e59bbd
commit 193e162ec6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
52 changed files with 201 additions and 250 deletions

View file

@ -277,8 +277,8 @@ v8::Local<v8::Value> ElectronBindings::GetCPUUsage(
v8::Isolate* isolate) {
auto dict = gin_helper::Dictionary::CreateEmpty(isolate);
int processor_count = base::SysInfo::NumberOfProcessors();
dict.Set("percentCPUUsage",
metrics->GetPlatformIndependentCPUUsage() / processor_count);
std::optional<double> usage = metrics->GetPlatformIndependentCPUUsage();
dict.Set("percentCPUUsage", usage.value_or(0) / processor_count);
// NB: This will throw NOTIMPLEMENTED() on Windows
// For backwards compatibility, we'll return 0