electron/shell/common
trop[bot] a3a595383d
perf: avoid redundant Promise.GetContext calls (#43618)
refactor: avoid redundant Promise.GetContext calls

Several Promise methods call `GetContext()` multiple times. From looking
at the assembly in obj/electron/electron_lib/promise.o, these redundant
calls are actually being made -- they aren't optmized out.

This PR keeps the return value in a local variable to avoid extra calls.

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2024-09-08 10:37:26 -05:00
..
api fix: gin_helper::MicrotasksScope instantiation (#43209) 2024-08-05 21:46:51 -05:00
asar refactor: take a uint8_t span in ValidateIntegrityOrDie() (#43614) 2024-09-06 22:16:51 -05:00
extensions refactor: move impl functions into private namespace (#43410) 2024-08-21 21:29:25 -05:00
gin_converters fix: don't use deprecate-soon class v8::String::Value (#43553) 2024-09-04 12:54:19 -05:00
gin_helper perf: avoid redundant Promise.GetContext calls (#43618) 2024-09-08 10:37:26 -05:00
mac chore: replace absl::optional<T> with std::optional<T> (#40928) 2024-01-10 16:23:35 -06:00
resources/mac fix: disable MallocNanoZone on mac (#33704) 2022-04-28 10:28:27 -04:00
application_info.cc fix: devtools allow restoring saved dock state on Windows (#39734) 2023-09-07 17:14:01 +09:00
application_info.h fix: devtools allow restoring saved dock state on Windows (#39734) 2023-09-07 17:14:01 +09:00
application_info_linux.cc fix: potential crash caused by dlopen different gtk libraries (#33650) 2022-04-18 13:24:32 +09:00
application_info_mac.mm chore: bump chromium to 118.0.5975.0 (main) (#39531) 2023-09-01 15:54:59 +09:00
application_info_win.cc chore: drop support for Windows 7 / 8 / 8.1 (#36427) 2022-11-30 17:13:29 -08:00
color_util.cc chore: remove unused std includes (#38767) 2023-06-14 11:07:18 -07:00
color_util.h feat: replace BrowserView with WebContentsView (#35658) 2023-12-13 13:01:03 -08:00
crash_keys.cc refactor: remove banned std::to_string() calls (#41087) 2024-01-24 16:43:31 -06:00
crash_keys.h chore: used nested namespaces (#34737) 2022-06-29 12:55:47 -07:00
electron_command_line.cc chore: bump chromium to 100.0.4857.0 (main) (#32419) 2022-02-09 18:58:52 -08:00
electron_command_line.h chore: bump chromium to 100.0.4857.0 (main) (#32419) 2022-02-09 18:58:52 -08:00
electron_constants.cc build: remove enable_run_as_node build flag (#38413) 2023-06-08 16:40:08 -04:00
electron_constants.h build: remove enable_run_as_node build flag (#38413) 2023-06-08 16:40:08 -04:00
electron_paths.h feat: allow customizing browser data location (#33554) 2022-05-09 10:26:57 -04:00
heap_snapshot.cc chore: enable check raw ptr fields (#38167) 2023-05-11 16:07:39 -04:00
heap_snapshot.h
key_weak_map.h refactor: simplify KeyWeakMap impl (#43484) 2024-08-26 18:10:34 -04:00
keyboard_util.cc refactor: remove banned std::to_string() calls (#41087) 2024-01-24 16:43:31 -06:00
keyboard_util.h chore: migrate base::StringPiece to std::string_view (#40915) 2024-01-10 19:00:37 -06:00
language_util.h
language_util_linux.cc feat: add app.getPreferredSystemLanguages() API (#36035) 2022-11-09 10:50:43 -05:00
language_util_mac.mm
language_util_win.cc chore: bump chromium to 121.0.6147.0 (main) (#40523) 2023-11-28 13:40:12 -08:00
logging.cc refactor: move impl functions into private namespace (#43410) 2024-08-21 21:29:25 -05:00
logging.h
node_bindings.cc fix: gin_helper::MicrotasksScope instantiation (#43209) 2024-08-05 21:46:51 -05:00
node_bindings.h fix: delete UvTaskRunner's timers only after they're closed (#43598) 2024-09-06 11:18:52 -05:00
node_bindings_linux.cc refactor: NodeBindings::Create() returns a unique_ptr (#43393) 2024-08-21 10:56:59 -04:00
node_bindings_linux.h chore: remove redundant code in node integration (#33500) 2022-03-29 20:09:42 -07:00
node_bindings_mac.cc refactor: NodeBindings::Create() returns a unique_ptr (#43393) 2024-08-21 10:56:59 -04:00
node_bindings_mac.h chore: remove redundant code in node integration (#33500) 2022-03-29 20:09:42 -07:00
node_bindings_win.cc refactor: NodeBindings::Create() returns a unique_ptr (#43393) 2024-08-21 10:56:59 -04:00
node_bindings_win.h chore: remove redundant code in node integration (#33500) 2022-03-29 20:09:42 -07:00
node_includes.h chore: rename built-in modules to bindings to match naming update in node (#37182) 2023-02-09 10:31:38 +09:00
node_util.cc chore: remove node patches by using the preload feature (#41080) 2024-01-24 09:54:32 -06:00
node_util.h fix: only remove hijackable envs from foreign parent (#41079) 2024-01-24 09:51:27 -06:00
options_switches.cc chore: bump chromium to 126.0.6445.0 (31-x-y) (#42119) 2024-05-13 20:19:31 +02:00
options_switches.h chore: bump chromium to 126.0.6445.0 (31-x-y) (#42119) 2024-05-13 20:19:31 +02:00
platform_util.cc chore: bump chromium to 111.0.5544.3 (main) (#36820) 2023-02-03 12:43:42 +01:00
platform_util.h feat: update app.{set|get}LoginItemSettings(settings) (#37244) 2023-10-16 12:25:11 -04:00
platform_util_internal.h chore: used nested namespaces (#34737) 2022-06-29 12:55:47 -07:00
platform_util_linux.cc fix: Launch apps with XDG_ACTIVATION_TOKEN in ozone/wayland (#43578) 2024-09-05 15:16:49 -05:00
platform_util_mac.mm chore: improve error message on failed SMApp register/unregister (#42557) 2024-06-18 14:15:36 +02:00
platform_util_win.cc fix: normalize path before calling showItemInFolder and openPath (#41642) 2024-03-22 10:28:44 -04:00
plugin_info.cc chore: bump chromium to 123.0.6312.5 (main) (#41337) 2024-02-21 15:27:05 -05:00
plugin_info.h chore: bump chromium to 109.0.5382.0 (main) (#36057) 2022-10-27 12:37:04 -04:00
process_util.cc refactor: use process_util.h helpers (#38574) 2023-06-06 17:19:13 +09:00
process_util.h refactor: use process_util.h helpers (#38574) 2023-06-06 17:19:13 +09:00
skia_util.cc chore: bump chromium to 110.0.5415.0 (main) (#36186) 2022-11-17 14:59:23 -05:00
skia_util.h chore: used nested namespaces (#34737) 2022-06-29 12:55:47 -07:00
thread_restrictions.h chore: bump chromium to 110.0.5415.0 (main) (#36186) 2022-11-17 14:59:23 -05:00
v8_value_serializer.cc fix: gin_helper::MicrotasksScope instantiation (#43209) 2024-08-05 21:46:51 -05:00
v8_value_serializer.h chore: bump chromium to 102.0.4961.0 (main) (#33091) 2022-03-24 21:39:03 -04:00
world_ids.h