mirror of
https://github.com/electron/electron.git
synced 2026-02-19 03:14:51 -05:00
Compare commits
139 Commits
wayland-ro
...
v11.0.0-be
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2e730fe48b | ||
|
|
88de23b241 | ||
|
|
3faa2c2a46 | ||
|
|
cab14277b8 | ||
|
|
ce243f8172 | ||
|
|
da4790d944 | ||
|
|
4088566a4d | ||
|
|
ac425c0cf3 | ||
|
|
ccb471e5d5 | ||
|
|
f44880f065 | ||
|
|
7ec001486e | ||
|
|
dd3fbae447 | ||
|
|
e9710f6a77 | ||
|
|
699a771288 | ||
|
|
f679dd8ad7 | ||
|
|
9f1b913793 | ||
|
|
9328725e93 | ||
|
|
cea757f59c | ||
|
|
d93cb942fc | ||
|
|
4d280ed483 | ||
|
|
bb69770267 | ||
|
|
d4112d38de | ||
|
|
b1eec448f0 | ||
|
|
becfe25528 | ||
|
|
a461001677 | ||
|
|
aa15eeed78 | ||
|
|
6daac26f49 | ||
|
|
3551c81cc5 | ||
|
|
2b1004919d | ||
|
|
d200b9192a | ||
|
|
c2e8704683 | ||
|
|
0b2862b184 | ||
|
|
d959222bb8 | ||
|
|
e5550e5bad | ||
|
|
8546f98a87 | ||
|
|
7a6965087c | ||
|
|
2558455be4 | ||
|
|
65fdfc1e16 | ||
|
|
139e20367f | ||
|
|
e84aa04bb5 | ||
|
|
7a06ae575e | ||
|
|
460594480f | ||
|
|
6e676c3695 | ||
|
|
e6fa69bfd2 | ||
|
|
df3fa7ddb7 | ||
|
|
c090fbfd11 | ||
|
|
6d99158379 | ||
|
|
bb11bdce36 | ||
|
|
ca163f9cf7 | ||
|
|
5598025884 | ||
|
|
df82bbab43 | ||
|
|
ed5fd9c910 | ||
|
|
0ac14ce30c | ||
|
|
3793cfc0ff | ||
|
|
1c8377967d | ||
|
|
485612ae68 | ||
|
|
4016def2d0 | ||
|
|
c35a67f31e | ||
|
|
fd5896919b | ||
|
|
7a669cbbb0 | ||
|
|
8acf548c62 | ||
|
|
dc9282d6ff | ||
|
|
a4cb3e2af9 | ||
|
|
1eea063c3a | ||
|
|
583e2b76d9 | ||
|
|
ca215070e9 | ||
|
|
9852e1f190 | ||
|
|
9ce7d133d8 | ||
|
|
c157521bd0 | ||
|
|
309df5a99d | ||
|
|
f298d4d54f | ||
|
|
ca227ede76 | ||
|
|
7120698f1f | ||
|
|
5eb225b5ae | ||
|
|
71c26dab90 | ||
|
|
f8ee8b2ee2 | ||
|
|
639fb15dc4 | ||
|
|
c6fa081558 | ||
|
|
dcbca5448a | ||
|
|
0667110350 | ||
|
|
e089cab8cd | ||
|
|
634b76e5a2 | ||
|
|
11c20477e4 | ||
|
|
fca920de40 | ||
|
|
ce5660db36 | ||
|
|
f8bdaa04d8 | ||
|
|
08ebf7c03b | ||
|
|
9f164607b7 | ||
|
|
d88ce0be9c | ||
|
|
e17b770690 | ||
|
|
ff97c5255b | ||
|
|
2ab7143b69 | ||
|
|
96f258b866 | ||
|
|
e6d5fc23a7 | ||
|
|
fe1b40ce9e | ||
|
|
fb7f783ee1 | ||
|
|
9ff208f898 | ||
|
|
a8dc3ae5c2 | ||
|
|
07ec50b547 | ||
|
|
8bdff7acbc | ||
|
|
a66ba564fd | ||
|
|
0f4f5ac32c | ||
|
|
4e080c4b15 | ||
|
|
7e40dc2237 | ||
|
|
e2b90ee28c | ||
|
|
69ded48ce4 | ||
|
|
a22dfc813f | ||
|
|
c1d04d8e49 | ||
|
|
80efb6d9da | ||
|
|
51a35f8b4d | ||
|
|
b88396cf00 | ||
|
|
35d2727de0 | ||
|
|
23c32766e5 | ||
|
|
db492c3178 | ||
|
|
86cc6a7b44 | ||
|
|
2ed7f0f4fc | ||
|
|
9e9cc8f606 | ||
|
|
1e1d35fb87 | ||
|
|
119cd24a7f | ||
|
|
138fa6cdf3 | ||
|
|
7745e48498 | ||
|
|
b62e00f0ae | ||
|
|
ad876ac1b1 | ||
|
|
c35ec6bc34 | ||
|
|
a08b3682c3 | ||
|
|
c3ad33c28b | ||
|
|
59f9e417d4 | ||
|
|
7931c8abfd | ||
|
|
622f5f84cf | ||
|
|
c8944df576 | ||
|
|
3efbee2061 | ||
|
|
aafada554f | ||
|
|
56e81665fb | ||
|
|
e68f086d95 | ||
|
|
74edd99570 | ||
|
|
63720fd603 | ||
|
|
d6bea2a681 | ||
|
|
5b53a08132 | ||
|
|
09e33b3420 |
@@ -69,7 +69,7 @@ parameters:
|
||||
# Build machines configs.
|
||||
docker-image: &docker-image
|
||||
docker:
|
||||
- image: electronjs/build:d09fd95029bd8c1c73069888231b29688ef385ed
|
||||
- image: electron.azurecr.io/build:4cec2c5ab66765caa724e37bae2bffb9b29722a5
|
||||
|
||||
machine-linux-medium: &machine-linux-medium
|
||||
<<: *docker-image
|
||||
@@ -85,17 +85,17 @@ machine-linux-2xlarge: &machine-linux-2xlarge
|
||||
|
||||
machine-mac: &machine-mac
|
||||
macos:
|
||||
xcode: "11.5.0"
|
||||
xcode: "12.2.0"
|
||||
|
||||
machine-mac-large: &machine-mac-large
|
||||
resource_class: large
|
||||
macos:
|
||||
xcode: "11.5.0"
|
||||
xcode: "12.2.0"
|
||||
|
||||
machine-mac-large-arm: &machine-mac-large-arm
|
||||
resource_class: large
|
||||
macos:
|
||||
xcode: "12.0.0-large"
|
||||
xcode: "12.2.0"
|
||||
|
||||
# Build configurations options.
|
||||
env-testing-build: &env-testing-build
|
||||
@@ -107,6 +107,7 @@ env-release-build: &env-release-build
|
||||
STRIP_BINARIES: true
|
||||
GENERATE_SYMBOLS: true
|
||||
CHECK_DIST_MANIFEST: '1'
|
||||
IS_RELEASE: true
|
||||
|
||||
env-headless-testing: &env-headless-testing
|
||||
DISPLAY: ':99.0'
|
||||
@@ -256,23 +257,25 @@ step-gclient-sync: &step-gclient-sync
|
||||
"$CIRCLE_REPOSITORY_URL"
|
||||
|
||||
ELECTRON_USE_THREE_WAY_MERGE_FOR_PATCHES=1 gclient sync --with_branch_heads --with_tags
|
||||
# Re-export all the patches to check if there were changes.
|
||||
python src/electron/script/export_all_patches.py src/electron/patches/config.json
|
||||
cd src/electron
|
||||
git update-index --refresh || true
|
||||
if ! git diff-index --quiet HEAD --; then
|
||||
# There are changes to the patches. Make a git commit with the updated patches
|
||||
git add patches
|
||||
GIT_COMMITTER_NAME="Electron Bot" GIT_COMMITTER_EMAIL="anonymous@electronjs.org" git commit -m "update patches" --author="Electron Bot <anonymous@electronjs.org>"
|
||||
# Export it
|
||||
mkdir -p ../../patches
|
||||
git format-patch -1 --stdout --keep-subject --no-stat --full-index > ../../patches/update-patches.patch
|
||||
echo
|
||||
echo "======================================================================"
|
||||
echo "There were changes to the patches when applying."
|
||||
echo "Check the CI artifacts for a patch you can apply to fix it."
|
||||
echo "======================================================================"
|
||||
exit 1
|
||||
if [ "$IS_RELEASE" != "true" ]; then
|
||||
# Re-export all the patches to check if there were changes.
|
||||
python src/electron/script/export_all_patches.py src/electron/patches/config.json
|
||||
cd src/electron
|
||||
git update-index --refresh || true
|
||||
if ! git diff-index --quiet HEAD --; then
|
||||
# There are changes to the patches. Make a git commit with the updated patches
|
||||
git add patches
|
||||
GIT_COMMITTER_NAME="Electron Bot" GIT_COMMITTER_EMAIL="anonymous@electronjs.org" git commit -m "update patches" --author="Electron Bot <anonymous@electronjs.org>"
|
||||
# Export it
|
||||
mkdir -p ../../patches
|
||||
git format-patch -1 --stdout --keep-subject --no-stat --full-index > ../../patches/update-patches.patch
|
||||
echo
|
||||
echo "======================================================================"
|
||||
echo "There were changes to the patches when applying."
|
||||
echo "Check the CI artifacts for a patch you can apply to fix it."
|
||||
echo "======================================================================"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
@@ -572,6 +575,9 @@ step-electron-dist-build: &step-electron-dist-build
|
||||
if [ x"$MAS_BUILD" == x"true" ]; then
|
||||
target_os=mac_mas
|
||||
fi
|
||||
if [ "$TARGET_ARCH" == "arm64" ]; then
|
||||
target_cpu=arm64
|
||||
fi
|
||||
elif [ "`uname`" == "Linux" ]; then
|
||||
target_os=linux
|
||||
if [ x"$TARGET_ARCH" == x ]; then
|
||||
@@ -764,14 +770,20 @@ step-setup-linux-for-headless-testing: &step-setup-linux-for-headless-testing
|
||||
|
||||
step-show-sccache-stats: &step-show-sccache-stats
|
||||
run:
|
||||
shell: /bin/bash
|
||||
name: Check sccache/goma stats after build
|
||||
command: |
|
||||
if [ "$SCCACHE_PATH" != "" ]; then
|
||||
$SCCACHE_PATH -s
|
||||
fi
|
||||
if [ "$USE_GOMA" == "true" ]; then
|
||||
set +e
|
||||
set +o pipefail
|
||||
$LOCAL_GOMA_DIR/goma_ctl.py stat
|
||||
$LOCAL_GOMA_DIR/diagnose_goma_log.py
|
||||
true
|
||||
fi
|
||||
when: always
|
||||
|
||||
step-mksnapshot-build: &step-mksnapshot-build
|
||||
run:
|
||||
@@ -1799,7 +1811,7 @@ jobs:
|
||||
|
||||
# Layer 2: Builds.
|
||||
linux-x64-testing:
|
||||
<<: *machine-linux-xlarge
|
||||
<<: *machine-linux-2xlarge
|
||||
environment:
|
||||
<<: *env-global
|
||||
<<: *env-testing-build
|
||||
@@ -1879,7 +1891,7 @@ jobs:
|
||||
checkout: false
|
||||
|
||||
linux-ia32-testing:
|
||||
<<: *machine-linux-xlarge
|
||||
<<: *machine-linux-2xlarge
|
||||
environment:
|
||||
<<: *env-global
|
||||
<<: *env-ia32
|
||||
@@ -1945,7 +1957,7 @@ jobs:
|
||||
checkout: false
|
||||
|
||||
linux-arm-testing:
|
||||
<<: *machine-linux-xlarge
|
||||
<<: *machine-linux-2xlarge
|
||||
environment:
|
||||
<<: *env-global
|
||||
<<: *env-arm
|
||||
@@ -2012,7 +2024,7 @@ jobs:
|
||||
checkout: false
|
||||
|
||||
linux-arm64-testing:
|
||||
<<: *machine-linux-xlarge
|
||||
<<: *machine-linux-2xlarge
|
||||
environment:
|
||||
<<: *env-global
|
||||
<<: *env-arm64
|
||||
|
||||
10
.gitattributes
vendored
10
.gitattributes
vendored
@@ -2,3 +2,13 @@
|
||||
# files to be checked out with LF endings even if core.autocrlf is true.
|
||||
*.patch text eol=lf
|
||||
patches/**/.patches merge=union
|
||||
|
||||
# Source code and markdown files should always use LF as line ending.
|
||||
*.cc text eol=lf
|
||||
*.mm text eol=lf
|
||||
*.h text eol=lf
|
||||
*.js text eol=lf
|
||||
*.ts text eol=lf
|
||||
*.py text eol=lf
|
||||
*.ps1 text eol=lf
|
||||
*.md text eol=lf
|
||||
|
||||
103
BUILD.gn
103
BUILD.gn
@@ -325,7 +325,6 @@ source_set("electron_lib") {
|
||||
"//base/allocator:buildflags",
|
||||
"//chrome/app:command_ids",
|
||||
"//chrome/app/resources:platform_locale_settings",
|
||||
"//chrome/services/printing/public/mojom",
|
||||
"//components/certificate_transparency",
|
||||
"//components/language/core/browser",
|
||||
"//components/net_log",
|
||||
@@ -372,6 +371,7 @@ source_set("electron_lib") {
|
||||
"//third_party/libyuv",
|
||||
"//third_party/webrtc_overrides:webrtc_component",
|
||||
"//third_party/widevine/cdm:headers",
|
||||
"//third_party/zlib/google:zip",
|
||||
"//ui/base/idle",
|
||||
"//ui/events:dom_keycode_converter",
|
||||
"//ui/gl",
|
||||
@@ -405,44 +405,26 @@ source_set("electron_lib") {
|
||||
defines += [ "GDK_DISABLE_DEPRECATION_WARNINGS" ]
|
||||
}
|
||||
|
||||
extra_source_filters = []
|
||||
if (!is_linux) {
|
||||
extra_source_filters += [
|
||||
"*\bx/*",
|
||||
"*_x11.h",
|
||||
"*_x11.cc",
|
||||
"*_gtk.h",
|
||||
"*_gtk.cc",
|
||||
"*\blibrary_loaders/*",
|
||||
]
|
||||
}
|
||||
if (!is_win) {
|
||||
extra_source_filters += [
|
||||
"*\bwin_*.h",
|
||||
"*\bwin_*.cc",
|
||||
]
|
||||
}
|
||||
if (!is_posix) {
|
||||
extra_source_filters += [
|
||||
"*_posix.cc",
|
||||
"*_posix.h",
|
||||
]
|
||||
}
|
||||
if (is_mac) {
|
||||
extra_source_filters += [
|
||||
"*_views.cc",
|
||||
"*_views.h",
|
||||
"*\bviews/*",
|
||||
]
|
||||
}
|
||||
if (!is_mas_build) {
|
||||
deps += [ "//components/crash/core/app" ]
|
||||
}
|
||||
|
||||
set_sources_assignment_filter(
|
||||
sources_assignment_filter + extra_source_filters)
|
||||
sources = filenames.lib_sources
|
||||
set_sources_assignment_filter(sources_assignment_filter)
|
||||
if (is_win) {
|
||||
sources += filenames.lib_sources_win
|
||||
}
|
||||
if (is_mac) {
|
||||
sources += filenames.lib_sources_mac
|
||||
}
|
||||
if (is_posix) {
|
||||
sources += filenames.lib_sources_posix
|
||||
}
|
||||
if (is_linux) {
|
||||
sources += filenames.lib_sources_linux
|
||||
}
|
||||
if (!is_mac) {
|
||||
sources += filenames.lib_sources_views
|
||||
}
|
||||
|
||||
if (is_component_build) {
|
||||
defines += [ "NODE_SHARED_MODE" ]
|
||||
@@ -531,7 +513,9 @@ source_set("electron_lib") {
|
||||
]
|
||||
}
|
||||
configs += [ ":gio_unix" ]
|
||||
configs += [ "//build/config/linux:x11" ]
|
||||
if (use_x11) {
|
||||
deps += [ "//ui/gfx/x" ]
|
||||
}
|
||||
defines += [
|
||||
# Disable warnings for g_settings_list_schemas.
|
||||
"GLIB_DISABLE_DEPRECATION_WARNINGS",
|
||||
@@ -587,7 +571,6 @@ source_set("electron_lib") {
|
||||
sources += [
|
||||
"shell/browser/osr/osr_host_display_client.cc",
|
||||
"shell/browser/osr/osr_host_display_client.h",
|
||||
"shell/browser/osr/osr_host_display_client_mac.mm",
|
||||
"shell/browser/osr/osr_render_widget_host_view.cc",
|
||||
"shell/browser/osr/osr_render_widget_host_view.h",
|
||||
"shell/browser/osr/osr_video_consumer.cc",
|
||||
@@ -596,8 +579,13 @@ source_set("electron_lib") {
|
||||
"shell/browser/osr/osr_view_proxy.h",
|
||||
"shell/browser/osr/osr_web_contents_view.cc",
|
||||
"shell/browser/osr/osr_web_contents_view.h",
|
||||
"shell/browser/osr/osr_web_contents_view_mac.mm",
|
||||
]
|
||||
if (is_mac) {
|
||||
sources += [
|
||||
"shell/browser/osr/osr_host_display_client_mac.mm",
|
||||
"shell/browser/osr/osr_web_contents_view_mac.mm",
|
||||
]
|
||||
}
|
||||
deps += [
|
||||
"//components/viz/service",
|
||||
"//services/viz/public/mojom",
|
||||
@@ -632,7 +620,10 @@ source_set("electron_lib") {
|
||||
"shell/renderer/printing/print_render_frame_helper_delegate.cc",
|
||||
"shell/renderer/printing/print_render_frame_helper_delegate.h",
|
||||
]
|
||||
deps += [ "//components/printing/common:mojo_interfaces" ]
|
||||
deps += [
|
||||
"//chrome/services/printing/public/mojom",
|
||||
"//components/printing/common:mojo_interfaces",
|
||||
]
|
||||
}
|
||||
|
||||
if (enable_electron_extensions) {
|
||||
@@ -670,6 +661,14 @@ source_set("electron_lib") {
|
||||
"shell/browser/electron_pdf_web_contents_helper_client.h",
|
||||
]
|
||||
}
|
||||
|
||||
if (is_win && enable_win_dark_mode_window_ui) {
|
||||
sources += [
|
||||
"shell/browser/win/dark_mode.cc",
|
||||
"shell/browser/win/dark_mode.h",
|
||||
]
|
||||
libs += [ "uxtheme.lib" ]
|
||||
}
|
||||
}
|
||||
|
||||
electron_paks("packed_resources") {
|
||||
@@ -695,10 +694,10 @@ if (is_mac) {
|
||||
action("fake_v8_context_snapshot_generator") {
|
||||
script = "build/fake_v8_context_snapshot_generator.py"
|
||||
args = [
|
||||
rebase_path("$root_out_dir/v8_context_snapshot.bin"),
|
||||
rebase_path("$root_out_dir/fake/v8_context_snapshot.bin"),
|
||||
rebase_path("$root_out_dir/$v8_context_snapshot_filename"),
|
||||
rebase_path("$root_out_dir/fake/$v8_context_snapshot_filename"),
|
||||
]
|
||||
outputs = [ "$root_out_dir/fake/v8_context_snapshot.bin" ]
|
||||
outputs = [ "$root_out_dir/fake/$v8_context_snapshot_filename" ]
|
||||
}
|
||||
|
||||
bundle_data("electron_framework_resources") {
|
||||
@@ -712,10 +711,10 @@ if (is_mac) {
|
||||
public_deps += [ "//v8" ]
|
||||
if (use_v8_context_snapshot) {
|
||||
if (use_prebuilt_v8_context_snapshot) {
|
||||
sources += [ "$root_out_dir/fake/v8_context_snapshot.bin" ]
|
||||
sources += [ "$root_out_dir/fake/$v8_context_snapshot_filename" ]
|
||||
public_deps += [ ":fake_v8_context_snapshot_generator" ]
|
||||
} else {
|
||||
sources += [ "$root_out_dir/v8_context_snapshot.bin" ]
|
||||
sources += [ "$root_out_dir/$v8_context_snapshot_filename" ]
|
||||
public_deps += [ "//tools/v8_context_snapshot" ]
|
||||
}
|
||||
} else {
|
||||
@@ -1138,22 +1137,24 @@ if (is_mac) {
|
||||
"//components/crash/core/app:run_as_crashpad_handler",
|
||||
]
|
||||
|
||||
ldflags = []
|
||||
|
||||
libs = [
|
||||
"comctl32.lib",
|
||||
"uiautomationcore.lib",
|
||||
"wtsapi32.lib",
|
||||
]
|
||||
|
||||
configs += [ "//build/config/win:windowed" ]
|
||||
|
||||
ldflags = [
|
||||
# Windows 7 doesn't have these DLLs.
|
||||
# TODO: are there other DLLs we need to list here to be win7
|
||||
# compatible?
|
||||
"/DELAYLOAD:api-ms-win-core-winrt-l1-1-0.dll",
|
||||
"/DELAYLOAD:api-ms-win-core-winrt-string-l1-1-0.dll",
|
||||
configs += [
|
||||
"//build/config/win:windowed",
|
||||
"//build/config/win:delayloads",
|
||||
]
|
||||
|
||||
if (target_cpu == "arm64") {
|
||||
configs -= [ "//build/config/win:cfi_linker" ]
|
||||
ldflags += [ "/guard:cf,nolongjmp" ]
|
||||
}
|
||||
|
||||
# This is to support renaming of electron.exe. node-gyp has hard-coded
|
||||
# executable names which it will recognise as node. This module definition
|
||||
# file claims that the electron executable is in fact named "node.exe",
|
||||
|
||||
4
DEPS
4
DEPS
@@ -14,13 +14,13 @@ gclient_gn_args = [
|
||||
|
||||
vars = {
|
||||
'chromium_version':
|
||||
'b04584161e07d4ac110045b7647fa8a81f5f0709',
|
||||
'87.0.4280.40',
|
||||
'node_version':
|
||||
'v12.18.3',
|
||||
'nan_version':
|
||||
'2c4ee8a32a299eada3cd6e468bbd0a473bfea96d',
|
||||
'squirrel.mac_version':
|
||||
'44468f858ce0d25c27bd5e674abfa104e0119738',
|
||||
'a3a5b3f03b824441c014893b18f99a103b2603e9',
|
||||
|
||||
'boto_version': 'f7574aa6cc2c819430c1f05e9a1a1a666ef8169b',
|
||||
'pyyaml_version': '3.12',
|
||||
|
||||
@@ -1 +1 @@
|
||||
11.0.0-nightly.20200826
|
||||
11.0.0-beta.20
|
||||
19
appveyor.yml
19
appveyor.yml
@@ -53,7 +53,9 @@ build_script:
|
||||
} else {
|
||||
node script/yarn.js install --frozen-lockfile
|
||||
|
||||
if ($(node script/doc-only-change.js --prNumber=$env:APPVEYOR_PULL_REQUEST_NUMBER --prBranch=$env:APPVEYOR_REPO_BRANCH;$LASTEXITCODE -eq 0)) {
|
||||
$result = node script/doc-only-change.js --prNumber=$env:APPVEYOR_PULL_REQUEST_NUMBER --prBranch=$env:APPVEYOR_REPO_BRANCH
|
||||
Write-Output $result
|
||||
if ($result.ExitCode -eq 0) {
|
||||
Write-warning "Skipping build for doc only change"; Exit-AppveyorBuild
|
||||
}
|
||||
}
|
||||
@@ -114,14 +116,16 @@ build_script:
|
||||
if ($env:SAVE_GCLIENT_SRC -eq 'true') {
|
||||
# archive current source for future use
|
||||
# only run on x64/woa to avoid contention saving
|
||||
if ($(7z a $zipfile src -xr!android_webview -xr!electron -xr'!*\.git' -xr!third_party\WebKit\LayoutTests! -xr!third_party\blink\web_tests -xr!third_party\blink\perf_tests -slp -t7z -mmt=30;$LASTEXITCODE -ne 0)) {
|
||||
$(7z a $zipfile src -xr!android_webview -xr!electron -xr'!*\.git' -xr!third_party\WebKit\LayoutTests! -xr!third_party\blink\web_tests -xr!third_party\blink\perf_tests -slp -t7z -mmt=30)
|
||||
if ($LASTEXITCODE -ne 0) {
|
||||
Write-warning "Could not save source to shared drive; continuing anyway"
|
||||
}
|
||||
# build time generation of file gen/angle/commit.h depends on
|
||||
# third_party/angle/.git/HEAD.
|
||||
# build time generation of file gen/angle/angle_commit.h depends on
|
||||
# third_party/angle/.git
|
||||
# https://chromium-review.googlesource.com/c/angle/angle/+/2074924
|
||||
if ($(7z a $zipfile src\third_party\angle\.git\HEAD;$LASTEXITCODE -ne 0)) {
|
||||
Write-warning "Failed to add third_party\angle\.git\HEAD; continuing anyway"
|
||||
$(7z a $zipfile src\third_party\angle\.git)
|
||||
if ($LASTEXITCODE -ne 0) {
|
||||
Write-warning "Failed to add third_party\angle\.git; continuing anyway"
|
||||
}
|
||||
}
|
||||
- ps: >-
|
||||
@@ -205,7 +209,8 @@ test_script:
|
||||
echo "Skipping tests for $env:GN_CONFIG build"
|
||||
}
|
||||
- cd electron
|
||||
- if "%RUN_TESTS%"=="true" ( echo Running test suite & node script/yarn test -- --trace-uncaught --enable-logging)
|
||||
# CalculateNativeWinOcclusion is disabled due to https://bugs.chromium.org/p/chromium/issues/detail?id=1139022
|
||||
- if "%RUN_TESTS%"=="true" ( echo Running test suite & node script/yarn test -- --trace-uncaught --enable-logging --disable-features=CalculateNativeWinOcclusion )
|
||||
- cd ..
|
||||
- if "%RUN_TESTS%"=="true" ( echo Verifying non proprietary ffmpeg & python electron\script\verify-ffmpeg.py --build-dir out\Default --source-root %cd% --ffmpeg-path out\ffmpeg )
|
||||
- echo "About to verify mksnapshot"
|
||||
|
||||
@@ -63,7 +63,8 @@ steps:
|
||||
set npm_config_nodedir=%cd%\out\Default\gen\node_headers
|
||||
set npm_config_arch=arm64
|
||||
cd electron
|
||||
node script/yarn test -- --enable-logging --verbose
|
||||
# CalculateNativeWinOcclusion is disabled due to https://bugs.chromium.org/p/chromium/issues/detail?id=1139022
|
||||
node script/yarn test -- --enable-logging --verbose --disable-features=CalculateNativeWinOcclusion
|
||||
displayName: 'Run Electron tests'
|
||||
env:
|
||||
ELECTRON_OUT_DIR: Default
|
||||
|
||||
@@ -2,7 +2,7 @@ is_electron_build = true
|
||||
root_extra_deps = [ "//electron" ]
|
||||
|
||||
# Registry of NMVs --> https://github.com/nodejs/node/blob/master/doc/abi_version_registry.json
|
||||
node_module_version = 82
|
||||
node_module_version = 85
|
||||
|
||||
v8_promise_internal_field_count = 1
|
||||
v8_typed_array_max_size_in_heap = 0
|
||||
|
||||
@@ -10,10 +10,9 @@ config.output = {
|
||||
filename: path.basename(outPath)
|
||||
};
|
||||
|
||||
const { wrapInitWithProfilingTimeout } = config;
|
||||
delete config.wrapInitWithProfilingTimeout;
|
||||
const { wrapInitWithProfilingTimeout, wrapInitWithTryCatch, ...webpackConfig } = config;
|
||||
|
||||
webpack(config, (err, stats) => {
|
||||
webpack(webpackConfig, (err, stats) => {
|
||||
if (err) {
|
||||
console.error(err);
|
||||
process.exit(1);
|
||||
@@ -21,9 +20,17 @@ webpack(config, (err, stats) => {
|
||||
console.error(stats.toString('normal'));
|
||||
process.exit(1);
|
||||
} else {
|
||||
let contents = fs.readFileSync(outPath, 'utf8');
|
||||
if (wrapInitWithTryCatch) {
|
||||
contents = `try {
|
||||
${contents}
|
||||
} catch (err) {
|
||||
console.error('Electron ${webpackConfig.output.filename} script failed to run');
|
||||
console.error(err);
|
||||
}`;
|
||||
}
|
||||
if (wrapInitWithProfilingTimeout) {
|
||||
const contents = fs.readFileSync(outPath, 'utf8');
|
||||
const newContents = `function ___electron_webpack_init__() {
|
||||
contents = `function ___electron_webpack_init__() {
|
||||
${contents}
|
||||
};
|
||||
if ((globalThis.process || binding.process).argv.includes("--profile-electron-init")) {
|
||||
@@ -31,8 +38,8 @@ if ((globalThis.process || binding.process).argv.includes("--profile-electron-in
|
||||
} else {
|
||||
___electron_webpack_init__();
|
||||
}`;
|
||||
fs.writeFileSync(outPath, newContents);
|
||||
}
|
||||
fs.writeFileSync(outPath, contents);
|
||||
process.exit(0);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -69,7 +69,8 @@ module.exports = ({
|
||||
loadElectronFromAlternateTarget,
|
||||
targetDeletesNodeGlobals,
|
||||
target,
|
||||
wrapInitWithProfilingTimeout
|
||||
wrapInitWithProfilingTimeout,
|
||||
wrapInitWithTryCatch
|
||||
}) => {
|
||||
let entry = path.resolve(electronRoot, 'lib', target, 'init.ts');
|
||||
if (!fs.existsSync(entry)) {
|
||||
@@ -87,6 +88,7 @@ module.exports = ({
|
||||
filename: `${target}.bundle.js`
|
||||
},
|
||||
wrapInitWithProfilingTimeout,
|
||||
wrapInitWithTryCatch,
|
||||
resolve: {
|
||||
alias: {
|
||||
'@electron/internal': path.resolve(electronRoot, 'lib'),
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
module.exports = require('./webpack.config.base')({
|
||||
target: 'isolated_renderer',
|
||||
alwaysHasNode: false
|
||||
alwaysHasNode: false,
|
||||
wrapInitWithTryCatch: true
|
||||
});
|
||||
|
||||
@@ -2,5 +2,6 @@ module.exports = require('./webpack.config.base')({
|
||||
target: 'renderer',
|
||||
alwaysHasNode: true,
|
||||
targetDeletesNodeGlobals: true,
|
||||
wrapInitWithProfilingTimeout: true
|
||||
wrapInitWithProfilingTimeout: true,
|
||||
wrapInitWithTryCatch: true
|
||||
});
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
module.exports = require('./webpack.config.base')({
|
||||
target: 'sandboxed_renderer',
|
||||
alwaysHasNode: false,
|
||||
wrapInitWithProfilingTimeout: true
|
||||
wrapInitWithProfilingTimeout: true,
|
||||
wrapInitWithTryCatch: true
|
||||
});
|
||||
|
||||
@@ -2,5 +2,6 @@ module.exports = require('./webpack.config.base')({
|
||||
target: 'worker',
|
||||
loadElectronFromAlternateTarget: 'renderer',
|
||||
alwaysHasNode: true,
|
||||
targetDeletesNodeGlobals: true
|
||||
targetDeletesNodeGlobals: true,
|
||||
wrapInitWithTryCatch: true
|
||||
});
|
||||
|
||||
21
build/zip.py
21
build/zip.py
@@ -13,27 +13,30 @@ EXTENSIONS_TO_SKIP = [
|
||||
]
|
||||
|
||||
PATHS_TO_SKIP = [
|
||||
'angledata', #Skipping because it is an output of //ui/gl that we don't need
|
||||
'./libVkICD_mock_', #Skipping because these are outputs that we don't need
|
||||
'./VkICD_mock_', #Skipping because these are outputs that we don't need
|
||||
|
||||
# Skipping because its an output of create_bundle from //build/config/mac/rules.gni
|
||||
# Skip because it is an output of //ui/gl that we don't need.
|
||||
'angledata',
|
||||
# Skip because these are outputs that we don't need.
|
||||
'./libVkICD_mock_',
|
||||
# Skip because these are outputs that we don't need.
|
||||
'./VkICD_mock_',
|
||||
# Skip because its an output of create_bundle from //build/config/mac/rules.gni
|
||||
# that we don't need
|
||||
'Electron.dSYM',
|
||||
|
||||
# Refs https://chromium-review.googlesource.com/c/angle/angle/+/2425197.
|
||||
# Remove this when Angle themselves remove the file: https://issuetracker.google.com/issues/168736059
|
||||
'gen/angle/angle_commit.h',
|
||||
# //chrome/browser:resources depends on this via
|
||||
# //chrome/browser/resources/ssl/ssl_error_assistant, but we don't need to
|
||||
# ship it.
|
||||
'pyproto',
|
||||
|
||||
# On Windows, this binary doesn't exist (the crashpad handler is built-in).
|
||||
# On MacOS, the binary is called 'chrome_crashpad_handler' and is inside the
|
||||
# app bundle.
|
||||
# On Linux, we don't use crashpad, but this binary is still built for some
|
||||
# reason. Exclude it from the zip.
|
||||
'./crashpad_handler',
|
||||
|
||||
'resources/inspector', #Skipping because these are outputs that we don't need
|
||||
# Skip because these are outputs that we don't need.
|
||||
'resources/inspector',
|
||||
]
|
||||
|
||||
def skip_path(dep, dist_zip, target_cpu):
|
||||
|
||||
@@ -21,6 +21,7 @@ buildflag_header("buildflags") {
|
||||
"ENABLE_ELECTRON_EXTENSIONS=$enable_electron_extensions",
|
||||
"ENABLE_BUILTIN_SPELLCHECKER=$enable_builtin_spellchecker",
|
||||
"ENABLE_PICTURE_IN_PICTURE=$enable_picture_in_picture",
|
||||
"ENABLE_WIN_DARK_MODE_WINDOW_UI=$enable_win_dark_mode_window_ui",
|
||||
"OVERRIDE_LOCATION_PROVIDER=$enable_fake_location_provider",
|
||||
]
|
||||
}
|
||||
|
||||
@@ -36,4 +36,7 @@ declare_args() {
|
||||
|
||||
# Enable Spellchecker support
|
||||
enable_builtin_spellchecker = true
|
||||
|
||||
# Undocumented Windows dark mode API
|
||||
enable_win_dark_mode_window_ui = false
|
||||
}
|
||||
|
||||
@@ -26,18 +26,10 @@ static_library("chrome") {
|
||||
"//chrome/browser/devtools/devtools_file_system_indexer.h",
|
||||
"//chrome/browser/extensions/global_shortcut_listener.cc",
|
||||
"//chrome/browser/extensions/global_shortcut_listener.h",
|
||||
"//chrome/browser/extensions/global_shortcut_listener_mac.h",
|
||||
"//chrome/browser/extensions/global_shortcut_listener_mac.mm",
|
||||
"//chrome/browser/extensions/global_shortcut_listener_win.cc",
|
||||
"//chrome/browser/extensions/global_shortcut_listener_win.h",
|
||||
"//chrome/browser/icon_loader.cc",
|
||||
"//chrome/browser/icon_loader.h",
|
||||
"//chrome/browser/icon_loader_mac.mm",
|
||||
"//chrome/browser/icon_loader_win.cc",
|
||||
"//chrome/browser/icon_manager.cc",
|
||||
"//chrome/browser/icon_manager.h",
|
||||
"//chrome/browser/media/webrtc/system_media_capture_permissions_mac.h",
|
||||
"//chrome/browser/media/webrtc/system_media_capture_permissions_mac.mm",
|
||||
"//chrome/browser/net/chrome_mojo_proxy_resolver_factory.cc",
|
||||
"//chrome/browser/net/chrome_mojo_proxy_resolver_factory.h",
|
||||
"//chrome/browser/net/proxy_config_monitor.cc",
|
||||
@@ -57,14 +49,32 @@ static_library("chrome") {
|
||||
"//chrome/browser/ssl/tls_deprecation_config.cc",
|
||||
"//chrome/browser/ui/views/autofill/autofill_popup_view_utils.cc",
|
||||
"//chrome/browser/ui/views/autofill/autofill_popup_view_utils.h",
|
||||
"//chrome/browser/win/chrome_process_finder.cc",
|
||||
"//chrome/browser/win/chrome_process_finder.h",
|
||||
"//chrome/child/v8_crashpad_support_win.cc",
|
||||
"//chrome/child/v8_crashpad_support_win.h",
|
||||
"//extensions/browser/app_window/size_constraints.cc",
|
||||
"//extensions/browser/app_window/size_constraints.h",
|
||||
]
|
||||
|
||||
if (is_mac) {
|
||||
sources += [
|
||||
"//chrome/browser/extensions/global_shortcut_listener_mac.h",
|
||||
"//chrome/browser/extensions/global_shortcut_listener_mac.mm",
|
||||
"//chrome/browser/icon_loader_mac.mm",
|
||||
"//chrome/browser/media/webrtc/system_media_capture_permissions_mac.h",
|
||||
"//chrome/browser/media/webrtc/system_media_capture_permissions_mac.mm",
|
||||
]
|
||||
}
|
||||
|
||||
if (is_win) {
|
||||
sources += [
|
||||
"//chrome/browser/extensions/global_shortcut_listener_win.cc",
|
||||
"//chrome/browser/extensions/global_shortcut_listener_win.h",
|
||||
"//chrome/browser/icon_loader_win.cc",
|
||||
"//chrome/browser/win/chrome_process_finder.cc",
|
||||
"//chrome/browser/win/chrome_process_finder.h",
|
||||
"//chrome/child/v8_crashpad_support_win.cc",
|
||||
"//chrome/child/v8_crashpad_support_win.h",
|
||||
]
|
||||
}
|
||||
|
||||
public_deps = [
|
||||
"//chrome/common",
|
||||
"//chrome/common:version_header",
|
||||
@@ -266,6 +276,15 @@ static_library("chrome") {
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
sources += [ "//chrome/browser/hang_monitor/hang_crash_dump.h" ]
|
||||
if (is_mac) {
|
||||
sources += [ "//chrome/browser/hang_monitor/hang_crash_dump_mac.cc" ]
|
||||
} else if (is_win) {
|
||||
sources += [ "//chrome/browser/hang_monitor/hang_crash_dump_win.cc" ]
|
||||
} else {
|
||||
sources += [ "//chrome/browser/hang_monitor/hang_crash_dump.cc" ]
|
||||
}
|
||||
}
|
||||
|
||||
source_set("plugins") {
|
||||
|
||||
@@ -36,6 +36,7 @@ net::NSSCertDatabase* GetNSSCertDatabaseForResourceContext(
|
||||
// Linux has only a single persistent slot compared to ChromeOS's separate
|
||||
// public and private slot.
|
||||
// Redirect any slot usage to this persistent slot on Linux.
|
||||
crypto::EnsureNSSInit();
|
||||
g_nss_cert_database = new net::NSSCertDatabase(
|
||||
crypto::ScopedPK11Slot(PK11_GetInternalKeySlot()) /* public slot */,
|
||||
crypto::ScopedPK11Slot(PK11_GetInternalKeySlot()) /* private slot */);
|
||||
|
||||
@@ -826,10 +826,9 @@ ProcessSingleton::NotifyResult ProcessSingleton::NotifyOtherProcessWithTimeout(
|
||||
to_send.append(current_dir.value());
|
||||
|
||||
const std::vector<std::string>& argv = electron::ElectronCommandLine::argv();
|
||||
for (std::vector<std::string>::const_iterator it = argv.begin();
|
||||
it != argv.end(); ++it) {
|
||||
for (const auto& arg : argv) {
|
||||
to_send.push_back(kTokenDelimiter);
|
||||
to_send.append(*it);
|
||||
to_send.append(arg);
|
||||
}
|
||||
|
||||
// Send the message
|
||||
|
||||
@@ -122,8 +122,7 @@ void GlobalMenuBarRegistrarX11::OnNameOwnerChanged(GObject* /* ignored */,
|
||||
GParamSpec* /* ignored */) {
|
||||
// If the name owner changed, we need to reregister all the live x11::Window
|
||||
// with the system.
|
||||
for (std::set<x11::Window>::const_iterator it = live_windows_.begin();
|
||||
it != live_windows_.end(); ++it) {
|
||||
RegisterXWindow(*it);
|
||||
for (const auto& window : live_windows_) {
|
||||
RegisterXWindow(window);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,7 +32,8 @@ In most cases, you should do everything in the `ready` event handler.
|
||||
|
||||
Returns:
|
||||
|
||||
* `launchInfo` unknown _macOS_
|
||||
* `event` Event
|
||||
* `launchInfo` Record<string, any> _macOS_
|
||||
|
||||
Emitted once, when Electron has finished initializing. On macOS, `launchInfo`
|
||||
holds the `userInfo` of the `NSUserNotification` that was used to open the
|
||||
@@ -402,7 +403,7 @@ Returns:
|
||||
* `killed` - Process was sent a SIGTERM or otherwise killed externally
|
||||
* `crashed` - Process crashed
|
||||
* `oom` - Process ran out of memory
|
||||
* `launch-failure` - Process never successfully launched
|
||||
* `launch-failed` - Process never successfully launched
|
||||
* `integrity-failure` - Windows code integrity checks failed
|
||||
|
||||
Emitted when the renderer process unexpectedly disappears. This is normally
|
||||
@@ -428,7 +429,7 @@ Returns:
|
||||
* `killed` - Process was sent a SIGTERM or otherwise killed externally
|
||||
* `crashed` - Process crashed
|
||||
* `oom` - Process ran out of memory
|
||||
* `launch-failure` - Process never successfully launched
|
||||
* `launch-failed` - Process never successfully launched
|
||||
* `integrity-failure` - Windows code integrity checks failed
|
||||
* `exitCode` Number - The exit code for the process
|
||||
(e.g. status from waitpid if on posix, from GetExitCodeProcess on Windows).
|
||||
|
||||
@@ -670,6 +670,20 @@ Emitted when the window has closed a sheet.
|
||||
|
||||
Emitted when the native new tab button is clicked.
|
||||
|
||||
#### Event: 'system-context-menu' _Windows_
|
||||
|
||||
Returns:
|
||||
|
||||
* `event` Event
|
||||
* `point` [Point](structures/point.md) - The screen coordinates the context menu was triggered at
|
||||
|
||||
Emitted when the system context menu is triggered on the window, this is
|
||||
normally only triggered when the user right clicks on the non-client area
|
||||
of your window. This is the window titlebar or any area you have declared
|
||||
as `-webkit-app-region: drag` in a frameless window.
|
||||
|
||||
Calling `event.preventDefault()` will prevent the menu from being displayed.
|
||||
|
||||
### Static Methods
|
||||
|
||||
The `BrowserWindow` class has the following static methods:
|
||||
|
||||
@@ -198,6 +198,14 @@ logging level for all code in the source files under a `foo/bar` directory.
|
||||
|
||||
This switch only works when `--enable-logging` is also passed.
|
||||
|
||||
### --force_high_performance_gpu
|
||||
|
||||
Force using discrete GPU when there are multiple GPUs available.
|
||||
|
||||
### --force_low_power_gpu
|
||||
|
||||
Force using integrated GPU when there are multiple GPUs available.
|
||||
|
||||
## Node.js Flags
|
||||
|
||||
Electron supports some of the [CLI flags][node-cli] supported by Node.js.
|
||||
|
||||
@@ -72,50 +72,6 @@ const constraints = {
|
||||
}
|
||||
```
|
||||
|
||||
This example shows how to capture a video from a [WebContents](web-contents.md)
|
||||
|
||||
```javascript
|
||||
// In the renderer process.
|
||||
const { desktopCapturer, remote } = require('electron')
|
||||
|
||||
desktopCapturer.getMediaSourceIdForWebContents(remote.getCurrentWebContents().id).then(async mediaSourceId => {
|
||||
try {
|
||||
const stream = await navigator.mediaDevices.getUserMedia({
|
||||
audio: {
|
||||
mandatory: {
|
||||
chromeMediaSource: 'tab',
|
||||
chromeMediaSourceId: mediaSourceId
|
||||
}
|
||||
},
|
||||
video: {
|
||||
mandatory: {
|
||||
chromeMediaSource: 'tab',
|
||||
chromeMediaSourceId: mediaSourceId,
|
||||
minWidth: 1280,
|
||||
maxWidth: 1280,
|
||||
minHeight: 720,
|
||||
maxHeight: 720
|
||||
}
|
||||
}
|
||||
})
|
||||
handleStream(stream)
|
||||
} catch (e) {
|
||||
handleError(e)
|
||||
}
|
||||
})
|
||||
|
||||
function handleStream (stream) {
|
||||
const video = document.querySelector('video')
|
||||
video.srcObject = stream
|
||||
video.onloadedmetadata = (e) => video.play()
|
||||
}
|
||||
|
||||
function handleError (e) {
|
||||
console.log(e)
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
## Methods
|
||||
|
||||
The `desktopCapturer` module has the following methods:
|
||||
@@ -138,15 +94,6 @@ Returns `Promise<DesktopCapturerSource[]>` - Resolves with an array of [`Desktop
|
||||
**Note** Capturing the screen contents requires user consent on macOS 10.15 Catalina or higher,
|
||||
which can detected by [`systemPreferences.getMediaAccessStatus`].
|
||||
|
||||
### `desktopCapturer.getMediaSourceIdForWebContents(webContentsId)`
|
||||
|
||||
* `webContentsId` number - Id of the WebContents to get stream of
|
||||
|
||||
Returns `Promise<string>` - Resolves with the identifier of a WebContents stream, this identifier can be
|
||||
used with [`navigator.mediaDevices.getUserMedia`].
|
||||
The identifier is **only valid for 10 seconds**.
|
||||
The identifier may be empty if not requested from a renderer process.
|
||||
|
||||
[`navigator.mediaDevices.getUserMedia`]: https://developer.mozilla.org/en/docs/Web/API/MediaDevices/getUserMedia
|
||||
[`systemPreferences.getMediaAccessStatus`]: system-preferences.md#systempreferencesgetmediaaccessstatusmediatype-macos
|
||||
|
||||
|
||||
@@ -102,3 +102,15 @@ The following methods of `chrome.tabs` are supported:
|
||||
> **Note:** In Chrome, passing `-1` as a tab ID signifies the "currently active
|
||||
> tab". Since Electron has no such concept, passing `-1` as a tab ID is not
|
||||
> supported and will raise an error.
|
||||
|
||||
### `chrome.management`
|
||||
|
||||
The following methods of `chrome.management` are supported:
|
||||
|
||||
- `chrome.management.getAll`
|
||||
- `chrome.management.get`
|
||||
- `chrome.management.getSelf`
|
||||
- `chrome.management.getPermissionWarningsById`
|
||||
- `chrome.management.getPermissionWarningsByManifest`
|
||||
- `chrome.management.onEnabled`
|
||||
- `chrome.management.onDisabled`
|
||||
|
||||
@@ -8,19 +8,19 @@ Process: [Main](../glossary.md#main-process)
|
||||
|
||||
The `powerMonitor` module emits the following events:
|
||||
|
||||
### Event: 'suspend'
|
||||
### Event: 'suspend' _macOS_ _Windows_
|
||||
|
||||
Emitted when the system is suspending.
|
||||
|
||||
### Event: 'resume'
|
||||
### Event: 'resume' _macOS_ _Windows_
|
||||
|
||||
Emitted when system is resuming.
|
||||
|
||||
### Event: 'on-ac' _Windows_
|
||||
### Event: 'on-ac' _macOS_ _Windows_
|
||||
|
||||
Emitted when the system changes to AC power.
|
||||
|
||||
### Event: 'on-battery' _Windows_
|
||||
### Event: 'on-battery' _macOS_ _Windows_
|
||||
|
||||
Emitted when system changes to battery power.
|
||||
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
# StreamProtocolResponse Object
|
||||
|
||||
* `statusCode` Number (optional) - The HTTP response code.
|
||||
* `headers` Record<String, String | String[]> (optional) - An object containing the response headers.
|
||||
* `data` ReadableStream | null - A Node.js readable stream representing the response body.
|
||||
@@ -1,5 +0,0 @@
|
||||
# StringProtocolResponse Object
|
||||
|
||||
* `mimeType` String (optional) - MIME type of the response.
|
||||
* `charset` String (optional) - Charset of the response.
|
||||
* `data` String | null - A string representing the response body.
|
||||
@@ -364,7 +364,7 @@ Returns:
|
||||
* `killed` - Process was sent a SIGTERM or otherwise killed externally
|
||||
* `crashed` - Process crashed
|
||||
* `oom` - Process ran out of memory
|
||||
* `launch-failure` - Process never successfully launched
|
||||
* `launch-failed` - Process never successfully launched
|
||||
* `integrity-failure` - Windows code integrity checks failed
|
||||
|
||||
Emitted when the renderer process unexpectedly disappears. This is normally
|
||||
@@ -998,6 +998,34 @@ Navigates to the specified offset from the "current entry".
|
||||
|
||||
Returns `Boolean` - Whether the renderer process has crashed.
|
||||
|
||||
#### `contents.forcefullyCrashRenderer()`
|
||||
|
||||
Forcefully terminates the renderer process that is currently hosting this
|
||||
`webContents`. This will cause the `render-process-gone` event to be emitted
|
||||
with the `reason=killed || reason=crashed`. Please note that some webContents share renderer
|
||||
processes and therefore calling this method may also crash the host process
|
||||
for other webContents as well.
|
||||
|
||||
Calling `reload()` immediately after calling this
|
||||
method will force the reload to occur in a new process. This should be used
|
||||
when this process is unstable or unusable, for instance in order to recover
|
||||
from the `unresponsive` event.
|
||||
|
||||
```js
|
||||
contents.on('unresponsive', async () => {
|
||||
const { response } = await dialog.showMessageBox({
|
||||
message: 'App X has become unresponsive',
|
||||
title: 'Do you want to try forcefully reloading the app?',
|
||||
buttons: ['OK', 'Cancel'],
|
||||
cancelId: 1
|
||||
})
|
||||
if (response === 0) {
|
||||
contents.forcefullyCrashRenderer()
|
||||
contents.reload()
|
||||
}
|
||||
})
|
||||
```
|
||||
|
||||
#### `contents.setUserAgent(userAgent)`
|
||||
|
||||
* `userAgent` String
|
||||
|
||||
@@ -1,61 +0,0 @@
|
||||
# Breaking changes (NetworkService) (Draft)
|
||||
|
||||
This document describes changes to Electron APIs after migrating network code
|
||||
to NetworkService API.
|
||||
|
||||
We don't currently have an estimate of when we will enable `NetworkService` by
|
||||
default in Electron, but as Chromium is already removing non-`NetworkService`
|
||||
code, we might switch before Electron 10.
|
||||
|
||||
The content of this document should be moved to `breaking-changes.md` once we have
|
||||
determined when to enable `NetworkService` in Electron.
|
||||
|
||||
## Planned Breaking API Changes
|
||||
|
||||
### `protocol.unregisterProtocol`
|
||||
### `protocol.uninterceptProtocol`
|
||||
|
||||
The APIs are now synchronous and the optional callback is no longer needed.
|
||||
|
||||
```javascript
|
||||
// Deprecated
|
||||
protocol.unregisterProtocol(scheme, () => { /* ... */ })
|
||||
// Replace with
|
||||
protocol.unregisterProtocol(scheme)
|
||||
```
|
||||
|
||||
### `protocol.registerFileProtocol`
|
||||
### `protocol.registerBufferProtocol`
|
||||
### `protocol.registerStringProtocol`
|
||||
### `protocol.registerHttpProtocol`
|
||||
### `protocol.registerStreamProtocol`
|
||||
### `protocol.interceptFileProtocol`
|
||||
### `protocol.interceptStringProtocol`
|
||||
### `protocol.interceptBufferProtocol`
|
||||
### `protocol.interceptHttpProtocol`
|
||||
### `protocol.interceptStreamProtocol`
|
||||
|
||||
The APIs are now synchronous and the optional callback is no longer needed.
|
||||
|
||||
```javascript
|
||||
// Deprecated
|
||||
protocol.registerFileProtocol(scheme, handler, () => { /* ... */ })
|
||||
// Replace with
|
||||
protocol.registerFileProtocol(scheme, handler)
|
||||
```
|
||||
|
||||
The registered or intercepted protocol does not have effect on current page
|
||||
until navigation happens.
|
||||
|
||||
### `protocol.isProtocolHandled`
|
||||
|
||||
This API is deprecated and users should use `protocol.isProtocolRegistered`
|
||||
and `protocol.isProtocolIntercepted` instead.
|
||||
|
||||
```javascript
|
||||
// Deprecated
|
||||
protocol.isProtocolHandled(scheme).then(() => { /* ... */ })
|
||||
// Replace with
|
||||
const isRegistered = protocol.isProtocolRegistered(scheme)
|
||||
const isIntercepted = protocol.isProtocolIntercepted(scheme)
|
||||
```
|
||||
@@ -133,6 +133,54 @@ const w = new BrowserWindow({
|
||||
We [recommend moving away from the remote
|
||||
module](https://medium.com/@nornagon/electrons-remote-module-considered-harmful-70d69500f31).
|
||||
|
||||
### `protocol.unregisterProtocol`
|
||||
### `protocol.uninterceptProtocol`
|
||||
|
||||
The APIs are now synchronous and the optional callback is no longer needed.
|
||||
|
||||
```javascript
|
||||
// Deprecated
|
||||
protocol.unregisterProtocol(scheme, () => { /* ... */ })
|
||||
// Replace with
|
||||
protocol.unregisterProtocol(scheme)
|
||||
```
|
||||
|
||||
### `protocol.registerFileProtocol`
|
||||
### `protocol.registerBufferProtocol`
|
||||
### `protocol.registerStringProtocol`
|
||||
### `protocol.registerHttpProtocol`
|
||||
### `protocol.registerStreamProtocol`
|
||||
### `protocol.interceptFileProtocol`
|
||||
### `protocol.interceptStringProtocol`
|
||||
### `protocol.interceptBufferProtocol`
|
||||
### `protocol.interceptHttpProtocol`
|
||||
### `protocol.interceptStreamProtocol`
|
||||
|
||||
The APIs are now synchronous and the optional callback is no longer needed.
|
||||
|
||||
```javascript
|
||||
// Deprecated
|
||||
protocol.registerFileProtocol(scheme, handler, () => { /* ... */ })
|
||||
// Replace with
|
||||
protocol.registerFileProtocol(scheme, handler)
|
||||
```
|
||||
|
||||
The registered or intercepted protocol does not have effect on current page
|
||||
until navigation happens.
|
||||
|
||||
### `protocol.isProtocolHandled`
|
||||
|
||||
This API is deprecated and users should use `protocol.isProtocolRegistered`
|
||||
and `protocol.isProtocolIntercepted` instead.
|
||||
|
||||
```javascript
|
||||
// Deprecated
|
||||
protocol.isProtocolHandled(scheme).then(() => { /* ... */ })
|
||||
// Replace with
|
||||
const isRegistered = protocol.isProtocolRegistered(scheme)
|
||||
const isIntercepted = protocol.isProtocolIntercepted(scheme)
|
||||
```
|
||||
|
||||
## Planned Breaking API Changes (9.0)
|
||||
|
||||
### Default Changed: Loading non-context-aware native modules in the renderer process is disabled by default
|
||||
|
||||
@@ -1,95 +1,95 @@
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow, ipcMain, dialog } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
ipcMain.on('open-error-dialog', event => {
|
||||
dialog.showErrorBox('An Error Message', 'Demonstrating an error message.')
|
||||
})
|
||||
|
||||
ipcMain.on('open-information-dialog', event => {
|
||||
const options = {
|
||||
type: 'info',
|
||||
title: 'Information',
|
||||
message: "This is an information dialog. Isn't it nice?",
|
||||
buttons: ['Yes', 'No']
|
||||
}
|
||||
dialog.showMessageBox(options, index => {
|
||||
event.sender.send('information-dialog-selection', index)
|
||||
})
|
||||
})
|
||||
|
||||
ipcMain.on('open-file-dialog', event => {
|
||||
dialog.showOpenDialog(
|
||||
{
|
||||
properties: ['openFile', 'openDirectory']
|
||||
},
|
||||
files => {
|
||||
if (files) {
|
||||
event.sender.send('selected-directory', files)
|
||||
}
|
||||
}
|
||||
)
|
||||
})
|
||||
|
||||
ipcMain.on('save-dialog', event => {
|
||||
const options = {
|
||||
title: 'Save an Image',
|
||||
filters: [{ name: 'Images', extensions: ['jpg', 'png', 'gif'] }]
|
||||
}
|
||||
dialog.showSaveDialog(options, filename => {
|
||||
event.sender.send('saved-file', filename)
|
||||
})
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow, ipcMain, dialog } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
ipcMain.on('open-error-dialog', event => {
|
||||
dialog.showErrorBox('An Error Message', 'Demonstrating an error message.')
|
||||
})
|
||||
|
||||
ipcMain.on('open-information-dialog', event => {
|
||||
const options = {
|
||||
type: 'info',
|
||||
title: 'Information',
|
||||
message: "This is an information dialog. Isn't it nice?",
|
||||
buttons: ['Yes', 'No']
|
||||
}
|
||||
dialog.showMessageBox(options, index => {
|
||||
event.sender.send('information-dialog-selection', index)
|
||||
})
|
||||
})
|
||||
|
||||
ipcMain.on('open-file-dialog', event => {
|
||||
dialog.showOpenDialog(
|
||||
{
|
||||
properties: ['openFile', 'openDirectory']
|
||||
},
|
||||
files => {
|
||||
if (files) {
|
||||
event.sender.send('selected-directory', files)
|
||||
}
|
||||
}
|
||||
)
|
||||
})
|
||||
|
||||
ipcMain.on('save-dialog', event => {
|
||||
const options = {
|
||||
title: 'Save an Image',
|
||||
filters: [{ name: 'Images', extensions: ['jpg', 'png', 'gif'] }]
|
||||
}
|
||||
dialog.showSaveDialog(options, filename => {
|
||||
event.sender.send('saved-file', filename)
|
||||
})
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
const { ipcRenderer, shell } = require('electron')
|
||||
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
const errorBtn = document.getElementById('error-dialog')
|
||||
|
||||
errorBtn.addEventListener('click', event => {
|
||||
ipcRenderer.send('open-error-dialog')
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
const { ipcRenderer, shell } = require('electron')
|
||||
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
const errorBtn = document.getElementById('error-dialog')
|
||||
|
||||
errorBtn.addEventListener('click', event => {
|
||||
ipcRenderer.send('open-error-dialog')
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
@@ -1,70 +1,70 @@
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow, ipcMain, dialog } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
ipcMain.on('open-information-dialog', event => {
|
||||
const options = {
|
||||
type: 'info',
|
||||
title: 'Information',
|
||||
message: "This is an information dialog. Isn't it nice?",
|
||||
buttons: ['Yes', 'No']
|
||||
}
|
||||
dialog.showMessageBox(options, index => {
|
||||
event.sender.send('information-dialog-selection', index)
|
||||
})
|
||||
})
|
||||
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow, ipcMain, dialog } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
ipcMain.on('open-information-dialog', event => {
|
||||
const options = {
|
||||
type: 'info',
|
||||
title: 'Information',
|
||||
message: "This is an information dialog. Isn't it nice?",
|
||||
buttons: ['Yes', 'No']
|
||||
}
|
||||
dialog.showMessageBox(options, index => {
|
||||
event.sender.send('information-dialog-selection', index)
|
||||
})
|
||||
})
|
||||
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
const { ipcRenderer, shell } = require('electron')
|
||||
|
||||
const informationBtn = document.getElementById('information-dialog')
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
informationBtn.addEventListener('click', event => {
|
||||
ipcRenderer.send('open-information-dialog')
|
||||
})
|
||||
|
||||
ipcRenderer.on('information-dialog-selection', (event, index) => {
|
||||
let message = 'You selected '
|
||||
if (index === 0) message += 'yes.'
|
||||
else message += 'no.'
|
||||
document.getElementById('info-selection').innerHTML = message
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
const { ipcRenderer, shell } = require('electron')
|
||||
|
||||
const informationBtn = document.getElementById('information-dialog')
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
informationBtn.addEventListener('click', event => {
|
||||
ipcRenderer.send('open-information-dialog')
|
||||
})
|
||||
|
||||
ipcRenderer.on('information-dialog-selection', (event, index) => {
|
||||
let message = 'You selected '
|
||||
if (index === 0) message += 'yes.'
|
||||
else message += 'no.'
|
||||
document.getElementById('info-selection').innerHTML = message
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
@@ -1,70 +1,70 @@
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow, ipcMain, dialog } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
ipcMain.on('open-file-dialog', event => {
|
||||
dialog.showOpenDialog(
|
||||
{
|
||||
properties: ['openFile', 'openDirectory']
|
||||
},
|
||||
files => {
|
||||
if (files) {
|
||||
event.sender.send('selected-directory', files)
|
||||
}
|
||||
}
|
||||
)
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow, ipcMain, dialog } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
ipcMain.on('open-file-dialog', event => {
|
||||
dialog.showOpenDialog(
|
||||
{
|
||||
properties: ['openFile', 'openDirectory']
|
||||
},
|
||||
files => {
|
||||
if (files) {
|
||||
event.sender.send('selected-directory', files)
|
||||
}
|
||||
}
|
||||
)
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
|
||||
@@ -1,22 +1,22 @@
|
||||
const { ipcRenderer, shell } = require('electron')
|
||||
|
||||
const selectDirBtn = document.getElementById('select-directory')
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
selectDirBtn.addEventListener('click', event => {
|
||||
ipcRenderer.send('open-file-dialog')
|
||||
})
|
||||
|
||||
ipcRenderer.on('selected-directory', (event, path) => {
|
||||
document.getElementById('selected-file').innerHTML = `You selected: ${path}`
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
const { ipcRenderer, shell } = require('electron')
|
||||
|
||||
const selectDirBtn = document.getElementById('select-directory')
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
selectDirBtn.addEventListener('click', event => {
|
||||
ipcRenderer.send('open-file-dialog')
|
||||
})
|
||||
|
||||
ipcRenderer.on('selected-directory', (event, path) => {
|
||||
document.getElementById('selected-file').innerHTML = `You selected: ${path}`
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
|
||||
@@ -1,66 +1,66 @@
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow, ipcMain, dialog } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
ipcMain.on('save-dialog', event => {
|
||||
const options = {
|
||||
title: 'Save an Image',
|
||||
filters: [{ name: 'Images', extensions: ['jpg', 'png', 'gif'] }]
|
||||
}
|
||||
dialog.showSaveDialog(options, filename => {
|
||||
event.sender.send('saved-file', filename)
|
||||
})
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow, ipcMain, dialog } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
ipcMain.on('save-dialog', event => {
|
||||
const options = {
|
||||
title: 'Save an Image',
|
||||
filters: [{ name: 'Images', extensions: ['jpg', 'png', 'gif'] }]
|
||||
}
|
||||
dialog.showSaveDialog(options, filename => {
|
||||
event.sender.send('saved-file', filename)
|
||||
})
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
|
||||
@@ -1,23 +1,23 @@
|
||||
const { ipcRenderer, shell } = require('electron')
|
||||
|
||||
const saveBtn = document.getElementById('save-dialog')
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
saveBtn.addEventListener('click', event => {
|
||||
ipcRenderer.send('save-dialog')
|
||||
})
|
||||
|
||||
ipcRenderer.on('saved-file', (event, path) => {
|
||||
if (!path) path = 'No path'
|
||||
document.getElementById('file-saved').innerHTML = `Path selected: ${path}`
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
const { ipcRenderer, shell } = require('electron')
|
||||
|
||||
const saveBtn = document.getElementById('save-dialog')
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
saveBtn.addEventListener('click', event => {
|
||||
ipcRenderer.send('save-dialog')
|
||||
})
|
||||
|
||||
ipcRenderer.on('saved-file', (event, path) => {
|
||||
if (!path) path = 'No path'
|
||||
document.getElementById('file-saved').innerHTML = `Path selected: ${path}`
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
@@ -1,56 +1,56 @@
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
const { shell } = require('electron')
|
||||
const os = require('os')
|
||||
|
||||
const exLinksBtn = document.getElementById('open-ex-links')
|
||||
const fileManagerBtn = document.getElementById('open-file-manager')
|
||||
|
||||
fileManagerBtn.addEventListener('click', (event) => {
|
||||
shell.showItemInFolder(os.homedir())
|
||||
})
|
||||
|
||||
exLinksBtn.addEventListener('click', (event) => {
|
||||
shell.openExternal('https://electronjs.org')
|
||||
const { shell } = require('electron')
|
||||
const os = require('os')
|
||||
|
||||
const exLinksBtn = document.getElementById('open-ex-links')
|
||||
const fileManagerBtn = document.getElementById('open-file-manager')
|
||||
|
||||
fileManagerBtn.addEventListener('click', (event) => {
|
||||
shell.showItemInFolder(os.homedir())
|
||||
})
|
||||
|
||||
exLinksBtn.addEventListener('click', (event) => {
|
||||
shell.openExternal('https://electronjs.org')
|
||||
})
|
||||
|
||||
@@ -1,56 +1,56 @@
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
|
||||
@@ -1,29 +1,29 @@
|
||||
const basicNotification = {
|
||||
title: 'Basic Notification',
|
||||
body: 'Short message part'
|
||||
}
|
||||
|
||||
const notification = {
|
||||
title: 'Notification with image',
|
||||
body: 'Short message plus a custom image',
|
||||
icon: 'https://via.placeholder.com/150'
|
||||
}
|
||||
|
||||
const basicNotificationButton = document.getElementById('basic-noti')
|
||||
const notificationButton = document.getElementById('advanced-noti')
|
||||
|
||||
notificationButton.addEventListener('click', () => {
|
||||
const myNotification = new window.Notification(notification.title, notification)
|
||||
|
||||
myNotification.onclick = () => {
|
||||
console.log('Notification clicked')
|
||||
}
|
||||
})
|
||||
|
||||
basicNotificationButton.addEventListener('click', () => {
|
||||
const myNotification = new window.Notification(basicNotification.title, basicNotification)
|
||||
|
||||
myNotification.onclick = () => {
|
||||
console.log('Notification clicked')
|
||||
}
|
||||
})
|
||||
const basicNotification = {
|
||||
title: 'Basic Notification',
|
||||
body: 'Short message part'
|
||||
}
|
||||
|
||||
const notification = {
|
||||
title: 'Notification with image',
|
||||
body: 'Short message plus a custom image',
|
||||
icon: 'https://via.placeholder.com/150'
|
||||
}
|
||||
|
||||
const basicNotificationButton = document.getElementById('basic-noti')
|
||||
const notificationButton = document.getElementById('advanced-noti')
|
||||
|
||||
notificationButton.addEventListener('click', () => {
|
||||
const myNotification = new window.Notification(notification.title, notification)
|
||||
|
||||
myNotification.onclick = () => {
|
||||
console.log('Notification clicked')
|
||||
}
|
||||
})
|
||||
|
||||
basicNotificationButton.addEventListener('click', () => {
|
||||
const myNotification = new window.Notification(basicNotification.title, basicNotification)
|
||||
|
||||
myNotification.onclick = () => {
|
||||
console.log('Notification clicked')
|
||||
}
|
||||
})
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1,35 +1,35 @@
|
||||
const { ipcRenderer, shell } = require('electron')
|
||||
|
||||
const trayBtn = document.getElementById('put-in-tray')
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
let trayOn = false
|
||||
|
||||
trayBtn.addEventListener('click', function (event) {
|
||||
if (trayOn) {
|
||||
trayOn = false
|
||||
document.getElementById('tray-countdown').innerHTML = ''
|
||||
ipcRenderer.send('remove-tray')
|
||||
} else {
|
||||
trayOn = true
|
||||
const message = 'Click demo again to remove.'
|
||||
document.getElementById('tray-countdown').innerHTML = message
|
||||
ipcRenderer.send('put-in-tray')
|
||||
}
|
||||
})
|
||||
// Tray removed from context menu on icon
|
||||
ipcRenderer.on('tray-removed', function () {
|
||||
ipcRenderer.send('remove-tray')
|
||||
trayOn = false
|
||||
document.getElementById('tray-countdown').innerHTML = ''
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
const { ipcRenderer, shell } = require('electron')
|
||||
|
||||
const trayBtn = document.getElementById('put-in-tray')
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
let trayOn = false
|
||||
|
||||
trayBtn.addEventListener('click', function (event) {
|
||||
if (trayOn) {
|
||||
trayOn = false
|
||||
document.getElementById('tray-countdown').innerHTML = ''
|
||||
ipcRenderer.send('remove-tray')
|
||||
} else {
|
||||
trayOn = true
|
||||
const message = 'Click demo again to remove.'
|
||||
document.getElementById('tray-countdown').innerHTML = message
|
||||
ipcRenderer.send('put-in-tray')
|
||||
}
|
||||
})
|
||||
// Tray removed from context menu on icon
|
||||
ipcRenderer.on('tray-removed', function () {
|
||||
ipcRenderer.send('remove-tray')
|
||||
trayOn = false
|
||||
document.getElementById('tray-countdown').innerHTML = ''
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
@@ -1,56 +1,56 @@
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
const { BrowserWindow } = require('electron').remote
|
||||
const shell = require('electron').shell
|
||||
|
||||
const framelessWindowBtn = document.getElementById('frameless-window')
|
||||
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
framelessWindowBtn.addEventListener('click', (event) => {
|
||||
const modalPath = 'https://electronjs.org'
|
||||
let win = new BrowserWindow({ frame: false })
|
||||
|
||||
win.on('close', () => { win = null })
|
||||
win.loadURL(modalPath)
|
||||
win.show()
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
const { BrowserWindow } = require('electron').remote
|
||||
const shell = require('electron').shell
|
||||
|
||||
const framelessWindowBtn = document.getElementById('frameless-window')
|
||||
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
framelessWindowBtn.addEventListener('click', (event) => {
|
||||
const modalPath = 'https://electronjs.org'
|
||||
let win = new BrowserWindow({ frame: false })
|
||||
|
||||
win.on('close', () => { win = null })
|
||||
win.loadURL(modalPath)
|
||||
win.show()
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
|
||||
@@ -1,56 +1,56 @@
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
|
||||
@@ -1,35 +1,35 @@
|
||||
const { BrowserWindow } = require('electron').remote
|
||||
const shell = require('electron').shell
|
||||
|
||||
const manageWindowBtn = document.getElementById('manage-window')
|
||||
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
let win
|
||||
|
||||
manageWindowBtn.addEventListener('click', (event) => {
|
||||
const modalPath = 'https://electronjs.org'
|
||||
win = new BrowserWindow({ width: 400, height: 275 })
|
||||
|
||||
win.on('resize', updateReply)
|
||||
win.on('move', updateReply)
|
||||
win.on('close', () => { win = null })
|
||||
win.loadURL(modalPath)
|
||||
win.show()
|
||||
|
||||
function updateReply () {
|
||||
const manageWindowReply = document.getElementById('manage-window-reply')
|
||||
const message = `Size: ${win.getSize()} Position: ${win.getPosition()}`
|
||||
manageWindowReply.innerText = message
|
||||
}
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
const { BrowserWindow } = require('electron').remote
|
||||
const shell = require('electron').shell
|
||||
|
||||
const manageWindowBtn = document.getElementById('manage-window')
|
||||
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
let win
|
||||
|
||||
manageWindowBtn.addEventListener('click', (event) => {
|
||||
const modalPath = 'https://electronjs.org'
|
||||
win = new BrowserWindow({ width: 400, height: 275 })
|
||||
|
||||
win.on('resize', updateReply)
|
||||
win.on('move', updateReply)
|
||||
win.on('close', () => { win = null })
|
||||
win.loadURL(modalPath)
|
||||
win.show()
|
||||
|
||||
function updateReply () {
|
||||
const manageWindowReply = document.getElementById('manage-window-reply')
|
||||
const message = `Size: ${win.getSize()} Position: ${win.getPosition()}`
|
||||
manageWindowReply.innerText = message
|
||||
}
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
|
||||
@@ -1,56 +1,56 @@
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// Modules to control application life and create native browser window
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
// Keep a global reference of the window object, if you don't, the window will
|
||||
// be closed automatically when the JavaScript object is garbage collected.
|
||||
let mainWindow
|
||||
|
||||
function createWindow () {
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
webPreferences: {
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadFile('index.html')
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', function () {
|
||||
// Dereference the window object, usually you would store windows
|
||||
// in an array if your app supports multi windows, this is the time
|
||||
// when you should delete the corresponding element.
|
||||
mainWindow = null
|
||||
})
|
||||
}
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
// Quit when all windows are closed.
|
||||
app.on('window-all-closed', function () {
|
||||
// On macOS it is common for applications and their menu bar
|
||||
// to stay active until the user quits explicitly with Cmd + Q
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
}
|
||||
})
|
||||
|
||||
app.on('activate', function () {
|
||||
// On macOS it is common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
}
|
||||
})
|
||||
|
||||
// In this file you can include the rest of your app's specific main process
|
||||
// code. You can also put them in separate files and require them here.
|
||||
|
||||
@@ -1,48 +1,48 @@
|
||||
const { BrowserWindow } = require('electron').remote
|
||||
const shell = require('electron').shell
|
||||
|
||||
const listenToWindowBtn = document.getElementById('listen-to-window')
|
||||
const focusModalBtn = document.getElementById('focus-on-modal-window')
|
||||
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
let win
|
||||
|
||||
listenToWindowBtn.addEventListener('click', () => {
|
||||
const modalPath = 'https://electronjs.org'
|
||||
win = new BrowserWindow({ width: 600, height: 400 })
|
||||
|
||||
const hideFocusBtn = () => {
|
||||
focusModalBtn.classList.add('disappear')
|
||||
focusModalBtn.classList.remove('smooth-appear')
|
||||
focusModalBtn.removeEventListener('click', clickHandler)
|
||||
}
|
||||
|
||||
const showFocusBtn = (btn) => {
|
||||
if (!win) return
|
||||
focusModalBtn.classList.add('smooth-appear')
|
||||
focusModalBtn.classList.remove('disappear')
|
||||
focusModalBtn.addEventListener('click', clickHandler)
|
||||
}
|
||||
|
||||
win.on('focus', hideFocusBtn)
|
||||
win.on('blur', showFocusBtn)
|
||||
win.on('close', () => {
|
||||
hideFocusBtn()
|
||||
win = null
|
||||
})
|
||||
win.loadURL(modalPath)
|
||||
win.show()
|
||||
|
||||
const clickHandler = () => { win.focus() }
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
const { BrowserWindow } = require('electron').remote
|
||||
const shell = require('electron').shell
|
||||
|
||||
const listenToWindowBtn = document.getElementById('listen-to-window')
|
||||
const focusModalBtn = document.getElementById('focus-on-modal-window')
|
||||
|
||||
const links = document.querySelectorAll('a[href]')
|
||||
|
||||
let win
|
||||
|
||||
listenToWindowBtn.addEventListener('click', () => {
|
||||
const modalPath = 'https://electronjs.org'
|
||||
win = new BrowserWindow({ width: 600, height: 400 })
|
||||
|
||||
const hideFocusBtn = () => {
|
||||
focusModalBtn.classList.add('disappear')
|
||||
focusModalBtn.classList.remove('smooth-appear')
|
||||
focusModalBtn.removeEventListener('click', clickHandler)
|
||||
}
|
||||
|
||||
const showFocusBtn = (btn) => {
|
||||
if (!win) return
|
||||
focusModalBtn.classList.add('smooth-appear')
|
||||
focusModalBtn.classList.remove('disappear')
|
||||
focusModalBtn.addEventListener('click', clickHandler)
|
||||
}
|
||||
|
||||
win.on('focus', hideFocusBtn)
|
||||
win.on('blur', showFocusBtn)
|
||||
win.on('close', () => {
|
||||
hideFocusBtn()
|
||||
win = null
|
||||
})
|
||||
win.loadURL(modalPath)
|
||||
win.show()
|
||||
|
||||
const clickHandler = () => { win.focus() }
|
||||
})
|
||||
|
||||
Array.prototype.forEach.call(links, (link) => {
|
||||
const url = link.getAttribute('href')
|
||||
if (url.indexOf('http') === 0) {
|
||||
link.addEventListener('click', (e) => {
|
||||
e.preventDefault()
|
||||
shell.openExternal(url)
|
||||
})
|
||||
}
|
||||
})
|
||||
|
||||
@@ -7,7 +7,7 @@ and then enable it in your application.
|
||||
## Prepare a Copy of Flash Plugin
|
||||
|
||||
On macOS and Linux, the details of the Pepper Flash plugin can be found by
|
||||
navigating to `chrome://flash` in the Chrome browser. Its location and version
|
||||
navigating to `chrome://version` in the Chrome browser. Its location and version
|
||||
are useful for Electron's Pepper Flash support. You can also copy it to another
|
||||
location.
|
||||
|
||||
|
||||
@@ -55,7 +55,6 @@ template("electron_extra_paks") {
|
||||
output = "${invoker.output_dir}/resources.pak"
|
||||
sources = [
|
||||
"$root_gen_dir/chrome/dev_ui_browser_resources.pak",
|
||||
"$root_gen_dir/chrome/print_preview_pdf_resources.pak",
|
||||
"$root_gen_dir/components/components_resources.pak",
|
||||
"$root_gen_dir/content/browser/resources/media/media_internals_resources.pak",
|
||||
"$root_gen_dir/content/browser/tracing/tracing_resources.pak",
|
||||
@@ -71,7 +70,6 @@ template("electron_extra_paks") {
|
||||
]
|
||||
deps = [
|
||||
"//chrome/browser:dev_ui_browser_resources",
|
||||
"//chrome/browser/resources:print_preview_pdf_resources",
|
||||
"//components/resources",
|
||||
"//content:content_resources",
|
||||
"//content:dev_ui_content_resources",
|
||||
@@ -96,6 +94,10 @@ template("electron_extra_paks") {
|
||||
sources +=
|
||||
[ "$root_gen_dir/content/browser/devtools/devtools_resources.pak" ]
|
||||
deps += [ "//content/browser/devtools:devtools_resources" ]
|
||||
if (enable_pdf_viewer) {
|
||||
sources += [ "$root_gen_dir/chrome/print_preview_pdf_resources.pak" ]
|
||||
deps += [ "//chrome/browser/resources:print_preview_pdf_resources" ]
|
||||
}
|
||||
if (enable_print_preview) {
|
||||
sources += [ "$root_gen_dir/chrome/print_preview_resources.pak" ]
|
||||
deps += [ "//chrome/browser/resources:print_preview_resources" ]
|
||||
|
||||
@@ -80,4 +80,8 @@
|
||||
Windows Utilities
|
||||
</message>
|
||||
</if>
|
||||
<message name="IDS_DOWNLOAD_MORE_ACTIONS"
|
||||
desc="Tooltip of a button on the downloads page that shows a menu with actions like 'Open downloads folder' or 'Clear all'">
|
||||
More actions
|
||||
</message>
|
||||
</grit-part>
|
||||
|
||||
@@ -119,8 +119,6 @@ auto_filenames = {
|
||||
"docs/api/structures/shared-worker-info.md",
|
||||
"docs/api/structures/shortcut-details.md",
|
||||
"docs/api/structures/size.md",
|
||||
"docs/api/structures/stream-protocol-response.md",
|
||||
"docs/api/structures/string-protocol-response.md",
|
||||
"docs/api/structures/task.md",
|
||||
"docs/api/structures/thumbar-button.md",
|
||||
"docs/api/structures/trace-categories-and-options.md",
|
||||
|
||||
406
filenames.gni
406
filenames.gni
@@ -21,12 +21,215 @@ filenames = {
|
||||
"node_modules/@primer/octicons/build/svg/star-fill-24.svg",
|
||||
]
|
||||
|
||||
lib_sources = [
|
||||
"chromium_src/chrome/browser/process_singleton.h",
|
||||
"chromium_src/chrome/browser/process_singleton_posix.cc",
|
||||
"chromium_src/chrome/browser/process_singleton_win.cc",
|
||||
lib_sources_linux = [
|
||||
"chromium_src/chrome/browser/ui/views/frame/global_menu_bar_registrar_x11.cc",
|
||||
"chromium_src/chrome/browser/ui/views/frame/global_menu_bar_registrar_x11.h",
|
||||
"shell/browser/ui/file_dialog_gtk.cc",
|
||||
"shell/browser/ui/message_box_gtk.cc",
|
||||
"shell/browser/ui/tray_icon_gtk.cc",
|
||||
"shell/browser/ui/tray_icon_gtk.h",
|
||||
"shell/browser/ui/views/global_menu_bar_x11.cc",
|
||||
"shell/browser/ui/views/global_menu_bar_x11.h",
|
||||
"shell/browser/ui/x/event_disabler.cc",
|
||||
"shell/browser/ui/x/event_disabler.h",
|
||||
"shell/browser/ui/x/window_state_watcher.cc",
|
||||
"shell/browser/ui/x/window_state_watcher.h",
|
||||
"shell/browser/ui/x/x_window_utils.cc",
|
||||
"shell/browser/ui/x/x_window_utils.h",
|
||||
"shell/browser/browser_linux.cc",
|
||||
"shell/browser/lib/power_observer_linux.cc",
|
||||
"shell/browser/lib/power_observer_linux.h",
|
||||
"shell/browser/notifications/linux/notification_presenter_linux.cc",
|
||||
"shell/browser/notifications/linux/notification_presenter_linux.h",
|
||||
"shell/browser/relauncher_linux.cc",
|
||||
"shell/common/application_info_linux.cc",
|
||||
"shell/common/language_util_linux.cc",
|
||||
"shell/common/node_bindings_linux.cc",
|
||||
"shell/common/node_bindings_linux.h",
|
||||
"shell/common/platform_util_linux.cc",
|
||||
"shell/browser/linux/unity_service.h",
|
||||
"shell/browser/notifications/linux/libnotify_notification.cc",
|
||||
"shell/browser/notifications/linux/libnotify_notification.h",
|
||||
"shell/browser/linux/unity_service.cc",
|
||||
]
|
||||
|
||||
lib_sources_posix = [
|
||||
"chromium_src/chrome/browser/process_singleton_posix.cc",
|
||||
"shell/browser/electron_browser_main_parts_posix.cc",
|
||||
]
|
||||
|
||||
lib_sources_win = [
|
||||
"chromium_src/chrome/browser/process_singleton_win.cc",
|
||||
"shell/browser/api/electron_api_power_monitor_win.cc",
|
||||
"shell/browser/api/electron_api_system_preferences_win.cc",
|
||||
"shell/browser/browser_win.cc",
|
||||
"shell/browser/native_window_views_win.cc",
|
||||
"shell/browser/notifications/win/notification_presenter_win.cc",
|
||||
"shell/browser/notifications/win/notification_presenter_win.h",
|
||||
"shell/browser/notifications/win/notification_presenter_win7.cc",
|
||||
"shell/browser/notifications/win/notification_presenter_win7.h",
|
||||
"shell/browser/relauncher_win.cc",
|
||||
"shell/browser/ui/certificate_trust_win.cc",
|
||||
"shell/browser/ui/file_dialog_win.cc",
|
||||
"shell/browser/ui/message_box_win.cc",
|
||||
"shell/browser/ui/tray_icon_win.cc",
|
||||
"shell/browser/ui/views/electron_views_delegate_win.cc",
|
||||
"shell/browser/ui/views/win_frame_view.cc",
|
||||
"shell/browser/ui/views/win_frame_view.h",
|
||||
"shell/browser/ui/win/electron_desktop_window_tree_host_win.cc",
|
||||
"shell/browser/ui/win/electron_desktop_window_tree_host_win.h",
|
||||
"shell/common/api/electron_api_native_image_win.cc",
|
||||
"shell/common/application_info_win.cc",
|
||||
"shell/common/language_util_win.cc",
|
||||
"shell/common/node_bindings_win.cc",
|
||||
"shell/common/node_bindings_win.h",
|
||||
"shell/common/platform_util_win.cc",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/common.h",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/desktop_notification_controller.cc",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/desktop_notification_controller.h",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/toast.cc",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/toast.h",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/toast_uia.cc",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/toast_uia.h",
|
||||
"shell/browser/notifications/win/win32_notification.cc",
|
||||
"shell/browser/notifications/win/win32_notification.h",
|
||||
"shell/browser/notifications/win/windows_toast_notification.cc",
|
||||
"shell/browser/notifications/win/windows_toast_notification.h",
|
||||
"shell/browser/ui/win/dialog_thread.cc",
|
||||
"shell/browser/ui/win/dialog_thread.h",
|
||||
"shell/browser/ui/win/electron_desktop_native_widget_aura.cc",
|
||||
"shell/browser/ui/win/electron_desktop_native_widget_aura.h",
|
||||
"shell/browser/ui/win/jump_list.cc",
|
||||
"shell/browser/ui/win/jump_list.h",
|
||||
"shell/browser/ui/win/notify_icon.cc",
|
||||
"shell/browser/ui/win/notify_icon.h",
|
||||
"shell/browser/ui/win/notify_icon_host.cc",
|
||||
"shell/browser/ui/win/notify_icon_host.h",
|
||||
"shell/browser/ui/win/taskbar_host.cc",
|
||||
"shell/browser/ui/win/taskbar_host.h",
|
||||
"shell/browser/win/scoped_hstring.cc",
|
||||
"shell/browser/win/scoped_hstring.h",
|
||||
]
|
||||
|
||||
lib_sources_mac = [
|
||||
"shell/app/electron_main_delegate_mac.h",
|
||||
"shell/app/electron_main_delegate_mac.mm",
|
||||
"shell/browser/api/electron_api_app_mac.mm",
|
||||
"shell/browser/api/electron_api_browser_window_mac.mm",
|
||||
"shell/browser/api/electron_api_menu_mac.h",
|
||||
"shell/browser/api/electron_api_menu_mac.mm",
|
||||
"shell/browser/api/electron_api_native_theme_mac.mm",
|
||||
"shell/browser/api/electron_api_power_monitor_mac.mm",
|
||||
"shell/browser/api/electron_api_system_preferences_mac.mm",
|
||||
"shell/browser/api/electron_api_web_contents_mac.mm",
|
||||
"shell/browser/auto_updater_mac.mm",
|
||||
"shell/browser/browser_mac.mm",
|
||||
"shell/browser/notifications/mac/notification_center_delegate.h",
|
||||
"shell/browser/notifications/mac/notification_center_delegate.mm",
|
||||
"shell/common/mac/main_application_bundle.h",
|
||||
"shell/common/mac/main_application_bundle.mm",
|
||||
"shell/browser/common_web_contents_delegate_mac.mm",
|
||||
"shell/browser/electron_browser_main_parts_mac.mm",
|
||||
"shell/browser/native_browser_view_mac.h",
|
||||
"shell/browser/native_browser_view_mac.mm",
|
||||
"shell/browser/native_window_mac.h",
|
||||
"shell/browser/native_window_mac.mm",
|
||||
"shell/browser/notifications/mac/notification_presenter_mac.h",
|
||||
"shell/browser/notifications/mac/notification_presenter_mac.mm",
|
||||
"shell/browser/relauncher_mac.cc",
|
||||
"shell/browser/ui/certificate_trust_mac.mm",
|
||||
"shell/browser/ui/cocoa/electron_native_widget_mac.h",
|
||||
"shell/browser/ui/cocoa/electron_native_widget_mac.mm",
|
||||
"shell/browser/ui/cocoa/root_view_mac.h",
|
||||
"shell/browser/ui/cocoa/root_view_mac.mm",
|
||||
"shell/browser/ui/cocoa/views_delegate_mac.h",
|
||||
"shell/browser/ui/cocoa/views_delegate_mac.mm",
|
||||
"shell/browser/ui/drag_util_mac.mm",
|
||||
"shell/browser/ui/file_dialog_mac.mm",
|
||||
"shell/browser/ui/inspectable_web_contents_view_mac.h",
|
||||
"shell/browser/ui/inspectable_web_contents_view_mac.mm",
|
||||
"shell/browser/ui/message_box_mac.mm",
|
||||
"shell/common/api/electron_api_clipboard_mac.mm",
|
||||
"shell/common/api/electron_api_native_image_mac.mm",
|
||||
"shell/common/application_info_mac.mm",
|
||||
"shell/common/language_util_mac.mm",
|
||||
"shell/common/node_bindings_mac.cc",
|
||||
"shell/common/node_bindings_mac.h",
|
||||
"shell/common/platform_util_mac.mm",
|
||||
"shell/browser/notifications/mac/cocoa_notification.h",
|
||||
"shell/browser/notifications/mac/cocoa_notification.mm",
|
||||
"shell/browser/ui/cocoa/NSColor+Hex.h",
|
||||
"shell/browser/ui/cocoa/NSColor+Hex.mm",
|
||||
"shell/browser/ui/cocoa/NSString+ANSI.h",
|
||||
"shell/browser/ui/cocoa/NSString+ANSI.mm",
|
||||
"shell/browser/ui/cocoa/delayed_native_view_host.cc",
|
||||
"shell/browser/ui/cocoa/delayed_native_view_host.h",
|
||||
"shell/browser/ui/cocoa/electron_bundle_mover.h",
|
||||
"shell/browser/ui/cocoa/electron_bundle_mover.mm",
|
||||
"shell/browser/ui/cocoa/electron_inspectable_web_contents_view.h",
|
||||
"shell/browser/ui/cocoa/electron_inspectable_web_contents_view.mm",
|
||||
"shell/browser/ui/cocoa/electron_menu_controller.h",
|
||||
"shell/browser/ui/cocoa/electron_menu_controller.mm",
|
||||
"shell/browser/ui/cocoa/electron_ns_window.h",
|
||||
"shell/browser/ui/cocoa/electron_ns_window.mm",
|
||||
"shell/browser/ui/cocoa/electron_ns_window_delegate.h",
|
||||
"shell/browser/ui/cocoa/electron_ns_window_delegate.mm",
|
||||
"shell/browser/ui/cocoa/electron_preview_item.h",
|
||||
"shell/browser/ui/cocoa/electron_preview_item.mm",
|
||||
"shell/browser/ui/cocoa/electron_touch_bar.h",
|
||||
"shell/browser/ui/cocoa/electron_touch_bar.mm",
|
||||
"shell/browser/ui/cocoa/event_dispatching_window.h",
|
||||
"shell/browser/ui/cocoa/event_dispatching_window.mm",
|
||||
"shell/browser/ui/tray_icon_cocoa.h",
|
||||
"shell/browser/ui/tray_icon_cocoa.mm",
|
||||
"shell/browser/mac/dict_util.h",
|
||||
"shell/browser/mac/dict_util.mm",
|
||||
"shell/browser/mac/electron_application.h",
|
||||
"shell/browser/mac/electron_application.mm",
|
||||
"shell/browser/mac/electron_application_delegate.h",
|
||||
"shell/browser/mac/electron_application_delegate.mm",
|
||||
"shell/browser/mac/in_app_purchase.h",
|
||||
"shell/browser/mac/in_app_purchase.mm",
|
||||
"shell/browser/mac/in_app_purchase_observer.h",
|
||||
"shell/browser/mac/in_app_purchase_observer.mm",
|
||||
"shell/browser/mac/in_app_purchase_product.h",
|
||||
"shell/browser/mac/in_app_purchase_product.mm",
|
||||
]
|
||||
|
||||
lib_sources_views = [
|
||||
"shell/browser/api/electron_api_browser_window_views.cc",
|
||||
"shell/browser/api/electron_api_menu_views.cc",
|
||||
"shell/browser/api/electron_api_menu_views.h",
|
||||
"shell/browser/common_web_contents_delegate_views.cc",
|
||||
"shell/browser/native_browser_view_views.cc",
|
||||
"shell/browser/native_browser_view_views.h",
|
||||
"shell/browser/native_window_views.cc",
|
||||
"shell/browser/native_window_views.h",
|
||||
"shell/browser/ui/drag_util_views.cc",
|
||||
"shell/browser/ui/views/inspectable_web_contents_view_views.cc",
|
||||
"shell/browser/ui/views/inspectable_web_contents_view_views.h",
|
||||
"shell/browser/ui/views/autofill_popup_view.cc",
|
||||
"shell/browser/ui/views/autofill_popup_view.h",
|
||||
"shell/browser/ui/views/electron_views_delegate.cc",
|
||||
"shell/browser/ui/views/electron_views_delegate.h",
|
||||
"shell/browser/ui/views/frameless_view.cc",
|
||||
"shell/browser/ui/views/frameless_view.h",
|
||||
"shell/browser/ui/views/menu_bar.cc",
|
||||
"shell/browser/ui/views/menu_bar.h",
|
||||
"shell/browser/ui/views/menu_delegate.cc",
|
||||
"shell/browser/ui/views/menu_delegate.h",
|
||||
"shell/browser/ui/views/menu_model_adapter.cc",
|
||||
"shell/browser/ui/views/menu_model_adapter.h",
|
||||
"shell/browser/ui/views/native_frame_view.cc",
|
||||
"shell/browser/ui/views/native_frame_view.h",
|
||||
"shell/browser/ui/views/root_view.cc",
|
||||
"shell/browser/ui/views/root_view.h",
|
||||
"shell/browser/ui/views/submenu_button.cc",
|
||||
"shell/browser/ui/views/submenu_button.h",
|
||||
]
|
||||
|
||||
lib_sources = [
|
||||
"chromium_src/chrome/browser/process_singleton.h",
|
||||
"shell/app/command_line_args.cc",
|
||||
"shell/app/command_line_args.h",
|
||||
"shell/app/electron_content_client.cc",
|
||||
@@ -35,13 +238,10 @@ filenames = {
|
||||
"shell/app/electron_crash_reporter_client.h",
|
||||
"shell/app/electron_main_delegate.cc",
|
||||
"shell/app/electron_main_delegate.h",
|
||||
"shell/app/electron_main_delegate_mac.h",
|
||||
"shell/app/electron_main_delegate_mac.mm",
|
||||
"shell/app/uv_task_runner.cc",
|
||||
"shell/app/uv_task_runner.h",
|
||||
"shell/browser/api/electron_api_app.cc",
|
||||
"shell/browser/api/electron_api_app.h",
|
||||
"shell/browser/api/electron_api_app_mac.mm",
|
||||
"shell/browser/api/electron_api_auto_updater.cc",
|
||||
"shell/browser/api/electron_api_auto_updater.h",
|
||||
"shell/browser/api/electron_api_base_window.cc",
|
||||
@@ -50,8 +250,6 @@ filenames = {
|
||||
"shell/browser/api/electron_api_browser_view.h",
|
||||
"shell/browser/api/electron_api_browser_window.cc",
|
||||
"shell/browser/api/electron_api_browser_window.h",
|
||||
"shell/browser/api/electron_api_browser_window_mac.mm",
|
||||
"shell/browser/api/electron_api_browser_window_views.cc",
|
||||
"shell/browser/api/electron_api_content_tracing.cc",
|
||||
"shell/browser/api/electron_api_cookies.cc",
|
||||
"shell/browser/api/electron_api_cookies.h",
|
||||
@@ -73,13 +271,8 @@ filenames = {
|
||||
"shell/browser/api/electron_api_in_app_purchase.h",
|
||||
"shell/browser/api/electron_api_menu.cc",
|
||||
"shell/browser/api/electron_api_menu.h",
|
||||
"shell/browser/api/electron_api_menu_mac.h",
|
||||
"shell/browser/api/electron_api_menu_mac.mm",
|
||||
"shell/browser/api/electron_api_menu_views.cc",
|
||||
"shell/browser/api/electron_api_menu_views.h",
|
||||
"shell/browser/api/electron_api_native_theme.cc",
|
||||
"shell/browser/api/electron_api_native_theme.h",
|
||||
"shell/browser/api/electron_api_native_theme_mac.mm",
|
||||
"shell/browser/api/electron_api_net.cc",
|
||||
"shell/browser/api/electron_api_net_log.cc",
|
||||
"shell/browser/api/electron_api_net_log.h",
|
||||
@@ -87,8 +280,6 @@ filenames = {
|
||||
"shell/browser/api/electron_api_notification.h",
|
||||
"shell/browser/api/electron_api_power_monitor.cc",
|
||||
"shell/browser/api/electron_api_power_monitor.h",
|
||||
"shell/browser/api/electron_api_power_monitor_mac.mm",
|
||||
"shell/browser/api/electron_api_power_monitor_win.cc",
|
||||
"shell/browser/api/electron_api_power_save_blocker.cc",
|
||||
"shell/browser/api/electron_api_power_save_blocker.h",
|
||||
"shell/browser/api/electron_api_protocol.cc",
|
||||
@@ -101,8 +292,6 @@ filenames = {
|
||||
"shell/browser/api/electron_api_session.h",
|
||||
"shell/browser/api/electron_api_system_preferences.cc",
|
||||
"shell/browser/api/electron_api_system_preferences.h",
|
||||
"shell/browser/api/electron_api_system_preferences_mac.mm",
|
||||
"shell/browser/api/electron_api_system_preferences_win.cc",
|
||||
"shell/browser/api/electron_api_tray.cc",
|
||||
"shell/browser/api/electron_api_tray.h",
|
||||
"shell/browser/api/electron_api_url_loader.cc",
|
||||
@@ -112,7 +301,6 @@ filenames = {
|
||||
"shell/browser/api/electron_api_web_contents.cc",
|
||||
"shell/browser/api/electron_api_web_contents.h",
|
||||
"shell/browser/api/electron_api_web_contents_impl.cc",
|
||||
"shell/browser/api/electron_api_web_contents_mac.mm",
|
||||
"shell/browser/api/electron_api_web_contents_view.cc",
|
||||
"shell/browser/api/electron_api_web_contents_view.h",
|
||||
"shell/browser/api/electron_api_web_request.cc",
|
||||
@@ -136,21 +324,15 @@ filenames = {
|
||||
"shell/browser/api/ui_event.h",
|
||||
"shell/browser/auto_updater.cc",
|
||||
"shell/browser/auto_updater.h",
|
||||
"shell/browser/auto_updater_mac.mm",
|
||||
"shell/browser/browser.cc",
|
||||
"shell/browser/browser.h",
|
||||
"shell/browser/browser_linux.cc",
|
||||
"shell/browser/browser_mac.mm",
|
||||
"shell/browser/browser_observer.h",
|
||||
"shell/browser/browser_process_impl.cc",
|
||||
"shell/browser/browser_process_impl.h",
|
||||
"shell/browser/browser_win.cc",
|
||||
"shell/browser/child_web_contents_tracker.cc",
|
||||
"shell/browser/child_web_contents_tracker.h",
|
||||
"shell/browser/common_web_contents_delegate.cc",
|
||||
"shell/browser/common_web_contents_delegate.h",
|
||||
"shell/browser/common_web_contents_delegate_mac.mm",
|
||||
"shell/browser/common_web_contents_delegate_views.cc",
|
||||
"shell/browser/cookie_change_notifier.cc",
|
||||
"shell/browser/cookie_change_notifier.h",
|
||||
"shell/browser/electron_autofill_driver.cc",
|
||||
@@ -163,8 +345,6 @@ filenames = {
|
||||
"shell/browser/electron_browser_context.h",
|
||||
"shell/browser/electron_browser_main_parts.cc",
|
||||
"shell/browser/electron_browser_main_parts.h",
|
||||
"shell/browser/electron_browser_main_parts_mac.mm",
|
||||
"shell/browser/electron_browser_main_parts_posix.cc",
|
||||
"shell/browser/electron_download_manager_delegate.cc",
|
||||
"shell/browser/electron_download_manager_delegate.h",
|
||||
"shell/browser/electron_gpu_client.cc",
|
||||
@@ -183,32 +363,20 @@ filenames = {
|
||||
"shell/browser/electron_web_ui_controller_factory.h",
|
||||
"shell/browser/event_emitter_mixin.cc",
|
||||
"shell/browser/event_emitter_mixin.h",
|
||||
"shell/browser/extended_web_contents_observer.h",
|
||||
"shell/browser/feature_list.cc",
|
||||
"shell/browser/feature_list.h",
|
||||
"shell/browser/file_select_helper.cc",
|
||||
"shell/browser/file_select_helper.h",
|
||||
"shell/browser/file_select_helper_mac.mm",
|
||||
"shell/browser/font_defaults.cc",
|
||||
"shell/browser/font_defaults.h",
|
||||
"shell/browser/javascript_environment.cc",
|
||||
"shell/browser/javascript_environment.h",
|
||||
"shell/browser/lib/bluetooth_chooser.cc",
|
||||
"shell/browser/lib/bluetooth_chooser.h",
|
||||
"shell/browser/lib/power_observer_linux.cc",
|
||||
"shell/browser/lib/power_observer_linux.h",
|
||||
"shell/browser/linux/unity_service.cc",
|
||||
"shell/browser/linux/unity_service.h",
|
||||
"shell/browser/login_handler.cc",
|
||||
"shell/browser/login_handler.h",
|
||||
"shell/browser/mac/dict_util.h",
|
||||
"shell/browser/mac/dict_util.mm",
|
||||
"shell/browser/mac/electron_application.h",
|
||||
"shell/browser/mac/electron_application.mm",
|
||||
"shell/browser/mac/electron_application_delegate.h",
|
||||
"shell/browser/mac/electron_application_delegate.mm",
|
||||
"shell/browser/mac/in_app_purchase.h",
|
||||
"shell/browser/mac/in_app_purchase.mm",
|
||||
"shell/browser/mac/in_app_purchase_observer.h",
|
||||
"shell/browser/mac/in_app_purchase_observer.mm",
|
||||
"shell/browser/mac/in_app_purchase_product.h",
|
||||
"shell/browser/mac/in_app_purchase_product.mm",
|
||||
"shell/browser/media/media_capture_devices_dispatcher.cc",
|
||||
"shell/browser/media/media_capture_devices_dispatcher.h",
|
||||
"shell/browser/media/media_device_id_salt.cc",
|
||||
@@ -219,18 +387,9 @@ filenames = {
|
||||
"shell/browser/microtasks_runner.h",
|
||||
"shell/browser/native_browser_view.cc",
|
||||
"shell/browser/native_browser_view.h",
|
||||
"shell/browser/native_browser_view_mac.h",
|
||||
"shell/browser/native_browser_view_mac.mm",
|
||||
"shell/browser/native_browser_view_views.cc",
|
||||
"shell/browser/native_browser_view_views.h",
|
||||
"shell/browser/native_window.cc",
|
||||
"shell/browser/native_window.h",
|
||||
"shell/browser/native_window_mac.h",
|
||||
"shell/browser/native_window_mac.mm",
|
||||
"shell/browser/native_window_observer.h",
|
||||
"shell/browser/native_window_views.cc",
|
||||
"shell/browser/native_window_views.h",
|
||||
"shell/browser/native_window_views_win.cc",
|
||||
"shell/browser/net/asar/asar_url_loader.cc",
|
||||
"shell/browser/net/asar/asar_url_loader.h",
|
||||
"shell/browser/net/cert_verifier_client.cc",
|
||||
@@ -258,16 +417,6 @@ filenames = {
|
||||
"shell/browser/network_hints_handler_impl.h",
|
||||
"shell/browser/node_debugger.cc",
|
||||
"shell/browser/node_debugger.h",
|
||||
"shell/browser/notifications/linux/libnotify_notification.cc",
|
||||
"shell/browser/notifications/linux/libnotify_notification.h",
|
||||
"shell/browser/notifications/linux/notification_presenter_linux.cc",
|
||||
"shell/browser/notifications/linux/notification_presenter_linux.h",
|
||||
"shell/browser/notifications/mac/cocoa_notification.h",
|
||||
"shell/browser/notifications/mac/cocoa_notification.mm",
|
||||
"shell/browser/notifications/mac/notification_center_delegate.h",
|
||||
"shell/browser/notifications/mac/notification_center_delegate.mm",
|
||||
"shell/browser/notifications/mac/notification_presenter_mac.h",
|
||||
"shell/browser/notifications/mac/notification_presenter_mac.mm",
|
||||
"shell/browser/notifications/notification.cc",
|
||||
"shell/browser/notifications/notification.h",
|
||||
"shell/browser/notifications/notification_delegate.h",
|
||||
@@ -275,21 +424,6 @@ filenames = {
|
||||
"shell/browser/notifications/notification_presenter.h",
|
||||
"shell/browser/notifications/platform_notification_service.cc",
|
||||
"shell/browser/notifications/platform_notification_service.h",
|
||||
"shell/browser/notifications/win/notification_presenter_win.cc",
|
||||
"shell/browser/notifications/win/notification_presenter_win.h",
|
||||
"shell/browser/notifications/win/notification_presenter_win7.cc",
|
||||
"shell/browser/notifications/win/notification_presenter_win7.h",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/common.h",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/desktop_notification_controller.cc",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/desktop_notification_controller.h",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/toast.cc",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/toast.h",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/toast_uia.cc",
|
||||
"shell/browser/notifications/win/win32_desktop_notifications/toast_uia.h",
|
||||
"shell/browser/notifications/win/win32_notification.cc",
|
||||
"shell/browser/notifications/win/win32_notification.h",
|
||||
"shell/browser/notifications/win/windows_toast_notification.cc",
|
||||
"shell/browser/notifications/win/windows_toast_notification.h",
|
||||
"shell/browser/plugins/plugin_utils.cc",
|
||||
"shell/browser/plugins/plugin_utils.h",
|
||||
"shell/browser/pref_store_delegate.cc",
|
||||
@@ -298,9 +432,6 @@ filenames = {
|
||||
"shell/browser/protocol_registry.h",
|
||||
"shell/browser/relauncher.cc",
|
||||
"shell/browser/relauncher.h",
|
||||
"shell/browser/relauncher_linux.cc",
|
||||
"shell/browser/relauncher_mac.cc",
|
||||
"shell/browser/relauncher_win.cc",
|
||||
"shell/browser/session_preferences.cc",
|
||||
"shell/browser/session_preferences.h",
|
||||
"shell/browser/special_storage_policy.cc",
|
||||
@@ -310,116 +441,27 @@ filenames = {
|
||||
"shell/browser/ui/autofill_popup.cc",
|
||||
"shell/browser/ui/autofill_popup.h",
|
||||
"shell/browser/ui/certificate_trust.h",
|
||||
"shell/browser/ui/certificate_trust_mac.mm",
|
||||
"shell/browser/ui/certificate_trust_win.cc",
|
||||
"shell/browser/ui/cocoa/NSColor+Hex.h",
|
||||
"shell/browser/ui/cocoa/NSColor+Hex.mm",
|
||||
"shell/browser/ui/cocoa/NSString+ANSI.h",
|
||||
"shell/browser/ui/cocoa/NSString+ANSI.mm",
|
||||
"shell/browser/ui/cocoa/delayed_native_view_host.cc",
|
||||
"shell/browser/ui/cocoa/delayed_native_view_host.h",
|
||||
"shell/browser/ui/cocoa/electron_bundle_mover.h",
|
||||
"shell/browser/ui/cocoa/electron_bundle_mover.mm",
|
||||
"shell/browser/ui/cocoa/electron_inspectable_web_contents_view.h",
|
||||
"shell/browser/ui/cocoa/electron_inspectable_web_contents_view.mm",
|
||||
"shell/browser/ui/cocoa/electron_menu_controller.h",
|
||||
"shell/browser/ui/cocoa/electron_menu_controller.mm",
|
||||
"shell/browser/ui/cocoa/electron_native_widget_mac.h",
|
||||
"shell/browser/ui/cocoa/electron_native_widget_mac.mm",
|
||||
"shell/browser/ui/cocoa/electron_ns_window.h",
|
||||
"shell/browser/ui/cocoa/electron_ns_window.mm",
|
||||
"shell/browser/ui/cocoa/electron_ns_window_delegate.h",
|
||||
"shell/browser/ui/cocoa/electron_ns_window_delegate.mm",
|
||||
"shell/browser/ui/cocoa/electron_preview_item.h",
|
||||
"shell/browser/ui/cocoa/electron_preview_item.mm",
|
||||
"shell/browser/ui/cocoa/electron_touch_bar.h",
|
||||
"shell/browser/ui/cocoa/electron_touch_bar.mm",
|
||||
"shell/browser/ui/cocoa/event_dispatching_window.h",
|
||||
"shell/browser/ui/cocoa/event_dispatching_window.mm",
|
||||
"shell/browser/ui/cocoa/root_view_mac.h",
|
||||
"shell/browser/ui/cocoa/root_view_mac.mm",
|
||||
"shell/browser/ui/cocoa/views_delegate_mac.h",
|
||||
"shell/browser/ui/cocoa/views_delegate_mac.mm",
|
||||
"shell/browser/ui/devtools_manager_delegate.cc",
|
||||
"shell/browser/ui/devtools_manager_delegate.h",
|
||||
"shell/browser/ui/devtools_ui.cc",
|
||||
"shell/browser/ui/devtools_ui.h",
|
||||
"shell/browser/ui/drag_util.cc",
|
||||
"shell/browser/ui/drag_util.h",
|
||||
"shell/browser/ui/drag_util_mac.mm",
|
||||
"shell/browser/ui/drag_util_views.cc",
|
||||
"shell/browser/ui/electron_menu_model.cc",
|
||||
"shell/browser/ui/electron_menu_model.h",
|
||||
"shell/browser/ui/file_dialog.h",
|
||||
"shell/browser/ui/file_dialog_gtk.cc",
|
||||
"shell/browser/ui/file_dialog_mac.mm",
|
||||
"shell/browser/ui/file_dialog_win.cc",
|
||||
"shell/browser/ui/inspectable_web_contents.cc",
|
||||
"shell/browser/ui/inspectable_web_contents.h",
|
||||
"shell/browser/ui/inspectable_web_contents_delegate.h",
|
||||
"shell/browser/ui/inspectable_web_contents_view.h",
|
||||
"shell/browser/ui/inspectable_web_contents_view_delegate.cc",
|
||||
"shell/browser/ui/inspectable_web_contents_view_delegate.h",
|
||||
"shell/browser/ui/inspectable_web_contents_view_mac.h",
|
||||
"shell/browser/ui/inspectable_web_contents_view_mac.mm",
|
||||
"shell/browser/ui/message_box.h",
|
||||
"shell/browser/ui/message_box_gtk.cc",
|
||||
"shell/browser/ui/message_box_mac.mm",
|
||||
"shell/browser/ui/message_box_win.cc",
|
||||
"shell/browser/ui/tray_icon.cc",
|
||||
"shell/browser/ui/tray_icon.h",
|
||||
"shell/browser/ui/tray_icon_cocoa.h",
|
||||
"shell/browser/ui/tray_icon_cocoa.mm",
|
||||
"shell/browser/ui/tray_icon_gtk.cc",
|
||||
"shell/browser/ui/tray_icon_gtk.h",
|
||||
"shell/browser/ui/tray_icon_observer.h",
|
||||
"shell/browser/ui/tray_icon_win.cc",
|
||||
"shell/browser/ui/views/autofill_popup_view.cc",
|
||||
"shell/browser/ui/views/autofill_popup_view.h",
|
||||
"shell/browser/ui/views/electron_views_delegate.cc",
|
||||
"shell/browser/ui/views/electron_views_delegate.h",
|
||||
"shell/browser/ui/views/electron_views_delegate_win.cc",
|
||||
"shell/browser/ui/views/frameless_view.cc",
|
||||
"shell/browser/ui/views/frameless_view.h",
|
||||
"shell/browser/ui/views/global_menu_bar_x11.cc",
|
||||
"shell/browser/ui/views/global_menu_bar_x11.h",
|
||||
"shell/browser/ui/views/inspectable_web_contents_view_views.cc",
|
||||
"shell/browser/ui/views/inspectable_web_contents_view_views.h",
|
||||
"shell/browser/ui/views/menu_bar.cc",
|
||||
"shell/browser/ui/views/menu_bar.h",
|
||||
"shell/browser/ui/views/menu_delegate.cc",
|
||||
"shell/browser/ui/views/menu_delegate.h",
|
||||
"shell/browser/ui/views/menu_model_adapter.cc",
|
||||
"shell/browser/ui/views/menu_model_adapter.h",
|
||||
"shell/browser/ui/views/native_frame_view.cc",
|
||||
"shell/browser/ui/views/native_frame_view.h",
|
||||
"shell/browser/ui/views/root_view.cc",
|
||||
"shell/browser/ui/views/root_view.h",
|
||||
"shell/browser/ui/views/submenu_button.cc",
|
||||
"shell/browser/ui/views/submenu_button.h",
|
||||
"shell/browser/ui/views/win_frame_view.cc",
|
||||
"shell/browser/ui/views/win_frame_view.h",
|
||||
"shell/browser/ui/webui/accessibility_ui.cc",
|
||||
"shell/browser/ui/webui/accessibility_ui.h",
|
||||
"shell/browser/ui/win/dialog_thread.cc",
|
||||
"shell/browser/ui/win/dialog_thread.h",
|
||||
"shell/browser/ui/win/electron_desktop_native_widget_aura.cc",
|
||||
"shell/browser/ui/win/electron_desktop_native_widget_aura.h",
|
||||
"shell/browser/ui/win/electron_desktop_window_tree_host_win.cc",
|
||||
"shell/browser/ui/win/electron_desktop_window_tree_host_win.h",
|
||||
"shell/browser/ui/win/jump_list.cc",
|
||||
"shell/browser/ui/win/jump_list.h",
|
||||
"shell/browser/ui/win/notify_icon.cc",
|
||||
"shell/browser/ui/win/notify_icon.h",
|
||||
"shell/browser/ui/win/notify_icon_host.cc",
|
||||
"shell/browser/ui/win/notify_icon_host.h",
|
||||
"shell/browser/ui/win/taskbar_host.cc",
|
||||
"shell/browser/ui/win/taskbar_host.h",
|
||||
"shell/browser/ui/x/event_disabler.cc",
|
||||
"shell/browser/ui/x/event_disabler.h",
|
||||
"shell/browser/ui/x/window_state_watcher.cc",
|
||||
"shell/browser/ui/x/window_state_watcher.h",
|
||||
"shell/browser/ui/x/x_window_utils.cc",
|
||||
"shell/browser/ui/x/x_window_utils.h",
|
||||
"shell/browser/unresponsive_suppressor.cc",
|
||||
"shell/browser/unresponsive_suppressor.h",
|
||||
"shell/browser/web_contents_permission_helper.cc",
|
||||
@@ -434,8 +476,6 @@ filenames = {
|
||||
"shell/browser/web_view_guest_delegate.h",
|
||||
"shell/browser/web_view_manager.cc",
|
||||
"shell/browser/web_view_manager.h",
|
||||
"shell/browser/win/scoped_hstring.cc",
|
||||
"shell/browser/win/scoped_hstring.h",
|
||||
"shell/browser/window_list.cc",
|
||||
"shell/browser/window_list.h",
|
||||
"shell/browser/window_list_observer.h",
|
||||
@@ -444,13 +484,10 @@ filenames = {
|
||||
"shell/common/api/electron_api_asar.cc",
|
||||
"shell/common/api/electron_api_clipboard.cc",
|
||||
"shell/common/api/electron_api_clipboard.h",
|
||||
"shell/common/api/electron_api_clipboard_mac.mm",
|
||||
"shell/common/api/electron_api_command_line.cc",
|
||||
"shell/common/api/electron_api_key_weak_map.h",
|
||||
"shell/common/api/electron_api_native_image.cc",
|
||||
"shell/common/api/electron_api_native_image.h",
|
||||
"shell/common/api/electron_api_native_image_mac.mm",
|
||||
"shell/common/api/electron_api_native_image_win.cc",
|
||||
"shell/common/api/electron_api_shell.cc",
|
||||
"shell/common/api/electron_api_v8_util.cc",
|
||||
"shell/common/api/electron_bindings.cc",
|
||||
@@ -460,9 +497,6 @@ filenames = {
|
||||
"shell/common/api/object_life_monitor.h",
|
||||
"shell/common/application_info.cc",
|
||||
"shell/common/application_info.h",
|
||||
"shell/common/application_info_linux.cc",
|
||||
"shell/common/application_info_mac.mm",
|
||||
"shell/common/application_info_win.cc",
|
||||
"shell/common/asar/archive.cc",
|
||||
"shell/common/asar/archive.h",
|
||||
"shell/common/asar/asar_util.cc",
|
||||
@@ -545,30 +579,16 @@ filenames = {
|
||||
"shell/common/keyboard_util.cc",
|
||||
"shell/common/keyboard_util.h",
|
||||
"shell/common/language_util.h",
|
||||
"shell/common/language_util_linux.cc",
|
||||
"shell/common/language_util_mac.mm",
|
||||
"shell/common/language_util_win.cc",
|
||||
"shell/common/mac/main_application_bundle.h",
|
||||
"shell/common/mac/main_application_bundle.mm",
|
||||
"shell/common/mouse_util.cc",
|
||||
"shell/common/mouse_util.h",
|
||||
"shell/common/node_bindings.cc",
|
||||
"shell/common/node_bindings.h",
|
||||
"shell/common/node_bindings_linux.cc",
|
||||
"shell/common/node_bindings_linux.h",
|
||||
"shell/common/node_bindings_mac.cc",
|
||||
"shell/common/node_bindings_mac.h",
|
||||
"shell/common/node_bindings_win.cc",
|
||||
"shell/common/node_bindings_win.h",
|
||||
"shell/common/node_includes.h",
|
||||
"shell/common/node_util.cc",
|
||||
"shell/common/node_util.h",
|
||||
"shell/common/options_switches.cc",
|
||||
"shell/common/options_switches.h",
|
||||
"shell/common/platform_util.h",
|
||||
"shell/common/platform_util_linux.cc",
|
||||
"shell/common/platform_util_mac.mm",
|
||||
"shell/common/platform_util_win.cc",
|
||||
"shell/common/process_util.cc",
|
||||
"shell/common/process_util.h",
|
||||
"shell/common/skia_util.cc",
|
||||
@@ -625,6 +645,8 @@ filenames = {
|
||||
"shell/browser/extensions/api/resources_private/resources_private_api.h",
|
||||
"shell/browser/extensions/api/runtime/electron_runtime_api_delegate.cc",
|
||||
"shell/browser/extensions/api/runtime/electron_runtime_api_delegate.h",
|
||||
"shell/browser/extensions/api/management/electron_management_api_delegate.cc",
|
||||
"shell/browser/extensions/api/management/electron_management_api_delegate.h",
|
||||
"shell/browser/extensions/api/tabs/tabs_api.cc",
|
||||
"shell/browser/extensions/api/tabs/tabs_api.h",
|
||||
"shell/browser/extensions/api/streams_private/streams_private_api.cc",
|
||||
|
||||
@@ -28,9 +28,11 @@ Object.setPrototypeOf(BrowserWindow.prototype, BaseWindow.prototype);
|
||||
// Though this hack is only needed on macOS when the app is launched from
|
||||
// Finder, we still do it on all platforms in case of other bugs we don't
|
||||
// know.
|
||||
this.webContents.once('load-url' as any, function (this: WebContents) {
|
||||
this.focus();
|
||||
});
|
||||
if (this.webContents._initiallyShown) {
|
||||
this.webContents.once('load-url' as any, function (this: WebContents) {
|
||||
this.focus();
|
||||
});
|
||||
}
|
||||
|
||||
// Redirect focus/blur event to app instance too.
|
||||
this.on('blur', (event: Event) => {
|
||||
|
||||
@@ -157,9 +157,12 @@ function sortGroups<T> (groups: {id?: T}[][]) {
|
||||
return sortedGroupIndexes.map(i => groups[i]);
|
||||
}
|
||||
|
||||
export function sortMenuItems (menuItems: {type?: string, id?: string}[]) {
|
||||
const isSeparator = (item: {type?: string}) => item.type === 'separator';
|
||||
const separators = menuItems.filter(i => i.type === 'separator');
|
||||
export function sortMenuItems (menuItems: (Electron.MenuItemConstructorOptions | Electron.MenuItem)[]) {
|
||||
const isSeparator = (i: Electron.MenuItemConstructorOptions | Electron.MenuItem) => {
|
||||
const opts = i as Electron.MenuItemConstructorOptions;
|
||||
return i.type === 'separator' && !opts.before && !opts.after && !opts.beforeGroupContaining && !opts.afterGroupContaining;
|
||||
};
|
||||
const separators = menuItems.filter(isSeparator);
|
||||
|
||||
// Split the items into their implicit groups based upon separators.
|
||||
const groups = splitArray(menuItems, isSeparator);
|
||||
|
||||
@@ -182,11 +182,11 @@ Menu.buildFromTemplate = function (template) {
|
||||
throw new TypeError('Invalid template for MenuItem: must have at least one of label, role or type');
|
||||
}
|
||||
|
||||
const filtered = removeExtraSeparators(template);
|
||||
const sorted = sortTemplate(filtered);
|
||||
const sorted = sortTemplate(template);
|
||||
const filtered = removeExtraSeparators(sorted);
|
||||
|
||||
const menu = new Menu();
|
||||
sorted.forEach(item => {
|
||||
filtered.forEach(item => {
|
||||
if (item instanceof MenuItem) {
|
||||
menu.append(item);
|
||||
} else {
|
||||
|
||||
@@ -461,6 +461,10 @@ const addReturnValueToEvent = (event: any) => {
|
||||
});
|
||||
};
|
||||
|
||||
const loggingEnabled = () => {
|
||||
return process.env.ELECTRON_ENABLE_LOGGING || app.commandLine.hasSwitch('enable-logging');
|
||||
};
|
||||
|
||||
// Add JavaScript wrappers for WebContents class.
|
||||
WebContents.prototype._init = function () {
|
||||
// The navigation controller.
|
||||
@@ -545,8 +549,13 @@ WebContents.prototype._init = function () {
|
||||
app.emit('renderer-process-crashed', event, this, ...args);
|
||||
});
|
||||
|
||||
this.on('render-process-gone', (event, ...args) => {
|
||||
app.emit('render-process-gone', event, this, ...args);
|
||||
this.on('render-process-gone', (event, details) => {
|
||||
app.emit('render-process-gone', event, this, details);
|
||||
|
||||
// Log out a hint to help users better debug renderer crashes.
|
||||
if (loggingEnabled()) {
|
||||
console.info(`Renderer process ${details.reason} - see https://www.electronjs.org/docs/tutorial/application-debugging for potential debugging information.`);
|
||||
}
|
||||
});
|
||||
|
||||
// The devtools requests the webContents to reload.
|
||||
@@ -606,6 +615,15 @@ WebContents.prototype._init = function () {
|
||||
app.emit('login', event, this, ...args);
|
||||
});
|
||||
|
||||
this.on('ready-to-show' as any, () => {
|
||||
const owner = this.getOwnerBrowserWindow();
|
||||
if (owner && !owner.isDestroyed()) {
|
||||
process.nextTick(() => {
|
||||
owner.emit('ready-to-show');
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
const event = process._linkedBinding('electron_browser_event').createEmpty();
|
||||
app.emit('web-contents-created', event, this);
|
||||
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
const {
|
||||
createDesktopCapturer,
|
||||
getMediaSourceIdForWebContents: getMediaSourceIdForWebContentsBinding
|
||||
} = process._linkedBinding('electron_browser_desktop_capturer');
|
||||
const { createDesktopCapturer } = process._linkedBinding('electron_browser_desktop_capturer');
|
||||
|
||||
const deepEqual = (a: ElectronInternal.GetSourcesOptions, b: ElectronInternal.GetSourcesOptions) => JSON.stringify(a) === JSON.stringify(b);
|
||||
|
||||
@@ -80,7 +77,3 @@ export const getSourcesImpl = (event: Electron.IpcMainEvent | null, args: Electr
|
||||
|
||||
return getSources;
|
||||
};
|
||||
|
||||
export const getMediaSourceIdForWebContents = (event: Electron.IpcMainEvent, webContentsId: number) => {
|
||||
return getMediaSourceIdForWebContentsBinding(event.sender.id, webContentsId);
|
||||
};
|
||||
|
||||
@@ -71,10 +71,6 @@ if (BUILDFLAG(ENABLE_DESKTOP_CAPTURER)) {
|
||||
|
||||
return typeUtils.serialize(await desktopCapturer.getSourcesImpl(event, options));
|
||||
});
|
||||
|
||||
ipcMainInternal.handle('ELECTRON_BROWSER_DESKTOP_CAPTURER_GET_MEDIA_SOURCE_ID_FOR_WEB_CONTENTS', function (event: IpcMainInvokeEvent, webContentsId: number) {
|
||||
return desktopCapturer.getMediaSourceIdForWebContents(event, webContentsId);
|
||||
});
|
||||
}
|
||||
|
||||
const isRemoteModuleEnabled = BUILDFLAG(ENABLE_REMOTE_MODULE)
|
||||
|
||||
@@ -38,7 +38,7 @@ const keysOfTypeNumber = ['top', 'left', ...Object.keys(keysOfTypeNumberCompileT
|
||||
type CoercedValue = string | number | boolean;
|
||||
function coerce (key: string, value: string): CoercedValue {
|
||||
if (keysOfTypeNumber.includes(key)) {
|
||||
return Number(value);
|
||||
return parseInt(value, 10);
|
||||
}
|
||||
|
||||
switch (value) {
|
||||
|
||||
@@ -43,10 +43,10 @@ if (process.type === 'renderer') {
|
||||
}
|
||||
|
||||
const originalResolveFilename = Module._resolveFilename;
|
||||
Module._resolveFilename = function (request: string, parent: NodeModule, isMain: boolean) {
|
||||
Module._resolveFilename = function (request: string, parent: NodeModule, isMain: boolean, options?: { paths: Array<string>}) {
|
||||
if (request === 'electron' || request.startsWith('electron/')) {
|
||||
return 'electron';
|
||||
} else {
|
||||
return originalResolveFilename(request, parent, isMain);
|
||||
return originalResolveFilename(request, parent, isMain, options);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -16,7 +16,3 @@ function getCurrentStack () {
|
||||
export async function getSources (options: Electron.SourcesOptions) {
|
||||
return deserialize(await ipcRendererInternal.invoke('ELECTRON_BROWSER_DESKTOP_CAPTURER_GET_SOURCES', options, getCurrentStack()));
|
||||
}
|
||||
|
||||
export function getMediaSourceIdForWebContents (webContentsId: number) {
|
||||
return ipcRendererInternal.invoke<string>('ELECTRON_BROWSER_DESKTOP_CAPTURER_GET_MEDIA_SOURCE_ID_FOR_WEB_CONTENTS', webContentsId, getCurrentStack());
|
||||
}
|
||||
|
||||
@@ -76,8 +76,9 @@ const isLocalhost = function () {
|
||||
*
|
||||
* @returns {boolean} Is a CSP with `unsafe-eval` set?
|
||||
*/
|
||||
const isUnsafeEvalEnabled = function () {
|
||||
return webFrame.executeJavaScript(`(${(() => {
|
||||
const isUnsafeEvalEnabled: () => Promise<boolean> = function () {
|
||||
// Call _executeJavaScript to bypass the world-safe deprecation warning
|
||||
return (webFrame as any)._executeJavaScript(`(${(() => {
|
||||
try {
|
||||
new Function(''); // eslint-disable-line no-new,no-new-func
|
||||
} catch {
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
{
|
||||
"name": "electron",
|
||||
"version": "11.0.0-nightly.20200826",
|
||||
"version": "11.0.0-beta.20",
|
||||
"repository": "https://github.com/electron/electron",
|
||||
"description": "Build cross platform desktop apps with JavaScript, HTML, and CSS",
|
||||
"devDependencies": {
|
||||
"@electron/docs-parser": "^0.9.1",
|
||||
"@electron/docs-parser": "^0.10.0",
|
||||
"@electron/typescript-definitions": "^8.7.5",
|
||||
"@octokit/rest": "^18.0.3",
|
||||
"@primer/octicons": "^10.0.0",
|
||||
|
||||
@@ -57,10 +57,10 @@ index 53cb9d2dc8f1962a70dc12b648d27c32be8aca4b..84af06fc56e4aa72d4d48801d7c037ad
|
||||
callback(EVP_aes_192_ctr(), "aes-192-ctr", NULL, arg);
|
||||
callback(EVP_aes_256_ctr(), "aes-256-ctr", NULL, arg);
|
||||
diff --git a/include/openssl/cipher.h b/include/openssl/cipher.h
|
||||
index d22a6c216a2afe29f9507c90a190a4c6992c06a5..0bde0af4b25fbc24ee479b0ffffa037481c71e53 100644
|
||||
index 31390a3f63a1e88d50c22fa8c0d3b53610ebda68..792ae8feaa53229e3f6f9130269b268f43ded8d6 100644
|
||||
--- a/include/openssl/cipher.h
|
||||
+++ b/include/openssl/cipher.h
|
||||
@@ -424,6 +424,7 @@ OPENSSL_EXPORT const EVP_CIPHER *EVP_des_ede3_ecb(void);
|
||||
@@ -430,6 +430,7 @@ OPENSSL_EXPORT const EVP_CIPHER *EVP_des_ede3_ecb(void);
|
||||
|
||||
// EVP_aes_128_cfb128 is only available in decrepit.
|
||||
OPENSSL_EXPORT const EVP_CIPHER *EVP_aes_128_cfb128(void);
|
||||
|
||||
@@ -80,7 +80,7 @@ index d540144b293297791c087e0b968a47d368a73695..53cb9d2dc8f1962a70dc12b648d27c32
|
||||
+ callback(EVP_ripemd160(), "ripemd160", NULL, arg);
|
||||
}
|
||||
diff --git a/include/openssl/digest.h b/include/openssl/digest.h
|
||||
index 7b0ed06cb352718a972be875d03d7c7c89489701..7072457224af3a66d1862f0028cb0ae17847f237 100644
|
||||
index 8e398e8b87f199cf947e097cf99e175bfc9870da..6c0ce559681817cae3273a50e6533468f17177ee 100644
|
||||
--- a/include/openssl/digest.h
|
||||
+++ b/include/openssl/digest.h
|
||||
@@ -89,6 +89,9 @@ OPENSSL_EXPORT const EVP_MD *EVP_sha512_256(void);
|
||||
|
||||
@@ -33,7 +33,6 @@ mas_disable_remote_layer.patch
|
||||
mas_disable_remote_accessibility.patch
|
||||
mas_disable_custom_window_frame.patch
|
||||
chrome_key_systems.patch
|
||||
allow_nested_error_trackers.patch
|
||||
add_didinstallconditionalfeatures.patch
|
||||
ssl_security_state_tab_helper.patch
|
||||
desktop_media_list.patch
|
||||
@@ -74,7 +73,6 @@ add_trustedauthclient_to_urlloaderfactory.patch
|
||||
feat_allow_disabling_blink_scheduler_throttling_per_renderview.patch
|
||||
accessible_pane_view.patch
|
||||
fix_use_the_new_mediaplaypause_key_listener_for_internal_chrome.patch
|
||||
use_electron_resources_in_pdf_util.patch
|
||||
hack_plugin_response_interceptor_to_point_to_electron.patch
|
||||
fix_route_mouse_event_navigations_through_the_web_contents_delegate.patch
|
||||
feat_add_support_for_overriding_the_base_spellchecker_download_url.patch
|
||||
@@ -94,9 +92,13 @@ crash_allow_disabling_compression_on_linux.patch
|
||||
allow_setting_secondary_label_via_simplemenumodel.patch
|
||||
fix_swap_global_proxies_before_initializing_the_windows_proxies.patch
|
||||
feat_add_streaming-protocol_registry_to_multibuffer_data_source.patch
|
||||
use_electron_resources_in_icon_reader_service.patch
|
||||
fix_patch_out_profile_refs_in_accessibility_ui.patch
|
||||
remove_some_deps_that_do_not_work_on_arm64.patch
|
||||
fix_check_issecureeventinputenabled_in_constructor_before_setting.patch
|
||||
skip_atk_toolchain_check.patch
|
||||
worker_feat_add_hook_to_notify_script_ready.patch
|
||||
cherry-pick-2f5b8357dca2.patch
|
||||
fix_use_electron_generated_resources.patch
|
||||
chore_expose_v8_initialization_isolate_callbacks.patch
|
||||
rename_the_v8_context_snapshot_on_arm64_macos_builds.patch
|
||||
crashpad-initialize-logging.patch
|
||||
|
||||
@@ -10,10 +10,10 @@ Allows Electron to restore WER when ELECTRON_DEFAULT_ERROR_MODE is set.
|
||||
This should be upstreamed.
|
||||
|
||||
diff --git a/content/gpu/gpu_main.cc b/content/gpu/gpu_main.cc
|
||||
index ed134d1d40fb23808a4cc251be50a7fbd833b49b..5aaf2356cc2c0fec9a90f3201f1e16553c69a5e3 100644
|
||||
index 1bb696ec5a89fd2215e523a9e320c6d74bd79a42..c0cbe3a2920b0cb453b847be7a0dc8a167ab3f9f 100644
|
||||
--- a/content/gpu/gpu_main.cc
|
||||
+++ b/content/gpu/gpu_main.cc
|
||||
@@ -255,6 +255,10 @@ int GpuMain(const MainFunctionParams& parameters) {
|
||||
@@ -256,6 +256,10 @@ int GpuMain(const MainFunctionParams& parameters) {
|
||||
// to the GpuProcessHost once the GpuServiceImpl has started.
|
||||
viz::GpuServiceImpl::InstallPreInitializeLogHandler();
|
||||
|
||||
@@ -24,7 +24,7 @@ index ed134d1d40fb23808a4cc251be50a7fbd833b49b..5aaf2356cc2c0fec9a90f3201f1e1655
|
||||
// We are experiencing what appear to be memory-stomp issues in the GPU
|
||||
// process. These issues seem to be impacting the task executor and listeners
|
||||
// registered to it. Create the task executor on the heap to guard against
|
||||
@@ -389,7 +393,6 @@ int GpuMain(const MainFunctionParams& parameters) {
|
||||
@@ -394,7 +398,6 @@ int GpuMain(const MainFunctionParams& parameters) {
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -33,10 +33,10 @@ index ed134d1d40fb23808a4cc251be50a7fbd833b49b..5aaf2356cc2c0fec9a90f3201f1e1655
|
||||
client->PostIOThreadCreated(gpu_process.io_task_runner());
|
||||
|
||||
diff --git a/content/public/gpu/content_gpu_client.h b/content/public/gpu/content_gpu_client.h
|
||||
index 88e80bdaecbdd9000109f638c6d79d8102d0e537..a0c0f17e6642dcd2690c095b95ff2c2de9b6ae4f 100644
|
||||
index 2231ce937692f567fd2d4661e4feea389e12203e..a281c7bd40dac0acf350d08683e7c71282a83e9a 100644
|
||||
--- a/content/public/gpu/content_gpu_client.h
|
||||
+++ b/content/public/gpu/content_gpu_client.h
|
||||
@@ -30,6 +30,10 @@ class CONTENT_EXPORT ContentGpuClient {
|
||||
@@ -31,6 +31,10 @@ class CONTENT_EXPORT ContentGpuClient {
|
||||
public:
|
||||
virtual ~ContentGpuClient() {}
|
||||
|
||||
|
||||
@@ -10,10 +10,10 @@ DidCreateScriptContext is called, not all JS APIs are available in the
|
||||
context, which can cause some preload scripts to trip.
|
||||
|
||||
diff --git a/content/public/renderer/render_frame_observer.h b/content/public/renderer/render_frame_observer.h
|
||||
index e1bd458060e2eba703562121f134d0eede7c1986..7b9f534dbfff58c0778a2a4b0c79adb73c8fc377 100644
|
||||
index f63b17435218d0d67bba044da67c1c80015fc996..d0fe24182f2cb48a1333054ce44b6a7f49b2f053 100644
|
||||
--- a/content/public/renderer/render_frame_observer.h
|
||||
+++ b/content/public/renderer/render_frame_observer.h
|
||||
@@ -115,6 +115,8 @@ class CONTENT_EXPORT RenderFrameObserver : public IPC::Listener,
|
||||
@@ -116,6 +116,8 @@ class CONTENT_EXPORT RenderFrameObserver : public IPC::Listener,
|
||||
virtual void DidHandleOnloadEvents() {}
|
||||
virtual void DidCreateScriptContext(v8::Local<v8::Context> context,
|
||||
int32_t world_id) {}
|
||||
@@ -23,10 +23,10 @@ index e1bd458060e2eba703562121f134d0eede7c1986..7b9f534dbfff58c0778a2a4b0c79adb7
|
||||
int32_t world_id) {}
|
||||
virtual void DidClearWindowObject() {}
|
||||
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
|
||||
index 62f6c5fd2ca94ac36851a952b5c1be3430331d60..68d2666696de00c28d57f9745f5ca902d2c16bc9 100644
|
||||
index e811aec4853c1ba0dacdcad758a5bc834643d7e3..5eb2dcde4d2033015677681ceeba7da9b9fe32df 100644
|
||||
--- a/content/renderer/render_frame_impl.cc
|
||||
+++ b/content/renderer/render_frame_impl.cc
|
||||
@@ -4940,6 +4940,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local<v8::Context> context,
|
||||
@@ -5034,6 +5034,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local<v8::Context> context,
|
||||
observer.DidCreateScriptContext(context, world_id);
|
||||
}
|
||||
|
||||
@@ -40,10 +40,10 @@ index 62f6c5fd2ca94ac36851a952b5c1be3430331d60..68d2666696de00c28d57f9745f5ca902
|
||||
int world_id) {
|
||||
for (auto& observer : observers_)
|
||||
diff --git a/content/renderer/render_frame_impl.h b/content/renderer/render_frame_impl.h
|
||||
index 0a1647b88f70b6a669e922fdc6bf3b55a3acd745..9befc7bd8fd78de9cdea25dbc860af651d87c042 100644
|
||||
index 7c18f07de49c422a35a38e96aca6bc52c85050cb..0cb91fc8369f8a7b602b1f249c897a11014ad3ac 100644
|
||||
--- a/content/renderer/render_frame_impl.h
|
||||
+++ b/content/renderer/render_frame_impl.h
|
||||
@@ -729,6 +729,8 @@ class CONTENT_EXPORT RenderFrameImpl
|
||||
@@ -710,6 +710,8 @@ class CONTENT_EXPORT RenderFrameImpl
|
||||
bool ShouldTrackUseCounter(const blink::WebURL& url) override;
|
||||
void DidCreateScriptContext(v8::Local<v8::Context> context,
|
||||
int world_id) override;
|
||||
@@ -53,10 +53,10 @@ index 0a1647b88f70b6a669e922fdc6bf3b55a3acd745..9befc7bd8fd78de9cdea25dbc860af65
|
||||
int world_id) override;
|
||||
void DidChangeScrollOffset() override;
|
||||
diff --git a/third_party/blink/public/web/web_local_frame_client.h b/third_party/blink/public/web/web_local_frame_client.h
|
||||
index e07d735a401ac23b3516fecef5a6a6094d2d0af3..e1d1502e839822277fef42e4e43e4f771485e335 100644
|
||||
index 069ebc8bc53c4c0b27f99f13199b406c29dee3f5..e96d6b9454229339b93a20c2117f58f2ce746777 100644
|
||||
--- a/third_party/blink/public/web/web_local_frame_client.h
|
||||
+++ b/third_party/blink/public/web/web_local_frame_client.h
|
||||
@@ -532,6 +532,9 @@ class BLINK_EXPORT WebLocalFrameClient {
|
||||
@@ -535,6 +535,9 @@ class BLINK_EXPORT WebLocalFrameClient {
|
||||
virtual void DidCreateScriptContext(v8::Local<v8::Context>,
|
||||
int32_t world_id) {}
|
||||
|
||||
@@ -67,7 +67,7 @@ index e07d735a401ac23b3516fecef5a6a6094d2d0af3..e1d1502e839822277fef42e4e43e4f77
|
||||
virtual void WillReleaseScriptContext(v8::Local<v8::Context>,
|
||||
int32_t world_id) {}
|
||||
diff --git a/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc b/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc
|
||||
index 5467a8c10153d7e88d58d8bcbccbd1716a82870a..9311077be9fd1540e504aa1995bfb6171119d200 100644
|
||||
index be4c8053f2bc5e2ad9da6a038a1a70edb37656c9..953e436fc09e9afa2189ad2ebdfdb085cabe51a7 100644
|
||||
--- a/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc
|
||||
+++ b/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc
|
||||
@@ -203,6 +203,7 @@ void LocalWindowProxy::Initialize() {
|
||||
@@ -79,7 +79,7 @@ index 5467a8c10153d7e88d58d8bcbccbd1716a82870a..9311077be9fd1540e504aa1995bfb617
|
||||
if (World().IsMainWorld()) {
|
||||
GetFrame()->Loader().DispatchDidClearWindowObjectInMainWorld();
|
||||
diff --git a/third_party/blink/renderer/core/exported/local_frame_client_impl.cc b/third_party/blink/renderer/core/exported/local_frame_client_impl.cc
|
||||
index b849df64ee16f08d2370638fbe14ed364b2c0650..f38e3cfb85d5d5da9a429fd51dec0cd335a1a930 100644
|
||||
index b99784880e15e5b8f8dbe2ae1616d71ffd7a16d1..d6bbf992272e13e2f4f2478af66c6e4ce19e3d24 100644
|
||||
--- a/third_party/blink/renderer/core/exported/local_frame_client_impl.cc
|
||||
+++ b/third_party/blink/renderer/core/exported/local_frame_client_impl.cc
|
||||
@@ -392,6 +392,13 @@ void LocalFrameClientImpl::DidCreateScriptContext(
|
||||
@@ -97,7 +97,7 @@ index b849df64ee16f08d2370638fbe14ed364b2c0650..f38e3cfb85d5d5da9a429fd51dec0cd3
|
||||
v8::Local<v8::Context> context,
|
||||
int32_t world_id) {
|
||||
diff --git a/third_party/blink/renderer/core/exported/local_frame_client_impl.h b/third_party/blink/renderer/core/exported/local_frame_client_impl.h
|
||||
index dd60568c183c164bede36c69260866399b7e4b79..ab05496705b4aeeedf14af4c509a32c1d4382bb8 100644
|
||||
index 1a9e59e20ebfcdaac5fc3a3b4098e4ec6f9192f4..7da3cdcf3ca099e81b8ac94e87c697ad2d841e61 100644
|
||||
--- a/third_party/blink/renderer/core/exported/local_frame_client_impl.h
|
||||
+++ b/third_party/blink/renderer/core/exported/local_frame_client_impl.h
|
||||
@@ -77,6 +77,8 @@ class CORE_EXPORT LocalFrameClientImpl final : public LocalFrameClient {
|
||||
@@ -123,10 +123,10 @@ index 831ce5ccc32676790307d49416a3a40e7e3652bc..8898a6162a759a3a4d313d8956051b62
|
||||
int32_t world_id) = 0;
|
||||
virtual bool AllowScriptExtensions() = 0;
|
||||
diff --git a/third_party/blink/renderer/core/loader/empty_clients.h b/third_party/blink/renderer/core/loader/empty_clients.h
|
||||
index c233b9b5067c7833e773926585bcb774641faf05..2d2bee9cf782851a93d1e2e021f3890893fa11f2 100644
|
||||
index 50beea038e1cf928ea18cac3e0a4071ca7686cc4..d47a028bdcdf67b892ce82a9d9660e1fb8ddb760 100644
|
||||
--- a/third_party/blink/renderer/core/loader/empty_clients.h
|
||||
+++ b/third_party/blink/renderer/core/loader/empty_clients.h
|
||||
@@ -331,6 +331,8 @@ class CORE_EXPORT EmptyLocalFrameClient : public LocalFrameClient {
|
||||
@@ -325,6 +325,8 @@ class CORE_EXPORT EmptyLocalFrameClient : public LocalFrameClient {
|
||||
|
||||
void DidCreateScriptContext(v8::Local<v8::Context>,
|
||||
int32_t world_id) override {}
|
||||
|
||||
@@ -39,10 +39,10 @@ index 2aef366ac8194aa261cbca6abc051f7da8a988d3..3c7d66c81032636abcca4f1538ce9b7f
|
||||
|
||||
GIN_EXPORT static ArrayBufferAllocator* SharedInstance();
|
||||
diff --git a/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc b/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
|
||||
index 211ea701aba4935ed5641914493fd90e277f18f5..7c2ae147254dad017214d2535203a18719294768 100644
|
||||
index 3c7a7a5675fce7ba4065f8b2f52e29dc083551a6..85ac9d5d95856470707d320d382743673cd1451a 100644
|
||||
--- a/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
|
||||
+++ b/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
|
||||
@@ -689,6 +689,10 @@ class ArrayBufferAllocator : public v8::ArrayBuffer::Allocator {
|
||||
@@ -685,6 +685,10 @@ class ArrayBufferAllocator : public v8::ArrayBuffer::Allocator {
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
@@ -10,10 +10,10 @@ WebContents, and cancels the authentication if there's no WebContents
|
||||
available, which there isn't in the case of the 'net' module.
|
||||
|
||||
diff --git a/services/network/public/mojom/network_context.mojom b/services/network/public/mojom/network_context.mojom
|
||||
index 7dc2d14d47d395e3b8046cae8788c4e04bc8e7f3..55068e71568a022bbf335147e6b35c24402d43ad 100644
|
||||
index 0f9d88529021db245fb498dfa339e5327450256a..962dc2d3e8c3976f5088146c9edc0516e41ebeb4 100644
|
||||
--- a/services/network/public/mojom/network_context.mojom
|
||||
+++ b/services/network/public/mojom/network_context.mojom
|
||||
@@ -214,6 +214,25 @@ struct CTPolicy {
|
||||
@@ -215,6 +215,25 @@ struct CTPolicy {
|
||||
array<string> excluded_legacy_spkis;
|
||||
};
|
||||
|
||||
@@ -39,7 +39,7 @@ index 7dc2d14d47d395e3b8046cae8788c4e04bc8e7f3..55068e71568a022bbf335147e6b35c24
|
||||
interface CertVerifierClient {
|
||||
Verify(
|
||||
int32 default_error,
|
||||
@@ -647,6 +666,8 @@ struct URLLoaderFactoryParams {
|
||||
@@ -641,6 +660,8 @@ struct URLLoaderFactoryParams {
|
||||
// impact because of the extra process hops, so use should be minimized.
|
||||
pending_remote<TrustedURLLoaderHeaderClient>? header_client;
|
||||
|
||||
@@ -49,10 +49,10 @@ index 7dc2d14d47d395e3b8046cae8788c4e04bc8e7f3..55068e71568a022bbf335147e6b35c24
|
||||
// the per-context allow patterns that is managed via NetworkContext
|
||||
// interface. This still respects the per-context block lists.
|
||||
diff --git a/services/network/url_loader.cc b/services/network/url_loader.cc
|
||||
index c209506ca5f450f4611cb339f6d9876175eb713e..d4ff5100be651655140ca024fec12a7d98baa00e 100644
|
||||
index e13745d859ca82ec313c25e1958945a3efeaaa62..0f6ec93b55fcc263f69157d650b20bf34d6a586f 100644
|
||||
--- a/services/network/url_loader.cc
|
||||
+++ b/services/network/url_loader.cc
|
||||
@@ -473,6 +473,7 @@ URLLoader::URLLoader(
|
||||
@@ -463,6 +463,7 @@ URLLoader::URLLoader(
|
||||
base::WeakPtr<KeepaliveStatisticsRecorder> keepalive_statistics_recorder,
|
||||
base::WeakPtr<NetworkUsageAccumulator> network_usage_accumulator,
|
||||
mojom::TrustedURLLoaderHeaderClient* url_loader_header_client,
|
||||
@@ -60,7 +60,7 @@ index c209506ca5f450f4611cb339f6d9876175eb713e..d4ff5100be651655140ca024fec12a7d
|
||||
mojom::OriginPolicyManager* origin_policy_manager,
|
||||
std::unique_ptr<TrustTokenRequestHelperFactory> trust_token_helper_factory,
|
||||
mojo::PendingRemote<mojom::CookieAccessObserver> cookie_observer)
|
||||
@@ -536,6 +537,11 @@ URLLoader::URLLoader(
|
||||
@@ -525,6 +526,11 @@ URLLoader::URLLoader(
|
||||
header_client_.set_disconnect_handler(
|
||||
base::BindOnce(&URLLoader::OnMojoDisconnect, base::Unretained(this)));
|
||||
}
|
||||
@@ -72,7 +72,7 @@ index c209506ca5f450f4611cb339f6d9876175eb713e..d4ff5100be651655140ca024fec12a7d
|
||||
if (want_raw_headers_) {
|
||||
options_ |= mojom::kURLLoadOptionSendSSLInfoWithResponse |
|
||||
mojom::kURLLoadOptionSendSSLInfoForCertificateError;
|
||||
@@ -1120,7 +1126,7 @@ void URLLoader::OnAuthRequired(net::URLRequest* url_request,
|
||||
@@ -1130,7 +1136,7 @@ void URLLoader::OnAuthRequired(net::URLRequest* url_request,
|
||||
// |this| may have been deleted.
|
||||
return;
|
||||
}
|
||||
@@ -81,7 +81,7 @@ index c209506ca5f450f4611cb339f6d9876175eb713e..d4ff5100be651655140ca024fec12a7d
|
||||
OnAuthCredentials(base::nullopt);
|
||||
return;
|
||||
}
|
||||
@@ -1136,11 +1142,20 @@ void URLLoader::OnAuthRequired(net::URLRequest* url_request,
|
||||
@@ -1146,11 +1152,20 @@ void URLLoader::OnAuthRequired(net::URLRequest* url_request,
|
||||
if (url_request->response_headers())
|
||||
head->headers = url_request->response_headers();
|
||||
head->auth_challenge_info = auth_info;
|
||||
@@ -108,7 +108,7 @@ index c209506ca5f450f4611cb339f6d9876175eb713e..d4ff5100be651655140ca024fec12a7d
|
||||
auth_challenge_responder_receiver_.set_disconnect_handler(
|
||||
base::BindOnce(&URLLoader::DeleteSelf, base::Unretained(this)));
|
||||
diff --git a/services/network/url_loader.h b/services/network/url_loader.h
|
||||
index 51c6034e14c0ddbbf69e02f293590a810328bcbb..63b8b0a5349d0a6401cb6c71b116958d13acaf15 100644
|
||||
index 70518f42849e5d1d6e1dd0faf4cae866ba39ef09..b081be5d939b17ecaffa85e75ebb012444bb2bf1 100644
|
||||
--- a/services/network/url_loader.h
|
||||
+++ b/services/network/url_loader.h
|
||||
@@ -118,6 +118,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) URLLoader
|
||||
@@ -119,7 +119,7 @@ index 51c6034e14c0ddbbf69e02f293590a810328bcbb..63b8b0a5349d0a6401cb6c71b116958d
|
||||
mojom::OriginPolicyManager* origin_policy_manager,
|
||||
std::unique_ptr<TrustTokenRequestHelperFactory>
|
||||
trust_token_helper_factory,
|
||||
@@ -471,6 +472,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) URLLoader
|
||||
@@ -481,6 +482,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) URLLoader
|
||||
base::Optional<base::UnguessableToken> fetch_window_id_;
|
||||
|
||||
mojo::Remote<mojom::TrustedHeaderClient> header_client_;
|
||||
@@ -148,10 +148,10 @@ index 75ae8488efa7e5acfda0b21029657b525fa95f86..5dce71ee5efc97f9f63d0b5f236dccdf
|
||||
std::move(cookie_observer));
|
||||
|
||||
diff --git a/services/network/url_loader_factory.h b/services/network/url_loader_factory.h
|
||||
index 8b29b67a5b0663778df3169e09bf818e6bbcec3f..e504fa3d41066907a3fbc41e69daac968415dfa6 100644
|
||||
index 182b26816da9e82d83c47c3c73ecfdcf3003b967..903a3ad083201ed85e82169698041152278697fa 100644
|
||||
--- a/services/network/url_loader_factory.h
|
||||
+++ b/services/network/url_loader_factory.h
|
||||
@@ -75,6 +75,7 @@ class URLLoaderFactory : public mojom::URLLoaderFactory {
|
||||
@@ -74,6 +74,7 @@ class URLLoaderFactory : public mojom::URLLoaderFactory {
|
||||
scoped_refptr<ResourceSchedulerClient> resource_scheduler_client_;
|
||||
mojo::Remote<mojom::TrustedURLLoaderHeaderClient> header_client_;
|
||||
mojo::Remote<mojom::CrossOriginEmbedderPolicyReporter> coep_reporter_;
|
||||
|
||||
@@ -1,34 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Charles Kerr <charles@charleskerr.com>
|
||||
Date: Thu, 20 Sep 2018 17:50:17 -0700
|
||||
Subject: allow_nested_error_trackers.patch
|
||||
|
||||
Only one X11ErrorTracker should exist at a time, but upstream has a bug
|
||||
where two can exist if running in headless mode --
|
||||
ui::(anonymous namespace)::SupportsEWMH() [inner tracker is created]
|
||||
ui::WmSupportsHint()
|
||||
ui::IsX11WindowFullScreen()
|
||||
ui::ScreensaverWindowFinder::IsScreensaverWindow()
|
||||
ui::ScreensaverWindowFinder::ShouldStopIterating()
|
||||
ui::EnumerateTopLevelWindows()
|
||||
ui::ScreensaverWindowFinder::ScreensaverWindowExists() [outer tracker created]
|
||||
ui::CheckIdleStateIsLocked()
|
||||
ui::CalculateIdleState()
|
||||
Removal of either tracker could have side-effects in some code paths,
|
||||
so this is probably better handled upstream. This patch tries to do the
|
||||
least harm in the interim by removing the check that prevents more than
|
||||
one tracker from existing at a time.
|
||||
|
||||
diff --git a/ui/gfx/x/x11_error_tracker.cc b/ui/gfx/x/x11_error_tracker.cc
|
||||
index 6592ae0483884815697358040123eed5ee657816..d6862673c0b5a61db550c084291787ad1549db69 100644
|
||||
--- a/ui/gfx/x/x11_error_tracker.cc
|
||||
+++ b/ui/gfx/x/x11_error_tracker.cc
|
||||
@@ -24,7 +24,7 @@ namespace gfx {
|
||||
X11ErrorTracker::X11ErrorTracker() {
|
||||
// This is a non-exhaustive check for incorrect usage. It disallows nested
|
||||
// X11ErrorTracker instances on the same thread.
|
||||
- DCHECK(g_handler == nullptr);
|
||||
+ // DCHECK(g_handler == nullptr);
|
||||
g_handler = this;
|
||||
XSync(GetXDisplay(), False);
|
||||
old_handler_ = XSetErrorHandler(X11ErrorHandler);
|
||||
@@ -6,7 +6,7 @@ Subject: allow new privileges in unsandboxed child processes
|
||||
This allows unsandboxed renderers to launch setuid processes on Linux.
|
||||
|
||||
diff --git a/content/browser/child_process_launcher_helper_linux.cc b/content/browser/child_process_launcher_helper_linux.cc
|
||||
index c1b5d30fd927feaeb3e068adc72edafa871ae8cd..7534eef2cfe57044be038632ab040b4df1e7ef9e 100644
|
||||
index f3d40b628ec20c140fb36d139bad55cb2b1bc30e..9b5b8166987dd82383984391893ca3f2c978aee6 100644
|
||||
--- a/content/browser/child_process_launcher_helper_linux.cc
|
||||
+++ b/content/browser/child_process_launcher_helper_linux.cc
|
||||
@@ -53,6 +53,18 @@ bool ChildProcessLauncherHelper::BeforeLaunchOnLauncherThread(
|
||||
|
||||
@@ -47,10 +47,10 @@ index 0c37f6e2caead2f3004f1fbdd2abe7921ef4bea7..6f46775d96153d0c6a0795a1d6085f53
|
||||
return items_[ValidateItemIndex(index)].minor_text;
|
||||
}
|
||||
diff --git a/ui/base/models/simple_menu_model.h b/ui/base/models/simple_menu_model.h
|
||||
index 5f1116ba19b8160a2fee008415b8841f056aad98..9c07e44c484a9a15b7d16d592311eb07d9b3734a 100644
|
||||
index 31669898f91d928bb63665d32ab9e4b114fecbf5..6c3f9734e2ee2cb3b6d5f9ed2787751709b013ed 100644
|
||||
--- a/ui/base/models/simple_menu_model.h
|
||||
+++ b/ui/base/models/simple_menu_model.h
|
||||
@@ -48,6 +48,7 @@ class COMPONENT_EXPORT(UI_BASE) SimpleMenuModel : public MenuModel {
|
||||
@@ -51,6 +51,7 @@ class COMPONENT_EXPORT(UI_BASE) SimpleMenuModel : public MenuModel {
|
||||
// Some command ids have labels and icons that change over time.
|
||||
virtual bool IsItemForCommandIdDynamic(int command_id) const;
|
||||
virtual base::string16 GetLabelForCommandId(int command_id) const;
|
||||
@@ -58,7 +58,7 @@ index 5f1116ba19b8160a2fee008415b8841f056aad98..9c07e44c484a9a15b7d16d592311eb07
|
||||
// Gets the icon for the item with the specified id.
|
||||
virtual ImageModel GetIconForCommandId(int command_id) const;
|
||||
|
||||
@@ -151,6 +152,9 @@ class COMPONENT_EXPORT(UI_BASE) SimpleMenuModel : public MenuModel {
|
||||
@@ -154,6 +155,9 @@ class COMPONENT_EXPORT(UI_BASE) SimpleMenuModel : public MenuModel {
|
||||
// Sets the label for the item at |index|.
|
||||
void SetLabel(int index, const base::string16& label);
|
||||
|
||||
@@ -68,7 +68,7 @@ index 5f1116ba19b8160a2fee008415b8841f056aad98..9c07e44c484a9a15b7d16d592311eb07
|
||||
// Sets the minor text for the item at |index|.
|
||||
void SetMinorText(int index, const base::string16& minor_text);
|
||||
|
||||
@@ -180,6 +184,7 @@ class COMPONENT_EXPORT(UI_BASE) SimpleMenuModel : public MenuModel {
|
||||
@@ -183,6 +187,7 @@ class COMPONENT_EXPORT(UI_BASE) SimpleMenuModel : public MenuModel {
|
||||
ui::MenuSeparatorType GetSeparatorTypeAt(int index) const override;
|
||||
int GetCommandIdAt(int index) const override;
|
||||
base::string16 GetLabelAt(int index) const override;
|
||||
@@ -76,7 +76,7 @@ index 5f1116ba19b8160a2fee008415b8841f056aad98..9c07e44c484a9a15b7d16d592311eb07
|
||||
base::string16 GetMinorTextAt(int index) const override;
|
||||
ImageModel GetMinorIconAt(int index) const override;
|
||||
bool IsItemDynamicAt(int index) const override;
|
||||
@@ -216,6 +221,7 @@ class COMPONENT_EXPORT(UI_BASE) SimpleMenuModel : public MenuModel {
|
||||
@@ -219,6 +224,7 @@ class COMPONENT_EXPORT(UI_BASE) SimpleMenuModel : public MenuModel {
|
||||
int command_id = 0;
|
||||
ItemType type = TYPE_COMMAND;
|
||||
base::string16 label;
|
||||
|
||||
@@ -6,10 +6,10 @@ Subject: blink-worker-enable-csp-in-file-scheme.patch
|
||||
This allows file:// URLs in workers to have a CSP.
|
||||
|
||||
diff --git a/third_party/blink/renderer/core/workers/worker_classic_script_loader.cc b/third_party/blink/renderer/core/workers/worker_classic_script_loader.cc
|
||||
index 7acd62e8657cce14733fa9d2449f3c48ad0dc0a6..f4c6c8b6361a6ae8403b13137cc213803892db5e 100644
|
||||
index 9c697793db98ddaaece76f7f8a7890ca0773f936..d264acf0173de6f2ebbf600187d4ceeea4625e42 100644
|
||||
--- a/third_party/blink/renderer/core/workers/worker_classic_script_loader.cc
|
||||
+++ b/third_party/blink/renderer/core/workers/worker_classic_script_loader.cc
|
||||
@@ -369,7 +369,6 @@ void WorkerClassicScriptLoader::ProcessContentSecurityPolicy(
|
||||
@@ -367,7 +367,6 @@ void WorkerClassicScriptLoader::ProcessContentSecurityPolicy(
|
||||
// document (which is implemented in WorkerMessagingProxy, and
|
||||
// m_contentSecurityPolicy should be left as nullptr to inherit the policy).
|
||||
if (!response.CurrentRequestUrl().ProtocolIs("blob") &&
|
||||
|
||||
@@ -14,12 +14,12 @@ when there is code doing that.
|
||||
This patch reverts the change to fix the crash in Electron.
|
||||
|
||||
diff --git a/third_party/blink/renderer/core/frame/local_frame.cc b/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
index 97cd8eb72e9932797089787dc13dcd0f540f2b78..edf0e4e8786997556509c8bb997bbc9859a5147e 100644
|
||||
index f532469a54a40ef56350063e2472cbf77705d69f..98b5007d5a41cb7b8f71bdd03ccb88d56d2e039e 100644
|
||||
--- a/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
@@ -563,10 +563,6 @@ void LocalFrame::DetachImpl(FrameDetachType type) {
|
||||
@@ -581,10 +581,6 @@ void LocalFrame::DetachImpl(FrameDetachType type) {
|
||||
}
|
||||
CHECK(!view_ || !view_->IsAttached());
|
||||
DCHECK(!view_ || !view_->IsAttached());
|
||||
|
||||
- // This is the earliest that scripting can be disabled:
|
||||
- // - FrameLoader::Detach() can fire XHR abort events
|
||||
@@ -28,10 +28,10 @@ index 97cd8eb72e9932797089787dc13dcd0f540f2b78..edf0e4e8786997556509c8bb997bbc98
|
||||
if (!Client())
|
||||
return;
|
||||
|
||||
@@ -584,6 +580,10 @@ void LocalFrame::DetachImpl(FrameDetachType type) {
|
||||
// Notify ScriptController that the frame is closing, since its cleanup ends
|
||||
@@ -601,6 +597,10 @@ void LocalFrame::DetachImpl(FrameDetachType type) {
|
||||
// Notify WindowProxyManager that the frame is closing, since its cleanup ends
|
||||
// up calling back to LocalFrameClient via WindowProxy.
|
||||
GetScriptController().ClearForClose();
|
||||
GetWindowProxyManager()->ClearForClose();
|
||||
+ // This is the earliest that scripting can be disabled:
|
||||
+ // - FrameLoader::Detach() can fire XHR abort events
|
||||
+ // - Document::Shutdown() can dispose plugins which can run script.
|
||||
|
||||
@@ -7,10 +7,10 @@ This exposes a method for obtaining a reference to an isolated world, which is
|
||||
otherwise not available in the Blink API.
|
||||
|
||||
diff --git a/third_party/blink/public/web/web_local_frame.h b/third_party/blink/public/web/web_local_frame.h
|
||||
index 9bda8d2fae9929485d2278de8b7ba9d4395e24b3..73e6de07678f24b983fcc6ebfba2ef000f9eac1c 100644
|
||||
index 0e8a64cdd2b38058b967b39260e6f5ff4e45147c..166ea5f681eee30f299242d826d97c17f8c6a5a8 100644
|
||||
--- a/third_party/blink/public/web/web_local_frame.h
|
||||
+++ b/third_party/blink/public/web/web_local_frame.h
|
||||
@@ -350,6 +350,8 @@ class WebLocalFrame : public WebFrame {
|
||||
@@ -365,6 +365,8 @@ class WebLocalFrame : public WebFrame {
|
||||
// Returns the world ID associated with |script_context|.
|
||||
virtual int32_t GetScriptContextWorldId(
|
||||
v8::Local<v8::Context> script_context) const = 0;
|
||||
@@ -20,10 +20,10 @@ index 9bda8d2fae9929485d2278de8b7ba9d4395e24b3..73e6de07678f24b983fcc6ebfba2ef00
|
||||
// Executes script in the context of the current page and returns the value
|
||||
// that the script evaluated to with callback. Script execution can be
|
||||
diff --git a/third_party/blink/renderer/core/frame/web_local_frame_impl.cc b/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
|
||||
index 584792c678e3f8bf965d59df16422b70a844542b..60109fdcc7499843d10c5c7e9f8e22deff6c007c 100644
|
||||
index 1bb42b8fc49d420767a2dbe4893d8594b7eda6d1..3f47067c3a4be48155771f0c1d25f614ad73b4e8 100644
|
||||
--- a/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
|
||||
@@ -950,6 +950,13 @@ v8::Local<v8::Object> WebLocalFrameImpl::GlobalProxy() const {
|
||||
@@ -992,6 +992,13 @@ v8::Local<v8::Object> WebLocalFrameImpl::GlobalProxy() const {
|
||||
return MainWorldScriptContext()->Global();
|
||||
}
|
||||
|
||||
@@ -38,10 +38,10 @@ index 584792c678e3f8bf965d59df16422b70a844542b..60109fdcc7499843d10c5c7e9f8e22de
|
||||
return BindingSecurity::ShouldAllowAccessToFrame(
|
||||
CurrentDOMWindow(V8PerIsolateData::MainThreadIsolate()),
|
||||
diff --git a/third_party/blink/renderer/core/frame/web_local_frame_impl.h b/third_party/blink/renderer/core/frame/web_local_frame_impl.h
|
||||
index a6c74bdad96fc535a52b40bf7927782d2198aefb..0f7e00f7ff58fbea3a797b6b1d90f316582d22af 100644
|
||||
index 5ff4f6a6d7e6b992c1ae702acd88116d19444986..ef068180f5a9e0f537a2c646212aab9fe4b9c874 100644
|
||||
--- a/third_party/blink/renderer/core/frame/web_local_frame_impl.h
|
||||
+++ b/third_party/blink/renderer/core/frame/web_local_frame_impl.h
|
||||
@@ -162,6 +162,8 @@ class CORE_EXPORT WebLocalFrameImpl final
|
||||
@@ -169,6 +169,8 @@ class CORE_EXPORT WebLocalFrameImpl final
|
||||
v8::Local<v8::Context> MainWorldScriptContext() const override;
|
||||
int32_t GetScriptContextWorldId(
|
||||
v8::Local<v8::Context> script_context) const override;
|
||||
|
||||
@@ -10,10 +10,10 @@ breakpad independently, as a "browser" process. This patches
|
||||
crash annotation.
|
||||
|
||||
diff --git a/components/crash/core/app/breakpad_linux.cc b/components/crash/core/app/breakpad_linux.cc
|
||||
index 72ee7e8df3d62eca301b08586f06d51711e941b5..fdd76ee1490e39dbfcd39bbff6686864a5c5af29 100644
|
||||
index 1c076672c77d90eb3814b5b269340d2800217868..7d23a5732b47bef04cadc707f58e50b423393605 100644
|
||||
--- a/components/crash/core/app/breakpad_linux.cc
|
||||
+++ b/components/crash/core/app/breakpad_linux.cc
|
||||
@@ -716,8 +716,13 @@ bool CrashDone(const MinidumpDescriptor& minidump,
|
||||
@@ -715,8 +715,13 @@ bool CrashDone(const MinidumpDescriptor& minidump,
|
||||
log_path[log_path_len] = '\0';
|
||||
info.log_filename = log_path;
|
||||
#endif
|
||||
@@ -29,7 +29,7 @@ index 72ee7e8df3d62eca301b08586f06d51711e941b5..fdd76ee1490e39dbfcd39bbff6686864
|
||||
info.distro = base::g_linux_distro;
|
||||
info.distro_length = my_strlen(base::g_linux_distro);
|
||||
info.upload = upload;
|
||||
@@ -2023,8 +2028,13 @@ void InitCrashReporter(const std::string& process_type) {
|
||||
@@ -2022,8 +2027,13 @@ void InitCrashReporter(const std::string& process_type) {
|
||||
process_type == kWebViewSingleProcessType ||
|
||||
process_type == kBrowserProcessType ||
|
||||
#endif
|
||||
|
||||
@@ -8,7 +8,7 @@ categories in use are known / declared. This patch is required for us
|
||||
to introduce a new Electron category for Electron-specific tracing.
|
||||
|
||||
diff --git a/base/trace_event/builtin_categories.h b/base/trace_event/builtin_categories.h
|
||||
index 732db68d17821b29041dd387e7e00b305c52a34c..d81a915e77a4dff952e6e81df7937292f4899d7d 100644
|
||||
index 97830615a4e286e3e50c0ca0f55748e8cf9a35d5..1d04ea7e776a7fcdee3c27c74b81a5f1846bfc42 100644
|
||||
--- a/base/trace_event/builtin_categories.h
|
||||
+++ b/base/trace_event/builtin_categories.h
|
||||
@@ -73,6 +73,7 @@
|
||||
|
||||
@@ -14,7 +14,7 @@ tradeoff is that switching from MAS_BUILD to !MAS_BUILD or vice-versa will
|
||||
rebuild the entire tree.
|
||||
|
||||
diff --git a/build/config/BUILDCONFIG.gn b/build/config/BUILDCONFIG.gn
|
||||
index e011502180b5a94bd32bcebb301c91314d12653e..12569e571f52a07ea5e9b104314427df1ccb558f 100644
|
||||
index 3082046a91da5fe400d8405da61f55ad66fa5e74..e0e90bcd7bb4741dfe792336d59028c500f59b39 100644
|
||||
--- a/build/config/BUILDCONFIG.gn
|
||||
+++ b/build/config/BUILDCONFIG.gn
|
||||
@@ -123,6 +123,9 @@ if (current_os == "") {
|
||||
@@ -27,7 +27,7 @@ index e011502180b5a94bd32bcebb301c91314d12653e..12569e571f52a07ea5e9b104314427df
|
||||
# Set to enable the official build level of optimization. This has nothing
|
||||
# to do with branding, but enables an additional level of optimization above
|
||||
# release (!is_debug). This might be better expressed as a tri-state
|
||||
@@ -440,6 +443,7 @@ default_compiler_configs = [
|
||||
@@ -335,6 +338,7 @@ default_compiler_configs = [
|
||||
"//build/config/compiler/pgo:default_pgo_flags",
|
||||
"//build/config/coverage:default_coverage",
|
||||
"//build/config/sanitizers:default_sanitizer_flags",
|
||||
|
||||
@@ -8,11 +8,11 @@ potentially prevent a window from being created.
|
||||
|
||||
TODO(loc): this patch is currently broken.
|
||||
|
||||
diff --git a/content/browser/frame_host/render_frame_host_impl.cc b/content/browser/frame_host/render_frame_host_impl.cc
|
||||
index 795238249222dd246c2254434a4454b9d2aedd7c..ca9463ee9326816fca51d1ef75634973a12cd4b9 100644
|
||||
--- a/content/browser/frame_host/render_frame_host_impl.cc
|
||||
+++ b/content/browser/frame_host/render_frame_host_impl.cc
|
||||
@@ -4883,6 +4883,7 @@ void RenderFrameHostImpl::CreateNewWindow(
|
||||
diff --git a/content/browser/renderer_host/render_frame_host_impl.cc b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
index 497033d3d5257daffe4aca2ebdd1fd71513db73f..7412bf8f9a9e07975917514e7f4c13253112138a 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
@@ -4945,6 +4945,7 @@ void RenderFrameHostImpl::CreateNewWindow(
|
||||
last_committed_origin_, params->window_container_type,
|
||||
params->target_url, params->referrer.To<Referrer>(),
|
||||
params->frame_name, params->disposition, *params->features,
|
||||
@@ -21,10 +21,10 @@ index 795238249222dd246c2254434a4454b9d2aedd7c..ca9463ee9326816fca51d1ef75634973
|
||||
&no_javascript_access);
|
||||
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index b92cebd04eacb5b6fa3ff3d4c06388e7c8eac942..3ab23d0c634e8379573a4d818bbbe6200a88d073 100644
|
||||
index a39f43b61afc70296470a9ed616d7e8a423780aa..b113c265dcf5b8e3c7533085f1b8409fa13bcfa0 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -3420,9 +3420,9 @@ RenderFrameHostDelegate* WebContentsImpl::CreateNewWindow(
|
||||
@@ -3703,9 +3703,9 @@ RenderFrameHostDelegate* WebContentsImpl::CreateNewWindow(
|
||||
}
|
||||
|
||||
if (delegate_) {
|
||||
@@ -38,10 +38,10 @@ index b92cebd04eacb5b6fa3ff3d4c06388e7c8eac942..3ab23d0c634e8379573a4d818bbbe620
|
||||
|
||||
observers_.ForEachObserver([&](WebContentsObserver* observer) {
|
||||
diff --git a/content/common/frame.mojom b/content/common/frame.mojom
|
||||
index c969ed9b17b915f713d9b82114c7b637c8fd90df..9530a1936b0a801a4c6152dd53ec5105d5d712e0 100644
|
||||
index e769df393c1e89cdf04519b82d75f7f1542ad26b..752818c2791343a5c574a96f0e0aa672a7ef3726 100644
|
||||
--- a/content/common/frame.mojom
|
||||
+++ b/content/common/frame.mojom
|
||||
@@ -264,6 +264,10 @@ struct CreateNewWindowParams {
|
||||
@@ -282,6 +282,10 @@ struct CreateNewWindowParams {
|
||||
|
||||
// The window features to use for the new window.
|
||||
blink.mojom.WindowFeatures features;
|
||||
@@ -53,10 +53,10 @@ index c969ed9b17b915f713d9b82114c7b637c8fd90df..9530a1936b0a801a4c6152dd53ec5105
|
||||
|
||||
// Operation result when the renderer asks the browser to create a new window.
|
||||
diff --git a/content/public/browser/content_browser_client.cc b/content/public/browser/content_browser_client.cc
|
||||
index 479e52d0c08050704f65fbf02779261446a107fe..0e150a89b451e7ae464f1bd5e38c412f58aa8568 100644
|
||||
index da3aceed75b10087a86bcb8427c241fe647cdcfe..cafd45df059293bc1cf31e1d7b798e67578f3e9d 100644
|
||||
--- a/content/public/browser/content_browser_client.cc
|
||||
+++ b/content/public/browser/content_browser_client.cc
|
||||
@@ -543,6 +543,8 @@ bool ContentBrowserClient::CanCreateWindow(
|
||||
@@ -544,6 +544,8 @@ bool ContentBrowserClient::CanCreateWindow(
|
||||
const std::string& frame_name,
|
||||
WindowOpenDisposition disposition,
|
||||
const blink::mojom::WindowFeatures& features,
|
||||
@@ -66,10 +66,10 @@ index 479e52d0c08050704f65fbf02779261446a107fe..0e150a89b451e7ae464f1bd5e38c412f
|
||||
bool opener_suppressed,
|
||||
bool* no_javascript_access) {
|
||||
diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h
|
||||
index 5f73f4713eae097b544ba38c4117621d3a1b77e4..170beaff3f579d3fcf9c461f6a41350e8c9439cc 100644
|
||||
index 27b7e117b531bb370ea948e56b33d1a07eef11c6..9953cc472c04c2dc6ae0f70b64ea2b8d6ac86a05 100644
|
||||
--- a/content/public/browser/content_browser_client.h
|
||||
+++ b/content/public/browser/content_browser_client.h
|
||||
@@ -149,6 +149,7 @@ class NetworkService;
|
||||
@@ -153,6 +153,7 @@ class NetworkService;
|
||||
class TrustedURLLoaderHeaderClient;
|
||||
} // namespace mojom
|
||||
struct ResourceRequest;
|
||||
@@ -77,7 +77,7 @@ index 5f73f4713eae097b544ba38c4117621d3a1b77e4..170beaff3f579d3fcf9c461f6a41350e
|
||||
} // namespace network
|
||||
|
||||
namespace sandbox {
|
||||
@@ -869,6 +870,8 @@ class CONTENT_EXPORT ContentBrowserClient {
|
||||
@@ -868,6 +869,8 @@ class CONTENT_EXPORT ContentBrowserClient {
|
||||
const std::string& frame_name,
|
||||
WindowOpenDisposition disposition,
|
||||
const blink::mojom::WindowFeatures& features,
|
||||
@@ -87,7 +87,7 @@ index 5f73f4713eae097b544ba38c4117621d3a1b77e4..170beaff3f579d3fcf9c461f6a41350e
|
||||
bool opener_suppressed,
|
||||
bool* no_javascript_access);
|
||||
diff --git a/content/public/browser/web_contents_delegate.cc b/content/public/browser/web_contents_delegate.cc
|
||||
index 5631ce92ac15737d4aff4d08e4a285bc507b6d47..04428e426ff43570deb01edf33400824f9a5206c 100644
|
||||
index 12ce66464a416262767c126d0600fed60f5b106a..f60cf6064fdf279b26f0d11125e2ffa5bbb36c78 100644
|
||||
--- a/content/public/browser/web_contents_delegate.cc
|
||||
+++ b/content/public/browser/web_contents_delegate.cc
|
||||
@@ -26,6 +26,17 @@ namespace content {
|
||||
@@ -109,7 +109,7 @@ index 5631ce92ac15737d4aff4d08e4a285bc507b6d47..04428e426ff43570deb01edf33400824
|
||||
const OpenURLParams& params) {
|
||||
return nullptr;
|
||||
diff --git a/content/public/browser/web_contents_delegate.h b/content/public/browser/web_contents_delegate.h
|
||||
index 61ed37a5868fd53f669d40c62542d6271daea91d..c1d7b01d0d63f9f1ba90a32511f69318c9ec10fb 100644
|
||||
index ee6b87d40496591935cef789bab9c1de8e60cee9..dd7f018be164b250f0b2408ce309219d61c50caa 100644
|
||||
--- a/content/public/browser/web_contents_delegate.h
|
||||
+++ b/content/public/browser/web_contents_delegate.h
|
||||
@@ -17,6 +17,7 @@
|
||||
@@ -135,18 +135,18 @@ index 61ed37a5868fd53f669d40c62542d6271daea91d..c1d7b01d0d63f9f1ba90a32511f69318
|
||||
// typically happens when popups are created.
|
||||
virtual void WebContentsCreated(WebContents* source_contents,
|
||||
diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc
|
||||
index 49619a9b5683a3e53c53c9b750c6ea6a0efc92b2..e7c03ac99a0a9cf80d65797a81065f8997cf4646 100644
|
||||
index fec5e2312b716436e96d5c57b2a5203ca2b1e423..f6697538b5717a12a6d29704bc49de0b6e632417 100644
|
||||
--- a/content/renderer/render_view_impl.cc
|
||||
+++ b/content/renderer/render_view_impl.cc
|
||||
@@ -67,6 +67,7 @@
|
||||
@@ -66,6 +66,7 @@
|
||||
#include "content/renderer/history_serialization.h"
|
||||
#include "content/renderer/internal_document_state_data.h"
|
||||
#include "content/renderer/loader/request_extra_data.h"
|
||||
+#include "content/renderer/loader/web_url_request_util.h"
|
||||
#include "content/renderer/media/audio/audio_device_factory.h"
|
||||
#include "content/renderer/render_frame_impl.h"
|
||||
#include "content/renderer/render_frame_proxy.h"
|
||||
@@ -1209,6 +1210,10 @@ WebView* RenderViewImpl::CreateView(
|
||||
#include "content/renderer/render_process.h"
|
||||
@@ -644,6 +645,10 @@ WebView* RenderViewImpl::CreateView(
|
||||
}
|
||||
params->features = ConvertWebWindowFeaturesToMojoWindowFeatures(features);
|
||||
|
||||
@@ -157,11 +157,11 @@ index 49619a9b5683a3e53c53c9b750c6ea6a0efc92b2..e7c03ac99a0a9cf80d65797a81065f89
|
||||
// We preserve this information before sending the message since |params| is
|
||||
// moved on send.
|
||||
bool is_background_tab =
|
||||
diff --git a/content/shell/browser/web_test/web_test_content_browser_client.cc b/content/shell/browser/web_test/web_test_content_browser_client.cc
|
||||
index c22aeb8e80440061f33271762b373912ef30cc48..5418efe944e0e897adb754f790ba8182c20f87ec 100644
|
||||
--- a/content/shell/browser/web_test/web_test_content_browser_client.cc
|
||||
+++ b/content/shell/browser/web_test/web_test_content_browser_client.cc
|
||||
@@ -381,6 +381,8 @@ bool WebTestContentBrowserClient::CanCreateWindow(
|
||||
diff --git a/content/web_test/browser/web_test_content_browser_client.cc b/content/web_test/browser/web_test_content_browser_client.cc
|
||||
index f0c53c0945d76ce4482ce4c24acb75c3eccb59e9..458919350048f02d07695bef1c4d4e41b0ce043e 100644
|
||||
--- a/content/web_test/browser/web_test_content_browser_client.cc
|
||||
+++ b/content/web_test/browser/web_test_content_browser_client.cc
|
||||
@@ -377,6 +377,8 @@ bool WebTestContentBrowserClient::CanCreateWindow(
|
||||
const std::string& frame_name,
|
||||
WindowOpenDisposition disposition,
|
||||
const blink::mojom::WindowFeatures& features,
|
||||
@@ -170,11 +170,11 @@ index c22aeb8e80440061f33271762b373912ef30cc48..5418efe944e0e897adb754f790ba8182
|
||||
bool user_gesture,
|
||||
bool opener_suppressed,
|
||||
bool* no_javascript_access) {
|
||||
diff --git a/content/shell/browser/web_test/web_test_content_browser_client.h b/content/shell/browser/web_test/web_test_content_browser_client.h
|
||||
index a79ff68cb0a9fa9f65b780c06df4b62696e34891..70c0073aac1e7b133b847d62ef4d87293ec5956c 100644
|
||||
--- a/content/shell/browser/web_test/web_test_content_browser_client.h
|
||||
+++ b/content/shell/browser/web_test/web_test_content_browser_client.h
|
||||
@@ -77,6 +77,8 @@ class WebTestContentBrowserClient : public ShellContentBrowserClient {
|
||||
diff --git a/content/web_test/browser/web_test_content_browser_client.h b/content/web_test/browser/web_test_content_browser_client.h
|
||||
index b96c23ec09111b29f9b9349a6324076d26f900bc..d42a00e59cde5195195096237f25eca5d4186797 100644
|
||||
--- a/content/web_test/browser/web_test_content_browser_client.h
|
||||
+++ b/content/web_test/browser/web_test_content_browser_client.h
|
||||
@@ -83,6 +83,8 @@ class WebTestContentBrowserClient : public ShellContentBrowserClient {
|
||||
const std::string& frame_name,
|
||||
WindowOpenDisposition disposition,
|
||||
const blink::mojom::WindowFeatures& features,
|
||||
@@ -206,10 +206,10 @@ index 4f735ad0d97eaac9a57dad137e479f8a7ec33a36..0a3c5821962c85609b64b3625fa6b8d6
|
||||
|
||||
} // namespace blink
|
||||
diff --git a/third_party/blink/renderer/core/frame/local_dom_window.cc b/third_party/blink/renderer/core/frame/local_dom_window.cc
|
||||
index 7a4451acee7822fc525d000f7b54a9922b1bd788..3c950eaa5bfb98b398a4daaec182745e87cc73d2 100644
|
||||
index 58c922f8da2a85f4354df61cf1ac7c454fd12359..d7903ef7b6e8dd458b14d13a24d7f9423a55707f 100644
|
||||
--- a/third_party/blink/renderer/core/frame/local_dom_window.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/local_dom_window.cc
|
||||
@@ -1915,6 +1915,7 @@ DOMWindow* LocalDOMWindow::open(v8::Isolate* isolate,
|
||||
@@ -1957,6 +1957,7 @@ DOMWindow* LocalDOMWindow::open(v8::Isolate* isolate,
|
||||
}
|
||||
|
||||
WebWindowFeatures window_features = GetWindowFeaturesFromString(features);
|
||||
|
||||
330
patches/chromium/cherry-pick-2f5b8357dca2.patch
Normal file
330
patches/chromium/cherry-pick-2f5b8357dca2.patch
Normal file
@@ -0,0 +1,330 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Martin Robinson <mrobinson@igalia.com>
|
||||
Date: Mon, 12 Oct 2020 08:50:01 +0000
|
||||
Subject: Expose AXIndex for accessibility TreeGrid and Tree rows on Mac
|
||||
|
||||
VoiceOver requires each row to have in index in order to announce it. We
|
||||
expose this property for rows which either have role=row or
|
||||
role=treeitem.
|
||||
|
||||
AX-Relnotes: Fix an issue where ARIA TreeGrid and Tree rows were not announced.
|
||||
Bug: 1115267
|
||||
Change-Id: Ia8917044a510b2467aa2480dff54fe226b90c391
|
||||
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2426569
|
||||
Auto-Submit: Martin Robinson <mrobinson@igalia.com>
|
||||
Commit-Queue: Martin Robinson <mrobinson@igalia.com>
|
||||
Reviewed-by: Dominic Mazzoni <dmazzoni@chromium.org>
|
||||
Reviewed-by: Abigail Klein <abigailbklein@google.com>
|
||||
Cr-Commit-Position: refs/heads/master@{#816089}
|
||||
|
||||
diff --git a/content/browser/accessibility/browser_accessibility_cocoa.h b/content/browser/accessibility/browser_accessibility_cocoa.h
|
||||
index 318af1ec3a11ee53a1146909f76c9cea7f78be1e..770c0cb6a4dad8cbf35900311a23a8296407d81d 100644
|
||||
--- a/content/browser/accessibility/browser_accessibility_cocoa.h
|
||||
+++ b/content/browser/accessibility/browser_accessibility_cocoa.h
|
||||
@@ -112,6 +112,11 @@ id AXTextMarkerRangeFrom(id anchor_textmarker, id focus_textmarker);
|
||||
- (NSString*)valueForRange:(NSRange)range;
|
||||
- (NSAttributedString*)attributedValueForRange:(NSRange)range;
|
||||
|
||||
+// Find the index of the given row among the descendants of this object
|
||||
+// or return nil if this row is not found.
|
||||
+- (bool)findRowIndex:(BrowserAccessibilityCocoa*)toFind
|
||||
+ withCurrentIndex:(int*)currentIndex;
|
||||
+
|
||||
// Internally-used property.
|
||||
@property(nonatomic, readonly) NSPoint origin;
|
||||
|
||||
@@ -150,6 +155,7 @@ id AXTextMarkerRangeFrom(id anchor_textmarker, id focus_textmarker);
|
||||
@property(nonatomic, readonly, getter=isIgnored) BOOL ignored;
|
||||
// Index of a row, column, or tree item.
|
||||
@property(nonatomic, readonly) NSNumber* index;
|
||||
+@property(nonatomic, readonly) NSNumber* treeItemRowIndex;
|
||||
#ifndef MAS_BUILD
|
||||
@property(nonatomic, readonly) NSNumber* insertionPointLineNumber;
|
||||
#endif
|
||||
diff --git a/content/browser/accessibility/browser_accessibility_cocoa.mm b/content/browser/accessibility/browser_accessibility_cocoa.mm
|
||||
index 96b6fa030c2a36ab5c4217ad19f0bfe4d5212bb8..3abd9933ab325bda6cb486a41fd6c8b246aa8e71 100644
|
||||
--- a/content/browser/accessibility/browser_accessibility_cocoa.mm
|
||||
+++ b/content/browser/accessibility/browser_accessibility_cocoa.mm
|
||||
@@ -1497,7 +1497,10 @@ - (id)highestEditableAncestor {
|
||||
- (NSNumber*)index {
|
||||
if (![self instanceActive])
|
||||
return nil;
|
||||
- if ([self internalRole] == ax::mojom::Role::kColumn) {
|
||||
+
|
||||
+ if ([self internalRole] == ax::mojom::Role::kTreeItem) {
|
||||
+ return [self treeItemRowIndex];
|
||||
+ } else if ([self internalRole] == ax::mojom::Role::kColumn) {
|
||||
DCHECK(_owner->node());
|
||||
base::Optional<int> col_index = *_owner->node()->GetTableColColIndex();
|
||||
if (col_index)
|
||||
@@ -1512,6 +1515,55 @@ - (NSNumber*)index {
|
||||
return nil;
|
||||
}
|
||||
|
||||
+- (NSNumber*)treeItemRowIndex {
|
||||
+ if (![self instanceActive])
|
||||
+ return nil;
|
||||
+
|
||||
+ DCHECK([self internalRole] == ax::mojom::Role::kTreeItem);
|
||||
+ DCHECK([[self role] isEqualToString:NSAccessibilityRowRole]);
|
||||
+
|
||||
+ // First find an ancestor that establishes this tree or treegrid. We
|
||||
+ // will search in this ancestor to calculate our row index.
|
||||
+ BrowserAccessibility* container = [self owner]->PlatformGetParent();
|
||||
+ while (container && container->GetRole() != ax::mojom::Role::kTree &&
|
||||
+ container->GetRole() != ax::mojom::Role::kTreeGrid) {
|
||||
+ container = container->PlatformGetParent();
|
||||
+ }
|
||||
+ if (!container)
|
||||
+ return nil;
|
||||
+
|
||||
+ const BrowserAccessibilityCocoa* cocoaContainer =
|
||||
+ ToBrowserAccessibilityCocoa(container);
|
||||
+ int currentIndex = 0;
|
||||
+ if ([cocoaContainer findRowIndex:self withCurrentIndex:¤tIndex]) {
|
||||
+ return @(currentIndex);
|
||||
+ }
|
||||
+
|
||||
+ return nil;
|
||||
+}
|
||||
+
|
||||
+- (bool)findRowIndex:(BrowserAccessibilityCocoa*)toFind
|
||||
+ withCurrentIndex:(int*)currentIndex {
|
||||
+ if (![self instanceActive])
|
||||
+ return false;
|
||||
+
|
||||
+ DCHECK([[toFind role] isEqualToString:NSAccessibilityRowRole]);
|
||||
+ for (BrowserAccessibilityCocoa* childToCheck in [self children]) {
|
||||
+ if ([toFind isEqual:childToCheck]) {
|
||||
+ return true;
|
||||
+ }
|
||||
+
|
||||
+ if ([[childToCheck role] isEqualToString:NSAccessibilityRowRole]) {
|
||||
+ ++(*currentIndex);
|
||||
+ }
|
||||
+
|
||||
+ if ([childToCheck findRowIndex:toFind withCurrentIndex:currentIndex]) {
|
||||
+ return true;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ return false;
|
||||
+}
|
||||
|
||||
#ifndef MAS_BUILD
|
||||
- (NSNumber*)insertionPointLineNumber {
|
||||
@@ -3441,12 +3493,15 @@ - (NSArray*)accessibilityAttributeNames {
|
||||
container = container->PlatformGetParent();
|
||||
if ([subrole isEqualToString:NSAccessibilityOutlineRowSubrole] ||
|
||||
(container && container->GetRole() == ax::mojom::Role::kTreeGrid)) {
|
||||
+ // clang-format off
|
||||
[ret addObjectsFromArray:@[
|
||||
- NSAccessibilityDisclosingAttribute,
|
||||
+ NSAccessibilityIndexAttribute,
|
||||
NSAccessibilityDisclosedByRowAttribute,
|
||||
- NSAccessibilityDisclosureLevelAttribute,
|
||||
- NSAccessibilityDisclosedRowsAttribute
|
||||
+ NSAccessibilityDisclosedRowsAttribute,
|
||||
+ NSAccessibilityDisclosingAttribute,
|
||||
+ NSAccessibilityDisclosureLevelAttribute
|
||||
]];
|
||||
+ // clang-format on
|
||||
} else {
|
||||
[ret addObjectsFromArray:@[ NSAccessibilityIndexAttribute ]];
|
||||
}
|
||||
diff --git a/content/test/data/accessibility/aria/aria-level-expected-mac.txt b/content/test/data/accessibility/aria/aria-level-expected-mac.txt
|
||||
index 2977dc82f7c894b8496158fb51dc2665939d0d9d..19b7c2b3f131a41f9e49dc4a8db875efe53e3cdb 100644
|
||||
--- a/content/test/data/accessibility/aria/aria-level-expected-mac.txt
|
||||
+++ b/content/test/data/accessibility/aria/aria-level-expected-mac.txt
|
||||
@@ -14,21 +14,21 @@ AXWebArea
|
||||
++AXHeading AXTitle='Level 5' AXValue=5
|
||||
++++AXStaticText AXValue='Level 5'
|
||||
++AXOutline
|
||||
-++++AXRow AXSubrole=AXOutlineRow AXDisclosing=1 AXDisclosureLevel=0 AXTitle='Tree item at level 1'
|
||||
+++++AXRow AXSubrole=AXOutlineRow AXDisclosing=1 AXDisclosureLevel=0 AXIndex=0 AXTitle='Tree item at level 1'
|
||||
++++++AXStaticText AXValue='Tree item at level 1'
|
||||
++++++AXGroup
|
||||
-++++++++AXRow AXSubrole=AXOutlineRow AXDisclosing=0 AXDisclosureLevel=1 AXTitle='Tree item at level 2'
|
||||
+++++++++AXRow AXSubrole=AXOutlineRow AXDisclosing=0 AXDisclosureLevel=1 AXIndex=1 AXTitle='Tree item at level 2'
|
||||
++++++++++AXStaticText AXValue='Tree item at level 2'
|
||||
-++++AXRow AXSubrole=AXOutlineRow AXDisclosing=0 AXDisclosureLevel=2 AXTitle='Tree item at level 3'
|
||||
+++++AXRow AXSubrole=AXOutlineRow AXDisclosing=0 AXDisclosureLevel=2 AXIndex=2 AXTitle='Tree item at level 3'
|
||||
++++++AXStaticText AXValue='Tree item at level 3'
|
||||
++AXTable
|
||||
-++++AXRow AXDisclosureLevel=0
|
||||
+++++AXRow AXDisclosureLevel=0 AXIndex=0
|
||||
++++++AXCell
|
||||
++++++++AXStaticText AXValue='Cell at level 1'
|
||||
-++++AXRow AXDisclosureLevel=1
|
||||
+++++AXRow AXDisclosureLevel=1 AXIndex=1
|
||||
++++++AXCell
|
||||
++++++++AXStaticText AXValue='Cell at level 2'
|
||||
-++++AXColumn
|
||||
+++++AXColumn AXIndex=0
|
||||
++++++AXCell
|
||||
++++++++AXStaticText AXValue='Cell at level 1'
|
||||
++++++AXCell
|
||||
diff --git a/content/test/data/accessibility/aria/aria-level.html b/content/test/data/accessibility/aria/aria-level.html
|
||||
index 9c499edadbfb8dfa3c07d5cf1d9e5f48349a48a5..b7aabab3a3232985c597cb2362184c0a436e8475 100644
|
||||
--- a/content/test/data/accessibility/aria/aria-level.html
|
||||
+++ b/content/test/data/accessibility/aria/aria-level.html
|
||||
@@ -3,6 +3,7 @@
|
||||
@MAC-ALLOW:AXSubrole=AXOutlineRow
|
||||
@MAC-ALLOW:AXDisclosing*
|
||||
@MAC-ALLOW:AXDisclosureLevel*
|
||||
+@MAC-ALLOW:AXIndex*
|
||||
@WIN-ALLOW:level:*
|
||||
@WIN-ALLOW:EXPANDED
|
||||
@WIN-DENY:name=''
|
||||
diff --git a/content/test/data/accessibility/aria/aria-tree-discontinuous-expected-mac.txt b/content/test/data/accessibility/aria/aria-tree-discontinuous-expected-mac.txt
|
||||
index 3f2259665df8fbc291a848e5ada5ee02c37eb8cd..48afda07b5d020f0972a9aaf9ccffcfb76fd3857 100644
|
||||
--- a/content/test/data/accessibility/aria/aria-tree-discontinuous-expected-mac.txt
|
||||
+++ b/content/test/data/accessibility/aria/aria-tree-discontinuous-expected-mac.txt
|
||||
@@ -1,7 +1,7 @@
|
||||
AXWebArea
|
||||
++AXOutline AXARIASetSize=2
|
||||
-++++AXRow AXARIAPosInSet=1 AXARIASetSize=2 AXTitle='card content'
|
||||
+++++AXRow AXARIAPosInSet=1 AXARIASetSize=2 AXIndex=0 AXTitle='card content'
|
||||
++++++AXStaticText AXValue='card content'
|
||||
++++AXGroup
|
||||
-++++AXRow AXARIAPosInSet=2 AXARIASetSize=2 AXTitle='card content'
|
||||
+++++AXRow AXARIAPosInSet=2 AXARIASetSize=2 AXIndex=1 AXTitle='card content'
|
||||
++++++AXStaticText AXValue='card content'
|
||||
diff --git a/content/test/data/accessibility/aria/aria-tree-discontinuous.html b/content/test/data/accessibility/aria/aria-tree-discontinuous.html
|
||||
index c0ef927e92216957f9369afedb07c068c0970025..f14ce533208511655e6c86f934661e1adec083ba 100644
|
||||
--- a/content/test/data/accessibility/aria/aria-tree-discontinuous.html
|
||||
+++ b/content/test/data/accessibility/aria/aria-tree-discontinuous.html
|
||||
@@ -1,6 +1,7 @@
|
||||
<!--
|
||||
@MAC-ALLOW:AXARIASetSize
|
||||
@MAC-ALLOW:AXARIAPosInSet
|
||||
+@MAC-ALLOW:AXIndex
|
||||
@WIN-ALLOW:setsize*
|
||||
@WIN-ALLOW:posinset*
|
||||
@UIA-WIN-ALLOW:SizeOfSet*
|
||||
diff --git a/content/test/data/accessibility/aria/aria-tree-expected-mac.txt b/content/test/data/accessibility/aria/aria-tree-expected-mac.txt
|
||||
index 5d40b45374b4cc3685eff0146d34e3f814216af8..2580c407cf97626dff52f6e883b5ee8c1c753dc8 100644
|
||||
--- a/content/test/data/accessibility/aria/aria-tree-expected-mac.txt
|
||||
+++ b/content/test/data/accessibility/aria/aria-tree-expected-mac.txt
|
||||
@@ -1,22 +1,22 @@
|
||||
AXWebArea
|
||||
++AXOutline AXARIASetSize=2
|
||||
-++++AXRow AXARIAPosInSet=1 AXARIASetSize=2 AXTitle='Animals' AXValue=2
|
||||
+++++AXRow AXARIAPosInSet=1 AXARIASetSize=2 AXIndex=0 AXTitle='Animals' AXValue=2
|
||||
++++++AXLink AXDescription='Animals'
|
||||
++++++++AXStaticText AXValue='Animals'
|
||||
++++++AXGroup AXARIASetSize=2
|
||||
-++++++++AXRow AXARIAPosInSet=1 AXARIASetSize=2 AXTitle='Domesticated'
|
||||
+++++++++AXRow AXARIAPosInSet=1 AXARIASetSize=2 AXIndex=1 AXTitle='Domesticated'
|
||||
++++++++++AXLink AXDescription='Domesticated'
|
||||
++++++++++++AXStaticText AXValue='Domesticated'
|
||||
++++++++++AXGroup AXARIASetSize=2
|
||||
-++++++++++++AXRow AXARIAPosInSet=1 AXARIASetSize=2 AXTitle='Dog' AXValue=1
|
||||
+++++++++++++AXRow AXARIAPosInSet=1 AXARIASetSize=2 AXIndex=2 AXTitle='Dog' AXValue=1
|
||||
++++++++++++++AXLink AXDescription='Dog'
|
||||
++++++++++++++++AXStaticText AXValue='Dog'
|
||||
-++++++++++++AXRow AXARIAPosInSet=2 AXARIASetSize=2 AXTitle='Cat' AXValue=0
|
||||
+++++++++++++AXRow AXARIAPosInSet=2 AXARIASetSize=2 AXIndex=3 AXTitle='Cat' AXValue=0
|
||||
++++++++++++++AXLink AXDescription='Cat'
|
||||
++++++++++++++++AXStaticText AXValue='Cat'
|
||||
-++++++++AXRow AXARIAPosInSet=2 AXARIASetSize=2 AXTitle='Wild'
|
||||
+++++++++AXRow AXARIAPosInSet=2 AXARIASetSize=2 AXIndex=4 AXTitle='Wild'
|
||||
++++++++++AXLink AXDescription='Wild'
|
||||
++++++++++++AXStaticText AXValue='Wild'
|
||||
-++++AXRow AXARIAPosInSet=2 AXARIASetSize=2 AXTitle='Plants'
|
||||
+++++AXRow AXARIAPosInSet=2 AXARIASetSize=2 AXIndex=5 AXTitle='Plants'
|
||||
++++++AXLink AXDescription='Plants'
|
||||
++++++++AXStaticText AXValue='Plants'
|
||||
diff --git a/content/test/data/accessibility/aria/aria-tree.html b/content/test/data/accessibility/aria/aria-tree.html
|
||||
index f2974e876b83e48d277a54d2bcf92319dcc89cfe..7b984675b97b09cb629d81d6835b5616c7b8873f 100644
|
||||
--- a/content/test/data/accessibility/aria/aria-tree.html
|
||||
+++ b/content/test/data/accessibility/aria/aria-tree.html
|
||||
@@ -1,4 +1,5 @@
|
||||
<!--
|
||||
+@MAC-ALLOW:AXIndex
|
||||
@MAC-ALLOW:AXARIASetSize
|
||||
@MAC-ALLOW:AXARIAPosInSet
|
||||
@WIN-ALLOW:setsize*
|
||||
diff --git a/content/test/data/accessibility/aria/aria-treegrid-expected-mac.txt b/content/test/data/accessibility/aria/aria-treegrid-expected-mac.txt
|
||||
index 3c28472ddfe697d88e3fba3fe0fcff5853e0d1d5..d4d0a70fd610994b19641ddd69a31bb56574a55e 100644
|
||||
--- a/content/test/data/accessibility/aria/aria-treegrid-expected-mac.txt
|
||||
+++ b/content/test/data/accessibility/aria/aria-treegrid-expected-mac.txt
|
||||
@@ -1,12 +1,12 @@
|
||||
AXWebArea
|
||||
++AXTable
|
||||
-++++AXRow AXDisclosureLevel=0
|
||||
+++++AXRow AXDisclosureLevel=0 AXIndex=0
|
||||
++++++AXCell
|
||||
++++++++AXStaticText AXValue='Cell at level 1'
|
||||
-++++AXRow AXDisclosureLevel=1
|
||||
+++++AXRow AXDisclosureLevel=1 AXIndex=1
|
||||
++++++AXCell
|
||||
++++++++AXStaticText AXValue='Cell at level 2'
|
||||
-++++AXColumn
|
||||
+++++AXColumn AXIndex=0
|
||||
++++++AXCell
|
||||
++++++++AXStaticText AXValue='Cell at level 1'
|
||||
++++++AXCell
|
||||
@@ -14,10 +14,10 @@ AXWebArea
|
||||
++++AXGroup
|
||||
++AXTable
|
||||
++++AXGroup
|
||||
-++++++AXRow AXDisclosureLevel=0
|
||||
+++++++AXRow AXDisclosureLevel=0 AXIndex=0
|
||||
++++++++AXCell
|
||||
++++++++++AXStaticText AXValue='Cell at level 1'
|
||||
-++++AXColumn
|
||||
+++++AXColumn AXIndex=0
|
||||
++++++AXCell
|
||||
++++++++AXStaticText AXValue='Cell at level 1'
|
||||
++++AXGroup
|
||||
diff --git a/content/test/data/accessibility/aria/aria-treegrid.html b/content/test/data/accessibility/aria/aria-treegrid.html
|
||||
index f8aefe163b900596152999b845bd856b44a05df2..01b74aa99db9304248e94273bbc3d73a170d8539 100644
|
||||
--- a/content/test/data/accessibility/aria/aria-treegrid.html
|
||||
+++ b/content/test/data/accessibility/aria/aria-treegrid.html
|
||||
@@ -1,5 +1,6 @@
|
||||
<!--
|
||||
@BLINK-ALLOW:hierarchicalLevel*
|
||||
+@MAC-ALLOW:AXIndex
|
||||
@MAC-ALLOW:AXRole=*
|
||||
@MAC-ALLOW:AXDisclosureLevel*
|
||||
@WIN-ALLOW:xml-roles:*
|
||||
diff --git a/content/test/data/accessibility/aria/aria-treeitem-nested-in-lists-expected-mac.txt b/content/test/data/accessibility/aria/aria-treeitem-nested-in-lists-expected-mac.txt
|
||||
index 0b7abc24fd7b3acec0a44244c7f975075282e887..523458d38299a7599060c1fda8a8c301acc4304f 100644
|
||||
--- a/content/test/data/accessibility/aria/aria-treeitem-nested-in-lists-expected-mac.txt
|
||||
+++ b/content/test/data/accessibility/aria/aria-treeitem-nested-in-lists-expected-mac.txt
|
||||
@@ -1,17 +1,17 @@
|
||||
AXWebArea AXRoleDescription='HTML content'
|
||||
++AXOutline AXARIASetSize=5 AXRoleDescription='outline'
|
||||
++++AXGroup AXRoleDescription='group'
|
||||
-++++++AXRow AXARIAPosInSet=2 AXARIASetSize=5 AXRoleDescription='row' AXTitle='treeitem 2 of 5, level 1'
|
||||
+++++++AXRow AXARIAPosInSet=2 AXARIASetSize=5 AXIndex=0 AXRoleDescription='row' AXTitle='treeitem 2 of 5, level 1'
|
||||
++++++++AXStaticText AXRoleDescription='text' AXValue='treeitem 2 of 5, level 1'
|
||||
++++AXGroup AXRoleDescription='group'
|
||||
-++++++AXRow AXARIAPosInSet=3 AXARIASetSize=5 AXRoleDescription='row' AXTitle='treeitem 3 of 5, level 1'
|
||||
+++++++AXRow AXARIAPosInSet=3 AXARIASetSize=5 AXIndex=1 AXRoleDescription='row' AXTitle='treeitem 3 of 5, level 1'
|
||||
++++++++AXStaticText AXRoleDescription='text' AXValue='treeitem 3 of 5, level 1'
|
||||
++++AXGroup AXRoleDescription='group'
|
||||
-++++++AXRow AXARIAPosInSet=1 AXARIASetSize=2 AXRoleDescription='row' AXTitle='treeitem 1 of 2, level 2'
|
||||
+++++++AXRow AXARIAPosInSet=1 AXARIASetSize=2 AXIndex=2 AXRoleDescription='row' AXTitle='treeitem 1 of 2, level 2'
|
||||
++++++++AXStaticText AXRoleDescription='text' AXValue='treeitem 1 of 2, level 2'
|
||||
++++AXGroup AXRoleDescription='group'
|
||||
-++++++AXRow AXARIAPosInSet=1 AXARIASetSize=1 AXRoleDescription='row' AXTitle='treeitem 1 of 1, level 3'
|
||||
+++++++AXRow AXARIAPosInSet=1 AXARIASetSize=1 AXIndex=3 AXRoleDescription='row' AXTitle='treeitem 1 of 1, level 3'
|
||||
++++++++AXStaticText AXRoleDescription='text' AXValue='treeitem 1 of 1, level 3'
|
||||
++++AXGroup AXRoleDescription='group'
|
||||
-++++++AXRow AXARIAPosInSet=2 AXARIASetSize=2 AXRoleDescription='row' AXTitle='treeitem 2 of 2, level 2'
|
||||
+++++++AXRow AXARIAPosInSet=2 AXARIASetSize=2 AXIndex=4 AXRoleDescription='row' AXTitle='treeitem 2 of 2, level 2'
|
||||
++++++++AXStaticText AXRoleDescription='text' AXValue='treeitem 2 of 2, level 2'
|
||||
diff --git a/content/test/data/accessibility/aria/aria-treeitem-nested-in-lists.html b/content/test/data/accessibility/aria/aria-treeitem-nested-in-lists.html
|
||||
index f3794bbad09a43a279fef12b5bc4f63e1c70341f..8294fb11adb63a801117e4439c8b43c48dc8ce59 100644
|
||||
--- a/content/test/data/accessibility/aria/aria-treeitem-nested-in-lists.html
|
||||
+++ b/content/test/data/accessibility/aria/aria-treeitem-nested-in-lists.html
|
||||
@@ -4,6 +4,7 @@
|
||||
@MAC-ALLOW:AXARIAPosInSet*
|
||||
@MAC-DENY:AXARIASetSize=0
|
||||
@MAC-DENY:AXARIAPosInSet=0
|
||||
+@MAC-ALLOW:AXIndex
|
||||
@WIN-ALLOW:xml-roles*
|
||||
@WIN-ALLOW:level*
|
||||
@WIN-ALLOW:setsize*
|
||||
@@ -0,0 +1,37 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Shelley Vohr <shelley.vohr@gmail.com>
|
||||
Date: Mon, 5 Oct 2020 13:43:59 -0700
|
||||
Subject: chore: expose v8 initialization isolate callbacks
|
||||
|
||||
This commit is necessary in order to ensure consistent behavior from
|
||||
v8 Isolate callbacks in contexts which Node.js does not control. If
|
||||
we're running with contextIsolation enabled, we should be falling back
|
||||
to Blink's logic. This will be upstreamed in some form.
|
||||
|
||||
diff --git a/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc b/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
|
||||
index 85ac9d5d95856470707d320d382743673cd1451a..398095d8890cee3f8838170a86ccb48010ff74a0 100644
|
||||
--- a/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
|
||||
+++ b/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
|
||||
@@ -438,7 +438,7 @@ CodeGenerationCheckCallbackInMainThread(v8::Local<v8::Context> context,
|
||||
return {true, std::move(stringified_source)};
|
||||
}
|
||||
|
||||
-static bool WasmCodeGenerationCheckCallbackInMainThread(
|
||||
+bool V8Initializer::WasmCodeGenerationCheckCallbackInMainThread(
|
||||
v8::Local<v8::Context> context,
|
||||
v8::Local<v8::String> source) {
|
||||
if (ExecutionContext* execution_context = ToExecutionContext(context)) {
|
||||
diff --git a/third_party/blink/renderer/bindings/core/v8/v8_initializer.h b/third_party/blink/renderer/bindings/core/v8/v8_initializer.h
|
||||
index e7cbc5db7d15aa0fcfb37ba261673b973827296a..6b93aa449a005e06862a99ea0c9b751ffff2d6ec 100644
|
||||
--- a/third_party/blink/renderer/bindings/core/v8/v8_initializer.h
|
||||
+++ b/third_party/blink/renderer/bindings/core/v8/v8_initializer.h
|
||||
@@ -67,6 +67,9 @@ class CORE_EXPORT V8Initializer {
|
||||
v8::Local<v8::Value>);
|
||||
static void MessageHandlerInWorker(v8::Local<v8::Message>,
|
||||
v8::Local<v8::Value>);
|
||||
+ static bool WasmCodeGenerationCheckCallbackInMainThread(
|
||||
+ v8::Local<v8::Context> context,
|
||||
+ v8::Local<v8::String> source);
|
||||
};
|
||||
|
||||
} // namespace blink
|
||||
@@ -7,10 +7,10 @@ spellchecker uses a few IDS_ resources. We need to load these from
|
||||
Electrons grit header instead of Chromes
|
||||
|
||||
diff --git a/chrome/browser/BUILD.gn b/chrome/browser/BUILD.gn
|
||||
index 178c8d95431e9bcfa7a3beae42d950451d78c047..781eee7436868d164549aa2932685223cdd7aca5 100644
|
||||
index b41fce646b16e51ccfdcc6fef68d2f29195a24f2..f76896877ae828a6fa7901507a62491188b5cd2d 100644
|
||||
--- a/chrome/browser/BUILD.gn
|
||||
+++ b/chrome/browser/BUILD.gn
|
||||
@@ -5602,6 +5602,7 @@ static_library("browser") {
|
||||
@@ -5955,6 +5955,7 @@ static_library("browser") {
|
||||
deps += [
|
||||
"//components/spellcheck/browser",
|
||||
"//components/spellcheck/common",
|
||||
@@ -44,7 +44,7 @@ index f28230ea94fece5ae8ca7ac27a14da48f40fadbb..c10eea103852b9411a644e1fe20a7e20
|
||||
]
|
||||
}
|
||||
diff --git a/components/language/core/browser/language_prefs.cc b/components/language/core/browser/language_prefs.cc
|
||||
index 9223b194237b0d7b4df7a9d47e00d14fbcabf2d7..dfd916986804f5ffa8ec8a7e29ad507fb4d1a5aa 100644
|
||||
index 75dcb9e5c4cb1aa64800240bd9282cac469c4524..b27d374f76e24b809f9bc9cf45560603f141350c 100644
|
||||
--- a/components/language/core/browser/language_prefs.cc
|
||||
+++ b/components/language/core/browser/language_prefs.cc
|
||||
@@ -20,7 +20,7 @@
|
||||
|
||||
@@ -32,17 +32,19 @@ index c5125495b4d178ffb18be4d2d9670f7556412cbd..cddb321abb938c667a4a2089f87eab99
|
||||
// Create an observer that registers a hot key for |accelerator|.
|
||||
std::unique_ptr<gfx::SingletonHwndHotKeyObserver> observer =
|
||||
diff --git a/chrome/browser/extensions/global_shortcut_listener_x11.cc b/chrome/browser/extensions/global_shortcut_listener_x11.cc
|
||||
index a33ff046e940880f9c1ad15769325b0dac22ee43..a4cf5dd70cd2ab6a5246b06790f2f7f6c9fd8631 100644
|
||||
index f43494af6f5ef89917b2c088a533ad1dabbf3b2b..a9506c394cdeff36dd03b50cd19c4ffe5a1ed249 100644
|
||||
--- a/chrome/browser/extensions/global_shortcut_listener_x11.cc
|
||||
+++ b/chrome/browser/extensions/global_shortcut_listener_x11.cc
|
||||
@@ -38,6 +38,7 @@ int GetNativeModifiers(const ui::Accelerator& accelerator) {
|
||||
modifiers |= accelerator.IsShiftDown() ? ShiftMask : 0;
|
||||
modifiers |= accelerator.IsCtrlDown() ? ControlMask : 0;
|
||||
modifiers |= accelerator.IsAltDown() ? Mod1Mask : 0;
|
||||
+ modifiers |= accelerator.IsCmdDown() ? Mod4Mask : 0;
|
||||
|
||||
return modifiers;
|
||||
@@ -39,7 +39,8 @@ x11::ModMask GetNativeModifiers(const ui::Accelerator& accelerator) {
|
||||
constexpr auto kNoMods = x11::ModMask{};
|
||||
return (accelerator.IsShiftDown() ? x11::ModMask::Shift : kNoMods) |
|
||||
(accelerator.IsCtrlDown() ? x11::ModMask::Control : kNoMods) |
|
||||
- (accelerator.IsAltDown() ? x11::ModMask::c_1 : kNoMods);
|
||||
+ (accelerator.IsAltDown() ? x11::ModMask::c_1 : kNoMods) |
|
||||
+ (accelerator.IsCmdDown() ? x11::ModMask::c_4 : kNoMods);
|
||||
}
|
||||
|
||||
} // namespace
|
||||
diff --git a/ui/base/accelerators/media_keys_listener.cc b/ui/base/accelerators/media_keys_listener.cc
|
||||
index 1145e1f3d79482b5bb468c3128431ac674310e5f..e9f595045e0c076e0735f27dfc38bfbc7951d372 100644
|
||||
--- a/ui/base/accelerators/media_keys_listener.cc
|
||||
|
||||
@@ -8,10 +8,10 @@ run before shutdown. This is required to cleanup WebContents asynchronously
|
||||
in atom::CommonWebContentsDelegate::ResetManageWebContents.
|
||||
|
||||
diff --git a/content/browser/browser_main_loop.cc b/content/browser/browser_main_loop.cc
|
||||
index 5bcf1709d610438ff8ebc37dc65ed4d5e01ece7e..1a4f1aff0644412bdff44be7b859d5e8b4508a72 100644
|
||||
index 7242f26441f93cab50a1fc7d79b086d5ffc63468..75dff99ae3b4803831331c10cd72650713de7e60 100644
|
||||
--- a/content/browser/browser_main_loop.cc
|
||||
+++ b/content/browser/browser_main_loop.cc
|
||||
@@ -1436,7 +1436,7 @@ void BrowserMainLoop::MainMessageLoopRun() {
|
||||
@@ -1453,7 +1453,7 @@ void BrowserMainLoop::MainMessageLoopRun() {
|
||||
NOTREACHED();
|
||||
#else
|
||||
base::RunLoop run_loop;
|
||||
|
||||
@@ -13,10 +13,10 @@ Ultimately we should remove the option to disable compression, and
|
||||
subsequently remove this patch.
|
||||
|
||||
diff --git a/components/crash/core/app/breakpad_linux.cc b/components/crash/core/app/breakpad_linux.cc
|
||||
index fdd76ee1490e39dbfcd39bbff6686864a5c5af29..4e717ba90066bc75bf173b5027100a05cc1c8749 100644
|
||||
index 7d23a5732b47bef04cadc707f58e50b423393605..f85395cd64db22f8d530b070e1929de7d1f59db3 100644
|
||||
--- a/components/crash/core/app/breakpad_linux.cc
|
||||
+++ b/components/crash/core/app/breakpad_linux.cc
|
||||
@@ -109,6 +109,8 @@ void SetUploadURL(const std::string& url) {
|
||||
@@ -108,6 +108,8 @@ void SetUploadURL(const std::string& url) {
|
||||
DCHECK(!g_upload_url);
|
||||
g_upload_url = strdup(url.c_str());
|
||||
}
|
||||
@@ -25,7 +25,7 @@ index fdd76ee1490e39dbfcd39bbff6686864a5c5af29..4e717ba90066bc75bf173b5027100a05
|
||||
#endif
|
||||
|
||||
bool g_is_node = false;
|
||||
@@ -1320,56 +1322,60 @@ void ExecUploadProcessOrTerminate(const BreakpadInfo& info,
|
||||
@@ -1319,56 +1321,60 @@ void ExecUploadProcessOrTerminate(const BreakpadInfo& info,
|
||||
|
||||
#else // defined(OS_CHROMEOS)
|
||||
|
||||
@@ -127,7 +127,7 @@ index fdd76ee1490e39dbfcd39bbff6686864a5c5af29..4e717ba90066bc75bf173b5027100a05
|
||||
static const char header_msg[] =
|
||||
"--header=Content-Type: multipart/form-data; boundary=";
|
||||
const size_t header_content_type_size =
|
||||
@@ -1396,7 +1402,8 @@ void ExecUploadProcessOrTerminate(const BreakpadInfo& info,
|
||||
@@ -1395,7 +1401,8 @@ void ExecUploadProcessOrTerminate(const BreakpadInfo& info,
|
||||
static const char kWgetBinary[] = "/usr/bin/wget";
|
||||
const char* args[] = {
|
||||
kWgetBinary,
|
||||
@@ -137,7 +137,7 @@ index fdd76ee1490e39dbfcd39bbff6686864a5c5af29..4e717ba90066bc75bf173b5027100a05
|
||||
header_content_type,
|
||||
post_file,
|
||||
g_upload_url,
|
||||
@@ -2037,6 +2044,7 @@ void InitCrashReporter(const std::string& process_type) {
|
||||
@@ -2036,6 +2043,7 @@ void InitCrashReporter(const std::string& process_type) {
|
||||
|
||||
#if !defined(OS_CHROMEOS)
|
||||
SetUploadURL(GetCrashReporterClient()->GetUploadUrl());
|
||||
|
||||
@@ -9,10 +9,10 @@ rate-limiting, compression and global annotations.
|
||||
This should be upstreamed.
|
||||
|
||||
diff --git a/components/crash/core/app/breakpad_linux.cc b/components/crash/core/app/breakpad_linux.cc
|
||||
index 9b07ab4667e691c0c8db4c71251b04d0cdf71ff3..72ee7e8df3d62eca301b08586f06d51711e941b5 100644
|
||||
index 9d8370ef035f2ca285c8aa35e98761bff7200d26..1c076672c77d90eb3814b5b269340d2800217868 100644
|
||||
--- a/components/crash/core/app/breakpad_linux.cc
|
||||
+++ b/components/crash/core/app/breakpad_linux.cc
|
||||
@@ -111,6 +111,7 @@ void SetUploadURL(const std::string& url) {
|
||||
@@ -110,6 +110,7 @@ void SetUploadURL(const std::string& url) {
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -21,7 +21,7 @@ index 9b07ab4667e691c0c8db4c71251b04d0cdf71ff3..72ee7e8df3d62eca301b08586f06d517
|
||||
uint64_t g_process_start_time = 0;
|
||||
pid_t g_pid = 0;
|
||||
diff --git a/components/crash/core/app/crash_reporter_client.cc b/components/crash/core/app/crash_reporter_client.cc
|
||||
index d18efa945502bfbb7f2d6fe659472f8e495600da..0acaaaeb6aa80747c9230ec81419cae884444c5e 100644
|
||||
index 1d0fb4f2a633fa5ddbe232ce19d716c22be78a37..5b81608d6e90f62f435302a53976fb18bbbf9e98 100644
|
||||
--- a/components/crash/core/app/crash_reporter_client.cc
|
||||
+++ b/components/crash/core/app/crash_reporter_client.cc
|
||||
@@ -140,6 +140,17 @@ bool CrashReporterClient::ReportingIsEnforcedByPolicy(bool* breakpad_enabled) {
|
||||
@@ -43,7 +43,7 @@ index d18efa945502bfbb7f2d6fe659472f8e495600da..0acaaaeb6aa80747c9230ec81419cae8
|
||||
unsigned int CrashReporterClient::GetCrashDumpPercentage() {
|
||||
return 100;
|
||||
diff --git a/components/crash/core/app/crash_reporter_client.h b/components/crash/core/app/crash_reporter_client.h
|
||||
index 1f33fd0baf1e8bed001260184e9d34cb77313b03..63c09694bedf3995235a1755d35d4d78ed32619a 100644
|
||||
index aaa9ad1d58d7f584cbf391e0cb0a61a0d25d5c69..5b02834b5ecaf4bcb7e051d9ee98cd5eb087b4fc 100644
|
||||
--- a/components/crash/core/app/crash_reporter_client.h
|
||||
+++ b/components/crash/core/app/crash_reporter_client.h
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
146
patches/chromium/crashpad-initialize-logging.patch
Normal file
146
patches/chromium/crashpad-initialize-logging.patch
Normal file
@@ -0,0 +1,146 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Joshua Peraza <jperaza@chromium.org>
|
||||
Date: Wed, 21 Oct 2020 11:10:25 -0700
|
||||
Subject: Initialize logging for crashpad
|
||||
|
||||
Although logging to files is not yet supported by mini_chromium, it is
|
||||
the default behavior for OS_WIN in chromium. This change should
|
||||
cause crashpad to log via OutputDebugString() on Windows, instead of
|
||||
debug.log files. Future work (crbug.com/crashpad/26) should arrange for
|
||||
logs to be uploaded with reports, embedded in associated minidumps or as
|
||||
file attachments.
|
||||
|
||||
Bug: chromium:711159
|
||||
Change-Id: I0f9004f7de94dd29d555cc7d23c48a63da6b4bba
|
||||
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2425108
|
||||
Reviewed-by: Mark Mentovai <mark@chromium.org>
|
||||
|
||||
diff --git a/base/logging.cc b/base/logging.cc
|
||||
index b5cf2c4933d0cbb89f2f1b410c5c249a0b8647f0..698dca03914934b294457d05d89722a27cdebb56 100644
|
||||
--- a/base/logging.cc
|
||||
+++ b/base/logging.cc
|
||||
@@ -369,21 +369,23 @@ bool BaseInitLoggingImpl(const LoggingSettings& settings) {
|
||||
g_log_format = settings.log_format;
|
||||
#endif
|
||||
|
||||
- base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
|
||||
- // Don't bother initializing |g_vlog_info| unless we use one of the
|
||||
- // vlog switches.
|
||||
- if (command_line->HasSwitch(switches::kV) ||
|
||||
- command_line->HasSwitch(switches::kVModule)) {
|
||||
- // NOTE: If |g_vlog_info| has already been initialized, it might be in use
|
||||
- // by another thread. Don't delete the old VLogInfo, just create a second
|
||||
- // one. We keep track of both to avoid memory leak warnings.
|
||||
- CHECK(!g_vlog_info_prev);
|
||||
- g_vlog_info_prev = g_vlog_info;
|
||||
-
|
||||
- g_vlog_info =
|
||||
- new VlogInfo(command_line->GetSwitchValueASCII(switches::kV),
|
||||
- command_line->GetSwitchValueASCII(switches::kVModule),
|
||||
- &g_min_log_level);
|
||||
+ if (base::CommandLine::InitializedForCurrentProcess()) {
|
||||
+ base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
|
||||
+ // Don't bother initializing |g_vlog_info| unless we use one of the
|
||||
+ // vlog switches.
|
||||
+ if (command_line->HasSwitch(switches::kV) ||
|
||||
+ command_line->HasSwitch(switches::kVModule)) {
|
||||
+ // NOTE: If |g_vlog_info| has already been initialized, it might be in use
|
||||
+ // by another thread. Don't delete the old VLogInfo, just create a second
|
||||
+ // one. We keep track of both to avoid memory leak warnings.
|
||||
+ CHECK(!g_vlog_info_prev);
|
||||
+ g_vlog_info_prev = g_vlog_info;
|
||||
+
|
||||
+ g_vlog_info =
|
||||
+ new VlogInfo(command_line->GetSwitchValueASCII(switches::kV),
|
||||
+ command_line->GetSwitchValueASCII(switches::kVModule),
|
||||
+ &g_min_log_level);
|
||||
+ }
|
||||
}
|
||||
|
||||
g_logging_destination = settings.logging_dest;
|
||||
@@ -394,7 +396,10 @@ bool BaseInitLoggingImpl(const LoggingSettings& settings) {
|
||||
config.min_severity = FX_LOG_INFO;
|
||||
config.console_fd = -1;
|
||||
config.log_service_channel = ZX_HANDLE_INVALID;
|
||||
- std::string log_tag = command_line->GetProgram().BaseName().AsUTF8Unsafe();
|
||||
+ std::string log_tag = base::CommandLine::ForCurrentProcess()
|
||||
+ ->GetProgram()
|
||||
+ .BaseName()
|
||||
+ .AsUTF8Unsafe();
|
||||
const char* log_tag_data = log_tag.data();
|
||||
config.tags = &log_tag_data;
|
||||
config.num_tags = 1;
|
||||
diff --git a/third_party/crashpad/crashpad/DEPS b/third_party/crashpad/crashpad/DEPS
|
||||
index 83995e0cdea91522c272415330c57af764d23163..7e83327aac2582e81a38720086a52832de58a37a 100644
|
||||
--- a/third_party/crashpad/crashpad/DEPS
|
||||
+++ b/third_party/crashpad/crashpad/DEPS
|
||||
@@ -42,7 +42,7 @@ deps = {
|
||||
'7bde79cc274d06451bf65ae82c012a5d3e476b5a',
|
||||
'crashpad/third_party/mini_chromium/mini_chromium':
|
||||
Var('chromium_git') + '/chromium/mini_chromium@' +
|
||||
- '76a9bb7475f6217eaf108789246379d3972b4e6a',
|
||||
+ '5fc64bfbf1c000161445c586de45e40464ff2314',
|
||||
'crashpad/third_party/libfuzzer/src':
|
||||
Var('chromium_git') + '/chromium/llvm-project/compiler-rt/lib/fuzzer.git@' +
|
||||
'fda403cf93ecb8792cb1d061564d89a6553ca020',
|
||||
diff --git a/third_party/crashpad/crashpad/handler/handler_main.cc b/third_party/crashpad/crashpad/handler/handler_main.cc
|
||||
index 33649291e253a7a9bd281b892bab415ff1950b6a..a3ba9bb17e221e8330b09eae572d116bd29e4ba4 100644
|
||||
--- a/third_party/crashpad/crashpad/handler/handler_main.cc
|
||||
+++ b/third_party/crashpad/crashpad/handler/handler_main.cc
|
||||
@@ -504,16 +504,26 @@ class ScopedStoppable {
|
||||
DISALLOW_COPY_AND_ASSIGN(ScopedStoppable);
|
||||
};
|
||||
|
||||
+void InitCrashpadLogging() {
|
||||
+ logging::LoggingSettings settings;
|
||||
+#if defined(OS_CHROMEOS)
|
||||
+ settings.logging_dest = logging::LOG_TO_FILE;
|
||||
+ settings.log_file_path = "/var/log/chrome/chrome";
|
||||
+#elif defined(OS_WIN)
|
||||
+ settings.logging_dest = logging::LOG_TO_SYSTEM_DEBUG_LOG;
|
||||
+#else
|
||||
+ settings.logging_dest =
|
||||
+ logging::LOG_TO_SYSTEM_DEBUG_LOG | logging::LOG_TO_STDERR;
|
||||
+#endif
|
||||
+ logging::InitLogging(settings);
|
||||
+}
|
||||
+
|
||||
} // namespace
|
||||
|
||||
int HandlerMain(int argc,
|
||||
char* argv[],
|
||||
const UserStreamDataSources* user_stream_sources) {
|
||||
-#if defined(OS_CHROMEOS)
|
||||
- if (freopen("/var/log/chrome/chrome", "a", stderr) == nullptr) {
|
||||
- PLOG(ERROR) << "Failed to redirect stderr to /var/log/chrome/chrome";
|
||||
- }
|
||||
-#endif
|
||||
+ InitCrashpadLogging();
|
||||
|
||||
InstallCrashHandler();
|
||||
CallMetricsRecordNormalExit metrics_record_normal_exit;
|
||||
diff --git a/third_party/crashpad/crashpad/test/gtest_main.cc b/third_party/crashpad/crashpad/test/gtest_main.cc
|
||||
index 67cfa0d72d7eb469775201f3a9df906f27c302a9..c67b8e24bb940935d5da88428ed3058a135f5a57 100644
|
||||
--- a/third_party/crashpad/crashpad/test/gtest_main.cc
|
||||
+++ b/third_party/crashpad/crashpad/test/gtest_main.cc
|
||||
@@ -12,6 +12,7 @@
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
+#include "base/logging.h"
|
||||
#include "build/build_config.h"
|
||||
#include "gtest/gtest.h"
|
||||
#include "test/main_arguments.h"
|
||||
@@ -99,6 +100,12 @@ int main(int argc, char* argv[]) {
|
||||
|
||||
#endif // CRASHPAD_IS_IN_CHROMIUM
|
||||
|
||||
+ // base::TestSuite initializes logging when using Chromium's test launcher.
|
||||
+ logging::LoggingSettings settings;
|
||||
+ settings.logging_dest =
|
||||
+ logging::LOG_TO_STDERR | logging::LOG_TO_SYSTEM_DEBUG_LOG;
|
||||
+ logging::InitLogging(settings);
|
||||
+
|
||||
#if defined(CRASHPAD_TEST_LAUNCHER_GOOGLEMOCK)
|
||||
testing::InitGoogleMock(&argc, argv);
|
||||
#elif defined(CRASHPAD_TEST_LAUNCHER_GOOGLETEST)
|
||||
@@ -16,11 +16,11 @@ example, the checks might be disabled for a whole build target, but actually
|
||||
only one or two specific checks fail. Then it's better to simply comment out the
|
||||
failing checks and allow the rest of the target to have them enabled.
|
||||
|
||||
diff --git a/content/browser/frame_host/navigation_controller_impl.cc b/content/browser/frame_host/navigation_controller_impl.cc
|
||||
index e026cf1322138009de75accc0e332e1e88267030..739e3ccb60d7a81fdb9af42b50d7ef8cd2811ff3 100644
|
||||
--- a/content/browser/frame_host/navigation_controller_impl.cc
|
||||
+++ b/content/browser/frame_host/navigation_controller_impl.cc
|
||||
@@ -1279,8 +1279,10 @@ NavigationType NavigationControllerImpl::ClassifyNavigation(
|
||||
diff --git a/content/browser/renderer_host/navigation_controller_impl.cc b/content/browser/renderer_host/navigation_controller_impl.cc
|
||||
index 18f5da7bc5953282e72933fffd7e37bbf77bfb31..b164f15fa7506caf82f0f5f450d90dbbd88a116e 100644
|
||||
--- a/content/browser/renderer_host/navigation_controller_impl.cc
|
||||
+++ b/content/browser/renderer_host/navigation_controller_impl.cc
|
||||
@@ -1275,8 +1275,10 @@ NavigationType NavigationControllerImpl::ClassifyNavigation(
|
||||
return NAVIGATION_TYPE_NEW_SUBFRAME;
|
||||
}
|
||||
|
||||
@@ -33,7 +33,7 @@ index e026cf1322138009de75accc0e332e1e88267030..739e3ccb60d7a81fdb9af42b50d7ef8c
|
||||
|
||||
if (rfh->GetParent()) {
|
||||
// All manual subframes would be did_create_new_entry and handled above, so
|
||||
@@ -1555,7 +1557,10 @@ void NavigationControllerImpl::RendererDidNavigateToNewPage(
|
||||
@@ -1551,7 +1553,10 @@ void NavigationControllerImpl::RendererDidNavigateToNewPage(
|
||||
new_entry->GetFavicon() = GetLastCommittedEntry()->GetFavicon();
|
||||
}
|
||||
|
||||
@@ -46,10 +46,10 @@ index e026cf1322138009de75accc0e332e1e88267030..739e3ccb60d7a81fdb9af42b50d7ef8c
|
||||
// navigation. Now we know that the renderer has updated its state accordingly
|
||||
// and it is safe to also clear the browser side history.
|
||||
diff --git a/ui/base/clipboard/clipboard_win.cc b/ui/base/clipboard/clipboard_win.cc
|
||||
index b422119ff36713399358b27aff8b18423f79d954..5c223f360ca641a3e29f23e6d409d7f97414a985 100644
|
||||
index 8d0e981720bb4a0ec4c42f389275fd375c1b1e43..9473f4f7819667d7cc4bfa514955b4e65d69c1c9 100644
|
||||
--- a/ui/base/clipboard/clipboard_win.cc
|
||||
+++ b/ui/base/clipboard/clipboard_win.cc
|
||||
@@ -831,10 +831,10 @@ SkBitmap ClipboardWin::ReadImageInternal(ClipboardBuffer buffer) const {
|
||||
@@ -850,10 +850,10 @@ SkBitmap ClipboardWin::ReadImageInternal(ClipboardBuffer buffer) const {
|
||||
|
||||
void ClipboardWin::WriteToClipboard(ClipboardFormatType format, HANDLE handle) {
|
||||
UINT cf_format = format.ToFormatEtc().cfFormat;
|
||||
|
||||
@@ -19,10 +19,10 @@ https://chromium-review.googlesource.com/c/chromium/src/+/1901591, we should try
|
||||
re-submitting the patch.
|
||||
|
||||
diff --git a/content/app/content_main_runner_impl.cc b/content/app/content_main_runner_impl.cc
|
||||
index 436d3628cc37df2612adbe2da6bbddd66c737ca4..51e0655bc3bce3640e26952513f1619f14cdf997 100644
|
||||
index a85c25303dfc00f862615f0c6e84135d1d8e175c..27951d85338f81406813a9bfddf402fb1aa81f9d 100644
|
||||
--- a/content/app/content_main_runner_impl.cc
|
||||
+++ b/content/app/content_main_runner_impl.cc
|
||||
@@ -663,7 +663,7 @@ int ContentMainRunnerImpl::Initialize(const ContentMainParams& params) {
|
||||
@@ -642,7 +642,7 @@ int ContentMainRunnerImpl::Initialize(const ContentMainParams& params) {
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -68,7 +68,7 @@ index 3038f9d25798f36811b6398f8cc0e7d83ecc41b0..68189c36c47ef85b345b0ccc40c456f8
|
||||
// Re-initializes schemes for tests.
|
||||
CONTENT_EXPORT void ReRegisterContentSchemesForTests();
|
||||
diff --git a/content/public/app/content_main_delegate.cc b/content/public/app/content_main_delegate.cc
|
||||
index 02985a525c98999f469906c8ff3647b740d9f962..e52e8d69c2d05b31d1f28b19752be362941e52be 100644
|
||||
index e6379748886956da819523200aa35f8f95d523ee..46110a92ba9849112889f3e93c1dccbbd4911dda 100644
|
||||
--- a/content/public/app/content_main_delegate.cc
|
||||
+++ b/content/public/app/content_main_delegate.cc
|
||||
@@ -36,6 +36,10 @@ int ContentMainDelegate::TerminateForFatalInitializationError() {
|
||||
@@ -79,14 +79,14 @@ index 02985a525c98999f469906c8ff3647b740d9f962..e52e8d69c2d05b31d1f28b19752be362
|
||||
+ return true;
|
||||
+}
|
||||
+
|
||||
service_manager::ProcessType ContentMainDelegate::OverrideProcessType() {
|
||||
return service_manager::ProcessType::kDefault;
|
||||
bool ContentMainDelegate::ShouldCreateFeatureList() {
|
||||
return true;
|
||||
}
|
||||
diff --git a/content/public/app/content_main_delegate.h b/content/public/app/content_main_delegate.h
|
||||
index 0ca924769b98009264b53121dfe6a892b81e8530..606a5cb8d89216a95e9187fba2ea9b6d4121a394 100644
|
||||
index abb46995385fccddf8363296fb0253624a4111c7..715d0818c03cfa7e5b9877b3ab83d1488f2f040f 100644
|
||||
--- a/content/public/app/content_main_delegate.h
|
||||
+++ b/content/public/app/content_main_delegate.h
|
||||
@@ -76,6 +76,20 @@ class CONTENT_EXPORT ContentMainDelegate {
|
||||
@@ -65,6 +65,20 @@ class CONTENT_EXPORT ContentMainDelegate {
|
||||
// returning initialization error code. Default behavior is CHECK(false).
|
||||
virtual int TerminateForFatalInitializationError();
|
||||
|
||||
@@ -104,6 +104,6 @@ index 0ca924769b98009264b53121dfe6a892b81e8530..606a5cb8d89216a95e9187fba2ea9b6d
|
||||
+ // from being locked.
|
||||
+ virtual bool ShouldLockSchemeRegistry();
|
||||
+
|
||||
// Overrides the Service Manager process type to use for the currently running
|
||||
// process.
|
||||
virtual service_manager::ProcessType OverrideProcessType();
|
||||
// Allows the embedder to perform platform-specific initialization before
|
||||
// creating the main message loop.
|
||||
virtual void PreCreateMainMessageLoop() {}
|
||||
|
||||
@@ -15,7 +15,7 @@ the redraw locking mechanism, which fixes these issues. The electron issue
|
||||
can be found at https://github.com/electron/electron/issues/1821
|
||||
|
||||
diff --git a/ui/views/win/hwnd_message_handler.cc b/ui/views/win/hwnd_message_handler.cc
|
||||
index 4cfdfcc93b4da0497271fd31e01db8485b2ec7b2..e7be846616e58631ed2a89530d02930d64336b70 100644
|
||||
index 754528f7d280a0b588c491fd928a26e9f32dda76..42eeb16a3d59de7e37eb858a982cc3534ab7cc51 100644
|
||||
--- a/ui/views/win/hwnd_message_handler.cc
|
||||
+++ b/ui/views/win/hwnd_message_handler.cc
|
||||
@@ -306,6 +306,10 @@ constexpr int kSynthesizedMouseMessagesTimeDifference = 500;
|
||||
@@ -62,7 +62,7 @@ index 7118ff56f0dd1c6291e4095ce7f3d8fc723f0398..5dbaab15ee1667ed1caf0b746b8e31d1
|
||||
HICON GetDefaultWindowIcon() const override;
|
||||
HICON GetSmallWindowIcon() const override;
|
||||
diff --git a/ui/views/win/hwnd_message_handler_delegate.h b/ui/views/win/hwnd_message_handler_delegate.h
|
||||
index 98efa2b7c4033c9ce8c73f7201e68e85baf05bba..4f0897ecc675d3e366ec07df28e09698c6b6e4cf 100644
|
||||
index 7344cdd4cf7d68da617b81cbdf464a859a40fb09..9ec1f23b26b41e10a46be0ca5d254583b6534ecb 100644
|
||||
--- a/ui/views/win/hwnd_message_handler_delegate.h
|
||||
+++ b/ui/views/win/hwnd_message_handler_delegate.h
|
||||
@@ -46,6 +46,8 @@ class VIEWS_EXPORT HWNDMessageHandlerDelegate {
|
||||
|
||||
@@ -20,10 +20,10 @@ to deal with color spaces. That is being tracked at
|
||||
https://crbug.com/634542 and https://crbug.com/711107.
|
||||
|
||||
diff --git a/cc/trees/layer_tree_host_impl.cc b/cc/trees/layer_tree_host_impl.cc
|
||||
index 5c87f4ea0d6426606a1001f51aea1aa8b0ecaa8b..16fa2e95b89b569c76b57c1a57d0336ac3b8ea54 100644
|
||||
index bb7ff971823db702991a3167b5b0ac1b3dd4a6c9..e5afad68300bdd6ac109b3c9b94d3c200d164456 100644
|
||||
--- a/cc/trees/layer_tree_host_impl.cc
|
||||
+++ b/cc/trees/layer_tree_host_impl.cc
|
||||
@@ -1748,6 +1748,10 @@ void LayerTreeHostImpl::SetIsLikelyToRequireADraw(
|
||||
@@ -1762,6 +1762,10 @@ void LayerTreeHostImpl::SetIsLikelyToRequireADraw(
|
||||
|
||||
gfx::ColorSpace LayerTreeHostImpl::GetRasterColorSpace(
|
||||
gfx::ContentColorUsage content_color_usage) const {
|
||||
@@ -35,10 +35,10 @@ index 5c87f4ea0d6426606a1001f51aea1aa8b0ecaa8b..16fa2e95b89b569c76b57c1a57d0336a
|
||||
|
||||
// If we are likely to software composite the resource, we use sRGB because
|
||||
diff --git a/cc/trees/layer_tree_settings.h b/cc/trees/layer_tree_settings.h
|
||||
index eaff59cabf659c0d3ffe46c394c51b6d30c05806..899be4f3d9cdb82e03d34ee940f26af89235dd31 100644
|
||||
index 64fe3c1c3f60758c25f9bc88daedf35633508aa7..a2e9ebb3dc31b4e8665376ffb1f805c6093bce5c 100644
|
||||
--- a/cc/trees/layer_tree_settings.h
|
||||
+++ b/cc/trees/layer_tree_settings.h
|
||||
@@ -99,6 +99,8 @@ class CC_EXPORT LayerTreeSettings {
|
||||
@@ -98,6 +98,8 @@ class CC_EXPORT LayerTreeSettings {
|
||||
bool use_rgba_4444 = false;
|
||||
bool unpremultiply_and_dither_low_bit_depth_tiles = false;
|
||||
|
||||
@@ -48,7 +48,7 @@ index eaff59cabf659c0d3ffe46c394c51b6d30c05806..899be4f3d9cdb82e03d34ee940f26af8
|
||||
// Image Decode Service and raster tiles without images until the decode is
|
||||
// ready.
|
||||
diff --git a/components/viz/common/display/renderer_settings.h b/components/viz/common/display/renderer_settings.h
|
||||
index 733d83e802b0c99d5d237ab5d0deea2385c4e899..f3dc39b3bd3e85cd7f68b81210b3bd64b8ae37ee 100644
|
||||
index 2e32385af86c6156c4197393248d70c470cdd4b5..350f56238e1c01cc6073555933f57df8cafca050 100644
|
||||
--- a/components/viz/common/display/renderer_settings.h
|
||||
+++ b/components/viz/common/display/renderer_settings.h
|
||||
@@ -23,6 +23,7 @@ class VIZ_COMMON_EXPORT RendererSettings {
|
||||
@@ -60,7 +60,7 @@ index 733d83e802b0c99d5d237ab5d0deea2385c4e899..f3dc39b3bd3e85cd7f68b81210b3bd64
|
||||
bool force_antialiasing = false;
|
||||
bool force_blending_with_shaders = false;
|
||||
diff --git a/components/viz/host/renderer_settings_creation.cc b/components/viz/host/renderer_settings_creation.cc
|
||||
index b06ea5f9fe36162dc9bcec32f604b1a8fc10f825..d53e7a0055dbdfe937a51939a312272317749f2a 100644
|
||||
index 5575c90cf05ec43bc787711f1d44b8dd58ead99c..a544d836159522751c1262370d8c156220662c0f 100644
|
||||
--- a/components/viz/host/renderer_settings_creation.cc
|
||||
+++ b/components/viz/host/renderer_settings_creation.cc
|
||||
@@ -16,6 +16,7 @@
|
||||
@@ -81,10 +81,10 @@ index b06ea5f9fe36162dc9bcec32f604b1a8fc10f825..d53e7a0055dbdfe937a51939a3122723
|
||||
!command_line->HasSwitch(switches::kUIDisablePartialSwap);
|
||||
#if defined(OS_APPLE)
|
||||
diff --git a/components/viz/service/display/gl_renderer.cc b/components/viz/service/display/gl_renderer.cc
|
||||
index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690c83e4a8c 100644
|
||||
index e5179c0e4971bc593860b1e5b606fec651e6756b..fc7c09d19c60d498885d3e4f1a4a4ac995060e3d 100644
|
||||
--- a/components/viz/service/display/gl_renderer.cc
|
||||
+++ b/components/viz/service/display/gl_renderer.cc
|
||||
@@ -89,6 +89,9 @@
|
||||
@@ -86,6 +86,9 @@
|
||||
|
||||
using gpu::gles2::GLES2Interface;
|
||||
|
||||
@@ -94,7 +94,7 @@ index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690
|
||||
namespace viz {
|
||||
namespace {
|
||||
|
||||
@@ -596,8 +599,9 @@ void GLRenderer::DoDrawQuad(const DrawQuad* quad,
|
||||
@@ -639,8 +642,9 @@ void GLRenderer::DoDrawQuad(const DrawQuad* quad,
|
||||
void GLRenderer::DrawDebugBorderQuad(const DebugBorderDrawQuad* quad) {
|
||||
SetBlendEnabled(quad->ShouldDrawWithBlending());
|
||||
|
||||
@@ -106,7 +106,7 @@ index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690
|
||||
|
||||
// Use the full quad_rect for debug quads to not move the edges based on
|
||||
// partial swaps.
|
||||
@@ -1574,7 +1578,8 @@ void GLRenderer::ChooseRPDQProgram(DrawRenderPassDrawQuadParams* params,
|
||||
@@ -1620,7 +1624,8 @@ void GLRenderer::ChooseRPDQProgram(DrawRenderPassDrawQuadParams* params,
|
||||
params->use_color_matrix, tint_gl_composited_content_,
|
||||
params->apply_shader_based_rounded_corner &&
|
||||
ShouldApplyRoundedCorner(params->quad)),
|
||||
@@ -116,17 +116,27 @@ index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690
|
||||
}
|
||||
|
||||
void GLRenderer::UpdateRPDQUniforms(DrawRenderPassDrawQuadParams* params) {
|
||||
@@ -2045,7 +2050,8 @@ void GLRenderer::DrawSolidColorQuad(const SolidColorDrawQuad* quad,
|
||||
@@ -2094,15 +2099,16 @@ void GLRenderer::DrawSolidColorQuad(const SolidColorDrawQuad* quad,
|
||||
SetUseProgram(ProgramKey::SolidColor(use_aa ? USE_AA : NO_AA,
|
||||
tint_gl_composited_content_,
|
||||
ShouldApplyRoundedCorner(quad)),
|
||||
- quad_color_space, CurrentRenderPassColorSpace());
|
||||
+ PATCH_CS(quad_color_space),
|
||||
- CurrentRenderPassColorSpace(), CurrentRenderPassColorSpace());
|
||||
+ PATCH_CS(CurrentRenderPassColorSpace()),
|
||||
+ PATCH_CS(CurrentRenderPassColorSpace()));
|
||||
SetShaderColor(color, opacity);
|
||||
if (current_program_->rounded_corner_rect_location() != -1) {
|
||||
SetShaderRoundedCorner(
|
||||
@@ -2200,7 +2206,8 @@ void GLRenderer::DrawContentQuadAA(const ContentDrawQuadBase* quad,
|
||||
|
||||
gfx::ColorSpace quad_color_space = gfx::ColorSpace::CreateSRGB();
|
||||
SkColor4f color_f = SkColor4f::FromColor(color);
|
||||
|
||||
// Apply color transform if the color space or source and target do not match.
|
||||
- if (quad_color_space != CurrentRenderPassColorSpace()) {
|
||||
+ if (PATCH_CS(quad_color_space) != PATCH_CS(CurrentRenderPassColorSpace())) {
|
||||
const gfx::ColorTransform* color_transform =
|
||||
- GetColorTransform(quad_color_space, CurrentRenderPassColorSpace());
|
||||
+ GetColorTransform(PATCH_CS(quad_color_space), PATCH_CS(CurrentRenderPassColorSpace()));
|
||||
gfx::ColorTransform::TriStim col(color_f.fR, color_f.fG, color_f.fB);
|
||||
color_transform->Transform(&col, 1);
|
||||
color_f.fR = col.x();
|
||||
@@ -2277,7 +2283,8 @@ void GLRenderer::DrawContentQuadAA(const ContentDrawQuadBase* quad,
|
||||
: NON_PREMULTIPLIED_ALPHA,
|
||||
false, false, tint_gl_composited_content_,
|
||||
ShouldApplyRoundedCorner(quad)),
|
||||
@@ -136,7 +146,7 @@ index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690
|
||||
|
||||
if (current_program_->tint_color_matrix_location() != -1) {
|
||||
auto matrix = cc::DebugColors::TintCompositedContentColorTransformMatrix();
|
||||
@@ -2296,7 +2303,8 @@ void GLRenderer::DrawContentQuadNoAA(const ContentDrawQuadBase* quad,
|
||||
@@ -2376,7 +2383,8 @@ void GLRenderer::DrawContentQuadNoAA(const ContentDrawQuadBase* quad,
|
||||
!quad->ShouldDrawWithBlending(), has_tex_clamp_rect,
|
||||
tint_gl_composited_content_,
|
||||
ShouldApplyRoundedCorner(quad)),
|
||||
@@ -146,7 +156,7 @@ index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690
|
||||
|
||||
if (current_program_->tint_color_matrix_location() != -1) {
|
||||
auto matrix = cc::DebugColors::TintCompositedContentColorTransformMatrix();
|
||||
@@ -2397,7 +2405,8 @@ void GLRenderer::DrawYUVVideoQuad(const YUVVideoDrawQuad* quad,
|
||||
@@ -2486,7 +2494,8 @@ void GLRenderer::DrawYUVVideoQuad(const YUVVideoDrawQuad* quad,
|
||||
// The source color space should never be RGB.
|
||||
DCHECK_NE(src_color_space, src_color_space.GetAsFullRangeRGB());
|
||||
|
||||
@@ -156,7 +166,7 @@ index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690
|
||||
|
||||
#if defined(OS_WIN)
|
||||
// Force sRGB output on Windows for overlay candidate video quads to match
|
||||
@@ -2563,7 +2572,8 @@ void GLRenderer::DrawStreamVideoQuad(const StreamVideoDrawQuad* quad,
|
||||
@@ -2661,7 +2670,8 @@ void GLRenderer::DrawStreamVideoQuad(const StreamVideoDrawQuad* quad,
|
||||
|
||||
SetUseProgram(ProgramKey::VideoStream(tex_coord_precision,
|
||||
ShouldApplyRoundedCorner(quad)),
|
||||
@@ -166,7 +176,7 @@ index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690
|
||||
|
||||
DCHECK_EQ(GL_TEXTURE0, GetActiveTextureUnit(gl_));
|
||||
gl_->BindTexture(GL_TEXTURE_EXTERNAL_OES, lock.texture_id());
|
||||
@@ -2628,8 +2638,8 @@ void GLRenderer::FlushTextureQuadCache(BoundGeometry flush_binding) {
|
||||
@@ -2728,8 +2738,8 @@ void GLRenderer::FlushTextureQuadCache(BoundGeometry flush_binding) {
|
||||
draw_cache_.nearest_neighbor ? GL_NEAREST : GL_LINEAR);
|
||||
|
||||
// Bind the program to the GL state.
|
||||
@@ -177,7 +187,7 @@ index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690
|
||||
/*adjust_src_white_level=*/draw_cache_.is_video_frame);
|
||||
|
||||
if (current_program_->rounded_corner_rect_location() != -1) {
|
||||
@@ -3376,7 +3386,9 @@ void GLRenderer::SetUseProgram(const ProgramKey& program_key_no_color,
|
||||
@@ -3546,7 +3556,9 @@ void GLRenderer::SetUseProgram(const ProgramKey& program_key_no_color,
|
||||
const gfx::ColorSpace& src_color_space,
|
||||
const gfx::ColorSpace& dst_color_space,
|
||||
bool adjust_src_white_level) {
|
||||
@@ -188,7 +198,7 @@ index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690
|
||||
gfx::ColorSpace adjusted_src_color_space = src_color_space;
|
||||
if (adjust_src_white_level) {
|
||||
// If the input color space is HDR, and it did not specify a white level,
|
||||
@@ -3759,9 +3771,9 @@ void GLRenderer::CopyRenderPassDrawQuadToOverlayResource(
|
||||
@@ -3926,9 +3938,9 @@ void GLRenderer::CopyRenderPassDrawQuadToOverlayResource(
|
||||
cc::MathUtil::CheckedRoundUp(iosurface_height, iosurface_multiple);
|
||||
}
|
||||
|
||||
@@ -201,7 +211,7 @@ index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690
|
||||
*new_bounds = gfx::RectF(updated_dst_rect.origin(),
|
||||
gfx::SizeF((*overlay_texture)->texture.size()));
|
||||
|
||||
@@ -3980,8 +3992,8 @@ void GLRenderer::FlushOverdrawFeedback(const gfx::Rect& output_rect) {
|
||||
@@ -4148,8 +4160,8 @@ void GLRenderer::FlushOverdrawFeedback(const gfx::Rect& output_rect) {
|
||||
|
||||
PrepareGeometry(SHARED_BINDING);
|
||||
|
||||
@@ -212,14 +222,14 @@ index 3dc5c652835653a70e0bc87f33525c401aec8ed2..5b524aa6eb50a1dc816e04841c60a690
|
||||
|
||||
gfx::Transform render_matrix;
|
||||
render_matrix.Translate(0.5 * output_rect.width() + output_rect.x(),
|
||||
@@ -4103,3 +4115,5 @@ GLRenderer::OverlayTexture::OverlayTexture() = default;
|
||||
@@ -4278,3 +4290,5 @@ GLRenderer::OverlayTexture::OverlayTexture() = default;
|
||||
GLRenderer::OverlayTexture::~OverlayTexture() = default;
|
||||
|
||||
} // namespace viz
|
||||
+
|
||||
+#undef PATCH_CS
|
||||
diff --git a/content/browser/gpu/gpu_process_host.cc b/content/browser/gpu/gpu_process_host.cc
|
||||
index 9b200dbd44e0e5524276c8784c873fb720961baa..cef79334b88bf1b947360ed890fbf2f99eb1f483 100644
|
||||
index de4eadaf7be8be95fc0ad454d66c8ec397cfc20a..d4c451ea992490befb34b3690a98d968bb50b899 100644
|
||||
--- a/content/browser/gpu/gpu_process_host.cc
|
||||
+++ b/content/browser/gpu/gpu_process_host.cc
|
||||
@@ -221,6 +221,7 @@ GpuTerminationStatus ConvertToGpuTerminationStatus(
|
||||
@@ -231,10 +241,10 @@ index 9b200dbd44e0e5524276c8784c873fb720961baa..cef79334b88bf1b947360ed890fbf2f9
|
||||
sandbox::policy::switches::kGpuSandboxAllowSysVShm,
|
||||
sandbox::policy::switches::kGpuSandboxFailuresFatal,
|
||||
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
index eb99c6f7ef7ca70c6d074d2d0aecd24da383ab76..b169770b27e21ebb2cb137b45c4ee66c4f71e878 100644
|
||||
index 74f19cb9c196510c19daffcd98c1577ec541ea54..0a65b9be576a437cc036af211230292d2c2c3c03 100644
|
||||
--- a/content/browser/renderer_host/render_process_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
@@ -226,6 +226,7 @@
|
||||
@@ -225,6 +225,7 @@
|
||||
#include "ui/accessibility/accessibility_switches.h"
|
||||
#include "ui/base/ui_base_switches.h"
|
||||
#include "ui/display/display_switches.h"
|
||||
@@ -242,16 +252,16 @@ index eb99c6f7ef7ca70c6d074d2d0aecd24da383ab76..b169770b27e21ebb2cb137b45c4ee66c
|
||||
#include "ui/gl/gl_switches.h"
|
||||
#include "ui/native_theme/native_theme_features.h"
|
||||
#include "url/origin.h"
|
||||
@@ -3291,6 +3292,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer(
|
||||
@@ -3313,6 +3314,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer(
|
||||
// Propagate the following switches to the renderer command line (along
|
||||
// with any associated values) if present in the browser command line.
|
||||
static const char* const kSwitchNames[] = {
|
||||
+ switches::kDisableColorCorrectRendering,
|
||||
network::switches::kExplicitlyAllowedPorts,
|
||||
service_manager::switches::kDisableInProcessStackTraces,
|
||||
switches::kDisableInProcessStackTraces,
|
||||
sandbox::policy::switches::kDisableSeccompFilterSandbox,
|
||||
diff --git a/third_party/blink/renderer/platform/graphics/canvas_color_params.cc b/third_party/blink/renderer/platform/graphics/canvas_color_params.cc
|
||||
index 3dc0fb19b33daf14cbf8550cbb58e3e146830f26..da34be87f36c6e50286d0ef24cade53156f0a688 100644
|
||||
index 0501709a855b9fae82ab06c4e143b42058ddc12e..e0a457aab29acda134d1da9c798b5472c9bdb627 100644
|
||||
--- a/third_party/blink/renderer/platform/graphics/canvas_color_params.cc
|
||||
+++ b/third_party/blink/renderer/platform/graphics/canvas_color_params.cc
|
||||
@@ -4,6 +4,7 @@
|
||||
@@ -270,7 +280,7 @@ index 3dc0fb19b33daf14cbf8550cbb58e3e146830f26..da34be87f36c6e50286d0ef24cade531
|
||||
|
||||
namespace blink {
|
||||
|
||||
@@ -90,6 +92,11 @@ uint8_t CanvasColorParams::BytesPerPixel() const {
|
||||
@@ -95,6 +97,11 @@ uint8_t CanvasColorParams::BytesPerPixel() const {
|
||||
}
|
||||
|
||||
gfx::ColorSpace CanvasColorParams::GetSamplerGfxColorSpace() const {
|
||||
@@ -282,7 +292,7 @@ index 3dc0fb19b33daf14cbf8550cbb58e3e146830f26..da34be87f36c6e50286d0ef24cade531
|
||||
// TODO(ccameron): If we add support for uint8srgb as a pixel format, this
|
||||
// will need to take into account whether or not this texture will be sampled
|
||||
// in linear or nonlinear space.
|
||||
@@ -97,6 +104,11 @@ gfx::ColorSpace CanvasColorParams::GetSamplerGfxColorSpace() const {
|
||||
@@ -102,6 +109,11 @@ gfx::ColorSpace CanvasColorParams::GetSamplerGfxColorSpace() const {
|
||||
}
|
||||
|
||||
gfx::ColorSpace CanvasColorParams::GetStorageGfxColorSpace() const {
|
||||
@@ -317,7 +327,7 @@ index 95e818f1406eb1a73a746b73a608137ab5c6e894..6e1d3b3b1add4eda90560856b6915d46
|
||||
// is what the renderer uses if its not threaded.
|
||||
settings.enable_checker_imaging =
|
||||
diff --git a/ui/gfx/mac/io_surface.cc b/ui/gfx/mac/io_surface.cc
|
||||
index fdb5fbcff837f989ab73c04dd45c4b1d9f78d8da..34b46fbdc36b9655eb7ea09c25f72a39d0e511a7 100644
|
||||
index 3e80dc40c83bd4eb96f9029643c4a0856253494e..8e19a78f106daf4185ee69970832ea1237d3d03b 100644
|
||||
--- a/ui/gfx/mac/io_surface.cc
|
||||
+++ b/ui/gfx/mac/io_surface.cc
|
||||
@@ -18,6 +18,7 @@
|
||||
@@ -326,9 +336,9 @@ index fdb5fbcff837f989ab73c04dd45c4b1d9f78d8da..34b46fbdc36b9655eb7ea09c25f72a39
|
||||
#include "ui/gfx/icc_profile.h"
|
||||
+#include "ui/gfx/switches.h"
|
||||
|
||||
#if defined(__MAC_11_0) && __MAC_OS_X_VERSION_MAX_ALLOWED >= __MAC_10_16
|
||||
// https://crbug.com/1108561: This is supposed to be deprecated (but available)
|
||||
@@ -140,6 +141,14 @@ void IOSurfaceMachPortTraits::Release(mach_port_t port) {
|
||||
namespace gfx {
|
||||
|
||||
@@ -126,6 +127,14 @@ void IOSurfaceMachPortTraits::Release(mach_port_t port) {
|
||||
// Common method used by IOSurfaceSetColorSpace and IOSurfaceCanSetColorSpace.
|
||||
bool IOSurfaceSetColorSpace(IOSurfaceRef io_surface,
|
||||
const ColorSpace& color_space) {
|
||||
@@ -343,7 +353,7 @@ index fdb5fbcff837f989ab73c04dd45c4b1d9f78d8da..34b46fbdc36b9655eb7ea09c25f72a39
|
||||
// Allow but ignore invalid color spaces.
|
||||
if (!color_space.IsValid())
|
||||
return true;
|
||||
@@ -274,6 +283,15 @@ IOSurfaceRef CreateIOSurface(const gfx::Size& size,
|
||||
@@ -265,6 +274,15 @@ IOSurfaceRef CreateIOSurface(const gfx::Size& size,
|
||||
DCHECK_EQ(kIOReturnSuccess, r);
|
||||
}
|
||||
|
||||
|
||||
@@ -6,10 +6,10 @@ Subject: fix: disabling compositor recycling
|
||||
Compositor recycling is useful for Chrome because there can be many tabs and spinning up a compositor for each one would be costly. In practice, Chrome uses the parent compositor code path of browser_compositor_view_mac.mm; the NSView of each tab is detached when it's hidden and attached when it's shown. For Electron, there is no parent compositor, so we're forced into the "own compositor" code path, which seems to be non-optimal and pretty ruthless in terms of the release of resources. Electron has no real concept of multiple tabs per window, so it should be okay to disable this ruthless recycling altogether in Electron.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_view_mac.mm b/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
index 764d23f23ce2c7bc8068d0fbd97da08fd81b35dd..da3aac955c09c46fb7091d606bf0c4c8e7c6fa2f 100644
|
||||
index 0a0784d4ba5c409eb2dbd370cace906a63fbbc05..42b8addaecb58e53fe0d5d684ccb3c110919a3ba 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
@@ -478,7 +478,11 @@
|
||||
@@ -481,7 +481,11 @@
|
||||
return;
|
||||
|
||||
host()->WasHidden();
|
||||
|
||||
@@ -6,10 +6,10 @@ Subject: disable_hidden.patch
|
||||
Electron uses this to disable background throttling for hidden windows.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
index 7dcc21f67320402a88b4ce7d6606a1e7d4c46ea3..77bc5b22fd03af3e576b3bec10ac8b747b013937 100644
|
||||
index 529a5b71b9987be21bfb1494b420ef88bbd17f7a..19d7421e1de9680a8b1364f010e19cc95ef7325a 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
@@ -739,6 +739,9 @@ void RenderWidgetHostImpl::WasHidden() {
|
||||
@@ -692,6 +692,9 @@ void RenderWidgetHostImpl::WasHidden() {
|
||||
if (is_hidden_)
|
||||
return;
|
||||
|
||||
@@ -20,10 +20,10 @@ index 7dcc21f67320402a88b4ce7d6606a1e7d4c46ea3..77bc5b22fd03af3e576b3bec10ac8b74
|
||||
blink::mojom::PointerLockResult::kWrongDocument);
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.h b/content/browser/renderer_host/render_widget_host_impl.h
|
||||
index ec4696ba8628cef696c0a7147a0cc6c95d409089..b4cf9688ee7599f6892dd741908a056c076b6151 100644
|
||||
index 9d7d10136a683620d6fb67246aae51df982930d0..c119dd8916fe2fbde97ce91cce6f788fc62f3534 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.h
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.h
|
||||
@@ -175,6 +175,9 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
||||
@@ -173,6 +173,9 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
||||
// RenderWidgetHostImpl.
|
||||
static RenderWidgetHostImpl* From(RenderWidgetHost* rwh);
|
||||
|
||||
@@ -34,10 +34,10 @@ index ec4696ba8628cef696c0a7147a0cc6c95d409089..b4cf9688ee7599f6892dd741908a056c
|
||||
const base::TimeDelta& delay) {
|
||||
new_content_rendering_delay_ = delay;
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_view_aura.cc b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
index dc010ee921dd606f04c8c176f4e3d90047f2c297..f97062555915eaab5c941e1793dafd4628b94d84 100644
|
||||
index f6cd4515bf8ffb750a7499ee81b213cf964b4491..5a5f32e94e17bcd82e1e1a86d970ea0b4ea1e8dc 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
@@ -622,7 +622,7 @@ void RenderWidgetHostViewAura::HideImpl() {
|
||||
@@ -625,7 +625,7 @@ void RenderWidgetHostViewAura::HideImpl() {
|
||||
DCHECK(visibility_ == Visibility::HIDDEN ||
|
||||
visibility_ == Visibility::OCCLUDED);
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ index 0ccfe130f00ec3b6c75cd8ee04d5a2777e1fd00c..653829457d58bf92057cc36aa8a28970
|
||||
DISALLOW_COPY_AND_ASSIGN(StaticHttpUserAgentSettings);
|
||||
};
|
||||
diff --git a/services/network/network_context.cc b/services/network/network_context.cc
|
||||
index f5ef11a3bed2a5eb3f699f9ee0ee37fbf5fe531a..7e01e5ef3fb8d548f2015b4de7d6834489a2bde0 100644
|
||||
index 3dc5c6d6027be44c1e799bb8e0b509a03bae963a..b2d9b7a74f71b3127f51ea2c4f4ed0caaa2bff05 100644
|
||||
--- a/services/network/network_context.cc
|
||||
+++ b/services/network/network_context.cc
|
||||
@@ -1082,6 +1082,13 @@ void NetworkContext::SetNetworkConditions(
|
||||
@@ -51,10 +51,10 @@ index f5ef11a3bed2a5eb3f699f9ee0ee37fbf5fe531a..7e01e5ef3fb8d548f2015b4de7d68344
|
||||
// This may only be called on NetworkContexts created with the constructor
|
||||
// that calls MakeURLRequestContext().
|
||||
diff --git a/services/network/network_context.h b/services/network/network_context.h
|
||||
index 75531d963c4ee8bb4197b30c93623e556f404155..26eeeef6e76a8a529377889b986aaf748c51912c 100644
|
||||
index 1372f6f6ca4899cc7b230a3cd1b26db4c16325b5..0e2c067837cd180ad9b99c082487199d72e5a0ed 100644
|
||||
--- a/services/network/network_context.h
|
||||
+++ b/services/network/network_context.h
|
||||
@@ -243,6 +243,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
@@ -244,6 +244,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
void CloseIdleConnections(CloseIdleConnectionsCallback callback) override;
|
||||
void SetNetworkConditions(const base::UnguessableToken& throttling_profile_id,
|
||||
mojom::NetworkConditionsPtr conditions) override;
|
||||
@@ -63,10 +63,10 @@ index 75531d963c4ee8bb4197b30c93623e556f404155..26eeeef6e76a8a529377889b986aaf74
|
||||
void SetEnableReferrers(bool enable_referrers) override;
|
||||
#if defined(OS_CHROMEOS)
|
||||
diff --git a/services/network/public/mojom/network_context.mojom b/services/network/public/mojom/network_context.mojom
|
||||
index 0b97c9fe29f24b1305740506458b0b6a02263c3c..7dc2d14d47d395e3b8046cae8788c4e04bc8e7f3 100644
|
||||
index e45dff2ab8abd378da7886b5becfcb673f5dc642..0f9d88529021db245fb498dfa339e5327450256a 100644
|
||||
--- a/services/network/public/mojom/network_context.mojom
|
||||
+++ b/services/network/public/mojom/network_context.mojom
|
||||
@@ -1061,6 +1061,9 @@ interface NetworkContext {
|
||||
@@ -1057,6 +1057,9 @@ interface NetworkContext {
|
||||
SetNetworkConditions(mojo_base.mojom.UnguessableToken throttling_profile_id,
|
||||
NetworkConditions? conditions);
|
||||
|
||||
@@ -77,10 +77,10 @@ index 0b97c9fe29f24b1305740506458b0b6a02263c3c..7dc2d14d47d395e3b8046cae8788c4e0
|
||||
SetAcceptLanguage(string new_accept_language);
|
||||
|
||||
diff --git a/services/network/test/test_network_context.h b/services/network/test/test_network_context.h
|
||||
index ff4bb599026ce57e46d5dd9d017a07308c4e83cd..8a0f77aa2b4a054d9a4b24e6e81785dd8fc6a5ea 100644
|
||||
index 789be83b3d42d464c1ccc71bf13820187c598fcb..d0eddf77b04f41ae25400647629b4324e4060d7a 100644
|
||||
--- a/services/network/test/test_network_context.h
|
||||
+++ b/services/network/test/test_network_context.h
|
||||
@@ -105,6 +105,7 @@ class TestNetworkContext : public mojom::NetworkContext {
|
||||
@@ -107,6 +107,7 @@ class TestNetworkContext : public mojom::NetworkContext {
|
||||
void CloseIdleConnections(CloseIdleConnectionsCallback callback) override {}
|
||||
void SetNetworkConditions(const base::UnguessableToken& throttling_profile_id,
|
||||
mojom::NetworkConditionsPtr conditions) override {}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user