mirror of
https://github.com/electron/electron.git
synced 2026-02-26 03:01:17 -05:00
Compare commits
10 Commits
test-linux
...
roller/chr
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
56d82cca04 | ||
|
|
572d8048ed | ||
|
|
de2aede56b | ||
|
|
ab3e39fadd | ||
|
|
8ec2170ee7 | ||
|
|
e787b035eb | ||
|
|
2125ad8768 | ||
|
|
5a71ad888c | ||
|
|
bf9b43059a | ||
|
|
537dceb0d2 |
@@ -2,7 +2,7 @@ version: '3'
|
||||
|
||||
services:
|
||||
buildtools:
|
||||
image: ghcr.io/electron/devcontainer:eac3529546ea8f3aa356d31e345715eef342233b
|
||||
image: ghcr.io/electron/devcontainer:a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb
|
||||
|
||||
volumes:
|
||||
- ..:/workspaces/gclient/src/electron:cached
|
||||
|
||||
2
.github/workflows/apply-patches.yml
vendored
2
.github/workflows/apply-patches.yml
vendored
@@ -41,7 +41,7 @@ jobs:
|
||||
permissions:
|
||||
contents: read
|
||||
container:
|
||||
image: ghcr.io/electron/build:eac3529546ea8f3aa356d31e345715eef342233b
|
||||
image: ghcr.io/electron/build:a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb
|
||||
options: --user root
|
||||
volumes:
|
||||
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
|
||||
|
||||
6
.github/workflows/build-git-cache.yml
vendored
6
.github/workflows/build-git-cache.yml
vendored
@@ -15,7 +15,7 @@ jobs:
|
||||
permissions:
|
||||
contents: read
|
||||
container:
|
||||
image: ghcr.io/electron/build:eac3529546ea8f3aa356d31e345715eef342233b
|
||||
image: ghcr.io/electron/build:a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb
|
||||
options: --user root
|
||||
volumes:
|
||||
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
|
||||
@@ -39,7 +39,7 @@ jobs:
|
||||
permissions:
|
||||
contents: read
|
||||
container:
|
||||
image: ghcr.io/electron/build:eac3529546ea8f3aa356d31e345715eef342233b
|
||||
image: ghcr.io/electron/build:a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb
|
||||
options: --user root --device /dev/fuse --cap-add SYS_ADMIN
|
||||
volumes:
|
||||
- /mnt/win-cache:/mnt/win-cache
|
||||
@@ -66,7 +66,7 @@ jobs:
|
||||
# This job updates the same git cache as linux, so it needs to run after the linux one.
|
||||
needs: build-git-cache-linux
|
||||
container:
|
||||
image: ghcr.io/electron/build:eac3529546ea8f3aa356d31e345715eef342233b
|
||||
image: ghcr.io/electron/build:a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb
|
||||
options: --user root
|
||||
volumes:
|
||||
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
|
||||
|
||||
4
.github/workflows/build.yml
vendored
4
.github/workflows/build.yml
vendored
@@ -6,7 +6,7 @@ on:
|
||||
build-image-sha:
|
||||
type: string
|
||||
description: 'SHA for electron/build image'
|
||||
default: 'eac3529546ea8f3aa356d31e345715eef342233b'
|
||||
default: 'a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb'
|
||||
required: true
|
||||
skip-macos:
|
||||
type: boolean
|
||||
@@ -77,7 +77,7 @@ jobs:
|
||||
id: set-output
|
||||
run: |
|
||||
if [ -z "${{ inputs.build-image-sha }}" ]; then
|
||||
echo "build-image-sha=eac3529546ea8f3aa356d31e345715eef342233b" >> "$GITHUB_OUTPUT"
|
||||
echo "build-image-sha=a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb" >> "$GITHUB_OUTPUT"
|
||||
else
|
||||
echo "build-image-sha=${{ inputs.build-image-sha }}" >> "$GITHUB_OUTPUT"
|
||||
fi
|
||||
|
||||
2
.github/workflows/linux-publish.yml
vendored
2
.github/workflows/linux-publish.yml
vendored
@@ -6,7 +6,7 @@ on:
|
||||
build-image-sha:
|
||||
type: string
|
||||
description: 'SHA for electron/build image'
|
||||
default: 'eac3529546ea8f3aa356d31e345715eef342233b'
|
||||
default: 'a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb'
|
||||
upload-to-storage:
|
||||
description: 'Uploads to Azure storage'
|
||||
required: false
|
||||
|
||||
2
.github/workflows/macos-publish.yml
vendored
2
.github/workflows/macos-publish.yml
vendored
@@ -6,7 +6,7 @@ on:
|
||||
build-image-sha:
|
||||
type: string
|
||||
description: 'SHA for electron/build image'
|
||||
default: 'eac3529546ea8f3aa356d31e345715eef342233b'
|
||||
default: 'a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb'
|
||||
required: true
|
||||
upload-to-storage:
|
||||
description: 'Uploads to Azure storage'
|
||||
|
||||
@@ -110,33 +110,6 @@ jobs:
|
||||
test-runs-on: ${{ inputs.test-runs-on }}
|
||||
test-container: ${{ inputs.test-container }}
|
||||
secrets: inherit
|
||||
test-wayland:
|
||||
uses: ./.github/workflows/pipeline-segment-electron-test.yml
|
||||
permissions:
|
||||
contents: read
|
||||
issues: read
|
||||
pull-requests: read
|
||||
needs: build
|
||||
if: ${{ inputs.target-platform == 'linux' && inputs.target-arch == 'x64' && !inputs.is-asan }}
|
||||
with:
|
||||
target-arch: ${{ inputs.target-arch }}
|
||||
target-platform: ${{ inputs.target-platform }}
|
||||
test-runs-on: ${{ inputs.test-runs-on }}
|
||||
test-container: ${{ inputs.test-container }}
|
||||
display-server: wayland
|
||||
secrets: inherit
|
||||
test-linux-64k:
|
||||
uses: ./.github/workflows/pipeline-segment-electron-test-64k.yml
|
||||
permissions:
|
||||
contents: read
|
||||
issues: read
|
||||
pull-requests: read
|
||||
needs: build
|
||||
if: ${{ inputs.target-platform == 'linux' && inputs.target-arch == 'arm64' && !inputs.is-asan }}
|
||||
with:
|
||||
test-runs-on: ${{ inputs.test-runs-on }}
|
||||
test-container: ${{ inputs.test-container }}
|
||||
secrets: inherit
|
||||
nn-test:
|
||||
uses: ./.github/workflows/pipeline-segment-node-nan-test.yml
|
||||
permissions:
|
||||
|
||||
@@ -1,64 +0,0 @@
|
||||
name: Pipeline Segment - Electron Test on Linux ARM64 64k
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
test-runs-on:
|
||||
type: string
|
||||
description: 'What host to run the tests on'
|
||||
required: true
|
||||
test-container:
|
||||
type: string
|
||||
description: 'JSON container information for aks runs-on'
|
||||
required: false
|
||||
default: '{"image":null}'
|
||||
|
||||
concurrency:
|
||||
group: electron-test-linux-64k-${{ github.ref_protected == true && github.run_id || github.ref }}
|
||||
cancel-in-progress: ${{ github.ref_protected != true }}
|
||||
|
||||
permissions: {}
|
||||
|
||||
env:
|
||||
ELECTRON_OUT_DIR: Default
|
||||
|
||||
jobs:
|
||||
test-linux-arm64-64k:
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
runs-on: ${{ inputs.test-runs-on }}
|
||||
permissions:
|
||||
contents: read
|
||||
issues: read
|
||||
pull-requests: read
|
||||
steps:
|
||||
- name: Download Generated Artifacts
|
||||
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131
|
||||
with:
|
||||
name: generated_artifacts_linux_arm64
|
||||
path: ./generated_artifacts_linux_arm64
|
||||
- name: Download Src Artifacts
|
||||
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131
|
||||
with:
|
||||
name: src_artifacts_linux_arm64
|
||||
path: ./src_artifacts_linux_arm64
|
||||
- name: Restore Generated Artifacts
|
||||
run: ./src/electron/script/actions/restore-artifacts.sh
|
||||
- name: Unzip Dist
|
||||
run: |
|
||||
cd src/out/Default
|
||||
unzip -:o dist.zip
|
||||
|
||||
- name: Run Electron Tests in QEMU 64k Container
|
||||
shell: bash
|
||||
env:
|
||||
MOCHA_REPORTER: mocha-multi-reporters
|
||||
MOCHA_MULTI_REPORTERS: mocha-junit-reporter, tap
|
||||
ELECTRON_DISABLE_SECURITY_WARNINGS: 1
|
||||
DISPLAY: ':99.0'
|
||||
run: |
|
||||
container=$(echo '${{ inputs.test-container }}' | jq -r '.image')
|
||||
echo "Running tests in container: $container"
|
||||
src/electron/script/run-qemu-64k.sh --container="$container" --testfiles=`pwd`/src
|
||||
|
||||
@@ -30,14 +30,9 @@ on:
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
display-server:
|
||||
description: 'Display backend for Linux tests: x11 or wayland'
|
||||
required: false
|
||||
type: string
|
||||
default: x11
|
||||
|
||||
concurrency:
|
||||
group: electron-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ inputs.is-asan }}-${{ inputs.display-server }}-${{ github.ref_protected == true && github.run_id || github.ref }}
|
||||
group: electron-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ inputs.is-asan }}-${{ github.ref_protected == true && github.run_id || github.ref }}
|
||||
cancel-in-progress: ${{ github.ref_protected != true }}
|
||||
|
||||
permissions: {}
|
||||
@@ -64,7 +59,7 @@ jobs:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
build-type: ${{ inputs.target-platform == 'macos' && fromJSON('["darwin","mas"]') || (inputs.target-platform == 'win' && fromJSON('["win"]') || fromJSON('["linux"]')) }}
|
||||
shard: ${{ case(inputs.display-server == 'wayland', fromJSON('[1]'), inputs.target-platform == 'linux', fromJSON('[1, 2, 3]'), fromJSON('[1, 2]')) }}
|
||||
shard: ${{ inputs.target-platform == 'linux' && fromJSON('[1, 2, 3]') || fromJSON('[1, 2]') }}
|
||||
env:
|
||||
BUILD_TYPE: ${{ matrix.build-type }}
|
||||
TARGET_ARCH: ${{ inputs.target-arch }}
|
||||
@@ -215,22 +210,7 @@ jobs:
|
||||
cd src/electron
|
||||
export ELECTRON_TEST_RESULTS_DIR=`pwd`/junit
|
||||
# Get which tests are on this shard
|
||||
tests_files=$(node script/split-tests ${{ matrix.shard }} ${{ case(inputs.display-server == 'wayland', 1, inputs.target-platform == 'linux', 3, 2) }})
|
||||
if [ "${{ inputs.display-server }}" = "wayland" ]; then
|
||||
allowlist_file=script/wayland-test-allowlist.txt
|
||||
filtered_tests=""
|
||||
for test_file in $tests_files; do
|
||||
if grep -Fxq "$test_file" "$allowlist_file"; then
|
||||
filtered_tests="$filtered_tests $test_file"
|
||||
fi
|
||||
done
|
||||
tests_files="${filtered_tests# }"
|
||||
|
||||
if [ -z "$tests_files" ]; then
|
||||
echo "No tests matched Wayland filter, skipping."
|
||||
exit 0
|
||||
fi
|
||||
fi
|
||||
tests_files=$(node script/split-tests ${{ matrix.shard }} ${{ inputs.target-platform == 'linux' && 3 || 2 }})
|
||||
|
||||
# Run tests
|
||||
if [ "${{ inputs.target-platform }}" != "linux" ]; then
|
||||
@@ -265,11 +245,7 @@ jobs:
|
||||
if [ "${{ inputs.target-arch }}" = "arm" ]; then
|
||||
runuser -u builduser -- xvfb-run script/actions/run-tests.sh script/yarn.js test --skipYarnInstall --runners=main --enableRerun=3 --trace-uncaught --enable-logging --files $tests_files
|
||||
else
|
||||
if [ "${{ inputs.display-server }}" = "wayland" ]; then
|
||||
runuser -u builduser -- script/actions/run-tests-wayland.sh script/yarn.js test --runners=main --enableRerun=3 --trace-uncaught --enable-logging --files $tests_files
|
||||
else
|
||||
runuser -u builduser -- xvfb-run script/actions/run-tests.sh script/yarn.js test --runners=main --enableRerun=3 --trace-uncaught --enable-logging --files $tests_files
|
||||
fi
|
||||
runuser -u builduser -- xvfb-run script/actions/run-tests.sh script/yarn.js test --runners=main --enableRerun=3 --trace-uncaught --enable-logging --files $tests_files
|
||||
fi
|
||||
|
||||
fi
|
||||
@@ -292,7 +268,7 @@ jobs:
|
||||
if: always() && !cancelled()
|
||||
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f
|
||||
with:
|
||||
name: ${{ inputs.target-platform == 'linux' && format('test_artifacts_{0}_{1}_{2}', env.ARTIFACT_KEY, inputs.display-server, matrix.shard) || format('test_artifacts_{0}_{1}', env.ARTIFACT_KEY, matrix.shard) }}
|
||||
name: test_artifacts_${{ env.ARTIFACT_KEY }}_${{ matrix.shard }}
|
||||
path: src/electron/spec/artifacts
|
||||
if-no-files-found: ignore
|
||||
- name: Wait for active SSH sessions
|
||||
|
||||
2
.github/workflows/windows-publish.yml
vendored
2
.github/workflows/windows-publish.yml
vendored
@@ -6,7 +6,7 @@ on:
|
||||
build-image-sha:
|
||||
type: string
|
||||
description: 'SHA for electron/build image'
|
||||
default: 'eac3529546ea8f3aa356d31e345715eef342233b'
|
||||
default: 'a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb'
|
||||
required: true
|
||||
upload-to-storage:
|
||||
description: 'Uploads to Azure storage'
|
||||
|
||||
2
DEPS
2
DEPS
@@ -2,7 +2,7 @@ gclient_gn_args_from = 'src'
|
||||
|
||||
vars = {
|
||||
'chromium_version':
|
||||
'147.0.7699.0',
|
||||
'147.0.7703.0',
|
||||
'node_version':
|
||||
'v24.13.1',
|
||||
'nan_version':
|
||||
|
||||
@@ -30,7 +30,7 @@ The `dialog` module has the following methods:
|
||||
* `openFile` - Allow files to be selected.
|
||||
* `openDirectory` - Allow directories to be selected.
|
||||
* `multiSelections` - Allow multiple paths to be selected.
|
||||
* `showHiddenFiles` _macOS_ _Windows_ _Deprecated_ - Show hidden files in dialog. Deprecated on Linux.
|
||||
* `showHiddenFiles` - Show hidden files in dialog.
|
||||
* `createDirectory` _macOS_ - Allow creating new directories from dialog.
|
||||
* `promptToCreate` _Windows_ - Prompt for creation if the file path entered
|
||||
in the dialog does not exist. This does not actually create the file at
|
||||
@@ -102,7 +102,7 @@ dialog.showOpenDialogSync(mainWindow, {
|
||||
* `openFile` - Allow files to be selected.
|
||||
* `openDirectory` - Allow directories to be selected.
|
||||
* `multiSelections` - Allow multiple paths to be selected.
|
||||
* `showHiddenFiles` _macOS_ _Windows_ _Deprecated_ - Show hidden files in dialog. Deprecated on Linux.
|
||||
* `showHiddenFiles` - Show hidden files in dialog.
|
||||
* `createDirectory` _macOS_ - Allow creating new directories from dialog.
|
||||
* `promptToCreate` _Windows_ - Prompt for creation if the file path entered
|
||||
in the dialog does not exist. This does not actually create the file at
|
||||
@@ -185,7 +185,7 @@ dialog.showOpenDialog(mainWindow, {
|
||||
* `showsTagField` boolean (optional) _macOS_ - Show the tags input box,
|
||||
defaults to `true`.
|
||||
* `properties` string[] (optional)
|
||||
* `showHiddenFiles` _macOS_ _Windows_ _Deprecated_ - Show hidden files in dialog. Deprecated on Linux.
|
||||
* `showHiddenFiles` - Show hidden files in dialog.
|
||||
* `createDirectory` _macOS_ - Allow creating new directories from dialog.
|
||||
* `treatPackageAsDirectory` _macOS_ - Treat packages, such as `.app` folders,
|
||||
as a directory instead of a file.
|
||||
@@ -215,7 +215,7 @@ The `filters` specifies an array of file types that can be displayed, see
|
||||
displayed in front of the filename text field.
|
||||
* `showsTagField` boolean (optional) _macOS_ - Show the tags input box, defaults to `true`.
|
||||
* `properties` string[] (optional)
|
||||
* `showHiddenFiles` _macOS_ _Windows_ _Deprecated_ - Show hidden files in dialog. Deprecated on Linux.
|
||||
* `showHiddenFiles` - Show hidden files in dialog.
|
||||
* `createDirectory` _macOS_ - Allow creating new directories from dialog.
|
||||
* `treatPackageAsDirectory` _macOS_ - Treat packages, such as `.app` folders,
|
||||
as a directory instead of a file.
|
||||
|
||||
@@ -80,12 +80,6 @@ your preload script and expose it using the [contextBridge](https://www.electron
|
||||
Debug symbols for MacOS (dSYM) now use xz compression in order to handle larger file sizes. `dsym.zip` files are now
|
||||
`dsym.tar.xz` files. End users using debug symbols may need to update their zip utilities.
|
||||
|
||||
### Deprecated: `showHiddenFiles` in Dialogs on Linux
|
||||
|
||||
This property will still be honored on macOS and Windows, but support on Linux
|
||||
will be removed in Electron 42. GTK intends for this to be a user choice rather
|
||||
than an app choice and has removed the API to do this programmatically.
|
||||
|
||||
## Planned Breaking API Changes (39.0)
|
||||
|
||||
### Deprecated: `--host-rules` command line switch
|
||||
|
||||
@@ -144,4 +144,3 @@ fix_linux_tray_id.patch
|
||||
expose_gtk_ui_platform_field.patch
|
||||
patch_osr_control_screen_info.patch
|
||||
refactor_allow_customizing_config_in_freedesktopsecretkeyprovider.patch
|
||||
fix_wayland_test_crash_on_teardown.patch
|
||||
|
||||
@@ -6,7 +6,7 @@ Subject: allow disabling blink scheduler throttling per RenderView
|
||||
This allows us to disable throttling for hidden windows.
|
||||
|
||||
diff --git a/content/browser/renderer_host/navigation_controller_impl_unittest.cc b/content/browser/renderer_host/navigation_controller_impl_unittest.cc
|
||||
index 371aa33917134510649ede22d1eca68fe1c7e4c4..6b8ad80f822a4100a164d0dbd52e15a96801d2ef 100644
|
||||
index 497c23b182d9288950ff54b4c70bdb0fbe80f91b..7e2839bf619ce3c0b88b33b1df2032672292fe06 100644
|
||||
--- a/content/browser/renderer_host/navigation_controller_impl_unittest.cc
|
||||
+++ b/content/browser/renderer_host/navigation_controller_impl_unittest.cc
|
||||
@@ -168,6 +168,12 @@ class MockPageBroadcast : public blink::mojom::PageBroadcast {
|
||||
@@ -116,7 +116,7 @@ index 932658273154ef2e022358e493a8e7c00c86e732..57bbfb5cde62c9496c351c861880a189
|
||||
// Visibility -----------------------------------------------------------
|
||||
|
||||
diff --git a/third_party/blink/renderer/core/exported/web_view_impl.cc b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
index d9518342ac260ceab7e67062912320282809ff25..6e7a1ffeadc4cf6ca23de271f4f9c2af3a62e88a 100644
|
||||
index cbdbf550db35685e806320d0984cf93adc760753..440d08d8e693d57bea4bba6899d0d78c1030d1ff 100644
|
||||
--- a/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
+++ b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
@@ -2519,6 +2519,10 @@ void WebViewImpl::SetPageLifecycleStateInternal(
|
||||
@@ -130,7 +130,7 @@ index d9518342ac260ceab7e67062912320282809ff25..6e7a1ffeadc4cf6ca23de271f4f9c2af
|
||||
bool storing_in_bfcache = new_state->is_in_back_forward_cache &&
|
||||
!old_state->is_in_back_forward_cache;
|
||||
bool restoring_from_bfcache = !new_state->is_in_back_forward_cache &&
|
||||
@@ -4192,10 +4196,23 @@ PageScheduler* WebViewImpl::Scheduler() const {
|
||||
@@ -4193,10 +4197,23 @@ PageScheduler* WebViewImpl::Scheduler() const {
|
||||
return GetPage()->GetPageScheduler();
|
||||
}
|
||||
|
||||
|
||||
@@ -11,10 +11,10 @@ if we ever align our .pak file generation with Chrome we can remove this
|
||||
patch.
|
||||
|
||||
diff --git a/chrome/BUILD.gn b/chrome/BUILD.gn
|
||||
index 8aad429c56915e0e842d95e246ad4ae41b0d1588..a13c79ad0c8a2ce42679847eee5ec57d6041932b 100644
|
||||
index 4b1fd316496e33f9e805aec89a91062587e6ee16..1b6fce9e2780a37e1e8bf3f8a62dc6bc80e101d1 100644
|
||||
--- a/chrome/BUILD.gn
|
||||
+++ b/chrome/BUILD.gn
|
||||
@@ -196,11 +196,16 @@ if (!is_android && !is_mac) {
|
||||
@@ -201,11 +201,16 @@ if (!is_android && !is_mac) {
|
||||
"common/crash_keys.h",
|
||||
]
|
||||
|
||||
@@ -33,10 +33,10 @@ index 8aad429c56915e0e842d95e246ad4ae41b0d1588..a13c79ad0c8a2ce42679847eee5ec57d
|
||||
"//base",
|
||||
"//build:branding_buildflags",
|
||||
diff --git a/chrome/browser/BUILD.gn b/chrome/browser/BUILD.gn
|
||||
index 427684f0010bd773e104dc5926ab98f95f463e7d..5c99a64abe6193b1e9109903edbebd25df2ebec5 100644
|
||||
index 86226a9c5e73288174b1bd5af997bafba79b617b..1d91d13ad6824574f0cad4baa106cc2330c9c0b3 100644
|
||||
--- a/chrome/browser/BUILD.gn
|
||||
+++ b/chrome/browser/BUILD.gn
|
||||
@@ -4744,7 +4744,7 @@ static_library("browser") {
|
||||
@@ -4679,7 +4679,7 @@ static_library("browser") {
|
||||
]
|
||||
}
|
||||
|
||||
@@ -46,10 +46,10 @@ index 427684f0010bd773e104dc5926ab98f95f463e7d..5c99a64abe6193b1e9109903edbebd25
|
||||
# than here in :chrome_dll.
|
||||
deps += [ "//chrome:packed_resources_integrity_header" ]
|
||||
diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn
|
||||
index c30465fdfab08f56ada781893663cd719144b3d6..a1fcbcfed2c34e068e31119ef07000fd239a7181 100644
|
||||
index c192cf1be554311d8496e93b3d82118ffe36b0a2..3d11ff48d08923c6c58e4f87650716705e6e0e2a 100644
|
||||
--- a/chrome/test/BUILD.gn
|
||||
+++ b/chrome/test/BUILD.gn
|
||||
@@ -7796,9 +7796,12 @@ test("unit_tests") {
|
||||
@@ -7807,9 +7807,12 @@ test("unit_tests") {
|
||||
"//chrome/notification_helper",
|
||||
]
|
||||
|
||||
@@ -63,7 +63,7 @@ index c30465fdfab08f56ada781893663cd719144b3d6..a1fcbcfed2c34e068e31119ef07000fd
|
||||
"//chrome//services/util_win:unit_tests",
|
||||
"//chrome/app:chrome_dll_resources",
|
||||
"//chrome/app:win_unit_tests",
|
||||
@@ -8770,6 +8773,10 @@ test("unit_tests") {
|
||||
@@ -8781,6 +8784,10 @@ test("unit_tests") {
|
||||
"../browser/performance_manager/policies/background_tab_loading_policy_unittest.cc",
|
||||
]
|
||||
|
||||
@@ -74,7 +74,7 @@ index c30465fdfab08f56ada781893663cd719144b3d6..a1fcbcfed2c34e068e31119ef07000fd
|
||||
sources += [
|
||||
# The importer code is not used on Android.
|
||||
"../common/importer/firefox_importer_utils_unittest.cc",
|
||||
@@ -8827,7 +8834,6 @@ test("unit_tests") {
|
||||
@@ -8838,7 +8845,6 @@ test("unit_tests") {
|
||||
# TODO(crbug.com/417513088): Maybe merge with the non-android `deps` declaration above?
|
||||
deps += [
|
||||
"../browser/screen_ai:screen_ai_install_state",
|
||||
|
||||
@@ -9,7 +9,7 @@ potentially prevent a window from being created.
|
||||
TODO(loc): this patch is currently broken.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_frame_host_impl.cc b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
index 46f4627856678c26fd1024b6f20253b0164475bb..1718e3138961349bc79d3f0fc753097b125276e9 100644
|
||||
index a1603ecd246075ff9fbf8c49c2ce18c50d12db06..72d195aeff5f8197782f98ef60ecbd4d3be7d5a3 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
@@ -10006,6 +10006,7 @@ void RenderFrameHostImpl::CreateNewWindow(
|
||||
@@ -21,10 +21,10 @@ index 46f4627856678c26fd1024b6f20253b0164475bb..1718e3138961349bc79d3f0fc753097b
|
||||
&no_javascript_access);
|
||||
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index d8725eeb8a7ee31bf11b43b08d76bb699aee371d..b6c4b24ac87e0aaeac82bd18b43bf4c12f469cf7 100644
|
||||
index f0b73768a716df109a1ff4fc4a6f7e7fe92a80dc..89f759eba4281d02ccce2c92e3338c68cdb8b89e 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -5361,6 +5361,10 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -5377,6 +5377,10 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
create_params.initially_hidden = renderer_started_hidden;
|
||||
create_params.initial_popup_url = params.target_url;
|
||||
|
||||
@@ -35,7 +35,7 @@ index d8725eeb8a7ee31bf11b43b08d76bb699aee371d..b6c4b24ac87e0aaeac82bd18b43bf4c1
|
||||
// Even though all codepaths leading here are in response to a renderer
|
||||
// trying to open a new window, if the new window ends up in a different
|
||||
// browsing instance, then the RenderViewHost, RenderWidgetHost,
|
||||
@@ -5413,6 +5417,12 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -5431,6 +5435,12 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
// Sets the newly created WebContents WindowOpenDisposition.
|
||||
new_contents_impl->original_window_open_disposition_ = params.disposition;
|
||||
|
||||
@@ -48,7 +48,7 @@ index d8725eeb8a7ee31bf11b43b08d76bb699aee371d..b6c4b24ac87e0aaeac82bd18b43bf4c1
|
||||
// If the new frame has a name, make sure any SiteInstances that can find
|
||||
// this named frame have proxies for it. Must be called after
|
||||
// SetSessionStorageNamespace, since this calls CreateRenderView, which uses
|
||||
@@ -5454,12 +5464,6 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -5472,12 +5482,6 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
AddWebContentsDestructionObserver(new_contents_impl);
|
||||
}
|
||||
|
||||
@@ -111,7 +111,7 @@ index 2c74ab3c01dc5e67aa5e5ada790201932d9569bb..965de8a4d84908a25b57be4a68545145
|
||||
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 2de33a2926953e6ca012764127da4c6ec457959c..b246049104bad331651699a93260835fd943a840 100644
|
||||
index 0c0672e0a2d05d5dff31ae171f1a3af1d20b3019..51be0b86d083318f01a9ebe76fb7d1fb60cd72fd 100644
|
||||
--- a/content/public/browser/web_contents_delegate.cc
|
||||
+++ b/content/public/browser/web_contents_delegate.cc
|
||||
@@ -34,6 +34,17 @@ namespace content {
|
||||
@@ -133,7 +133,7 @@ index 2de33a2926953e6ca012764127da4c6ec457959c..b246049104bad331651699a93260835f
|
||||
WebContents* source,
|
||||
const OpenURLParams& params,
|
||||
diff --git a/content/public/browser/web_contents_delegate.h b/content/public/browser/web_contents_delegate.h
|
||||
index c0c3706f9b20299ab4d8f96e26adb1b8e882470b..c7896c828644ed84b8423df4486d8e36835a6c4d 100644
|
||||
index 0650197909d484b8a0f48ab61b22471c71bce0e8..29c380d7845aab1a7b3417e0d3940ea00460260b 100644
|
||||
--- a/content/public/browser/web_contents_delegate.h
|
||||
+++ b/content/public/browser/web_contents_delegate.h
|
||||
@@ -18,6 +18,7 @@
|
||||
@@ -224,7 +224,7 @@ index d92bab531c12c62a5321a23f4a0cb89691668127..2060e04795ba8e7a923fd0fe3485b8c5
|
||||
|
||||
} // 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 6b6397f2dd6c5dbb832d540464192c2ad73d3c16..979eb77e66ba2ad6d7f89851d183e2036b027674 100644
|
||||
index 20d51975e347148b71623e41e729a417b4230bc4..5fabc0ad72960fa761c98fdc5601c00afe6d9f1e 100644
|
||||
--- a/third_party/blink/renderer/core/frame/local_dom_window.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/local_dom_window.cc
|
||||
@@ -2339,6 +2339,8 @@ DOMWindow* LocalDOMWindow::open(v8::Isolate* isolate,
|
||||
|
||||
@@ -6,10 +6,10 @@ Subject: chore: add electron deps to gitignores
|
||||
Makes things like "git status" quicker when developing electron locally
|
||||
|
||||
diff --git a/.gitignore b/.gitignore
|
||||
index 2e51e5ac21e2ee4b94944c2c39f788e51e82f489..285e151fc1cf2ae0768fa71c5620dfdda48e1115 100644
|
||||
index 9b41e0fcf1feba39a148da5d293b61cb6fdc566d..0d0af3d0b01d0516f961bc39117a23bdc27943ee 100644
|
||||
--- a/.gitignore
|
||||
+++ b/.gitignore
|
||||
@@ -229,6 +229,7 @@ vs-chromium-project.txt
|
||||
@@ -224,6 +224,7 @@ vs-chromium-project.txt
|
||||
/data
|
||||
/delegate_execute
|
||||
/device/serial/device_serial_mojo.xml
|
||||
|
||||
@@ -14,10 +14,10 @@ track down the source of this problem & figure out if we can fix it
|
||||
by changing something in Electron.
|
||||
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index c2adef9ec376176439985234d021316ac0521adf..f1276da6c20a8c1e4bd124b20c47057fa677894b 100644
|
||||
index f0847e8dbe381b7a086cebe2c361f77bfb0c9bed..2da562e56b01873f811827adf1f6c9ccb9a2d3f6 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -5332,7 +5332,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -5348,7 +5348,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
: IsGuest();
|
||||
// While some guest types do not have a guest SiteInstance, the ones that
|
||||
// don't all override WebContents creation above.
|
||||
|
||||
@@ -14,7 +14,7 @@ This change patches it out to prevent the DCHECK.
|
||||
It can be removed once/if we see a better solution to the problem.
|
||||
|
||||
diff --git a/content/browser/site_instance_impl.cc b/content/browser/site_instance_impl.cc
|
||||
index eb47e6d14c11c4f61501df84a87c37e5fcf81bb0..7077a94c743f8c6c24a3aef6f43fa25e44f66938 100644
|
||||
index c12fcb91069e601f2e42f31cc1ac9d18dfc3ca3b..085e87b694f42cbbd4fd37cbb17f9977e3bb1586 100644
|
||||
--- a/content/browser/site_instance_impl.cc
|
||||
+++ b/content/browser/site_instance_impl.cc
|
||||
@@ -224,7 +224,7 @@ scoped_refptr<SiteInstanceImpl> SiteInstanceImpl::CreateForGuest(
|
||||
|
||||
@@ -80,10 +80,10 @@ index 39fa45f0a0f9076bd7ac0be6f455dd540a276512..3d0381d463eed73470b28085830f2a23
|
||||
content::WebContents* source,
|
||||
const content::OpenURLParams& params,
|
||||
diff --git a/chrome/browser/ui/browser.cc b/chrome/browser/ui/browser.cc
|
||||
index f8c5f63b57a7a36d2f889bec68d8e313b24cb82f..7c51540115a7b1391c5a9249765650aea0e9ba8d 100644
|
||||
index f5e20aa57de2cdb5d7dc4d9a60ff739081f33e10..814cb6ccc911c11e61006846174afb6a26a9ba48 100644
|
||||
--- a/chrome/browser/ui/browser.cc
|
||||
+++ b/chrome/browser/ui/browser.cc
|
||||
@@ -2293,7 +2293,8 @@ bool Browser::IsWebContentsCreationOverridden(
|
||||
@@ -2281,7 +2281,8 @@ bool Browser::IsWebContentsCreationOverridden(
|
||||
content::mojom::WindowContainerType window_container_type,
|
||||
const GURL& opener_url,
|
||||
const std::string& frame_name,
|
||||
@@ -93,7 +93,7 @@ index f8c5f63b57a7a36d2f889bec68d8e313b24cb82f..7c51540115a7b1391c5a9249765650ae
|
||||
if (HasActorTask(profile(), opener)) {
|
||||
// If an ExecutionEngine is acting on the opener, prevent it from creating a
|
||||
// new WebContents. We'll instead force the navigation to happen in the same
|
||||
@@ -2306,7 +2307,7 @@ bool Browser::IsWebContentsCreationOverridden(
|
||||
@@ -2294,7 +2295,7 @@ bool Browser::IsWebContentsCreationOverridden(
|
||||
return (window_container_type ==
|
||||
content::mojom::WindowContainerType::BACKGROUND &&
|
||||
ShouldCreateBackgroundContents(source_site_instance, opener_url,
|
||||
@@ -103,7 +103,7 @@ index f8c5f63b57a7a36d2f889bec68d8e313b24cb82f..7c51540115a7b1391c5a9249765650ae
|
||||
|
||||
WebContents* Browser::CreateCustomWebContents(
|
||||
diff --git a/chrome/browser/ui/browser.h b/chrome/browser/ui/browser.h
|
||||
index a0e42d5be427ac89737baeaf07ec2ed3b678be5b..d0ec6b819a697b2f97e4a2f960028959a24e57e1 100644
|
||||
index bc20c6322289d13937a00255d63f026182b16c5c..d6ed05574d5fac21861346ed2c89875e49ecd30c 100644
|
||||
--- a/chrome/browser/ui/browser.h
|
||||
+++ b/chrome/browser/ui/browser.h
|
||||
@@ -915,8 +915,7 @@ class Browser : public TabStripModelObserver,
|
||||
@@ -159,7 +159,7 @@ index 783d05c39ecbe5e556af2e5fd8b4f30fb5aa1196..e1895bcf9d3c6818aa64b1479774a143
|
||||
}
|
||||
content::WebContents* CreateCustomWebContents(
|
||||
diff --git a/components/embedder_support/android/delegate/web_contents_delegate_android.cc b/components/embedder_support/android/delegate/web_contents_delegate_android.cc
|
||||
index fca620bdddec4d4a8de558675a1b5c52ab52cc56..2d09f22a415426f1d749344f75e97b264a55b46f 100644
|
||||
index 6e3bab760b4a5156870c792782f499a4eff69eb8..763daa00d3cacb4530bf0e465888f9659bce6b5a 100644
|
||||
--- a/components/embedder_support/android/delegate/web_contents_delegate_android.cc
|
||||
+++ b/components/embedder_support/android/delegate/web_contents_delegate_android.cc
|
||||
@@ -207,15 +207,14 @@ bool WebContentsDelegateAndroid::IsWebContentsCreationOverridden(
|
||||
@@ -223,10 +223,10 @@ index b969f1d97b7e3396119b579cfbe61e19ff7d2dd4..b8d6169652da28266a514938b45b39c5
|
||||
content::WebContents* AddNewContents(
|
||||
content::WebContents* source,
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index ae313e6fd5344c508121327dd12c8897f2f9254b..85a0d1eebff80d6054b80c1e9cc6e8a2ef8584e2 100644
|
||||
index 2c34c776b747f1de8e8f1d9eb3386acc19c183d3..4556e86d40d3abcc4091d09dc9fa85145d73aa41 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -5296,8 +5296,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -5312,8 +5312,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
if (delegate_ &&
|
||||
delegate_->IsWebContentsCreationOverridden(
|
||||
opener, source_site_instance, params.window_container_type,
|
||||
@@ -237,7 +237,7 @@ index ae313e6fd5344c508121327dd12c8897f2f9254b..85a0d1eebff80d6054b80c1e9cc6e8a2
|
||||
static_cast<WebContentsImpl*>(delegate_->CreateCustomWebContents(
|
||||
opener, source_site_instance, is_new_browsing_instance,
|
||||
diff --git a/content/public/browser/web_contents_delegate.cc b/content/public/browser/web_contents_delegate.cc
|
||||
index b246049104bad331651699a93260835fd943a840..90915662c4e9dbd8d9ccd365427cf36e32ee1608 100644
|
||||
index 51be0b86d083318f01a9ebe76fb7d1fb60cd72fd..02ec57eeb67dd5e5e0ff250853599c88c2a75ed0 100644
|
||||
--- a/content/public/browser/web_contents_delegate.cc
|
||||
+++ b/content/public/browser/web_contents_delegate.cc
|
||||
@@ -160,8 +160,7 @@ bool WebContentsDelegate::IsWebContentsCreationOverridden(
|
||||
@@ -251,7 +251,7 @@ index b246049104bad331651699a93260835fd943a840..90915662c4e9dbd8d9ccd365427cf36e
|
||||
}
|
||||
|
||||
diff --git a/content/public/browser/web_contents_delegate.h b/content/public/browser/web_contents_delegate.h
|
||||
index c7896c828644ed84b8423df4486d8e36835a6c4d..8c13343c426ec11195021114d04b663d5f461020 100644
|
||||
index 29c380d7845aab1a7b3417e0d3940ea00460260b..234d6d89d1c8c7f333b96f35dacb73daeecf7b17 100644
|
||||
--- a/content/public/browser/web_contents_delegate.h
|
||||
+++ b/content/public/browser/web_contents_delegate.h
|
||||
@@ -380,8 +380,7 @@ class CONTENT_EXPORT WebContentsDelegate {
|
||||
|
||||
@@ -6,7 +6,7 @@ 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 c4ada35c3ca32ce06ffc57577af7bc4c45c98579..9f345d0da8bcc8f2818f71347a2eab7675ad544a 100644
|
||||
index d0ec6830b555bcaddd882d4b626bca7762ad0317..9b25f25f035792cdb9ab0a3c99254b48a6c497ad 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
@@ -573,7 +573,11 @@
|
||||
|
||||
@@ -33,7 +33,7 @@ index 0ab8187b0db8ae6db46d81738f653a2bc4c566f6..de3d55e85c22317f7f9375eb94d0d5d4
|
||||
|
||||
} // namespace net
|
||||
diff --git a/services/network/network_context.cc b/services/network/network_context.cc
|
||||
index 24bf1331876ae80b7d0b9a88876d83922a446a85..6318cb88a4a5bb8c74d9c66e91ee95ca20594a4a 100644
|
||||
index 70204038a0f4f12f5b469c3975dcdde544990283..e861aedcf9f90a17b9b8caec1db7e940cdcb76b2 100644
|
||||
--- a/services/network/network_context.cc
|
||||
+++ b/services/network/network_context.cc
|
||||
@@ -1880,6 +1880,13 @@ void NetworkContext::SetNetworkConditions(
|
||||
@@ -51,7 +51,7 @@ index 24bf1331876ae80b7d0b9a88876d83922a446a85..6318cb88a4a5bb8c74d9c66e91ee95ca
|
||||
// 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 ea1941500a0036d5d9ab81be113f67e79bb7e96a..5c81de1cc186c16d92c4ffb4aeaa5d99edae2287 100644
|
||||
index 4b03933f18e1556c397290b0492110ce5fecaa00..1b55290b129e833fd94db97b0a489fae751d7c7e 100644
|
||||
--- a/services/network/network_context.h
|
||||
+++ b/services/network/network_context.h
|
||||
@@ -321,6 +321,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
@@ -63,7 +63,7 @@ index ea1941500a0036d5d9ab81be113f67e79bb7e96a..5c81de1cc186c16d92c4ffb4aeaa5d99
|
||||
void SetEnableReferrers(bool enable_referrers) override;
|
||||
#if BUILDFLAG(IS_CT_SUPPORTED)
|
||||
diff --git a/services/network/public/mojom/network_context.mojom b/services/network/public/mojom/network_context.mojom
|
||||
index 3ae721ad0d982d64f0531d9a0b94ff7062a2865a..ba76f74b352c677352eed38c027ab46e4d5452dd 100644
|
||||
index 91964a97001d05ce2fd1c881efe896bf1b12b1ab..3cd621ecd8322c8a9dce9f8eeae45bbbeaf27940 100644
|
||||
--- a/services/network/public/mojom/network_context.mojom
|
||||
+++ b/services/network/public/mojom/network_context.mojom
|
||||
@@ -1276,6 +1276,9 @@ interface NetworkContext {
|
||||
@@ -77,7 +77,7 @@ index 3ae721ad0d982d64f0531d9a0b94ff7062a2865a..ba76f74b352c677352eed38c027ab46e
|
||||
SetAcceptLanguage(string new_accept_language);
|
||||
|
||||
diff --git a/services/network/test/test_network_context.h b/services/network/test/test_network_context.h
|
||||
index d08e0914da4e53b1cf0f2de8c067a4aed634a474..80af85c3ed86155b7fe25bb00546946d4696eee3 100644
|
||||
index 91a94e8759817f2506e07d8e18c3d6ecf1e29da0..700ec937f9e2f4c6c343052e8f991abba06eb4c5 100644
|
||||
--- a/services/network/test/test_network_context.h
|
||||
+++ b/services/network/test/test_network_context.h
|
||||
@@ -156,6 +156,7 @@ class TestNetworkContext : public mojom::NetworkContext {
|
||||
|
||||
@@ -15,7 +15,7 @@ Ideally we could add an embedder observer pattern here but that can be
|
||||
done in future work.
|
||||
|
||||
diff --git a/third_party/blink/renderer/core/exported/web_view_impl.cc b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
index 6e7a1ffeadc4cf6ca23de271f4f9c2af3a62e88a..40fab97eaea3c6591fd08fb7c054685a1b48024f 100644
|
||||
index 440d08d8e693d57bea4bba6899d0d78c1030d1ff..39c0baabce305c00ad8ca38a61057de136069984 100644
|
||||
--- a/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
+++ b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
@@ -1903,6 +1903,8 @@ void WebView::ApplyWebPreferences(const web_pref::WebPreferences& prefs,
|
||||
|
||||
@@ -262,7 +262,7 @@ index 61683d0eddb04c494ca5e650e7d556b44968ec49..5492456a9138b250e97a5479838bb443
|
||||
|
||||
} // namespace ui
|
||||
diff --git a/ui/shell_dialogs/select_file_dialog_linux_portal.cc b/ui/shell_dialogs/select_file_dialog_linux_portal.cc
|
||||
index c66b8da5d3ce640c1a1bdfdaec66bba3b4878d3e..bf57b000175b93908ed44b31726dc1941d9bf5a9 100644
|
||||
index cf60f909cb2bed76024e3393ca858df15d73d0df..6a258bac924d12a81b4602ba702695cd64d3cfce 100644
|
||||
--- a/ui/shell_dialogs/select_file_dialog_linux_portal.cc
|
||||
+++ b/ui/shell_dialogs/select_file_dialog_linux_portal.cc
|
||||
@@ -22,9 +22,11 @@
|
||||
@@ -277,7 +277,7 @@ index c66b8da5d3ce640c1a1bdfdaec66bba3b4878d3e..bf57b000175b93908ed44b31726dc194
|
||||
#include "ui/aura/window_tree_host.h"
|
||||
#include "ui/base/l10n/l10n_util.h"
|
||||
#include "ui/gfx/native_ui_types.h"
|
||||
@@ -349,11 +351,14 @@ dbus_xdg::Dictionary SelectFileDialogLinuxPortal::BuildOptionsDictionary(
|
||||
@@ -347,11 +349,14 @@ dbus_xdg::Dictionary SelectFileDialogLinuxPortal::BuildOptionsDictionary(
|
||||
const PortalFilterSet& filter_set) {
|
||||
dbus_xdg::Dictionary dict;
|
||||
|
||||
@@ -295,7 +295,7 @@ index c66b8da5d3ce640c1a1bdfdaec66bba3b4878d3e..bf57b000175b93908ed44b31726dc194
|
||||
[[fallthrough]];
|
||||
case SelectFileDialog::SELECT_FOLDER:
|
||||
case SelectFileDialog::Type::SELECT_EXISTING_FOLDER:
|
||||
@@ -366,6 +371,11 @@ dbus_xdg::Dictionary SelectFileDialogLinuxPortal::BuildOptionsDictionary(
|
||||
@@ -364,6 +369,11 @@ dbus_xdg::Dictionary SelectFileDialogLinuxPortal::BuildOptionsDictionary(
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
@@ -414,10 +414,10 @@ index 33e2ff42e4d9da442d522b959a4a21c2f7032b6b..a0d81212327fc17e1f4704e78803c1d7
|
||||
std::vector<std::string> extension_schemes;
|
||||
// Registers a URL scheme with a predefined default custom handler.
|
||||
diff --git a/url/url_util.cc b/url/url_util.cc
|
||||
index 863a091228114ad24dce8dd26dafe7557fedbbf7..b1f788e4a42970b6d96a7a189afee211b367d4db 100644
|
||||
index 8dd125800231bd8acc3a267feb88009d455757f1..f6e35d8d4bd57813bef8586ad6e3fff3fd5ff7d1 100644
|
||||
--- a/url/url_util.cc
|
||||
+++ b/url/url_util.cc
|
||||
@@ -131,6 +131,9 @@ struct SchemeRegistry {
|
||||
@@ -132,6 +132,9 @@ struct SchemeRegistry {
|
||||
kMaterializedViewScheme,
|
||||
};
|
||||
|
||||
@@ -427,7 +427,7 @@ index 863a091228114ad24dce8dd26dafe7557fedbbf7..b1f788e4a42970b6d96a7a189afee211
|
||||
// Schemes with a predefined default custom handler.
|
||||
std::vector<SchemeWithHandler> predefined_handler_schemes;
|
||||
|
||||
@@ -666,6 +669,15 @@ const std::vector<std::string>& GetEmptyDocumentSchemes() {
|
||||
@@ -667,6 +670,15 @@ const std::vector<std::string>& GetEmptyDocumentSchemes() {
|
||||
return GetSchemeRegistry().empty_document_schemes;
|
||||
}
|
||||
|
||||
@@ -444,7 +444,7 @@ index 863a091228114ad24dce8dd26dafe7557fedbbf7..b1f788e4a42970b6d96a7a189afee211
|
||||
std::string_view handler) {
|
||||
DoAddSchemeWithHandler(
|
||||
diff --git a/url/url_util.h b/url/url_util.h
|
||||
index e0bcce98722ab2af3216c0309e26e354c79be754..f889e914d50fd5491aac96d5bd2ec9759ac6002c 100644
|
||||
index 8d7210827ed4efdc42c3c94abeff57d74e6c7ed8..141aa6858d00f56615769bc1919f69ed38209d26 100644
|
||||
--- a/url/url_util.h
|
||||
+++ b/url/url_util.h
|
||||
@@ -115,6 +115,15 @@ COMPONENT_EXPORT(URL) const std::vector<std::string>& GetCSPBypassingSchemes();
|
||||
|
||||
@@ -20,7 +20,7 @@ making three primary changes to Blink:
|
||||
* Controls whether the CSS rule is available.
|
||||
|
||||
diff --git a/third_party/blink/public/mojom/use_counter/metrics/css_property_id.mojom b/third_party/blink/public/mojom/use_counter/metrics/css_property_id.mojom
|
||||
index 3d92fdce159a52728f572481f23d27758beafb9a..cae9673c37f65ca9a98e43f544d1c1651f6593c2 100644
|
||||
index 01215910aa9a7f804251155c22962efe3cdfa25e..affdd9a597b4fdda80006760cf03d47ae8f5ef3c 100644
|
||||
--- a/third_party/blink/public/mojom/use_counter/metrics/css_property_id.mojom
|
||||
+++ b/third_party/blink/public/mojom/use_counter/metrics/css_property_id.mojom
|
||||
@@ -50,7 +50,7 @@ enum CSSSampleId {
|
||||
@@ -46,10 +46,10 @@ index 6e60de1319c5506d7180719fa230ab9cf537b832..e570e335fbd413340ddedeee423eca71
|
||||
'internal-forced-visited-'):
|
||||
internal_visited_order = 0
|
||||
diff --git a/third_party/blink/renderer/core/css/css_properties.json5 b/third_party/blink/renderer/core/css/css_properties.json5
|
||||
index 3061b694a6d9288567699d3858405be08c2f03e8..ef14d789f52741b4eb83c56f8cbdb3a6a81d7237 100644
|
||||
index d19776b90bd382ab43812d2fa09b1ceb6549149f..7266f42b698a0581ce114e4ddcba4c455c0fafb2 100644
|
||||
--- a/third_party/blink/renderer/core/css/css_properties.json5
|
||||
+++ b/third_party/blink/renderer/core/css/css_properties.json5
|
||||
@@ -9550,6 +9550,26 @@
|
||||
@@ -9588,6 +9588,26 @@
|
||||
property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"],
|
||||
},
|
||||
|
||||
@@ -77,7 +77,7 @@ index 3061b694a6d9288567699d3858405be08c2f03e8..ef14d789f52741b4eb83c56f8cbdb3a6
|
||||
{
|
||||
name: "-internal-visited-color",
|
||||
diff --git a/third_party/blink/renderer/core/css/css_property_equality.cc b/third_party/blink/renderer/core/css/css_property_equality.cc
|
||||
index add3cfe363fcd6e0bf05429f21290ede31059936..ddf26f82b131d3f017115484b14307b0fd29bc58 100644
|
||||
index 593b56ba4035f42ec39c398620b91d9a47f0652f..265ee39d2a9faa5d9683d1f7af3e0a5d7180a699 100644
|
||||
--- a/third_party/blink/renderer/core/css/css_property_equality.cc
|
||||
+++ b/third_party/blink/renderer/core/css/css_property_equality.cc
|
||||
@@ -402,6 +402,8 @@ bool CSSPropertyEquality::PropertiesEqual(const PropertyHandle& property,
|
||||
@@ -90,10 +90,10 @@ index add3cfe363fcd6e0bf05429f21290ede31059936..ddf26f82b131d3f017115484b14307b0
|
||||
return a.EmptyCells() == b.EmptyCells();
|
||||
case CSSPropertyID::kFill:
|
||||
diff --git a/third_party/blink/renderer/core/css/properties/longhands/longhands_custom.cc b/third_party/blink/renderer/core/css/properties/longhands/longhands_custom.cc
|
||||
index 3836f5f4f39d69494b68e8dc8a7bdd2a28259514..301124fe2b8efd589872f3a3a66c3d3283ce6493 100644
|
||||
index 98e390dd9fcfe4d1bfec3d2d37111d5e941bf95e..38819d9b86c024076dd14572b7489de6cd6e3ac3 100644
|
||||
--- a/third_party/blink/renderer/core/css/properties/longhands/longhands_custom.cc
|
||||
+++ b/third_party/blink/renderer/core/css/properties/longhands/longhands_custom.cc
|
||||
@@ -13128,5 +13128,36 @@ const CSSValue* InternalEmptyLineHeight::ParseSingleValue(
|
||||
@@ -13135,5 +13135,36 @@ const CSSValue* InternalEmptyLineHeight::ParseSingleValue(
|
||||
CSSValueID::kNone>(stream);
|
||||
}
|
||||
|
||||
@@ -202,7 +202,7 @@ index 19cda703154dab9397827ab6ea66c2ca446c644d..dd5943c511886f4e39b2e7f10e67e60f
|
||||
return result;
|
||||
}
|
||||
diff --git a/third_party/blink/renderer/platform/BUILD.gn b/third_party/blink/renderer/platform/BUILD.gn
|
||||
index 878869ec15e97201f8aa557e30590a3c170a468c..62b32313503c7a77bdcf83dc3998bd3b624988b2 100644
|
||||
index 90b57dd3ea2ede9cbf4954f5aab2ea4d749400bd..6c28d38b18a3b920de9a5ee633f7ab4210bdde9e 100644
|
||||
--- a/third_party/blink/renderer/platform/BUILD.gn
|
||||
+++ b/third_party/blink/renderer/platform/BUILD.gn
|
||||
@@ -1671,6 +1671,8 @@ component("platform") {
|
||||
@@ -313,7 +313,7 @@ index 18f283e625101318ee14b50e6e765dfd1c9a1a44..44a3a55974c9e4b9e715574075f25661
|
||||
|
||||
auto DrawAsSinglePath = [&]() {
|
||||
diff --git a/third_party/blink/renderer/platform/runtime_enabled_features.json5 b/third_party/blink/renderer/platform/runtime_enabled_features.json5
|
||||
index 385220b37a9f12a112bcb083811af6ddfdedebe8..9766d2feab34c890827494fceb3b783f24086863 100644
|
||||
index b3a4a34ed20d3cdf7b560ac7f2b401027f2f3a7a..5df897a26bb03e955289c0bb69de88a0231f9fe4 100644
|
||||
--- a/third_party/blink/renderer/platform/runtime_enabled_features.json5
|
||||
+++ b/third_party/blink/renderer/platform/runtime_enabled_features.json5
|
||||
@@ -214,6 +214,10 @@
|
||||
|
||||
@@ -619,7 +619,7 @@ index 2f462f0deb5fc8a637457243fb5d5849fc214d14..695869b83cefaa24af93a2e11b39de05
|
||||
+ Draw(gfx.mojom.Rect damage_rect) => ();
|
||||
};
|
||||
diff --git a/ui/compositor/compositor.h b/ui/compositor/compositor.h
|
||||
index 2d9a64dc320017b6b5c4ff9d67674493f440700c..cbca71f44ec504c06ae3a119695db205f42302fc 100644
|
||||
index 8b28abfa176ce76e513a0d5703e12e8236f6afe3..732fd74d3d1c0af3e790a3d12e8fee2ff5b7944e 100644
|
||||
--- a/ui/compositor/compositor.h
|
||||
+++ b/ui/compositor/compositor.h
|
||||
@@ -89,6 +89,7 @@ class DisplayPrivate;
|
||||
@@ -656,7 +656,7 @@ index 2d9a64dc320017b6b5c4ff9d67674493f440700c..cbca71f44ec504c06ae3a119695db205
|
||||
// Sets the root of the layer tree drawn by this Compositor. The root layer
|
||||
// must have no parent. The compositor's root layer is reset if the root layer
|
||||
// is destroyed. NULL can be passed to reset the root layer, in which case the
|
||||
@@ -631,6 +644,8 @@ class COMPOSITOR_EXPORT Compositor : public base::PowerSuspendObserver,
|
||||
@@ -632,6 +645,8 @@ class COMPOSITOR_EXPORT Compositor : public base::PowerSuspendObserver,
|
||||
simple_begin_frame_observers_;
|
||||
std::unique_ptr<ui::HostBeginFrameObserver> host_begin_frame_observer_;
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ index 33e23680b927d417b0882c7572fe32dc2d2b90c3..9413492f8e0fd6c5371c66329e1ad6d4
|
||||
|
||||
// Returns the http referrer of original request which initited this load.
|
||||
diff --git a/third_party/blink/renderer/core/loader/document_loader.h b/third_party/blink/renderer/core/loader/document_loader.h
|
||||
index 65e50de149ebc487eb10e0e1c1613ebc1b9005e8..020b0325d59907061319defc5ace6858a78be86f 100644
|
||||
index 113b7e93defa2329ef697be1f43c730e39a8dda5..53fd2191fd2415fd45255d2d778745333fc5e479 100644
|
||||
--- a/third_party/blink/renderer/core/loader/document_loader.h
|
||||
+++ b/third_party/blink/renderer/core/loader/document_loader.h
|
||||
@@ -322,7 +322,7 @@ class CORE_EXPORT DocumentLoader : public GarbageCollected<DocumentLoader>,
|
||||
|
||||
@@ -76,7 +76,7 @@ index ce69b40f1738bea97f52ed954a2908c5abdcad8b..67e8b7093a6359afef3044b2e7fc63a8
|
||||
network::ResourceRequest::TrustedParams::EnabledClientHints>&
|
||||
enabled_client_hints(
|
||||
diff --git a/services/network/public/mojom/url_request.mojom b/services/network/public/mojom/url_request.mojom
|
||||
index 0a0c6d22bdb2ce106e8e18adb5141999167e3f93..e49e8f85bdd122ee263d69efe0ee0abc139e83b3 100644
|
||||
index 9db6156ff06caca52cd4c2d47a9ff094a45eccb3..f141436a3b9feb56ca9c41b6c398451bc2bdd770 100644
|
||||
--- a/services/network/public/mojom/url_request.mojom
|
||||
+++ b/services/network/public/mojom/url_request.mojom
|
||||
@@ -111,6 +111,9 @@ struct TrustedUrlRequestParams {
|
||||
@@ -90,7 +90,7 @@ index 0a0c6d22bdb2ce106e8e18adb5141999167e3f93..e49e8f85bdd122ee263d69efe0ee0abc
|
||||
// when it receives the AcceptCHFrame.
|
||||
EnabledClientHints? enabled_client_hints;
|
||||
diff --git a/services/network/public/mojom/url_response_head.mojom b/services/network/public/mojom/url_response_head.mojom
|
||||
index 13a211107294e856616d1626fa1dc9c79eb5646c..549a36886d665c1a8100f09b7a86c8dc13c80e84 100644
|
||||
index 916dadfe0eba27c8493b1b64bb01f9e77153692e..4a599fed851ea5af4be66895b7b2d83c5f128c0d 100644
|
||||
--- a/services/network/public/mojom/url_response_head.mojom
|
||||
+++ b/services/network/public/mojom/url_response_head.mojom
|
||||
@@ -14,6 +14,7 @@ import "services/network/public/mojom/encoded_body_length.mojom";
|
||||
@@ -112,7 +112,7 @@ index 13a211107294e856616d1626fa1dc9c79eb5646c..549a36886d665c1a8100f09b7a86c8dc
|
||||
string mime_type;
|
||||
|
||||
diff --git a/services/network/url_loader.cc b/services/network/url_loader.cc
|
||||
index 1cdafc5c4189c0af64c03b8140ff310e0579d10f..939ebc202ef225387f0e9e77885a7a21aafef559 100644
|
||||
index c4f6d52508042c365a71060f5b64ad8b5b57d3aa..ad14c9357b85be82db9a75bc48084b5b961fccf1 100644
|
||||
--- a/services/network/url_loader.cc
|
||||
+++ b/services/network/url_loader.cc
|
||||
@@ -373,6 +373,9 @@ URLLoader::URLLoader(
|
||||
@@ -155,7 +155,7 @@ index 1cdafc5c4189c0af64c03b8140ff310e0579d10f..939ebc202ef225387f0e9e77885a7a21
|
||||
|
||||
if (expected_response_headers_for_synthetic_response &&
|
||||
diff --git a/services/network/url_loader.h b/services/network/url_loader.h
|
||||
index 3411c79d785cc6f9d6404e6384ec8e97f6bad8d7..9890fee8cba2da4bf126d4849a4ca41e3d3d2209 100644
|
||||
index f849b9ccd321fe5cf67266328a347ca72d089887..7d2ef80e723e872fb42a201f6fa29072d792ead3 100644
|
||||
--- a/services/network/url_loader.h
|
||||
+++ b/services/network/url_loader.h
|
||||
@@ -629,6 +629,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) URLLoader
|
||||
|
||||
@@ -8,7 +8,7 @@ Check for broken links by confirming the file exists before setting its utime.
|
||||
This patch should be upstreamed & removed.
|
||||
|
||||
diff --git a/tools/clang/scripts/update.py b/tools/clang/scripts/update.py
|
||||
index 25aae31df7604819841c9c089c29c18fb2f1fcd4..dc72a5726a5f31716b1657cf6deee1dafb8b2af7 100755
|
||||
index d17117f9b2cf255e848639ed9e904957c0497848..bd7cb77e77f5ca13d82f720a6f887e232bdecf3e 100755
|
||||
--- a/tools/clang/scripts/update.py
|
||||
+++ b/tools/clang/scripts/update.py
|
||||
@@ -201,10 +201,9 @@ def DownloadAndUnpack(url, output_dir, path_prefixes=None, is_known_zip=False):
|
||||
|
||||
@@ -28,10 +28,10 @@ The patch should be removed in favor of either:
|
||||
Upstream bug https://bugs.chromium.org/p/chromium/issues/detail?id=1081397.
|
||||
|
||||
diff --git a/content/browser/renderer_host/navigation_request.cc b/content/browser/renderer_host/navigation_request.cc
|
||||
index 7440cac2f1641bcb31b5bb7eb93a0838b97cc1a3..c34757b3c6d88b657c27dfb5a89d031250e2684e 100644
|
||||
index 3b60dafdcb6201bdee21fd5e780610d2edde0227..68c63dd81bc0283df0a7113ab55e7d4976a2ac8f 100644
|
||||
--- a/content/browser/renderer_host/navigation_request.cc
|
||||
+++ b/content/browser/renderer_host/navigation_request.cc
|
||||
@@ -11669,6 +11669,11 @@ url::Origin NavigationRequest::GetOriginForURLLoaderFactoryUnchecked() {
|
||||
@@ -11671,6 +11671,11 @@ url::Origin NavigationRequest::GetOriginForURLLoaderFactoryUnchecked() {
|
||||
target_rph_id);
|
||||
}
|
||||
|
||||
@@ -44,10 +44,10 @@ index 7440cac2f1641bcb31b5bb7eb93a0838b97cc1a3..c34757b3c6d88b657c27dfb5a89d0312
|
||||
// origin of |common_params.url| and/or |common_params.initiator_origin|.
|
||||
url::Origin resolved_origin = url::Origin::Resolve(
|
||||
diff --git a/third_party/blink/renderer/core/loader/document_loader.cc b/third_party/blink/renderer/core/loader/document_loader.cc
|
||||
index 17eeeb829ca50e5c2119e9094e7168eca5040313..99517ac017a12328223e02b18b96e55cc9a25d4a 100644
|
||||
index bcf06c7e6748f5dc8970d77db2091c88399d9ec2..827e0d3fe33738221202ea8a7832df98b505c1be 100644
|
||||
--- a/third_party/blink/renderer/core/loader/document_loader.cc
|
||||
+++ b/third_party/blink/renderer/core/loader/document_loader.cc
|
||||
@@ -2321,6 +2321,7 @@ Frame* DocumentLoader::CalculateOwnerFrame() {
|
||||
@@ -2335,6 +2335,7 @@ Frame* DocumentLoader::CalculateOwnerFrame() {
|
||||
scoped_refptr<SecurityOrigin> DocumentLoader::CalculateOrigin(
|
||||
Document* owner_document) {
|
||||
scoped_refptr<SecurityOrigin> origin;
|
||||
@@ -55,7 +55,7 @@ index 17eeeb829ca50e5c2119e9094e7168eca5040313..99517ac017a12328223e02b18b96e55c
|
||||
// Whether the origin is newly created within this call, instead of copied
|
||||
// from an existing document's origin or from `origin_to_commit_`. If this is
|
||||
// true, we won't try to compare the nonce of this origin (if it's opaque) to
|
||||
@@ -2357,6 +2358,9 @@ scoped_refptr<SecurityOrigin> DocumentLoader::CalculateOrigin(
|
||||
@@ -2371,6 +2372,9 @@ scoped_refptr<SecurityOrigin> DocumentLoader::CalculateOrigin(
|
||||
// non-renderer only origin bits will be the same, which will be asserted at
|
||||
// the end of this function.
|
||||
origin = origin_to_commit_;
|
||||
|
||||
@@ -12,7 +12,7 @@ invisible state of the `viz::DisplayScheduler` owned
|
||||
by the `ui::Compositor`.
|
||||
|
||||
diff --git a/ui/compositor/compositor.cc b/ui/compositor/compositor.cc
|
||||
index 0baec53e72ffcc36c47e097c21ebb03e7b15aca0..a72f53bf0b40a493aeb56c20eea5bbd198855fcf 100644
|
||||
index f12e18ad1255c0e0228805f2ba334519b446ef63..10f4b53423a8a7cf7f1f09e4570871fa1ead27ca 100644
|
||||
--- a/ui/compositor/compositor.cc
|
||||
+++ b/ui/compositor/compositor.cc
|
||||
@@ -369,7 +369,8 @@ void Compositor::SetLayerTreeFrameSink(
|
||||
@@ -36,7 +36,7 @@ index 0baec53e72ffcc36c47e097c21ebb03e7b15aca0..a72f53bf0b40a493aeb56c20eea5bbd1
|
||||
|
||||
if (changed) {
|
||||
observer_list_.Notify(&CompositorObserver::OnCompositorVisibilityChanged,
|
||||
@@ -1084,6 +1087,15 @@ void Compositor::MaybeUpdateObserveBeginFrame() {
|
||||
@@ -1087,6 +1090,15 @@ void Compositor::MaybeUpdateObserveBeginFrame() {
|
||||
host_begin_frame_observer_->GetBoundRemote());
|
||||
}
|
||||
|
||||
@@ -53,10 +53,10 @@ index 0baec53e72ffcc36c47e097c21ebb03e7b15aca0..a72f53bf0b40a493aeb56c20eea5bbd1
|
||||
void Compositor::SetSeamlessRefreshRates(
|
||||
const std::vector<float>& seamless_refresh_rates) {
|
||||
diff --git a/ui/compositor/compositor.h b/ui/compositor/compositor.h
|
||||
index cbca71f44ec504c06ae3a119695db205f42302fc..4b999d9387279c7cb5ada13344212504ef48ef42 100644
|
||||
index 732fd74d3d1c0af3e790a3d12e8fee2ff5b7944e..03b0ca0457a752df40f6ff0e4809b8dc17cd7445 100644
|
||||
--- a/ui/compositor/compositor.h
|
||||
+++ b/ui/compositor/compositor.h
|
||||
@@ -515,6 +515,10 @@ class COMPOSITOR_EXPORT Compositor : public base::PowerSuspendObserver,
|
||||
@@ -516,6 +516,10 @@ class COMPOSITOR_EXPORT Compositor : public base::PowerSuspendObserver,
|
||||
|
||||
const cc::LayerTreeSettings& GetLayerTreeSettings() const;
|
||||
|
||||
@@ -67,7 +67,7 @@ index cbca71f44ec504c06ae3a119695db205f42302fc..4b999d9387279c7cb5ada13344212504
|
||||
size_t saved_events_metrics_count_for_testing() const {
|
||||
return host_->saved_events_metrics_count_for_testing();
|
||||
}
|
||||
@@ -731,6 +735,12 @@ class COMPOSITOR_EXPORT Compositor : public base::PowerSuspendObserver,
|
||||
@@ -727,6 +731,12 @@ class COMPOSITOR_EXPORT Compositor : public base::PowerSuspendObserver,
|
||||
// See go/report-ux-metrics-at-painting for details.
|
||||
bool animation_started_ = false;
|
||||
|
||||
|
||||
@@ -13,10 +13,10 @@ This patch adds a global reference count to keep track of
|
||||
enable/disable behavior on this reference count.
|
||||
|
||||
diff --git a/base/message_loop/message_pump_apple.mm b/base/message_loop/message_pump_apple.mm
|
||||
index 55753d0249ad013f244a88d77a4bdf4620df4a45..aa73243057b27e38e664629ef402f00de8835975 100644
|
||||
index c0a11588b63fc764177dc9a7194c3a02759d80b0..d800b03835358884f2be46f42f4be0b67dafb091 100644
|
||||
--- a/base/message_loop/message_pump_apple.mm
|
||||
+++ b/base/message_loop/message_pump_apple.mm
|
||||
@@ -774,20 +774,29 @@ explicit OptionalAutoreleasePool(MessagePumpCFRunLoopBase* pump) {
|
||||
@@ -775,20 +775,29 @@ explicit OptionalAutoreleasePool(MessagePumpCFRunLoopBase* pump) {
|
||||
|
||||
#else
|
||||
|
||||
|
||||
@@ -13,10 +13,10 @@ messages in the legacy window handle layer.
|
||||
These conditions are regularly hit with WCO-enabled windows on Windows.
|
||||
|
||||
diff --git a/content/browser/renderer_host/legacy_render_widget_host_win.cc b/content/browser/renderer_host/legacy_render_widget_host_win.cc
|
||||
index 871bb720529690ef81fbcd27056393766b9525ff..471a5b3ecb184ef2bf23b0ec3066711925ddaa4b 100644
|
||||
index c7794d6a969b407281db12acc027a933a4a82921..382d01ab2f0ad774f7c0d1dc214dd45b6998549a 100644
|
||||
--- a/content/browser/renderer_host/legacy_render_widget_host_win.cc
|
||||
+++ b/content/browser/renderer_host/legacy_render_widget_host_win.cc
|
||||
@@ -371,12 +371,12 @@ LRESULT LegacyRenderWidgetHostHWND::OnKeyboardRange(UINT message,
|
||||
@@ -377,12 +377,12 @@ LRESULT LegacyRenderWidgetHostHWND::OnKeyboardRange(UINT message,
|
||||
LRESULT LegacyRenderWidgetHostHWND::OnMouseRange(UINT message,
|
||||
WPARAM w_param,
|
||||
LPARAM l_param) {
|
||||
@@ -31,7 +31,7 @@ index 871bb720529690ef81fbcd27056393766b9525ff..471a5b3ecb184ef2bf23b0ec30667119
|
||||
tme.hwndTrack = hwnd();
|
||||
tme.dwHoverTime = 0;
|
||||
TrackMouseEvent(&tme);
|
||||
@@ -409,7 +409,10 @@ LRESULT LegacyRenderWidgetHostHWND::OnMouseRange(UINT message,
|
||||
@@ -421,7 +421,10 @@ LRESULT LegacyRenderWidgetHostHWND::OnMouseRange(UINT message,
|
||||
// the picture.
|
||||
if (!msg_handled &&
|
||||
(message >= WM_NCMOUSEMOVE && message <= WM_NCXBUTTONDBLCLK)) {
|
||||
|
||||
@@ -87,10 +87,10 @@ index 5158897a7a7af9f29580faa17498a8dbab40af87..96617b9bb0275144b0e9ed18547d9982
|
||||
// The view with active text input state, i.e., a focused <input> element.
|
||||
// It will be nullptr if no such view exists. Note that the active view
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index d72fddcda30ea6d18180f7734ba958b8696355b4..c2adef9ec376176439985234d021316ac0521adf 100644
|
||||
index 8593aa220a4e71450cedea0784fb4fa6843bacd4..f0847e8dbe381b7a086cebe2c361f77bfb0c9bed 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -10208,7 +10208,7 @@ void WebContentsImpl::OnFocusedElementChangedInFrame(
|
||||
@@ -10230,7 +10230,7 @@ void WebContentsImpl::OnFocusedElementChangedInFrame(
|
||||
"WebContentsImpl::OnFocusedElementChangedInFrame",
|
||||
"render_frame_host", frame);
|
||||
RenderWidgetHostViewBase* root_view =
|
||||
|
||||
@@ -211,7 +211,7 @@ index f2c94689450f0333a144ccf82cf147c194896e6b..1c2e9fe36c297f7d614d9ca290e4d13c
|
||||
const mojom::blink::UserActivationOption user_activation_option_;
|
||||
const mojom::blink::LoadEventBlockingOption blocking_option_;
|
||||
diff --git a/third_party/blink/renderer/core/frame/web_frame_test.cc b/third_party/blink/renderer/core/frame/web_frame_test.cc
|
||||
index c274456a74f5e91f7852965fd8e1b5e9f0733e53..bdaeb9a9b252d81a5ad1563a4af1b329c2771873 100644
|
||||
index 72c5cecc619aba2e106b838898f1d9c911bcb331..7ed7f7ff7fed1d71ee6330c2783941ad239715c6 100644
|
||||
--- a/third_party/blink/renderer/core/frame/web_frame_test.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/web_frame_test.cc
|
||||
@@ -298,6 +298,7 @@ void ExecuteScriptsInMainWorld(
|
||||
|
||||
@@ -1,20 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Mitchell Cohen <mitch.cohen@me.com>
|
||||
Date: Sun, 22 Feb 2026 11:38:49 -0500
|
||||
Subject: fix: Wayland test crash on teardown
|
||||
|
||||
Allows Wayland test job to teardown the connection without crashing when trying to update the pointer
|
||||
|
||||
diff --git a/ui/ozone/platform/wayland/host/wayland_connection.cc b/ui/ozone/platform/wayland/host/wayland_connection.cc
|
||||
index 4c44eaeebe091906a1676da106faa9072819b67e..224f6abfe06794d31fc4d876c8242dab79ba075d 100644
|
||||
--- a/ui/ozone/platform/wayland/host/wayland_connection.cc
|
||||
+++ b/ui/ozone/platform/wayland/host/wayland_connection.cc
|
||||
@@ -426,7 +426,7 @@ std::vector<TouchscreenDevice> WaylandConnection::CreateTouchscreenDevices()
|
||||
}
|
||||
|
||||
void WaylandConnection::UpdateCursor() {
|
||||
- if (auto* pointer = seat_->pointer()) {
|
||||
+ if (auto* pointer = seat_ ? seat_->pointer() : nullptr) {
|
||||
cursor_ = std::make_unique<WaylandCursor>(pointer, this);
|
||||
cursor_->set_listener(listener_);
|
||||
cursor_position_ = std::make_unique<WaylandCursorPosition>();
|
||||
@@ -6,7 +6,7 @@ Subject: frame_host_manager.patch
|
||||
Allows embedder to intercept site instances created by chromium.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_frame_host_manager.cc b/content/browser/renderer_host/render_frame_host_manager.cc
|
||||
index bd2915a20b70df4edec7bf9eeed20532faca0c31..c3d7a422a0e77a096234a362d5ddd45f27145b53 100644
|
||||
index 9d38302c32a040272d9eeab4a7d20755231a3cb6..4c14e547fbedcd7918a3bd950dbed4ed48231fd4 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_manager.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_manager.cc
|
||||
@@ -4852,6 +4852,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
|
||||
@@ -50,7 +50,7 @@ system font by checking if it's kCTFontPriorityAttribute is set to
|
||||
system priority.
|
||||
|
||||
diff --git a/base/BUILD.gn b/base/BUILD.gn
|
||||
index 37b8fc7c5f035ad9eeeda8738ee2e891faf1ae29..df301071102be15f3748d434339ce9030ceda0ba 100644
|
||||
index 0d3f3638037a2a4b701c0739a43b7ac5ccee5795..a62d7450e2bbd75280191292b2e27ab6fb5338a4 100644
|
||||
--- a/base/BUILD.gn
|
||||
+++ b/base/BUILD.gn
|
||||
@@ -1085,6 +1085,7 @@ component("base") {
|
||||
@@ -1020,7 +1020,7 @@ index 367834e678f44d6e71c4218d293e11c3569daf2b..c97fb8f0411b45c1a01e4fab8dc40cc3
|
||||
// Used to force the NSApplication's focused accessibility element to be the
|
||||
// content::BrowserAccessibilityCocoa accessibility tree when the NSView for
|
||||
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 cf8652cb6ddbf07e114d576c192bcda99dc78e3a..c4ada35c3ca32ce06ffc57577af7bc4c45c98579 100644
|
||||
index fd37e14335bebe3235c4a10b4322fc06f4bd9296..d0ec6830b555bcaddd882d4b626bca7762ad0317 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
@@ -52,6 +52,7 @@
|
||||
@@ -1095,10 +1095,10 @@ index cf8652cb6ddbf07e114d576c192bcda99dc78e3a..c4ada35c3ca32ce06ffc57577af7bc4c
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
diff --git a/content/common/BUILD.gn b/content/common/BUILD.gn
|
||||
index 8af29cca616f1a29a2b59b68b7105635cedd6417..a82661cf81efa357a97da45b2d807569443f9b5e 100644
|
||||
index 5487c3756c60389a3442c2e59a08c91890fb6f87..f17ed8c3485102ac63f34239b3b31a3a322088f9 100644
|
||||
--- a/content/common/BUILD.gn
|
||||
+++ b/content/common/BUILD.gn
|
||||
@@ -278,6 +278,7 @@ source_set("common") {
|
||||
@@ -279,6 +279,7 @@ source_set("common") {
|
||||
"//ui/shell_dialogs",
|
||||
"//url",
|
||||
"//url/ipc:url_ipc",
|
||||
@@ -1330,10 +1330,10 @@ index 8b7a675d95ad36cbb9528bc5bc7ef05e5124e5a3..ed6a9a326b82b177059317dc4bc54b10
|
||||
|
||||
namespace ui {
|
||||
diff --git a/media/audio/BUILD.gn b/media/audio/BUILD.gn
|
||||
index fe6b3d10d4467983652ad1203f03769e9f236a9f..575c8b7c71eb245b7b431ea450b5f05d5445c60a 100644
|
||||
index d3ceb8cfbfe1fb63804232c3fd62bafcd90752bd..a82ca8b52a4b8f96ccb013abd5c0bf7c2765b073 100644
|
||||
--- a/media/audio/BUILD.gn
|
||||
+++ b/media/audio/BUILD.gn
|
||||
@@ -201,6 +201,7 @@ source_set("audio") {
|
||||
@@ -199,6 +199,7 @@ source_set("audio") {
|
||||
"CoreMedia.framework",
|
||||
]
|
||||
weak_frameworks = [ "ScreenCaptureKit.framework" ] # macOS 13.0
|
||||
|
||||
@@ -7,7 +7,7 @@ This adds a callback from the network service that's used to implement
|
||||
session.setCertificateVerifyCallback.
|
||||
|
||||
diff --git a/services/network/network_context.cc b/services/network/network_context.cc
|
||||
index 970cb10cfcd0c17937c95d21b27a788d398304a9..24bf1331876ae80b7d0b9a88876d83922a446a85 100644
|
||||
index 90e788dd34052d64719689bdcb3bb92cd4b0d1b2..70204038a0f4f12f5b469c3975dcdde544990283 100644
|
||||
--- a/services/network/network_context.cc
|
||||
+++ b/services/network/network_context.cc
|
||||
@@ -171,6 +171,11 @@
|
||||
@@ -148,7 +148,7 @@ index 970cb10cfcd0c17937c95d21b27a788d398304a9..24bf1331876ae80b7d0b9a88876d8392
|
||||
void NetworkContext::CreateURLLoaderFactory(
|
||||
mojo::PendingReceiver<mojom::URLLoaderFactory> receiver,
|
||||
mojom::URLLoaderFactoryParamsPtr params) {
|
||||
@@ -2680,6 +2797,10 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
|
||||
@@ -2679,6 +2796,10 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
|
||||
cert_verifier = std::make_unique<net::CachingCertVerifier>(
|
||||
std::make_unique<net::CoalescingCertVerifier>(
|
||||
std::move(cert_verifier)));
|
||||
@@ -160,7 +160,7 @@ index 970cb10cfcd0c17937c95d21b27a788d398304a9..24bf1331876ae80b7d0b9a88876d8392
|
||||
|
||||
builder.SetCertVerifier(IgnoreErrorsCertVerifier::MaybeWrapCertVerifier(
|
||||
diff --git a/services/network/network_context.h b/services/network/network_context.h
|
||||
index aff2d758cc0aae06977e84115e890aa798a494b3..ea1941500a0036d5d9ab81be113f67e79bb7e96a 100644
|
||||
index 0a66897041304092974991ad575e3542fc1bd965..4b03933f18e1556c397290b0492110ce5fecaa00 100644
|
||||
--- a/services/network/network_context.h
|
||||
+++ b/services/network/network_context.h
|
||||
@@ -118,6 +118,7 @@ class SimpleUrlPatternMatcher;
|
||||
@@ -180,7 +180,7 @@ index aff2d758cc0aae06977e84115e890aa798a494b3..ea1941500a0036d5d9ab81be113f67e7
|
||||
void ResetURLLoaderFactories() override;
|
||||
void GetViaObliviousHttp(
|
||||
mojom::ObliviousHttpRequestPtr request,
|
||||
@@ -965,6 +968,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
@@ -964,6 +967,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
std::vector<base::OnceClosure> dismount_closures_;
|
||||
#endif // BUILDFLAG(IS_DIRECTORY_TRANSFER_REQUIRED)
|
||||
|
||||
@@ -190,7 +190,7 @@ index aff2d758cc0aae06977e84115e890aa798a494b3..ea1941500a0036d5d9ab81be113f67e7
|
||||
std::unique_ptr<HostResolver> internal_host_resolver_;
|
||||
std::set<std::unique_ptr<HostResolver>, base::UniquePtrComparator>
|
||||
diff --git a/services/network/public/mojom/network_context.mojom b/services/network/public/mojom/network_context.mojom
|
||||
index 19d4a2c7119f080d077da74320c47cfa16d820de..3ae721ad0d982d64f0531d9a0b94ff7062a2865a 100644
|
||||
index f15e345eb867a76b27389b2cf89bb18d5c12e44b..91964a97001d05ce2fd1c881efe896bf1b12b1ab 100644
|
||||
--- a/services/network/public/mojom/network_context.mojom
|
||||
+++ b/services/network/public/mojom/network_context.mojom
|
||||
@@ -313,6 +313,17 @@ struct SocketBrokerRemotes {
|
||||
@@ -222,7 +222,7 @@ index 19d4a2c7119f080d077da74320c47cfa16d820de..3ae721ad0d982d64f0531d9a0b94ff70
|
||||
CreateURLLoaderFactory(
|
||||
pending_receiver<URLLoaderFactory> url_loader_factory,
|
||||
diff --git a/services/network/test/test_network_context.h b/services/network/test/test_network_context.h
|
||||
index 278c242e398a5a23b5d3d220983aed6db00bbd84..d08e0914da4e53b1cf0f2de8c067a4aed634a474 100644
|
||||
index e561dccc1ab718039d6073b009d94c2c4c5082f9..91a94e8759817f2506e07d8e18c3d6ecf1e29da0 100644
|
||||
--- a/services/network/test/test_network_context.h
|
||||
+++ b/services/network/test/test_network_context.h
|
||||
@@ -63,6 +63,8 @@ class TestNetworkContext : public mojom::NetworkContext {
|
||||
|
||||
@@ -133,7 +133,7 @@ index 9bf238e64af483294ae3c3f18a4e9aed49a8658d..b9b2a4c8c387b8e8b4eb1f02fc0f891c
|
||||
const GURL& document_url,
|
||||
const WeakDocumentPtr& weak_document_ptr,
|
||||
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
index 74b0f1e78d4c4268d25397082f52396fba47a9d9..97019858eb12edf78ab97515c1d01f51edd6c01a 100644
|
||||
index 429d4168b1f8c110494dfe1f364a46441840c517..ce32116e41b3f3a71069baa3e6d05dd02d4a7460 100644
|
||||
--- a/content/browser/renderer_host/render_process_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
@@ -2359,7 +2359,7 @@ void RenderProcessHostImpl::CreateNotificationService(
|
||||
|
||||
@@ -11,10 +11,10 @@ For resolving complex conflict please pin @reitowo
|
||||
For more reason please see: https://crrev.com/c/5465148
|
||||
|
||||
diff --git a/gpu/command_buffer/service/shared_image/d3d_image_backing_factory.cc b/gpu/command_buffer/service/shared_image/d3d_image_backing_factory.cc
|
||||
index 660a50670db25c48bdb7ab9facd8efbe944844f1..904ae1ef29aae9a28b555acc71928450ea848588 100644
|
||||
index 6f31a20329a7bc7cafb6384c3b8ec9ed7a11e64e..3bf92efa5c0ad0212096e61383b53095867aa62e 100644
|
||||
--- a/gpu/command_buffer/service/shared_image/d3d_image_backing_factory.cc
|
||||
+++ b/gpu/command_buffer/service/shared_image/d3d_image_backing_factory.cc
|
||||
@@ -378,7 +378,8 @@ gfx::GpuMemoryBufferHandle D3DImageBackingFactory::CreateGpuMemoryBufferHandle(
|
||||
@@ -379,7 +379,8 @@ gfx::GpuMemoryBufferHandle D3DImageBackingFactory::CreateGpuMemoryBufferHandle(
|
||||
// so make sure that the usage is one that we support.
|
||||
DCHECK(usage == gfx::BufferUsage::GPU_READ ||
|
||||
usage == gfx::BufferUsage::SCANOUT ||
|
||||
@@ -24,7 +24,7 @@ index 660a50670db25c48bdb7ab9facd8efbe944844f1..904ae1ef29aae9a28b555acc71928450
|
||||
<< "Incorrect usage, usage=" << gfx::BufferUsageToString(usage);
|
||||
|
||||
D3D11_TEXTURE2D_DESC desc = {
|
||||
@@ -392,7 +393,9 @@ gfx::GpuMemoryBufferHandle D3DImageBackingFactory::CreateGpuMemoryBufferHandle(
|
||||
@@ -393,7 +394,9 @@ gfx::GpuMemoryBufferHandle D3DImageBackingFactory::CreateGpuMemoryBufferHandle(
|
||||
D3D11_BIND_SHADER_RESOURCE | D3D11_BIND_RENDER_TARGET,
|
||||
0,
|
||||
D3D11_RESOURCE_MISC_SHARED_NTHANDLE |
|
||||
|
||||
@@ -61,7 +61,7 @@ index c0696d530d282dcc2d8d95c518faa6326a354e8e..5a967fd5697a92d2acea2ea81b6c1115
|
||||
CompleteDefaultWebNativeRendererColorIdsDefinition(
|
||||
mixer, dark_mode,
|
||||
diff --git a/ui/color/win/native_color_mixers_win.cc b/ui/color/win/native_color_mixers_win.cc
|
||||
index 1e9287a29a293654968fd2263792bdabfab84e27..569b764b4e5ed6be525e6faa36669050bdd5bace 100644
|
||||
index 43214fd65d27b6443d54a14ea8557932f65c29e8..6401b52c160728d3a3971ffad5305bde4f9ec363 100644
|
||||
--- a/ui/color/win/native_color_mixers_win.cc
|
||||
+++ b/ui/color/win/native_color_mixers_win.cc
|
||||
@@ -145,6 +145,10 @@ void AddNativeUiColorMixer(ColorProvider* provider,
|
||||
|
||||
@@ -44,10 +44,10 @@ index 1455aa5083f8eef7bf9644a1cc522db3e67b0227..5df63357160d96b77c8c123a984aeef9
|
||||
|
||||
void RenderWidgetHostImpl::ShowContextMenuAtPoint(
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index b6c4b24ac87e0aaeac82bd18b43bf4c12f469cf7..ae313e6fd5344c508121327dd12c8897f2f9254b 100644
|
||||
index 89f759eba4281d02ccce2c92e3338c68cdb8b89e..2c34c776b747f1de8e8f1d9eb3386acc19c183d3 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -6169,6 +6169,11 @@ TextInputManager* WebContentsImpl::GetTextInputManager() {
|
||||
@@ -6187,6 +6187,11 @@ TextInputManager* WebContentsImpl::GetTextInputManager() {
|
||||
return text_input_manager_.get();
|
||||
}
|
||||
|
||||
@@ -60,10 +60,10 @@ index b6c4b24ac87e0aaeac82bd18b43bf4c12f469cf7..ae313e6fd5344c508121327dd12c8897
|
||||
RenderWidgetHostImpl* render_widget_host) {
|
||||
return render_widget_host == GetPrimaryMainFrame()->GetRenderWidgetHost();
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.h b/content/browser/web_contents/web_contents_impl.h
|
||||
index 1f4f44aabe1255989f53e04737607031835eb594..ee0012bc2811a7f8469300a2118c494c1ff00c0e 100644
|
||||
index af0e49fd2bc9e93d9561634da93712b4290237a7..5e6b38afd17892107466bf25602bee91e8aca8e1 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.h
|
||||
+++ b/content/browser/web_contents/web_contents_impl.h
|
||||
@@ -1192,6 +1192,7 @@ class CONTENT_EXPORT WebContentsImpl
|
||||
@@ -1193,6 +1193,7 @@ class CONTENT_EXPORT WebContentsImpl
|
||||
void SendScreenRects() override;
|
||||
void SendActiveState(bool active) override;
|
||||
TextInputManager* GetTextInputManager() override;
|
||||
|
||||
@@ -15,10 +15,10 @@ This CL removes these filters so the unresponsive event can still be
|
||||
accessed from our JS event. The filtering is moved into Electron's code.
|
||||
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index f1276da6c20a8c1e4bd124b20c47057fa677894b..79f24f6f667222091b220f8b7f010b7e33415487 100644
|
||||
index 2da562e56b01873f811827adf1f6c9ccb9a2d3f6..a11d808a0bcfd910966a969054c011a3c0d8411b 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -10370,25 +10370,13 @@ void WebContentsImpl::RendererUnresponsive(
|
||||
@@ -10392,25 +10392,13 @@ void WebContentsImpl::RendererUnresponsive(
|
||||
base::RepeatingClosure hang_monitor_restarter) {
|
||||
OPTIONAL_TRACE_EVENT1("content", "WebContentsImpl::RendererUnresponsive",
|
||||
"render_widget_host", render_widget_host);
|
||||
|
||||
@@ -52,10 +52,10 @@ Some alternatives to this patch:
|
||||
None of these options seems like a substantial maintainability win over this patch to me (@nornagon).
|
||||
|
||||
diff --git a/chrome/BUILD.gn b/chrome/BUILD.gn
|
||||
index 4a54a9062f94b6fdae1435ae46fd3b88fc164fa4..8aad429c56915e0e842d95e246ad4ae41b0d1588 100644
|
||||
index c8c10cdab040d39f69fa56aad12fc8b1c67854f3..4b1fd316496e33f9e805aec89a91062587e6ee16 100644
|
||||
--- a/chrome/BUILD.gn
|
||||
+++ b/chrome/BUILD.gn
|
||||
@@ -1539,7 +1539,7 @@ if (is_chrome_branded && !is_android) {
|
||||
@@ -1548,7 +1548,7 @@ if (is_chrome_branded && !is_android) {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -64,7 +64,7 @@ index 4a54a9062f94b6fdae1435ae46fd3b88fc164fa4..8aad429c56915e0e842d95e246ad4ae4
|
||||
chrome_paks("packed_resources") {
|
||||
if (is_mac) {
|
||||
output_dir = "$root_gen_dir/repack"
|
||||
@@ -1585,6 +1585,12 @@ repack("browser_tests_pak") {
|
||||
@@ -1594,6 +1594,12 @@ repack("browser_tests_pak") {
|
||||
deps = [ "//chrome/test/data/webui:resources" ]
|
||||
}
|
||||
|
||||
|
||||
@@ -245,7 +245,7 @@ index 1ef2c9052262eccdbc40030746a858b7f30ac469..c7101b0d71826b05f61bfe0e74429d92
|
||||
}
|
||||
|
||||
diff --git a/content/common/features.cc b/content/common/features.cc
|
||||
index 4694ce5a21f5a7ce9d2b418a06fc82a193e72a4a..fe398012794ca185042385660dc47c670adb5f15 100644
|
||||
index 5c8091c422be395b14db3dea765a29bbd5b97e5d..2ef4346a3b7a0b223a31cd164b7706d7ab5c6e6a 100644
|
||||
--- a/content/common/features.cc
|
||||
+++ b/content/common/features.cc
|
||||
@@ -354,6 +354,14 @@ BASE_FEATURE(kInterestGroupUpdateIfOlderThan, base::FEATURE_ENABLED_BY_DEFAULT);
|
||||
|
||||
@@ -54,10 +54,10 @@ index 9b598ba34285bfe04c7c45557dd51af73bece3fe..c435d4441c99f87cc6a38fa73f73da6b
|
||||
if (mouse_event_callback.Run(mouse_event)) {
|
||||
return;
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index 79f24f6f667222091b220f8b7f010b7e33415487..d2715bd234558c7a131856121e5bb33d227057d4 100644
|
||||
index a11d808a0bcfd910966a969054c011a3c0d8411b..92c15693e3807a8c65e817c9a5a94b134e48e35e 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -4463,6 +4463,12 @@ void WebContentsImpl::RenderWidgetWasResized(
|
||||
@@ -4475,6 +4475,12 @@ void WebContentsImpl::RenderWidgetWasResized(
|
||||
width_changed);
|
||||
}
|
||||
|
||||
@@ -71,10 +71,10 @@ index 79f24f6f667222091b220f8b7f010b7e33415487..d2715bd234558c7a131856121e5bb33d
|
||||
const gfx::PointF& client_pt) {
|
||||
if (delegate_) {
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.h b/content/browser/web_contents/web_contents_impl.h
|
||||
index ee0012bc2811a7f8469300a2118c494c1ff00c0e..c755229cd1c52d1431e6b17459db562da8653cc2 100644
|
||||
index 5e6b38afd17892107466bf25602bee91e8aca8e1..eb1047d627710b72b198f5fd9335cc4f346b361e 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.h
|
||||
+++ b/content/browser/web_contents/web_contents_impl.h
|
||||
@@ -1122,6 +1122,7 @@ class CONTENT_EXPORT WebContentsImpl
|
||||
@@ -1123,6 +1123,7 @@ class CONTENT_EXPORT WebContentsImpl
|
||||
|
||||
double GetPendingZoomLevel(RenderWidgetHostImpl* rwh) override;
|
||||
|
||||
@@ -83,7 +83,7 @@ index ee0012bc2811a7f8469300a2118c494c1ff00c0e..c755229cd1c52d1431e6b17459db562d
|
||||
const gfx::PointF& client_pt);
|
||||
void PreHandleDragExit();
|
||||
diff --git a/content/public/browser/web_contents_delegate.cc b/content/public/browser/web_contents_delegate.cc
|
||||
index 90915662c4e9dbd8d9ccd365427cf36e32ee1608..bec604166fc7adb049734d74b1e5a12e1c446a5c 100644
|
||||
index 02ec57eeb67dd5e5e0ff250853599c88c2a75ed0..5f104dccc8a4b6d50d10aac01b3fe73b781e0ac1 100644
|
||||
--- a/content/public/browser/web_contents_delegate.cc
|
||||
+++ b/content/public/browser/web_contents_delegate.cc
|
||||
@@ -126,6 +126,12 @@ bool WebContentsDelegate::HandleContextMenu(RenderFrameHost& render_frame_host,
|
||||
@@ -100,7 +100,7 @@ index 90915662c4e9dbd8d9ccd365427cf36e32ee1608..bec604166fc7adb049734d74b1e5a12e
|
||||
WebContents* source,
|
||||
const input::NativeWebKeyboardEvent& event) {
|
||||
diff --git a/content/public/browser/web_contents_delegate.h b/content/public/browser/web_contents_delegate.h
|
||||
index 8c13343c426ec11195021114d04b663d5f461020..a928d215fc4bb1bfaa7222f1fcc635f500453ef9 100644
|
||||
index 234d6d89d1c8c7f333b96f35dacb73daeecf7b17..2bb0499064346697fc19d012740fcacdda40f722 100644
|
||||
--- a/content/public/browser/web_contents_delegate.h
|
||||
+++ b/content/public/browser/web_contents_delegate.h
|
||||
@@ -326,6 +326,13 @@ class CONTENT_EXPORT WebContentsDelegate {
|
||||
|
||||
@@ -6,7 +6,7 @@ Subject: Revert "Remove the AllowAggressiveThrottlingWithWebSocket feature."
|
||||
This reverts commit 615c1810a187840ffeb04096087efff86edb37de.
|
||||
|
||||
diff --git a/third_party/blink/renderer/modules/websockets/websocket_channel_impl.cc b/third_party/blink/renderer/modules/websockets/websocket_channel_impl.cc
|
||||
index 2aabcba134b58d36d6570a06b221f3e5991d5377..0b9b721da002c6d931cd2e32aa62737d7c964716 100644
|
||||
index ff9573ba3d4eaef0da2c11fc915c1687992f1fee..514d633d83a7161fbce39e79f2496804d252c162 100644
|
||||
--- a/third_party/blink/renderer/modules/websockets/websocket_channel_impl.cc
|
||||
+++ b/third_party/blink/renderer/modules/websockets/websocket_channel_impl.cc
|
||||
@@ -102,6 +102,17 @@ enum WebSocketOpCode {
|
||||
|
||||
@@ -10,10 +10,10 @@ on Windows. We should refactor our code so that this patch isn't
|
||||
necessary.
|
||||
|
||||
diff --git a/testing/variations/fieldtrial_testing_config.json b/testing/variations/fieldtrial_testing_config.json
|
||||
index 28af0584326b720ac28c2c2fb83874d0f8a050bf..0028306866159616a26a97381783a33a1c370f25 100644
|
||||
index bada99ebfe33b5eac18cfe8f8f5f39ae9e4ae86a..e8c917128b31eea00fdbbb6d49d6807166b9c140 100644
|
||||
--- a/testing/variations/fieldtrial_testing_config.json
|
||||
+++ b/testing/variations/fieldtrial_testing_config.json
|
||||
@@ -26772,6 +26772,21 @@
|
||||
@@ -26703,6 +26703,21 @@
|
||||
]
|
||||
}
|
||||
],
|
||||
|
||||
@@ -22,7 +22,7 @@ However, the patch would need to be reviewed by the security team, as it
|
||||
does touch a security-sensitive class.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
index 97019858eb12edf78ab97515c1d01f51edd6c01a..b2292f89fdd53c9ec2b1b3d31b5c208b2f1f6acf 100644
|
||||
index ce32116e41b3f3a71069baa3e6d05dd02d4a7460..54d7041009e26d3e4572080ec81e90ce0cb1fd08 100644
|
||||
--- a/content/browser/renderer_host/render_process_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
@@ -1939,6 +1939,10 @@ bool RenderProcessHostImpl::Init() {
|
||||
|
||||
@@ -9,10 +9,10 @@ is needed for OSR.
|
||||
Originally landed in https://github.com/electron/libchromiumcontent/pull/226.
|
||||
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index 85a0d1eebff80d6054b80c1e9cc6e8a2ef8584e2..3237246346af539a860ff3f71c75d20292df3f7b 100644
|
||||
index 4556e86d40d3abcc4091d09dc9fa85145d73aa41..a2bf967fef8f92a2ed9854ac559c4b6f59e54f19 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -4180,6 +4180,13 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
|
||||
@@ -4192,6 +4192,13 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
|
||||
params.main_frame_name, GetOpener(), primary_main_frame_policy,
|
||||
base::UnguessableToken::Create());
|
||||
|
||||
@@ -26,7 +26,7 @@ index 85a0d1eebff80d6054b80c1e9cc6e8a2ef8584e2..3237246346af539a860ff3f71c75d202
|
||||
std::unique_ptr<WebContentsViewDelegate> delegate =
|
||||
GetContentClient()->browser()->GetWebContentsViewDelegate(this);
|
||||
|
||||
@@ -4190,6 +4197,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
|
||||
@@ -4202,6 +4209,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
|
||||
view_ = CreateWebContentsView(this, std::move(delegate),
|
||||
&render_view_host_delegate_view_);
|
||||
}
|
||||
@@ -35,7 +35,7 @@ index 85a0d1eebff80d6054b80c1e9cc6e8a2ef8584e2..3237246346af539a860ff3f71c75d202
|
||||
CHECK(view_.get());
|
||||
|
||||
diff --git a/content/public/browser/web_contents.h b/content/public/browser/web_contents.h
|
||||
index d3ff17bbff0e71ead2c3f98e90bbecd922ab6008..81bffaddac5dfd0e4fd81c5d30cffc661532c2f8 100644
|
||||
index 78776430d970d73d3c92f94c26764a3e94ee0013..cce0d7df8ea6608a4fdb84d5eefbfb252a0031db 100644
|
||||
--- a/content/public/browser/web_contents.h
|
||||
+++ b/content/public/browser/web_contents.h
|
||||
@@ -129,11 +129,14 @@ class PrerenderHandle;
|
||||
|
||||
@@ -15,7 +15,7 @@ Note that we also need to manually update embedder's
|
||||
`api::WebContents::IsFullscreenForTabOrPending` value.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_frame_host_impl.cc b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
index 1718e3138961349bc79d3f0fc753097b125276e9..d67b02af700ae374d2321447db8e4b2b385beb9e 100644
|
||||
index 72d195aeff5f8197782f98ef60ecbd4d3be7d5a3..7c8c63f47e273acee7c39d78a921cf014a3d3c05 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
@@ -9104,6 +9104,17 @@ void RenderFrameHostImpl::EnterFullscreen(
|
||||
@@ -37,10 +37,10 @@ index 1718e3138961349bc79d3f0fc753097b125276e9..d67b02af700ae374d2321447db8e4b2b
|
||||
if (had_fullscreen_token && !GetView()->HasFocus()) {
|
||||
GetView()->Focus();
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index 3237246346af539a860ff3f71c75d20292df3f7b..d72fddcda30ea6d18180f7734ba958b8696355b4 100644
|
||||
index a2bf967fef8f92a2ed9854ac559c4b6f59e54f19..8593aa220a4e71450cedea0784fb4fa6843bacd4 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -4480,21 +4480,25 @@ KeyboardEventProcessingResult WebContentsImpl::PreHandleKeyboardEvent(
|
||||
@@ -4492,21 +4492,25 @@ KeyboardEventProcessingResult WebContentsImpl::PreHandleKeyboardEvent(
|
||||
const input::NativeWebKeyboardEvent& event) {
|
||||
OPTIONAL_TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("content.verbose"),
|
||||
"WebContentsImpl::PreHandleKeyboardEvent");
|
||||
@@ -80,7 +80,7 @@ index 3237246346af539a860ff3f71c75d20292df3f7b..d72fddcda30ea6d18180f7734ba958b8
|
||||
}
|
||||
|
||||
bool WebContentsImpl::HandleMouseEvent(const blink::WebMouseEvent& event) {
|
||||
@@ -4670,7 +4674,7 @@ void WebContentsImpl::EnterFullscreenMode(
|
||||
@@ -4682,7 +4686,7 @@ void WebContentsImpl::EnterFullscreenMode(
|
||||
OPTIONAL_TRACE_EVENT0("content", "WebContentsImpl::EnterFullscreenMode");
|
||||
DCHECK(CanEnterFullscreenMode(requesting_frame));
|
||||
DCHECK(requesting_frame->IsActive());
|
||||
|
||||
@@ -1,30 +0,0 @@
|
||||
#!/bin/bash
|
||||
set -euo pipefail
|
||||
|
||||
export XDG_SESSION_TYPE=wayland
|
||||
export WAYLAND_DISPLAY="${WAYLAND_DISPLAY:-wayland-99}"
|
||||
|
||||
if [[ -z "${XDG_RUNTIME_DIR:-}" ]]; then
|
||||
XDG_RUNTIME_DIR="$(mktemp -d)"
|
||||
chmod 700 "$XDG_RUNTIME_DIR"
|
||||
export XDG_RUNTIME_DIR
|
||||
trap 'kill "$WESTON_PID" >/dev/null 2>&1 || true; rm -rf "$XDG_RUNTIME_DIR"' EXIT
|
||||
else
|
||||
trap 'kill "$WESTON_PID" >/dev/null 2>&1 || true' EXIT
|
||||
fi
|
||||
|
||||
weston \
|
||||
--backend=headless-backend.so \
|
||||
--socket="$WAYLAND_DISPLAY" \
|
||||
--idle-time=0 \
|
||||
>/tmp/weston-headless.log 2>&1 &
|
||||
WESTON_PID=$!
|
||||
|
||||
for _ in {1..100}; do
|
||||
if [[ -S "$XDG_RUNTIME_DIR/$WAYLAND_DISPLAY" ]]; then
|
||||
break
|
||||
fi
|
||||
sleep 0.1
|
||||
done
|
||||
|
||||
node "$@" --ozone-platform=wayland
|
||||
@@ -1,41 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
echo "Mounting essential filesystems"
|
||||
mount -t proc proc /proc
|
||||
mount -t sysfs sys /sys
|
||||
mkdir -p /dev/pts
|
||||
mount -t devpts devpts /dev/pts
|
||||
mkdir -p /dev/shm
|
||||
mount -t tmpfs tmpfs /dev/shm
|
||||
mount -t tmpfs tmpfs /tmp
|
||||
chmod 1777 /tmp
|
||||
mount -t tmpfs tmpfs /run
|
||||
mkdir -p /run/dbus
|
||||
mkdir -p /run/user/0
|
||||
chmod 700 /run/user/0
|
||||
mount -t tmpfs tmpfs /var/tmp
|
||||
|
||||
echo "Setting up machine-id for D-Bus"
|
||||
cat /proc/sys/kernel/random/uuid | tr -d '-' > /etc/machine-id
|
||||
|
||||
echo "Setting system clock"
|
||||
date -s "$(cat /host-time)"
|
||||
|
||||
echo "Setting up networking"
|
||||
ip link set lo up
|
||||
ip link set eth0 up
|
||||
ip addr add 10.0.2.15/24 dev eth0
|
||||
ip route add default via 10.0.2.2
|
||||
echo "nameserver 10.0.2.3" > /etc/resolv.conf
|
||||
|
||||
export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
|
||||
export XDG_RUNTIME_DIR=/run/user/0
|
||||
|
||||
echo "Starting entrypoint"
|
||||
echo "System: $(uname -s) $(uname -r) $(uname -m), page size: $(getconf PAGESIZE) bytes"
|
||||
EXIT_CODE=$?
|
||||
echo $EXIT_CODE > /exit-code
|
||||
sync
|
||||
|
||||
echo "Powering off"
|
||||
echo o > /proc/sysrq-trigger
|
||||
@@ -1,89 +0,0 @@
|
||||
#!/bin/sh
|
||||
set -e
|
||||
|
||||
CONTAINER=""
|
||||
TESTFILES=""
|
||||
ARGS=""
|
||||
|
||||
while [ $# -gt 0 ]; do
|
||||
case "$1" in
|
||||
--container) CONTAINER="$2"; shift 2 ;;
|
||||
--testfiles) TESTFILES="$2"; shift 2 ;;
|
||||
--) shift; ARGS="$*"; break ;;
|
||||
*) echo "Unknown option: $1"; exit 1 ;;
|
||||
esac
|
||||
done
|
||||
|
||||
if [ -z "$CONTAINER" ]; then
|
||||
echo "Usage: $0 --container CONTAINER [-- ARGS...]"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "Installing QEMU system emulation and tools"
|
||||
sudo apt-get update && sudo apt-get install -y qemu-system-arm binutils
|
||||
|
||||
echo "Exporting container filesystem"
|
||||
CONTAINER_ID=$(docker create --platform linux/arm64 "$CONTAINER")
|
||||
ROOTFS_DIR=$(mktemp -d)
|
||||
docker export "$CONTAINER_ID" | sudo tar -xf - -C "$ROOTFS_DIR"
|
||||
docker rm -f "$CONTAINER_ID"
|
||||
|
||||
echo "Removing container image to free disk space"
|
||||
docker rmi "$CONTAINER" || true
|
||||
docker system prune -f || true
|
||||
|
||||
echo "Copying test files into root filesystem"
|
||||
if [ -n "$TESTFILES" ]; then
|
||||
sudo cp -r $TESTFILES "$ROOTFS_DIR/root/"
|
||||
fi
|
||||
|
||||
echo "Downloading Ubuntu 24.04 generic-64k kernel for ARM64"
|
||||
KERNEL_URL="http://ports.ubuntu.com/ubuntu-ports/pool/main/l/linux/linux-image-unsigned-6.8.0-90-generic-64k_6.8.0-90.91_arm64.deb"
|
||||
KERNEL_DIR=$(mktemp -d)
|
||||
curl -fL "$KERNEL_URL" -o "$KERNEL_DIR/kernel.deb"
|
||||
|
||||
echo "Extracting kernel"
|
||||
(cd "$KERNEL_DIR" && ar x kernel.deb && tar xf data.tar*)
|
||||
VMLINUZ="$KERNEL_DIR/boot/vmlinuz-6.8.0-90-generic-64k"
|
||||
if [ ! -f "$VMLINUZ" ]; then
|
||||
echo "Error: Could not find kernel at $VMLINUZ"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "Storing test arguments and installing init script"
|
||||
echo "$ARGS" > "$ROOTFS_DIR/test-args"
|
||||
date -u '+%Y-%m-%d %H:%M:%S' > "$ROOTFS_DIR/host-time"
|
||||
sudo mv "$ROOTFS_DIR/root/electron/scripts/qemu-init.sh" "$ROOTFS_DIR/init"
|
||||
sudo chmod +x "$ROOTFS_DIR/init"
|
||||
|
||||
echo "Creating disk image with root filesystem"
|
||||
DISK_IMG=$(mktemp)
|
||||
dd if=/dev/zero of="$DISK_IMG" bs=1M count=2048 status=none
|
||||
sudo mkfs.ext4 -q -d "$ROOTFS_DIR" "$DISK_IMG"
|
||||
sudo rm -rf "$ROOTFS_DIR"
|
||||
|
||||
echo "Starting QEMU VM with 64K page size kernel"
|
||||
timeout 1800 qemu-system-aarch64 \
|
||||
-M virt \
|
||||
-cpu max,pauth-impdef=on \
|
||||
-accel tcg,thread=multi \
|
||||
-m 4096 \
|
||||
-smp 2 \
|
||||
-kernel "$VMLINUZ" \
|
||||
-append "console=ttyAMA0 root=/dev/vda rw init=/init net.ifnames=0" \
|
||||
-drive file="$DISK_IMG",format=raw,if=virtio \
|
||||
-netdev user,id=net0 \
|
||||
-device virtio-net-pci,netdev=net0 \
|
||||
-nographic \
|
||||
-no-reboot \
|
||||
|| true
|
||||
|
||||
echo "Extracting test results from disk image"
|
||||
MOUNT_DIR=$(mktemp -d)
|
||||
sudo mount -o loop "$DISK_IMG" "$MOUNT_DIR"
|
||||
if [ -f "$MOUNT_DIR/root/results.xml" ]; then
|
||||
cp "$MOUNT_DIR/root/results.xml" "$TEST_DIR/results.xml"
|
||||
fi
|
||||
EXIT_CODE=$(cat "$MOUNT_DIR/exit-code" 2>/dev/null || echo 1)
|
||||
sudo umount "$MOUNT_DIR"
|
||||
exit $EXIT_CODE
|
||||
@@ -1,4 +0,0 @@
|
||||
spec/parse-features-string-spec.ts
|
||||
spec/types-spec.ts
|
||||
spec/version-bump-spec.ts
|
||||
spec/api-app-spec.ts
|
||||
@@ -14,7 +14,6 @@
|
||||
#include "base/process/launch.h"
|
||||
#include "base/process/process.h"
|
||||
#include "chrome/browser/browser_process.h"
|
||||
#include "content/browser/network_service_instance_impl.h" // nogncheck
|
||||
#include "content/public/browser/child_process_host.h"
|
||||
#include "content/public/browser/service_process_host.h"
|
||||
#include "content/public/common/result_codes.h"
|
||||
@@ -73,8 +72,7 @@ UtilityProcessWrapper::UtilityProcessWrapper(
|
||||
base::FilePath current_working_directory,
|
||||
bool use_plugin_helper,
|
||||
bool create_network_observer,
|
||||
bool disclaim_responsibility)
|
||||
: create_network_observer_(create_network_observer) {
|
||||
bool disclaim_responsibility) {
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
base::win::ScopedHandle stdout_write(nullptr);
|
||||
base::win::ScopedHandle stderr_write(nullptr);
|
||||
@@ -214,15 +212,32 @@ UtilityProcessWrapper::UtilityProcessWrapper(
|
||||
connector_->set_connection_error_handler(base::BindOnce(
|
||||
&UtilityProcessWrapper::CloseConnectorPort, weak_factory_.GetWeakPtr()));
|
||||
|
||||
params->url_loader_factory_params = CreateURLLoaderFactoryParams();
|
||||
mojo::PendingRemote<network::mojom::URLLoaderFactory> url_loader_factory;
|
||||
network::mojom::URLLoaderFactoryParamsPtr loader_params =
|
||||
network::mojom::URLLoaderFactoryParams::New();
|
||||
loader_params->process_id = network::OriginatingProcess::browser();
|
||||
loader_params->is_orb_enabled = false;
|
||||
loader_params->is_trusted = true;
|
||||
if (create_network_observer) {
|
||||
url_loader_network_observer_.emplace();
|
||||
loader_params->url_loader_network_observer =
|
||||
url_loader_network_observer_->Bind();
|
||||
}
|
||||
network::mojom::NetworkContext* network_context =
|
||||
g_browser_process->system_network_context_manager()->GetContext();
|
||||
network_context->CreateURLLoaderFactory(
|
||||
url_loader_factory.InitWithNewPipeAndPassReceiver(),
|
||||
std::move(loader_params));
|
||||
params->url_loader_factory = std::move(url_loader_factory);
|
||||
mojo::PendingRemote<network::mojom::HostResolver> host_resolver;
|
||||
network_context->CreateHostResolver(
|
||||
{}, host_resolver.InitWithNewPipeAndPassReceiver());
|
||||
params->host_resolver = std::move(host_resolver);
|
||||
params->use_network_observer_from_url_loader_factory =
|
||||
create_network_observer;
|
||||
|
||||
node_service_remote_->Initialize(std::move(params),
|
||||
receiver_.BindNewPipeAndPassRemote());
|
||||
|
||||
// Subscribe to Network Service process gone notifications.
|
||||
network_service_gone_subscription_ =
|
||||
content::RegisterNetworkServiceProcessGoneHandler(base::BindRepeating(
|
||||
&UtilityProcessWrapper::CreateAndSendURLLoaderFactory,
|
||||
weak_factory_.GetWeakPtr()));
|
||||
}
|
||||
|
||||
UtilityProcessWrapper::~UtilityProcessWrapper() {
|
||||
@@ -414,44 +429,6 @@ void UtilityProcessWrapper::OnV8FatalError(const std::string& location,
|
||||
EmitWithoutEvent("error", "FatalError", location, report);
|
||||
}
|
||||
|
||||
void UtilityProcessWrapper::CreateAndSendURLLoaderFactory(bool /* crashed */) {
|
||||
if (!node_service_remote_.is_connected())
|
||||
return;
|
||||
|
||||
node_service_remote_->UpdateURLLoaderFactory(CreateURLLoaderFactoryParams());
|
||||
}
|
||||
|
||||
node::mojom::URLLoaderFactoryParamsPtr
|
||||
UtilityProcessWrapper::CreateURLLoaderFactoryParams() {
|
||||
node::mojom::URLLoaderFactoryParamsPtr params =
|
||||
node::mojom::URLLoaderFactoryParams::New();
|
||||
mojo::PendingRemote<network::mojom::URLLoaderFactory> url_loader_factory;
|
||||
network::mojom::URLLoaderFactoryParamsPtr loader_params =
|
||||
network::mojom::URLLoaderFactoryParams::New();
|
||||
loader_params->process_id = network::OriginatingProcess::browser();
|
||||
loader_params->is_orb_enabled = false;
|
||||
loader_params->is_trusted = true;
|
||||
if (create_network_observer_) {
|
||||
url_loader_network_observer_.emplace();
|
||||
loader_params->url_loader_network_observer =
|
||||
url_loader_network_observer_->Bind();
|
||||
}
|
||||
|
||||
network::mojom::NetworkContext* network_context =
|
||||
g_browser_process->system_network_context_manager()->GetContext();
|
||||
network_context->CreateURLLoaderFactory(
|
||||
url_loader_factory.InitWithNewPipeAndPassReceiver(),
|
||||
std::move(loader_params));
|
||||
params->url_loader_factory = std::move(url_loader_factory);
|
||||
mojo::PendingRemote<network::mojom::HostResolver> host_resolver;
|
||||
network_context->CreateHostResolver(
|
||||
{}, host_resolver.InitWithNewPipeAndPassReceiver());
|
||||
params->host_resolver = std::move(host_resolver);
|
||||
params->use_network_observer_from_url_loader_factory =
|
||||
create_network_observer_;
|
||||
return params;
|
||||
}
|
||||
|
||||
// static
|
||||
raw_ptr<UtilityProcessWrapper> UtilityProcessWrapper::FromProcessId(
|
||||
base::ProcessId pid) {
|
||||
|
||||
@@ -9,7 +9,6 @@
|
||||
#include <memory>
|
||||
#include <string>
|
||||
|
||||
#include "base/callback_list.h"
|
||||
#include "base/containers/id_map.h"
|
||||
#include "base/environment.h"
|
||||
#include "base/memory/weak_ptr.h"
|
||||
@@ -100,11 +99,6 @@ class UtilityProcessWrapper final
|
||||
void OnServiceProcessDisconnected(uint32_t exit_code,
|
||||
const std::string& description);
|
||||
|
||||
// Creates and sends a new URLLoaderFactory to the utility process.
|
||||
// Called after Network Service restart to update the factory.
|
||||
void CreateAndSendURLLoaderFactory(bool crashed);
|
||||
node::mojom::URLLoaderFactoryParamsPtr CreateURLLoaderFactoryParams();
|
||||
|
||||
base::ProcessId pid_ = base::kNullProcessId;
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
// Non-owning handles, these will be closed when the
|
||||
@@ -117,14 +111,12 @@ class UtilityProcessWrapper final
|
||||
bool connector_closed_ = false;
|
||||
bool terminated_ = false;
|
||||
bool killed_ = false;
|
||||
bool create_network_observer_ = false;
|
||||
std::unique_ptr<mojo::Connector> connector_;
|
||||
blink::MessagePortDescriptor host_port_;
|
||||
mojo::Receiver<node::mojom::NodeServiceClient> receiver_{this};
|
||||
mojo::Remote<node::mojom::NodeService> node_service_remote_;
|
||||
std::optional<electron::URLLoaderNetworkObserver>
|
||||
url_loader_network_observer_;
|
||||
base::CallbackListSubscription network_service_gone_subscription_;
|
||||
base::WeakPtrFactory<UtilityProcessWrapper> weak_factory_{this};
|
||||
};
|
||||
|
||||
|
||||
@@ -30,7 +30,6 @@
|
||||
#include "components/proxy_config/pref_proxy_config_tracker_impl.h"
|
||||
#include "components/proxy_config/proxy_config_pref_names.h"
|
||||
#include "content/browser/blob_storage/chrome_blob_storage_context.h" // nogncheck
|
||||
#include "content/browser/network_service_instance_impl.h" // nogncheck
|
||||
#include "content/public/browser/browser_thread.h"
|
||||
#include "content/public/browser/cors_origin_pattern_setter.h"
|
||||
#include "content/public/browser/host_zoom_map.h"
|
||||
@@ -408,18 +407,10 @@ ElectronBrowserContext::ElectronBrowserContext(
|
||||
extension_system->FinishInitialization();
|
||||
}
|
||||
#endif
|
||||
|
||||
// Subscribe to Network Service process gone notifications to reset the
|
||||
// cached URLLoaderFactory when the Network Service crashes or restarts.
|
||||
network_service_gone_subscription_ =
|
||||
content::RegisterNetworkServiceProcessGoneHandler(base::BindRepeating(
|
||||
&ElectronBrowserContext::OnNetworkServiceProcessGone,
|
||||
weak_factory_.GetWeakPtr()));
|
||||
}
|
||||
|
||||
ElectronBrowserContext::~ElectronBrowserContext() {
|
||||
DCHECK_CURRENTLY_ON(BrowserThread::UI);
|
||||
|
||||
NotifyWillBeDestroyed();
|
||||
|
||||
// Notify any keyed services of browser context destruction.
|
||||
@@ -577,12 +568,6 @@ content::PreconnectManager* ElectronBrowserContext::GetPreconnectManager() {
|
||||
return preconnect_manager_.get();
|
||||
}
|
||||
|
||||
void ElectronBrowserContext::OnNetworkServiceProcessGone(bool /* crashed */) {
|
||||
// Clear the cached URLLoaderFactory so the next request creates a new one
|
||||
// from the new NetworkContext.
|
||||
url_loader_factory_.reset();
|
||||
}
|
||||
|
||||
scoped_refptr<network::SharedURLLoaderFactory>
|
||||
ElectronBrowserContext::GetURLLoaderFactory() {
|
||||
if (url_loader_factory_)
|
||||
|
||||
@@ -13,9 +13,7 @@
|
||||
#include <variant>
|
||||
#include <vector>
|
||||
|
||||
#include "base/callback_list.h"
|
||||
#include "base/files/file_path.h"
|
||||
#include "base/memory/weak_ptr.h"
|
||||
#include "content/public/browser/browser_context.h"
|
||||
#include "content/public/browser/media_stream_request.h"
|
||||
#include "mojo/public/cpp/bindings/remote.h"
|
||||
@@ -186,9 +184,6 @@ class ElectronBrowserContext : public content::BrowserContext {
|
||||
// Initialize pref registry.
|
||||
void InitPrefs();
|
||||
|
||||
// Called when the Network Service process crashes or restarts.
|
||||
void OnNetworkServiceProcessGone(bool crashed);
|
||||
|
||||
scoped_refptr<ValueMapPrefStore> in_memory_pref_store_;
|
||||
std::unique_ptr<CookieChangeNotifier> cookie_change_notifier_;
|
||||
std::unique_ptr<PrefService> prefs_;
|
||||
@@ -212,9 +207,6 @@ class ElectronBrowserContext : public content::BrowserContext {
|
||||
// Shared URLLoaderFactory.
|
||||
scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory_;
|
||||
|
||||
// Subscription to Network Service process gone notifications.
|
||||
base::CallbackListSubscription network_service_gone_subscription_;
|
||||
|
||||
network::mojom::SSLConfigPtr ssl_config_;
|
||||
mojo::Remote<network::mojom::SSLConfigClient> ssl_config_client_;
|
||||
|
||||
@@ -222,8 +214,6 @@ class ElectronBrowserContext : public content::BrowserContext {
|
||||
|
||||
// In-memory cache that holds objects that have been granted permissions.
|
||||
DevicePermissionMap granted_devices_;
|
||||
|
||||
base::WeakPtrFactory<ElectronBrowserContext> weak_factory_{this};
|
||||
};
|
||||
|
||||
} // namespace electron
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
#include "ui/base/clipboard/scoped_clipboard_writer.h"
|
||||
#include "ui/gfx/codec/png_codec.h"
|
||||
#include "ui/gfx/image/image.h"
|
||||
#include "url/gurl.h"
|
||||
|
||||
namespace {
|
||||
|
||||
@@ -199,7 +200,19 @@ void Clipboard::WriteText(const std::u16string& text,
|
||||
std::u16string Clipboard::ReadRTF(gin::Arguments* const args) {
|
||||
std::string data;
|
||||
ui::Clipboard* clipboard = ui::Clipboard::GetForCurrentThread();
|
||||
clipboard->ReadRTF(GetClipboardBuffer(args), /* data_dst = */ nullptr, &data);
|
||||
|
||||
base::RunLoop run_loop(base::RunLoop::Type::kNestableTasksAllowed);
|
||||
clipboard->ReadRTF(
|
||||
GetClipboardBuffer(args),
|
||||
/* data_dst = */ std::nullopt,
|
||||
base::BindOnce(
|
||||
[](std::string* out, base::OnceClosure quit, std::string result) {
|
||||
*out = std::move(result);
|
||||
std::move(quit).Run();
|
||||
},
|
||||
&data, run_loop.QuitClosure()));
|
||||
run_loop.Run();
|
||||
|
||||
return base::UTF8ToUTF16(data);
|
||||
}
|
||||
|
||||
@@ -209,16 +222,28 @@ void Clipboard::WriteRTF(const std::string& text, gin::Arguments* const args) {
|
||||
}
|
||||
|
||||
std::u16string Clipboard::ReadHTML(gin::Arguments* const args) {
|
||||
std::u16string data;
|
||||
std::u16string html;
|
||||
std::string url;
|
||||
uint32_t start;
|
||||
uint32_t end;
|
||||
uint32_t start = 0;
|
||||
uint32_t end = 0;
|
||||
ui::Clipboard* clipboard = ui::Clipboard::GetForCurrentThread();
|
||||
clipboard->ReadHTML(GetClipboardBuffer(args), /* data_dst = */ nullptr, &html,
|
||||
&url, &start, &end);
|
||||
data = html.substr(start, end - start);
|
||||
return data;
|
||||
|
||||
base::RunLoop run_loop(base::RunLoop::Type::kNestableTasksAllowed);
|
||||
clipboard->ReadHTML(
|
||||
GetClipboardBuffer(args),
|
||||
/* data_dst = */ std::nullopt,
|
||||
base::BindOnce(
|
||||
[](std::u16string* out_html, uint32_t* out_start, uint32_t* out_end,
|
||||
base::OnceClosure quit, std::u16string markup, GURL src_url,
|
||||
uint32_t fragment_start, uint32_t fragment_end) {
|
||||
*out_html = std::move(markup);
|
||||
*out_start = fragment_start;
|
||||
*out_end = fragment_end;
|
||||
std::move(quit).Run();
|
||||
},
|
||||
&html, &start, &end, run_loop.QuitClosure()));
|
||||
run_loop.Run();
|
||||
|
||||
return html.substr(start, end - start);
|
||||
}
|
||||
|
||||
void Clipboard::WriteHTML(const std::u16string& html,
|
||||
@@ -229,12 +254,25 @@ void Clipboard::WriteHTML(const std::u16string& html,
|
||||
|
||||
v8::Local<v8::Value> Clipboard::ReadBookmark(v8::Isolate* const isolate) {
|
||||
std::u16string title;
|
||||
std::string url;
|
||||
GURL url;
|
||||
auto dict = gin_helper::Dictionary::CreateEmpty(isolate);
|
||||
ui::Clipboard* clipboard = ui::Clipboard::GetForCurrentThread();
|
||||
clipboard->ReadBookmark(/* data_dst = */ nullptr, &title, &url);
|
||||
|
||||
base::RunLoop run_loop(base::RunLoop::Type::kNestableTasksAllowed);
|
||||
clipboard->ReadBookmark(
|
||||
/* data_dst = */ std::nullopt,
|
||||
base::BindOnce(
|
||||
[](std::u16string* out_title, GURL* out_url, base::OnceClosure quit,
|
||||
std::u16string title, GURL url) {
|
||||
*out_title = std::move(title);
|
||||
*out_url = std::move(url);
|
||||
std::move(quit).Run();
|
||||
},
|
||||
&title, &url, run_loop.QuitClosure()));
|
||||
run_loop.Run();
|
||||
|
||||
dict.Set("title", title);
|
||||
dict.Set("url", url);
|
||||
dict.Set("url", url.spec());
|
||||
return dict.GetHandle();
|
||||
}
|
||||
|
||||
|
||||
@@ -5,12 +5,8 @@
|
||||
#include "base/command_line.h"
|
||||
#include "base/dcheck_is_on.h"
|
||||
#include "base/logging.h"
|
||||
#include "content/browser/network_service_instance_impl.h" // nogncheck
|
||||
#include "content/public/browser/network_service_instance.h"
|
||||
#include "content/public/common/content_switches.h"
|
||||
#include "shell/common/callback_util.h"
|
||||
#include "shell/common/gin_helper/dictionary.h"
|
||||
#include "shell/common/gin_helper/promise.h"
|
||||
#include "shell/common/node_includes.h"
|
||||
#include "v8/include/v8.h"
|
||||
|
||||
@@ -45,18 +41,6 @@ std::string GetLoggingDestination() {
|
||||
return command_line->GetSwitchValueASCII(switches::kEnableLogging);
|
||||
}
|
||||
|
||||
v8::Local<v8::Promise> SimulateNetworkServiceCrash(v8::Isolate* isolate) {
|
||||
gin_helper::Promise<void> promise(isolate);
|
||||
v8::Local<v8::Promise> handle = promise.GetHandle();
|
||||
auto subscription = content::RegisterNetworkServiceProcessGoneHandler(
|
||||
electron::AdaptCallbackForRepeating(
|
||||
base::BindOnce([](gin_helper::Promise<void> promise,
|
||||
bool crashed) { promise.Resolve(); },
|
||||
std::move(promise))));
|
||||
content::RestartNetworkService();
|
||||
return handle;
|
||||
}
|
||||
|
||||
void Initialize(v8::Local<v8::Object> exports,
|
||||
v8::Local<v8::Value> unused,
|
||||
v8::Local<v8::Context> context,
|
||||
@@ -65,7 +49,6 @@ void Initialize(v8::Local<v8::Object> exports,
|
||||
gin_helper::Dictionary dict{isolate, exports};
|
||||
dict.SetMethod("log", &Log);
|
||||
dict.SetMethod("getLoggingDestination", &GetLoggingDestination);
|
||||
dict.SetMethod("simulateNetworkServiceCrash", &SimulateNetworkServiceCrash);
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
||||
@@ -484,7 +484,6 @@ void SimpleURLLoaderWrapper::Clone(
|
||||
|
||||
void SimpleURLLoaderWrapper::Cancel() {
|
||||
loader_.reset();
|
||||
url_loader_factory_.reset();
|
||||
pinned_wrapper_.Reset();
|
||||
pinned_chunk_pipe_getter_.Reset();
|
||||
// This ensures that no further callbacks will be called, so there's no need
|
||||
@@ -751,7 +750,6 @@ void SimpleURLLoaderWrapper::OnComplete(bool success) {
|
||||
// we would perform cleanup of the wrapper and we should bail out below.
|
||||
if (self) {
|
||||
loader_.reset();
|
||||
url_loader_factory_.reset();
|
||||
pinned_wrapper_.Reset();
|
||||
pinned_chunk_pipe_getter_.Reset();
|
||||
}
|
||||
|
||||
@@ -97,9 +97,8 @@ void ElectronExtensionsAPIProvider::RegisterPermissions(
|
||||
extensions::GetPermissionAliases());
|
||||
}
|
||||
|
||||
void ElectronExtensionsAPIProvider::RegisterManifestHandlers() {
|
||||
extensions::ManifestHandlerRegistry* registry =
|
||||
extensions::ManifestHandlerRegistry::Get();
|
||||
void ElectronExtensionsAPIProvider::RegisterManifestHandlers(
|
||||
extensions::ManifestHandlerRegistry* registry) {
|
||||
registry->RegisterHandler(
|
||||
std::make_unique<extensions::MinimumChromeVersionChecker>());
|
||||
}
|
||||
|
||||
@@ -32,7 +32,8 @@ class ElectronExtensionsAPIProvider : public extensions::ExtensionsAPIProvider {
|
||||
std::string_view GetAPISchema(const std::string& name) override;
|
||||
void RegisterPermissions(
|
||||
extensions::PermissionsInfo* permissions_info) override;
|
||||
void RegisterManifestHandlers() override;
|
||||
void RegisterManifestHandlers(
|
||||
extensions::ManifestHandlerRegistry* registry) override;
|
||||
};
|
||||
|
||||
} // namespace electron
|
||||
|
||||
@@ -31,7 +31,7 @@ namespace {
|
||||
bool HasWordCharacters(const std::u16string& text, size_t index) {
|
||||
base_icu::UChar32 code;
|
||||
while (index < text.size() &&
|
||||
base::ReadUnicodeCharacter(text.c_str(), text.size(), &index, &code)) {
|
||||
base::ReadUnicodeCharacter(text, &index, &code)) {
|
||||
++index;
|
||||
UErrorCode error = U_ZERO_ERROR;
|
||||
if (uscript_getScript(code, &error) != USCRIPT_COMMON)
|
||||
|
||||
@@ -122,9 +122,10 @@ void NodeService::Initialize(
|
||||
|
||||
ParentPort::GetInstance()->Initialize(std::move(params->port));
|
||||
|
||||
if (params->url_loader_factory_params) {
|
||||
UpdateURLLoaderFactory(std::move(params->url_loader_factory_params));
|
||||
}
|
||||
URLLoaderBundle::GetInstance()->SetURLLoaderFactory(
|
||||
std::move(params->url_loader_factory),
|
||||
mojo::Remote(std::move(params->host_resolver)),
|
||||
params->use_network_observer_from_url_loader_factory);
|
||||
|
||||
js_env_ = std::make_unique<JavascriptEnvironment>(node_bindings_->uv_loop());
|
||||
|
||||
@@ -207,12 +208,4 @@ void NodeService::Initialize(
|
||||
node_bindings_->StartPolling();
|
||||
}
|
||||
|
||||
void NodeService::UpdateURLLoaderFactory(
|
||||
node::mojom::URLLoaderFactoryParamsPtr params) {
|
||||
URLLoaderBundle::GetInstance()->SetURLLoaderFactory(
|
||||
std::move(params->url_loader_factory),
|
||||
mojo::Remote(std::move(params->host_resolver)),
|
||||
params->use_network_observer_from_url_loader_factory);
|
||||
}
|
||||
|
||||
} // namespace electron
|
||||
|
||||
@@ -65,8 +65,6 @@ class NodeService : public node::mojom::NodeService {
|
||||
void Initialize(node::mojom::NodeServiceParamsPtr params,
|
||||
mojo::PendingRemote<node::mojom::NodeServiceClient>
|
||||
client_pending_remote) override;
|
||||
void UpdateURLLoaderFactory(
|
||||
node::mojom::URLLoaderFactoryParamsPtr params) override;
|
||||
|
||||
private:
|
||||
// This needs to be initialized first so that it can be destroyed last
|
||||
|
||||
@@ -10,18 +10,14 @@ import "services/network/public/mojom/host_resolver.mojom";
|
||||
import "services/network/public/mojom/url_loader_factory.mojom";
|
||||
import "third_party/blink/public/mojom/messaging/message_port_descriptor.mojom";
|
||||
|
||||
struct URLLoaderFactoryParams {
|
||||
pending_remote<network.mojom.URLLoaderFactory> url_loader_factory;
|
||||
pending_remote<network.mojom.HostResolver> host_resolver;
|
||||
bool use_network_observer_from_url_loader_factory = false;
|
||||
};
|
||||
|
||||
struct NodeServiceParams {
|
||||
mojo_base.mojom.FilePath script;
|
||||
array<string> args;
|
||||
array<string> exec_args;
|
||||
blink.mojom.MessagePortDescriptor port;
|
||||
URLLoaderFactoryParams url_loader_factory_params;
|
||||
pending_remote<network.mojom.URLLoaderFactory> url_loader_factory;
|
||||
pending_remote<network.mojom.HostResolver> host_resolver;
|
||||
bool use_network_observer_from_url_loader_factory = false;
|
||||
};
|
||||
|
||||
interface NodeServiceClient {
|
||||
@@ -32,6 +28,4 @@ interface NodeServiceClient {
|
||||
interface NodeService {
|
||||
Initialize(NodeServiceParams params,
|
||||
pending_remote<NodeServiceClient> client_remote);
|
||||
|
||||
UpdateURLLoaderFactory(URLLoaderFactoryParams params);
|
||||
};
|
||||
|
||||
@@ -15,7 +15,7 @@ import { setTimeout } from 'node:timers/promises';
|
||||
import { promisify } from 'node:util';
|
||||
|
||||
import { collectStreamBody, getResponse } from './lib/net-helpers';
|
||||
import { ifdescribe, ifit, isWayland, listen, waitUntil } from './lib/spec-helpers';
|
||||
import { ifdescribe, ifit, listen, waitUntil } from './lib/spec-helpers';
|
||||
import { closeWindow, closeAllWindows } from './lib/window-helpers';
|
||||
|
||||
const fixturesPath = path.resolve(__dirname, 'fixtures');
|
||||
@@ -587,7 +587,7 @@ describe('app module', () => {
|
||||
});
|
||||
|
||||
// FIXME: re-enable this test on win32.
|
||||
ifit(process.platform !== 'win32' && !isWayland)('should emit render-process-gone event when renderer crashes', async () => {
|
||||
ifit(process.platform !== 'win32')('should emit render-process-gone event when renderer crashes', async () => {
|
||||
w = new BrowserWindow({
|
||||
show: false,
|
||||
webPreferences: {
|
||||
@@ -1437,7 +1437,7 @@ describe('app module', () => {
|
||||
|
||||
describe('getApplicationNameForProtocol()', () => {
|
||||
// TODO: Linux CI doesn't have registered http & https handlers
|
||||
ifit(!(process.env.CI && process.platform === 'linux') && !isWayland)('returns application names for common protocols', function () {
|
||||
ifit(!(process.env.CI && process.platform === 'linux'))('returns application names for common protocols', function () {
|
||||
// We can't expect particular app names here, but these protocols should
|
||||
// at least have _something_ registered. Except on our Linux CI
|
||||
// environment apparently.
|
||||
|
||||
@@ -56,13 +56,13 @@ ifdescribe(process.platform !== 'win32' || process.arch !== 'arm64')('clipboard
|
||||
|
||||
ifdescribe(process.platform !== 'linux')('clipboard.readBookmark', () => {
|
||||
it('returns title and url', () => {
|
||||
clipboard.writeBookmark('a title', 'https://electronjs.org');
|
||||
clipboard.writeBookmark('a title', 'https://electronjs.org/');
|
||||
|
||||
const readBookmark = clipboard.readBookmark();
|
||||
if (process.platform !== 'win32') {
|
||||
expect(readBookmark.title).to.equal('a title');
|
||||
}
|
||||
expect(clipboard.readBookmark().url).to.equal('https://electronjs.org');
|
||||
expect(clipboard.readBookmark().url).to.equal('https://electronjs.org/');
|
||||
|
||||
clipboard.writeText('no bookmark');
|
||||
expect(clipboard.readBookmark()).to.deep.equal({
|
||||
@@ -90,7 +90,7 @@ ifdescribe(process.platform !== 'win32' || process.arch !== 'arm64')('clipboard
|
||||
|
||||
describe('clipboard.write()', () => {
|
||||
it('returns data correctly', () => {
|
||||
const text = 'test';
|
||||
const text = 'https://electronjs.org/';
|
||||
const rtf = '{\\rtf1\\utf8 text}';
|
||||
const p = path.join(fixtures, 'assets', 'logo.png');
|
||||
const i = nativeImage.createFromPath(p);
|
||||
@@ -99,9 +99,9 @@ ifdescribe(process.platform !== 'win32' || process.arch !== 'arm64')('clipboard
|
||||
if (process.platform === 'darwin') {
|
||||
markup = '<meta charset=\'utf-8\'><b>Hi</b>';
|
||||
}
|
||||
const bookmark = { title: 'a title', url: 'test' };
|
||||
const bookmark = { title: 'a title', url: text };
|
||||
clipboard.write({
|
||||
text: 'test',
|
||||
text,
|
||||
html: '<b>Hi</b>',
|
||||
rtf: '{\\rtf1\\utf8 text}',
|
||||
bookmark: 'a title',
|
||||
|
||||
@@ -16,19 +16,19 @@ describe('nativeImage module', () => {
|
||||
height: 190
|
||||
};
|
||||
const image1x1 = {
|
||||
dataUrl: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADElEQVR4nGJhAAIAAAAA//8MRDDqAAAABklEQVQDAAAZAAXV/wceAAAAAElFTkSuQmCC',
|
||||
dataUrl: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADElEQVR4nGJiAAIAAAAA//81yQwvAAAABklEQVQDAAAPAAMkN33pAAAAAElFTkSuQmCC',
|
||||
path: path.join(fixturesPath, 'assets', '1x1.png'),
|
||||
height: 1,
|
||||
width: 1
|
||||
};
|
||||
const image2x2 = {
|
||||
dataUrl: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAIAAAD91JpzAAAAE0lEQVR4nGL5//8/AwMDCwMYAAAAAP//fpSNxQAAAAZJREFUAwAkPgMGdYltawAAAABJRU5ErkJggg==',
|
||||
dataUrl: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAIAAAD91JpzAAAAE0lEQVR4nGL5//8/AwMDEwMYAAAAAP//aYxtrAAAAAZJREFUAwAkMAMEkRkhTQAAAABJRU5ErkJggg==',
|
||||
path: path.join(fixturesPath, 'assets', '2x2.jpg'),
|
||||
height: 2,
|
||||
width: 2
|
||||
};
|
||||
const image3x3 = {
|
||||
dataUrl: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAADCAYAAABWKLW/AAABCWlDQ1BfAAB4nJWQsUrDUBSGv6oggqCDg4PDHVyVakEcnKoQXGOE6pbEGIUkDUlKVxdxFsRZxGfQBxFdXPoIDuLsfxswXTr0XM49H+f+nPtzoDVCsdCGNKsK1+ma3tm5WRzR0hmHH5Y500Oq389a+77F7LF0EZWh6rfSK/S5Rh6J1+Kae5aDmhPLwyqvxDeWC889FD+IV+MJDiY4zAurfxEfpMkgbHyzHGWnJ6r7yg1KXBy6GN0+KQMq8ZBr1SvRLttKg0eh90z6SyKsZVOP7D9p1A/M3ze94BHe7mD9q+ltPsPKLbx+NL1mh7lf+P/bmet0png2Y88OfZ2YRE4Mx3IVyqX12maHvT9v1kU+i+h9qQAAAA9JREFUeJxiYUACLDg5AAAAAP//htosgQAAAAZJREFUAwABXwANF48ZOwAAAABJRU5ErkJggg==',
|
||||
dataUrl: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAADCAYAAABWKLW/AAABCWlDQ1BfAAB4nJWQsUrDUBSGv6oggqCDg4PDHVyVakEcnKoQXGOE6pbEGIUkDUlKVxdxFsRZxGfQBxFdXPoIDuLsfxswXTr0XM49H+f+nPtzoDVCsdCGNKsK1+ma3tm5WRzR0hmHH5Y500Oq389a+77F7LF0EZWh6rfSK/S5Rh6J1+Kae5aDmhPLwyqvxDeWC889FD+IV+MJDiY4zAurfxEfpMkgbHyzHGWnJ6r7yg1KXBy6GN0+KQMq8ZBr1SvRLttKg0eh90z6SyKsZVOP7D9p1A/M3ze94BHe7mD9q+ltPsPKLbx+NL1mh7lf+P/bmet0png2Y88OfZ2YRE4Mx3IVyqX12maHvT9v1kU+i+h9qQAAAA9JREFUeJxiYkACTDg5AAAAAP//rSd/1QAAAAZJREFUAwAAwwAHu+/W1AAAAABJRU5ErkJggg==',
|
||||
path: path.join(fixturesPath, 'assets', '3x3.png'),
|
||||
height: 3,
|
||||
width: 3
|
||||
|
||||
@@ -1688,61 +1688,4 @@ describe('net module', () => {
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
describe('Network Service crash recovery', () => {
|
||||
const binding = process._linkedBinding('electron_common_testing');
|
||||
|
||||
it('should recover net.fetch after Network Service crash (main process)', async () => {
|
||||
const serverUrl = await respondOnce.toSingleURL((request, response) => {
|
||||
response.end('first');
|
||||
});
|
||||
const firstResponse = await net.fetch(serverUrl);
|
||||
expect(firstResponse.ok).to.be.true();
|
||||
expect(await firstResponse.text()).to.equal('first');
|
||||
|
||||
await binding.simulateNetworkServiceCrash();
|
||||
|
||||
// Wait for StoragePartitionImpl's NetworkContext disconnect handler to
|
||||
// fire and reinitialize the context in the new Network Service.
|
||||
await setTimeout(500);
|
||||
|
||||
const secondServerUrl = await respondOnce.toSingleURL((request, response) => {
|
||||
response.end('second');
|
||||
});
|
||||
const secondResponse = await net.fetch(secondServerUrl);
|
||||
expect(secondResponse.ok).to.be.true();
|
||||
expect(await secondResponse.text()).to.equal('second');
|
||||
});
|
||||
|
||||
it('should recover net.fetch after Network Service crash (utility process)', async () => {
|
||||
const child = utilityProcess.fork(path.join(fixturesPath, 'api', 'utility-process', 'network-restart-test.js'));
|
||||
await once(child, 'spawn');
|
||||
await once(child, 'message');
|
||||
|
||||
const firstServerUrl = await respondOnce.toSingleURL((request, response) => {
|
||||
response.end('utility-first');
|
||||
});
|
||||
child.postMessage({ type: 'fetch', url: firstServerUrl });
|
||||
const [firstResult] = await once(child, 'message');
|
||||
expect(firstResult.ok).to.be.true();
|
||||
expect(firstResult.body).to.equal('utility-first');
|
||||
|
||||
await binding.simulateNetworkServiceCrash();
|
||||
|
||||
// Needed for UpdateURLLoaderFactory IPC to propagate to the utility process
|
||||
// and for any in-flight requests to settle
|
||||
await setTimeout(500);
|
||||
|
||||
const secondServerUrl = await respondOnce.toSingleURL((request, response) => {
|
||||
response.end('utility-second');
|
||||
});
|
||||
child.postMessage({ type: 'fetch', url: secondServerUrl });
|
||||
const [secondResult] = await once(child, 'message');
|
||||
expect(secondResult.ok).to.be.true();
|
||||
expect(secondResult.body).to.equal('utility-second');
|
||||
|
||||
child.kill();
|
||||
await once(child, 'exit');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
@@ -1,24 +0,0 @@
|
||||
const { net } = require('electron');
|
||||
|
||||
process.parentPort.on('message', async (e) => {
|
||||
const { type, url } = e.data;
|
||||
|
||||
if (type === 'fetch') {
|
||||
try {
|
||||
const response = await net.fetch(url);
|
||||
const body = await response.text();
|
||||
process.parentPort.postMessage({
|
||||
ok: response.ok,
|
||||
status: response.status,
|
||||
body
|
||||
});
|
||||
} catch (error) {
|
||||
process.parentPort.postMessage({
|
||||
ok: false,
|
||||
error: error.message
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
process.parentPort.postMessage({ type: 'ready' });
|
||||
@@ -25,12 +25,6 @@ const addOnly = <T>(fn: Function): T => {
|
||||
export const ifit = (condition: boolean) => (condition ? it : addOnly<TestFunction>(it.skip));
|
||||
export const ifdescribe = (condition: boolean) => (condition ? describe : addOnly<SuiteFunction>(describe.skip));
|
||||
|
||||
export const isWayland = process.platform === 'linux' && (
|
||||
process.env.XDG_SESSION_TYPE === 'wayland' ||
|
||||
!!process.env.WAYLAND_DISPLAY ||
|
||||
process.argv.includes('--ozone-platform=wayland')
|
||||
);
|
||||
|
||||
type CleanupFunction = (() => void) | (() => Promise<void>)
|
||||
const cleanupFunctions: CleanupFunction[] = [];
|
||||
export async function runCleanupFunctions () {
|
||||
|
||||
Reference in New Issue
Block a user