mirror of
https://github.com/electron/electron.git
synced 2026-02-19 03:14:51 -05:00
Compare commits
27 Commits
testing-na
...
test-patch
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0f403b2468 | ||
|
|
3534923bd2 | ||
|
|
59063774d9 | ||
|
|
00e937013a | ||
|
|
ac0a67beea | ||
|
|
31055077fd | ||
|
|
66b8b79229 | ||
|
|
52e4e81d02 | ||
|
|
c0c2e5764b | ||
|
|
74bc52a559 | ||
|
|
243be0a638 | ||
|
|
4d5b086c3e | ||
|
|
24d6c28b5a | ||
|
|
1684b1edc6 | ||
|
|
f50fdd559d | ||
|
|
beb4582956 | ||
|
|
2f63917519 | ||
|
|
d06ed3364e | ||
|
|
7a96e135ac | ||
|
|
ba8ad4716b | ||
|
|
37608933ae | ||
|
|
edb939ae80 | ||
|
|
003c32331d | ||
|
|
18abeb3add | ||
|
|
dad6e130f5 | ||
|
|
8e8ea3ee8b | ||
|
|
6d2c72b14e |
2
.gitattributes
vendored
2
.gitattributes
vendored
@@ -2,6 +2,8 @@
|
||||
# files to be checked out with LF endings even if core.autocrlf is true.
|
||||
*.patch text eol=lf
|
||||
patches/**/.patches merge=union
|
||||
# Target file for patch has CRLF line endings
|
||||
patches/nan/apply_allcan_read_write_test.patch eol=crlf
|
||||
|
||||
# Source code and markdown files should always use LF as line ending.
|
||||
*.c text eol=lf
|
||||
|
||||
18
.github/actions/build-electron/action.yml
vendored
18
.github/actions/build-electron/action.yml
vendored
@@ -23,6 +23,9 @@ inputs:
|
||||
upload-to-storage:
|
||||
description: 'Upload to storage'
|
||||
required: true
|
||||
is-asan:
|
||||
description: 'The ASan Linux build'
|
||||
required: false
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
@@ -56,7 +59,7 @@ runs:
|
||||
run: |
|
||||
cd src
|
||||
e build electron:electron_dist_zip -j $NUMBER_OF_NINJA_PROCESSES
|
||||
if [ "${{ env.CHECK_DIST_MANIFEST }}" = "true" ]; then
|
||||
if [ "${{ inputs.is-asan }}" != "true" ]; then
|
||||
target_os=${{ inputs.target-platform == 'linux' && 'linux' || 'mac'}}
|
||||
if [ "${{ inputs.artifact-platform }}" = "mas" ]; then
|
||||
target_os="${target_os}_mas"
|
||||
@@ -181,6 +184,15 @@ runs:
|
||||
echo 'Uploading Electron release distribution to GitHub releases'
|
||||
script/release/uploaders/upload.py --verbose
|
||||
fi
|
||||
- name: Generate Artifact Key
|
||||
shell: bash
|
||||
run: |
|
||||
if [ "${{ inputs.is-asan }}" = "true" ]; then
|
||||
ARTIFACT_KEY=${{ inputs.artifact-platform }}_${{ env.TARGET_ARCH }}_asan
|
||||
else
|
||||
ARTIFACT_KEY=${{ inputs.artifact-platform }}_${{ env.TARGET_ARCH }}
|
||||
fi
|
||||
echo "ARTIFACT_KEY=$ARTIFACT_KEY" >> $GITHUB_ENV
|
||||
# The current generated_artifacts_<< artifact.key >> name was taken from CircleCI
|
||||
# to ensure we don't break anything, but we may be able to improve that.
|
||||
- name: Move all Generated Artifacts to Upload Folder ${{ inputs.step-suffix }}
|
||||
@@ -189,10 +201,10 @@ runs:
|
||||
- name: Upload Generated Artifacts ${{ inputs.step-suffix }}
|
||||
uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808
|
||||
with:
|
||||
name: generated_artifacts_${{ inputs.artifact-platform }}_${{ env.TARGET_ARCH }}
|
||||
name: generated_artifacts_${{ env.ARTIFACT_KEY }}
|
||||
path: ./generated_artifacts_${{ inputs.artifact-platform }}_${{ env.TARGET_ARCH }}
|
||||
- name: Upload Src Artifacts ${{ inputs.step-suffix }}
|
||||
uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808
|
||||
with:
|
||||
name: src_artifacts_${{ inputs.artifact-platform }}_${{ env.TARGET_ARCH }}
|
||||
name: src_artifacts_${{ env.ARTIFACT_KEY }}
|
||||
path: ./src_artifacts_${{ inputs.artifact-platform }}_${{ env.TARGET_ARCH }}
|
||||
|
||||
14
.github/actions/restore-cache-azcopy/action.yml
vendored
14
.github/actions/restore-cache-azcopy/action.yml
vendored
@@ -4,7 +4,15 @@ runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: Obtain SAS Key
|
||||
uses: actions/cache/restore@v4
|
||||
continue-on-error: true
|
||||
uses: actions/cache/restore@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9
|
||||
with:
|
||||
path: |
|
||||
sas-token
|
||||
key: sas-key-${{ github.run_number }}-1
|
||||
- name: Obtain SAS Key
|
||||
continue-on-error: true
|
||||
uses: actions/cache/restore@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9
|
||||
with:
|
||||
path: |
|
||||
sas-token
|
||||
@@ -20,6 +28,10 @@ runs:
|
||||
retry_on: error
|
||||
command: |
|
||||
sas_token=$(cat sas-token)
|
||||
if [ -z $sas-token ]; then
|
||||
echo "SAS Token not found; exiting src cache download early..."
|
||||
exit 1
|
||||
fi
|
||||
azcopy copy \
|
||||
"https://${{ env.AZURE_AKS_CACHE_STORAGE_ACCOUNT }}.file.core.windows.net/${{ env.AZURE_AKS_CACHE_SHARE_NAME }}/${{ env.CACHE_PATH }}?$sas_token" $DEPSHASH.tar
|
||||
- name: Clean SAS Key
|
||||
|
||||
80
.github/workflows/build.yml
vendored
80
.github/workflows/build.yml
vendored
@@ -23,17 +23,22 @@ on:
|
||||
description: 'Skip lint check'
|
||||
default: false
|
||||
required: false
|
||||
# push:
|
||||
# pull_request:
|
||||
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
- '[1-9][0-9]-x-y'
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
changes:
|
||||
setup:
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
pull-requests: read
|
||||
outputs:
|
||||
docs: ${{ steps.filter.outputs.docs }}
|
||||
src: ${{ steps.filter.outputs.src }}
|
||||
build-image-sha: ${{ steps.set-output.outputs.build-image-sha }}
|
||||
docs-only: ${{ steps.set-output.outputs.docs-only }}
|
||||
steps:
|
||||
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 #v4.0.2
|
||||
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
|
||||
@@ -44,37 +49,49 @@ jobs:
|
||||
- 'docs/**'
|
||||
src:
|
||||
- '!docs/**'
|
||||
- name: Set Outputs for Build Image SHA & Docs Only
|
||||
id: set-output
|
||||
run: |
|
||||
if [ -z "${{ inputs.build-image-sha }}" ]; then
|
||||
echo "build-image-sha=cf814a4d2501e8e843caea071a6b70a48e78b855" >> "$GITHUB_OUTPUT"
|
||||
else
|
||||
echo "build-image-sha=${{ inputs.build-image-sha }}" >> "$GITHUB_OUTPUT"
|
||||
fi
|
||||
echo "docs-only=${{ steps.filter.outputs.docs == 'true' && steps.filter.outputs.src == 'false' }}" >> "$GITHUB_OUTPUT"
|
||||
|
||||
# Lint Jobs
|
||||
lint:
|
||||
needs: setup
|
||||
if: ${{ !inputs.skip-lint }}
|
||||
uses: ./.github/workflows/pipeline-electron-lint.yml
|
||||
with:
|
||||
container: '{"image":"ghcr.io/electron/build:${{ inputs.build-image-sha }}","options":"--user root"}'
|
||||
container: '{"image":"ghcr.io/electron/build:${{ needs.setup.outputs.build-image-sha }}","options":"--user root"}'
|
||||
secrets: inherit
|
||||
|
||||
# Docs Only Jobs
|
||||
docs-only:
|
||||
needs: changes
|
||||
if: ${{ needs.changes.outputs.docs == 'true' && needs.changes.outputs.src == 'false'}}
|
||||
needs: setup
|
||||
if: ${{ needs.setup.outputs.docs-only == 'true' }}
|
||||
uses: ./.github/workflows/pipeline-electron-docs-only.yml
|
||||
with:
|
||||
container: '{"image":"ghcr.io/electron/build:${{ inputs.build-image-sha }}","options":"--user root"}'
|
||||
container: '{"image":"ghcr.io/electron/build:${{ needs.setup.outputs.build-image-sha }}","options":"--user root"}'
|
||||
secrets: inherit
|
||||
|
||||
# Checkout Jobs
|
||||
checkout-macos:
|
||||
needs: changes
|
||||
if: ${{ needs.changes.outputs.src == 'true' && !inputs.skip-macos}}
|
||||
needs: setup
|
||||
if: ${{ needs.setup.outputs.src == 'true' && !inputs.skip-macos}}
|
||||
runs-on: aks-linux-large
|
||||
container:
|
||||
image: ghcr.io/electron/build:${{ inputs.build-image-sha }}
|
||||
image: ghcr.io/electron/build:${{ needs.setup.outputs.build-image-sha }}
|
||||
options: --user root
|
||||
volumes:
|
||||
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
|
||||
- /var/run/sas:/var/run/sas
|
||||
env:
|
||||
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_mac=True --custom-var=host_os=mac'
|
||||
outputs:
|
||||
build-image-sha: ${{ needs.setup.outputs.build-image-sha }}
|
||||
steps:
|
||||
- name: Checkout Electron
|
||||
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332
|
||||
@@ -87,17 +104,19 @@ jobs:
|
||||
generate-sas-token: 'true'
|
||||
|
||||
checkout-linux:
|
||||
needs: changes
|
||||
if: ${{ needs.changes.outputs.src == 'true' && !inputs.skip-linux}}
|
||||
needs: setup
|
||||
if: ${{ needs.setup.outputs.src == 'true' && !inputs.skip-linux}}
|
||||
runs-on: aks-linux-large
|
||||
container:
|
||||
image: ghcr.io/electron/build:${{ inputs.build-image-sha }}
|
||||
image: ghcr.io/electron/build:${{ needs.setup.outputs.build-image-sha }}
|
||||
options: --user root
|
||||
volumes:
|
||||
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
|
||||
- /var/run/sas:/var/run/sas
|
||||
env:
|
||||
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_arm=True --custom-var=checkout_arm64=True'
|
||||
outputs:
|
||||
build-image-sha: ${{ needs.setup.outputs.build-image-sha}}
|
||||
steps:
|
||||
- name: Checkout Electron
|
||||
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332
|
||||
@@ -154,8 +173,8 @@ jobs:
|
||||
with:
|
||||
build-runs-on: aks-linux-large
|
||||
test-runs-on: aks-linux-medium
|
||||
build-container: '{"image":"ghcr.io/electron/build:${{ inputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
|
||||
test-container: '{"image":"ghcr.io/electron/build:${{ inputs.build-image-sha }}","options":"--user root --privileged --init"}'
|
||||
build-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
|
||||
test-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root --privileged --init"}'
|
||||
target-platform: linux
|
||||
target-arch: x64
|
||||
is-release: false
|
||||
@@ -163,6 +182,27 @@ jobs:
|
||||
generate-symbols: false
|
||||
upload-to-storage: '0'
|
||||
secrets: inherit
|
||||
|
||||
linux-x64-asan:
|
||||
permissions:
|
||||
contents: read
|
||||
issues: read
|
||||
pull-requests: read
|
||||
uses: ./.github/workflows/pipeline-electron-build-and-test.yml
|
||||
needs: checkout-linux
|
||||
with:
|
||||
build-runs-on: aks-linux-large
|
||||
test-runs-on: aks-linux-medium
|
||||
build-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
|
||||
test-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root --privileged --init"}'
|
||||
target-platform: linux
|
||||
target-arch: x64
|
||||
is-release: false
|
||||
gn-build-type: testing
|
||||
generate-symbols: false
|
||||
upload-to-storage: '0'
|
||||
is-asan: true
|
||||
secrets: inherit
|
||||
|
||||
linux-arm:
|
||||
permissions:
|
||||
@@ -174,8 +214,8 @@ jobs:
|
||||
with:
|
||||
build-runs-on: aks-linux-large
|
||||
test-runs-on: aks-linux-arm-medium
|
||||
build-container: '{"image":"ghcr.io/electron/build:${{ inputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
|
||||
test-container: '{"image":"ghcr.io/electron/test:arm32v7-${{ inputs.build-image-sha }}","options":"--user root --privileged --init","volumes":["/home/runner/externals:/mnt/runner-externals"]}'
|
||||
build-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
|
||||
test-container: '{"image":"ghcr.io/electron/test:arm32v7-${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root --privileged --init","volumes":["/home/runner/externals:/mnt/runner-externals"]}'
|
||||
target-platform: linux
|
||||
target-arch: arm
|
||||
is-release: false
|
||||
@@ -194,8 +234,8 @@ jobs:
|
||||
with:
|
||||
build-runs-on: aks-linux-large
|
||||
test-runs-on: aks-linux-arm-medium
|
||||
build-container: '{"image":"ghcr.io/electron/build:${{ inputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
|
||||
test-container: '{"image":"ghcr.io/electron/test:arm64v8-${{ inputs.build-image-sha }}","options":"--user root --privileged --init"}'
|
||||
build-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
|
||||
test-container: '{"image":"ghcr.io/electron/test:arm64v8-${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root --privileged --init"}'
|
||||
target-platform: linux
|
||||
target-arch: arm64
|
||||
is-release: false
|
||||
|
||||
2
.github/workflows/linux-publish.yml
vendored
2
.github/workflows/linux-publish.yml
vendored
@@ -27,7 +27,7 @@ jobs:
|
||||
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
|
||||
- /var/run/sas:/var/run/sas
|
||||
env:
|
||||
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_mac=True --custom-var=host_os=mac'
|
||||
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_arm=True --custom-var=checkout_arm64=True'
|
||||
steps:
|
||||
- name: Checkout Electron
|
||||
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332
|
||||
|
||||
@@ -49,6 +49,11 @@ on:
|
||||
required: true
|
||||
type: string
|
||||
default: '0'
|
||||
is-asan:
|
||||
description: 'Building the Address Sanitizer (ASan) Linux build'
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
|
||||
concurrency:
|
||||
group: electron-build-and-test-and-nan-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref }}
|
||||
@@ -75,6 +80,7 @@ jobs:
|
||||
check-runs-on: ${{ inputs.build-runs-on }}
|
||||
check-container: ${{ inputs.build-container }}
|
||||
gn-build-type: ${{ inputs.gn-build-type }}
|
||||
is-asan: ${{ inputs.is-asan }}
|
||||
secrets: inherit
|
||||
test:
|
||||
uses: ./.github/workflows/pipeline-segment-electron-test.yml
|
||||
|
||||
@@ -49,6 +49,11 @@ on:
|
||||
required: true
|
||||
type: string
|
||||
default: '0'
|
||||
is-asan:
|
||||
description: 'Building the Address Sanitizer (ASan) Linux build'
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
|
||||
concurrency:
|
||||
group: electron-build-and-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref }}
|
||||
@@ -71,6 +76,7 @@ jobs:
|
||||
gn-build-type: ${{ inputs.gn-build-type }}
|
||||
generate-symbols: ${{ inputs.generate-symbols }}
|
||||
upload-to-storage: ${{ inputs.upload-to-storage }}
|
||||
is-asan: ${{ inputs.is-asan}}
|
||||
secrets: inherit
|
||||
gn-check:
|
||||
uses: ./.github/workflows/pipeline-segment-electron-gn-check.yml
|
||||
@@ -80,6 +86,7 @@ jobs:
|
||||
check-runs-on: ${{ inputs.build-runs-on }}
|
||||
check-container: ${{ inputs.build-container }}
|
||||
gn-build-type: ${{ inputs.gn-build-type }}
|
||||
is-asan: ${{ inputs.is-asan }}
|
||||
secrets: inherit
|
||||
test:
|
||||
uses: ./.github/workflows/pipeline-segment-electron-test.yml
|
||||
@@ -89,4 +96,5 @@ jobs:
|
||||
target-platform: ${{ inputs.target-platform }}
|
||||
test-runs-on: ${{ inputs.test-runs-on }}
|
||||
test-container: ${{ inputs.test-container }}
|
||||
is-asan: ${{ inputs.is-asan}}
|
||||
secrets: inherit
|
||||
|
||||
@@ -44,10 +44,15 @@ on:
|
||||
required: true
|
||||
type: string
|
||||
default: '0'
|
||||
is-asan:
|
||||
description: 'Building the Address Sanitizer (ASan) Linux build'
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
|
||||
|
||||
concurrency:
|
||||
group: electron-build-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref }}
|
||||
group: electron-build-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ inputs.is-asan }}-${{ github.ref }}
|
||||
cancel-in-progress: ${{ github.ref != 'refs/heads/main' && !endsWith(github.ref, '-x-y') }}
|
||||
|
||||
env:
|
||||
@@ -102,6 +107,8 @@ jobs:
|
||||
fi
|
||||
elif [ "${{ inputs.target-arch }}" = "arm64" ]; then
|
||||
GN_EXTRA_ARGS='target_cpu="arm64" fatal_linker_warnings=false enable_linux_installer=false'
|
||||
elif [ "${{ inputs.is-asan }}" = true ]; then
|
||||
GN_EXTRA_ARGS='is_asan=true'
|
||||
fi
|
||||
echo "GN_EXTRA_ARGS=$GN_EXTRA_ARGS" >> $GITHUB_ENV
|
||||
- name: Get Depot Tools
|
||||
@@ -183,6 +190,7 @@ jobs:
|
||||
is-release: '${{ inputs.is-release }}'
|
||||
generate-symbols: '${{ inputs.generate-symbols }}'
|
||||
upload-to-storage: '${{ inputs.upload-to-storage }}'
|
||||
is-asan: '${{ inputs.is-asan }}'
|
||||
- name: Set GN_EXTRA_ARGS for MAS Build
|
||||
if: ${{ inputs.target-platform == 'macos' }}
|
||||
run: |
|
||||
|
||||
@@ -25,9 +25,14 @@ on:
|
||||
required: true
|
||||
type: string
|
||||
default: testing
|
||||
is-asan:
|
||||
description: 'Building the Address Sanitizer (ASan) Linux build'
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
|
||||
concurrency:
|
||||
group: electron-gn-check-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref }}
|
||||
group: electron-gn-check-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ inputs.is-asan }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
env:
|
||||
|
||||
@@ -20,9 +20,14 @@ on:
|
||||
description: 'JSON container information for aks runs-on'
|
||||
required: false
|
||||
default: '{"image":null}'
|
||||
is-asan:
|
||||
description: 'Building the Address Sanitizer (ASan) Linux build'
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
|
||||
concurrency:
|
||||
group: electron-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref }}
|
||||
group: electron-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ inputs.is-asan }}-${{ github.ref }}
|
||||
cancel-in-progress: ${{ github.ref != 'refs/heads/main' && !endsWith(github.ref, '-x-y') }}
|
||||
|
||||
permissions:
|
||||
@@ -47,6 +52,7 @@ jobs:
|
||||
env:
|
||||
BUILD_TYPE: ${{ matrix.build-type }}
|
||||
TARGET_ARCH: ${{ inputs.target-arch }}
|
||||
ARTIFACT_KEY: ${{ matrix.build-type }}_${{ inputs.target-arch }}
|
||||
steps:
|
||||
- name: Fix node20 on arm32 runners
|
||||
if: ${{ inputs.target-arch == 'arm' }}
|
||||
@@ -112,16 +118,22 @@ jobs:
|
||||
touch .disable_auto_update
|
||||
- name: Add Depot Tools to PATH
|
||||
run: echo "$(pwd)/depot_tools" >> $GITHUB_PATH
|
||||
- name: Load ASan specific environment variables
|
||||
if: ${{ inputs.is-asan == true }}
|
||||
run: |
|
||||
echo "ARTIFACT_KEY=${{ matrix.build-type }}_${{ inputs.target-arch }}_asan" >> $GITHUB_ENV
|
||||
echo "DISABLE_CRASH_REPORTER_TESTS=true" >> $GITHUB_ENV
|
||||
echo "IS_ASAN=true" >> $GITHUB_ENV
|
||||
- name: Download Generated Artifacts
|
||||
uses: actions/download-artifact@65a9edc5881444af0b9093a5e628f2fe47ea3b2e
|
||||
with:
|
||||
name: generated_artifacts_${{ matrix.build-type }}_${{ inputs.target-arch }}
|
||||
name: generated_artifacts_${{ env.ARTIFACT_KEY }}
|
||||
path: ./generated_artifacts_${{ matrix.build-type }}_${{ inputs.target-arch }}
|
||||
- name: Download Src Artifacts
|
||||
uses: actions/download-artifact@65a9edc5881444af0b9093a5e628f2fe47ea3b2e
|
||||
with:
|
||||
name: src_artifacts_${{ matrix.build-type }}_${{ env.TARGET_ARCH }}
|
||||
path: ./src_artifacts_${{ matrix.build-type }}_${{ env.TARGET_ARCH }}
|
||||
name: src_artifacts_${{ env.ARTIFACT_KEY }}
|
||||
path: ./src_artifacts_${{ matrix.build-type }}_${{ inputs.target-arch }}
|
||||
- name: Restore Generated Artifacts
|
||||
run: ./src/electron/script/actions/restore-artifacts.sh
|
||||
- name: Unzip Dist, Mksnapshot & Chromedriver
|
||||
@@ -130,12 +142,12 @@ jobs:
|
||||
unzip -:o dist.zip
|
||||
unzip -:o chromedriver.zip
|
||||
unzip -:o mksnapshot.zip
|
||||
# - name: Import & Trust Self-Signed Codesigning Cert on MacOS
|
||||
# if: ${{ inputs.target-platform == 'macos' }}
|
||||
# run: |
|
||||
# sudo security authorizationdb write com.apple.trust-settings.admin allow
|
||||
# cd src/electron
|
||||
# ./script/codesign/generate-identity.sh
|
||||
- name: Import & Trust Self-Signed Codesigning Cert on MacOS
|
||||
if: ${{ inputs.target-platform == 'macos' && inputs.target-arch == 'x64' }}
|
||||
run: |
|
||||
sudo security authorizationdb write com.apple.trust-settings.admin allow
|
||||
cd src/electron
|
||||
./script/codesign/generate-identity.sh
|
||||
- name: Run Electron Tests
|
||||
shell: bash
|
||||
env:
|
||||
@@ -159,7 +171,21 @@ jobs:
|
||||
chown -R :builduser . && chmod -R g+w .
|
||||
chmod 4755 ../out/Default/chrome-sandbox
|
||||
runuser -u builduser -- git config --global --add safe.directory $(pwd)
|
||||
runuser -u builduser -- xvfb-run script/actions/run-tests.sh script/yarn test --runners=main --trace-uncaught --enable-logging --files $tests_files
|
||||
if [ "${{ inputs.is-asan }}" == "true" ]; then
|
||||
cd ..
|
||||
ASAN_SYMBOLIZE="$PWD/tools/valgrind/asan/asan_symbolize.py --executable-path=$PWD/out/Default/electron"
|
||||
export ASAN_OPTIONS="symbolize=0 handle_abort=1"
|
||||
export G_SLICE=always-malloc
|
||||
export NSS_DISABLE_ARENA_FREE_LIST=1
|
||||
export NSS_DISABLE_UNLOAD=1
|
||||
export LLVM_SYMBOLIZER_PATH=$PWD/third_party/llvm-build/Release+Asserts/bin/llvm-symbolizer
|
||||
export MOCHA_TIMEOUT=180000
|
||||
echo "Piping output to ASAN_SYMBOLIZE ($ASAN_SYMBOLIZE)"
|
||||
cd electron
|
||||
runuser -u builduser -- xvfb-run script/actions/run-tests.sh script/yarn test --runners=main --trace-uncaught --enable-logging --files $tests_files | $ASAN_SYMBOLIZE
|
||||
else
|
||||
runuser -u builduser -- xvfb-run script/actions/run-tests.sh script/yarn test --runners=main --trace-uncaught --enable-logging --files $tests_files
|
||||
fi
|
||||
fi
|
||||
- name: Wait for active SSH sessions
|
||||
if: always() && !cancelled()
|
||||
|
||||
2
DEPS
2
DEPS
@@ -2,7 +2,7 @@ gclient_gn_args_from = 'src'
|
||||
|
||||
vars = {
|
||||
'chromium_version':
|
||||
'128.0.6544.0',
|
||||
'128.0.6555.0',
|
||||
'node_version':
|
||||
'v20.14.0',
|
||||
'nan_version':
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
> Get system preferences.
|
||||
|
||||
Process: [Main](../glossary.md#main-process)
|
||||
Process: [Main](../glossary.md#main-process), [Utility](../glossary.md#utility-process)
|
||||
|
||||
```js
|
||||
const { systemPreferences } = require('electron')
|
||||
|
||||
@@ -125,7 +125,7 @@ in the form included below:
|
||||
]
|
||||
```
|
||||
|
||||
::: info
|
||||
:::info
|
||||
|
||||
For an implementation example, see [`src/resedit.ts`](https://github.com/electron/packager/blob/main/src/resedit.ts)
|
||||
in the Electron Packager code.
|
||||
|
||||
@@ -350,6 +350,7 @@ auto_filenames = {
|
||||
|
||||
utility_bundle_deps = [
|
||||
"lib/browser/api/net-fetch.ts",
|
||||
"lib/browser/api/system-preferences.ts",
|
||||
"lib/browser/message-port-main.ts",
|
||||
"lib/common/api/net-client-request.ts",
|
||||
"lib/common/define-properties.ts",
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
// Utility side modules, please sort alphabetically.
|
||||
export const utilityNodeModuleList: ElectronInternal.ModuleEntry[] = [
|
||||
{ name: 'net', loader: () => require('./net') }
|
||||
{ name: 'net', loader: () => require('./net') },
|
||||
{ name: 'systemPreferences', loader: () => require('@electron/internal/browser/api/system-preferences') }
|
||||
];
|
||||
|
||||
@@ -17,6 +17,14 @@ const { makeRequireFunction } = __non_webpack_require__('internal/modules/helper
|
||||
global.module = new Module('electron/js2c/worker_init');
|
||||
global.require = makeRequireFunction(global.module);
|
||||
|
||||
// See WebWorkerObserver::WorkerScriptReadyForEvaluation.
|
||||
if ((globalThis as any).blinkfetch) {
|
||||
const keys = ['fetch', 'Response', 'FormData', 'Request', 'Headers'];
|
||||
for (const key of keys) {
|
||||
(globalThis as any)[key] = (globalThis as any)[`blink${key}`];
|
||||
}
|
||||
}
|
||||
|
||||
// Set the __filename to the path of html file if it is file: protocol.
|
||||
// NB. 'self' isn't defined in an AudioWorklet.
|
||||
if (typeof self !== 'undefined' && self.location.protocol === 'file:') {
|
||||
|
||||
@@ -19,7 +19,6 @@
|
||||
"@types/chai-as-promised": "^7.1.3",
|
||||
"@types/dirty-chai": "^2.0.2",
|
||||
"@types/express": "^4.17.13",
|
||||
"@types/fs-extra": "^9.0.1",
|
||||
"@types/minimist": "^1.2.0",
|
||||
"@types/mocha": "^7.0.2",
|
||||
"@types/node": "^20.9.0",
|
||||
@@ -50,7 +49,6 @@
|
||||
"events": "^3.2.0",
|
||||
"express": "^4.19.2",
|
||||
"folder-hash": "^2.1.1",
|
||||
"fs-extra": "^9.0.1",
|
||||
"got": "^11.8.5",
|
||||
"husky": "^8.0.1",
|
||||
"lint": "^1.1.2",
|
||||
|
||||
@@ -23,10 +23,10 @@ index 902d84ad70adc9496f3af989465a99b6f44b077a..3ce043eea32c41130aa59ab8570a05b3
|
||||
int32_t world_id) {}
|
||||
virtual void DidClearWindowObject() {}
|
||||
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
|
||||
index 8e023991b3fdd05ceb60cf9f87f8e9f359570226..946e303709a16706da11ab9729e7d5e962effbee 100644
|
||||
index 9601b8a33c5c0b77143462395a30da1d3f515efe..6dfad272ba75c6680d00539b0e45b41de5637793 100644
|
||||
--- a/content/renderer/render_frame_impl.cc
|
||||
+++ b/content/renderer/render_frame_impl.cc
|
||||
@@ -4695,6 +4695,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local<v8::Context> context,
|
||||
@@ -4692,6 +4692,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local<v8::Context> context,
|
||||
observer.DidCreateScriptContext(context, world_id);
|
||||
}
|
||||
|
||||
|
||||
@@ -23,10 +23,10 @@ index 8a921c9310b2540b4b4d7d7383406698993d40d7..348e0de3e5193e6f97a4c83f43476497
|
||||
return receiver_.BindNewEndpointAndPassDedicatedRemote();
|
||||
}
|
||||
diff --git a/content/browser/renderer_host/render_view_host_impl.cc b/content/browser/renderer_host/render_view_host_impl.cc
|
||||
index e3955cead61e4a51013253a75ab0c9e6fd027a68..8c40afa0153ef9974ef59373ac74bb67c5914662 100644
|
||||
index 56f1f9234bee383ac4e8643e009ced56f2b12bb0..4f52bb9f87c1e3b86ddd0bfd920ac5d8812e11c7 100644
|
||||
--- a/content/browser/renderer_host/render_view_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_view_host_impl.cc
|
||||
@@ -730,6 +730,11 @@ void RenderViewHostImpl::SetBackgroundOpaque(bool opaque) {
|
||||
@@ -732,6 +732,11 @@ void RenderViewHostImpl::SetBackgroundOpaque(bool opaque) {
|
||||
GetWidget()->GetAssociatedFrameWidget()->SetBackgroundOpaque(opaque);
|
||||
}
|
||||
|
||||
@@ -51,7 +51,7 @@ index 779e90581cdfb2d1bdd904da038f7537d0477f5a..c85620ac2f30998d1b67f159e50ee722
|
||||
void SendRendererPreferencesToRenderer(
|
||||
const blink::RendererPreferences& preferences);
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_view_aura.cc b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
index 1bed3962a7ac89b815cb6c5827de39c3bfa2449b..6c18d7fd13f447641490c375e0d3a5789b7f8c20 100644
|
||||
index 41ed2610ae5bdfdc9b3f1e47df58140c71bff790..d19f13ba781b24bf9863a0ff5b7d767b9c2ffcc6 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
@@ -570,8 +570,8 @@ void RenderWidgetHostViewAura::ShowImpl(PageVisibilityState page_visibility) {
|
||||
@@ -116,10 +116,10 @@ index a1197832494afac5207b682f187929844b0ebfd7..1c2c61d09d505eef575107201302c7be
|
||||
// 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 f65c2cee6f6a1de4df7431941a30d216058d9aa6..884862490b783a9ae7705e2cefbdff3397758153 100644
|
||||
index 567629babc9ff43995f56f62fa4fa7cae01651f3..e2f3e1171327eafb62d824c1241b0a06feb98312 100644
|
||||
--- a/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
+++ b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
@@ -2458,6 +2458,10 @@ void WebViewImpl::SetPageLifecycleStateInternal(
|
||||
@@ -2460,6 +2460,10 @@ void WebViewImpl::SetPageLifecycleStateInternal(
|
||||
TRACE_EVENT2("navigation", "WebViewImpl::SetPageLifecycleStateInternal",
|
||||
"old_state", old_state, "new_state", new_state);
|
||||
|
||||
@@ -130,7 +130,7 @@ index f65c2cee6f6a1de4df7431941a30d216058d9aa6..884862490b783a9ae7705e2cefbdff33
|
||||
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 &&
|
||||
@@ -3972,10 +3976,23 @@ PageScheduler* WebViewImpl::Scheduler() const {
|
||||
@@ -3974,10 +3978,23 @@ PageScheduler* WebViewImpl::Scheduler() const {
|
||||
return GetPage()->GetPageScheduler();
|
||||
}
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ 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 b1aa9154f1013d420d10117817789869207bd098..f76bf214a9d0464f754ac07e010408e9a1ff54c1 100644
|
||||
index d88de5e36d6013224566bef67118e455765cff46..4650a54199700b199de3d4316be4c444a7ed3bd0 100644
|
||||
--- a/chrome/BUILD.gn
|
||||
+++ b/chrome/BUILD.gn
|
||||
@@ -192,11 +192,16 @@ if (!is_android && !is_mac) {
|
||||
@@ -33,10 +33,10 @@ index b1aa9154f1013d420d10117817789869207bd098..f76bf214a9d0464f754ac07e010408e9
|
||||
"//base",
|
||||
"//build:branding_buildflags",
|
||||
diff --git a/chrome/browser/BUILD.gn b/chrome/browser/BUILD.gn
|
||||
index c272298da0a551f9cef0341cf89d6e59ca97fbf9..fb4f9768a6ed77d9a640c84a9edf197e78071b73 100644
|
||||
index 40ba7a2c7584b5a08358fc21f3fd53e829b9430c..ce5a1d20c9a12e616ea579dc23dbe8bddb0c772f 100644
|
||||
--- a/chrome/browser/BUILD.gn
|
||||
+++ b/chrome/browser/BUILD.gn
|
||||
@@ -4858,7 +4858,7 @@ static_library("browser") {
|
||||
@@ -4860,7 +4860,7 @@ static_library("browser") {
|
||||
|
||||
# On Windows, the hashes are embedded in //chrome:chrome_initial rather
|
||||
# than here in :chrome_dll.
|
||||
@@ -46,7 +46,7 @@ index c272298da0a551f9cef0341cf89d6e59ca97fbf9..fb4f9768a6ed77d9a640c84a9edf197e
|
||||
sources += [ "certificate_viewer_stub.cc" ]
|
||||
}
|
||||
diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn
|
||||
index a7aed4b664a0116a7c26f8b32ec4472f924b4624..26affdbe4f47e9ea310f256d23bfd19cfa28ef06 100644
|
||||
index 88c61c3a4e2aabe85bab2043916549a6debd0159..ed12f9d1649a7518ff7b5db63dad775d95a2f410 100644
|
||||
--- a/chrome/test/BUILD.gn
|
||||
+++ b/chrome/test/BUILD.gn
|
||||
@@ -7376,9 +7376,12 @@ test("unit_tests") {
|
||||
|
||||
@@ -6,7 +6,7 @@ Subject: build: make libcxx_abi_unstable false for electron
|
||||
https://nornagon.medium.com/a-libc-odyssey-973e51649063
|
||||
|
||||
diff --git a/buildtools/third_party/libc++/__config_site b/buildtools/third_party/libc++/__config_site
|
||||
index d3249c5c3056c77036d39b9d9604ee2984f5b51a..40dca160004a6e819374b2990f8ac0bb34e91e6a 100644
|
||||
index 6bb31f334ab590fe5de47214785270a1ff05f885..780e5a3d43ac06d2543fde0024f3df8a94a1146c 100644
|
||||
--- a/buildtools/third_party/libc++/__config_site
|
||||
+++ b/buildtools/third_party/libc++/__config_site
|
||||
@@ -13,7 +13,9 @@
|
||||
|
||||
@@ -9,10 +9,10 @@ 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 b299d94f7d1c6dad988c0cf63c6db60dfc429d9c..af4354e4417ecca880fabddb1f9368e877f14ee4 100644
|
||||
index f8cb8938e99bc8e5f3a937fc33045747b0718189..018f04380c2d04bfaaac138c2b059bda575036c8 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
@@ -8554,6 +8554,7 @@ void RenderFrameHostImpl::CreateNewWindow(
|
||||
@@ -8557,6 +8557,7 @@ void RenderFrameHostImpl::CreateNewWindow(
|
||||
last_committed_origin_, params->window_container_type,
|
||||
params->target_url, params->referrer.To<Referrer>(),
|
||||
params->frame_name, params->disposition, *params->features,
|
||||
@@ -21,10 +21,10 @@ index b299d94f7d1c6dad988c0cf63c6db60dfc429d9c..af4354e4417ecca880fabddb1f9368e8
|
||||
&no_javascript_access);
|
||||
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index 3352d1409320718a4402c31cfb7b59eee7464b66..a7279d4ea1a7db8f50f85f935e1e06d0f0987bc5 100644
|
||||
index 3a6322f9ff87c287319d551b11cb7d2515d9f324..be7ff72576a6bb59f7a302d2034460f3ff002a69 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -4754,6 +4754,12 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -4761,6 +4761,12 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
|
||||
auto* new_contents_impl = new_contents.get();
|
||||
|
||||
@@ -37,7 +37,7 @@ index 3352d1409320718a4402c31cfb7b59eee7464b66..a7279d4ea1a7db8f50f85f935e1e06d0
|
||||
// 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
|
||||
@@ -4795,12 +4801,6 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -4802,12 +4808,6 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
AddWebContentsDestructionObserver(new_contents_impl);
|
||||
}
|
||||
|
||||
@@ -66,7 +66,7 @@ index 6df9186bcee6a56da11da8e365c7cf5b4375e366..0fdda1a6e0ac98a8c8619b4d4fab5977
|
||||
|
||||
// Operation result when the renderer asks the browser to create a new window.
|
||||
diff --git a/content/public/browser/content_browser_client.cc b/content/public/browser/content_browser_client.cc
|
||||
index e5240583f8f409b524978206c9f239a80887bb87..349037d41c387e914d4207433fb3d27d37b8aca4 100644
|
||||
index 2668ab84237c37b7df1e2b19ceda0ed012c0c072..8a7bdd7ff737795411368ce41e94bba8eb53bd0a 100644
|
||||
--- a/content/public/browser/content_browser_client.cc
|
||||
+++ b/content/public/browser/content_browser_client.cc
|
||||
@@ -741,6 +741,8 @@ bool ContentBrowserClient::CanCreateWindow(
|
||||
@@ -79,7 +79,7 @@ index e5240583f8f409b524978206c9f239a80887bb87..349037d41c387e914d4207433fb3d27d
|
||||
bool opener_suppressed,
|
||||
bool* no_javascript_access) {
|
||||
diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h
|
||||
index 45bacd6590db81d46fb40344ee18f67c9789a330..d1506bc5ef109d04f07dc261c404d63068eddc7f 100644
|
||||
index e5c261c9d1eaa5550609ac28a6fcfebebf0ee091..223265d74f6c5056e5e6af6adcb115cf406f0c5f 100644
|
||||
--- a/content/public/browser/content_browser_client.h
|
||||
+++ b/content/public/browser/content_browser_client.h
|
||||
@@ -188,6 +188,7 @@ class NetworkService;
|
||||
@@ -148,10 +148,10 @@ index fd851a9347dd6920e035bc9183991ea2a275aff4..579a796fcfdecf44ab415ceebc30b427
|
||||
// typically happens when popups are created.
|
||||
virtual void WebContentsCreated(WebContents* source_contents,
|
||||
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
|
||||
index a74484bcf315a4b70f5c2e23e93317e73a984320..8e023991b3fdd05ceb60cf9f87f8e9f359570226 100644
|
||||
index 929f2e14399b92f5190d23fa48158efeae63d95d..9601b8a33c5c0b77143462395a30da1d3f515efe 100644
|
||||
--- a/content/renderer/render_frame_impl.cc
|
||||
+++ b/content/renderer/render_frame_impl.cc
|
||||
@@ -6673,6 +6673,10 @@ WebView* RenderFrameImpl::CreateNewWindow(
|
||||
@@ -6668,6 +6668,10 @@ WebView* RenderFrameImpl::CreateNewWindow(
|
||||
request.HasUserGesture(), GetWebFrame()->IsAdFrame(),
|
||||
GetWebFrame()->IsAdScriptInStack());
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ This patch comes after Chromium removed the ScopedAllowIO API in favor
|
||||
of explicitly adding ScopedAllowBlocking calls as friends.
|
||||
|
||||
diff --git a/base/threading/thread_restrictions.h b/base/threading/thread_restrictions.h
|
||||
index fca9f03283c9b11e63d585411eb1620a20174bf6..96a4280e94988857545cd4e2bb0752077cb0132f 100644
|
||||
index 1bc39182f84c77f4b2652f1c7f3208ab09fdbad0..fd533986c227e25d102f3025db8a06a7d51c66f4 100644
|
||||
--- a/base/threading/thread_restrictions.h
|
||||
+++ b/base/threading/thread_restrictions.h
|
||||
@@ -136,6 +136,7 @@ class KeyStorageLinux;
|
||||
@@ -18,7 +18,7 @@ index fca9f03283c9b11e63d585411eb1620a20174bf6..96a4280e94988857545cd4e2bb075207
|
||||
class Profile;
|
||||
class ProfileImpl;
|
||||
class ScopedAllowBlockingForProfile;
|
||||
@@ -285,6 +286,9 @@ class BackendImpl;
|
||||
@@ -286,6 +287,9 @@ class BackendImpl;
|
||||
class InFlightIO;
|
||||
bool CleanupDirectorySync(const base::FilePath&);
|
||||
} // namespace disk_cache
|
||||
@@ -28,7 +28,7 @@ index fca9f03283c9b11e63d585411eb1620a20174bf6..96a4280e94988857545cd4e2bb075207
|
||||
namespace enterprise_connectors {
|
||||
class LinuxKeyRotationCommand;
|
||||
} // namespace enterprise_connectors
|
||||
@@ -592,6 +596,7 @@ class BASE_EXPORT [[maybe_unused, nodiscard]] ScopedAllowBlocking {
|
||||
@@ -593,6 +597,7 @@ class BASE_EXPORT [[maybe_unused, nodiscard]] ScopedAllowBlocking {
|
||||
friend class ::DesktopNotificationBalloon;
|
||||
friend class ::FirefoxProfileLock;
|
||||
friend class ::GaiaConfig;
|
||||
@@ -36,7 +36,7 @@ index fca9f03283c9b11e63d585411eb1620a20174bf6..96a4280e94988857545cd4e2bb075207
|
||||
friend class ::ProfileImpl;
|
||||
friend class ::ScopedAllowBlockingForProfile;
|
||||
friend class ::StartupTabProviderImpl;
|
||||
@@ -632,6 +637,7 @@ class BASE_EXPORT [[maybe_unused, nodiscard]] ScopedAllowBlocking {
|
||||
@@ -633,6 +638,7 @@ class BASE_EXPORT [[maybe_unused, nodiscard]] ScopedAllowBlocking {
|
||||
friend class crosapi::LacrosThreadTypeDelegate;
|
||||
friend class crypto::ScopedAllowBlockingForNSS; // http://crbug.com/59847
|
||||
friend class drive::FakeDriveService;
|
||||
|
||||
@@ -80,10 +80,10 @@ index 28cd699814f32a7a569d63936b9544567a66d9c4..fd461fa448d983481dc4c0c7d03b1945
|
||||
}
|
||||
|
||||
diff --git a/chrome/browser/ui/browser.cc b/chrome/browser/ui/browser.cc
|
||||
index 6ca8527a73e53fdb6515360e7cd58310c46402d5..5f0c343e5a5f2b554a672f6d69ce2a7291c93d21 100644
|
||||
index 52152047604632037159a5136bcc9ba98ab71a70..39eb85390dbd3e7ad8c8a0cdeb760e1325652d44 100644
|
||||
--- a/chrome/browser/ui/browser.cc
|
||||
+++ b/chrome/browser/ui/browser.cc
|
||||
@@ -2070,12 +2070,11 @@ bool Browser::IsWebContentsCreationOverridden(
|
||||
@@ -2066,12 +2066,11 @@ bool Browser::IsWebContentsCreationOverridden(
|
||||
content::SiteInstance* source_site_instance,
|
||||
content::mojom::WindowContainerType window_container_type,
|
||||
const GURL& opener_url,
|
||||
@@ -99,10 +99,10 @@ index 6ca8527a73e53fdb6515360e7cd58310c46402d5..5f0c343e5a5f2b554a672f6d69ce2a72
|
||||
|
||||
WebContents* Browser::CreateCustomWebContents(
|
||||
diff --git a/chrome/browser/ui/browser.h b/chrome/browser/ui/browser.h
|
||||
index 69f2c9c0ff003b6ced9a3db101c07db76510a47d..c5cdeba9d5835f67ecda9877e3afa337ffee0c79 100644
|
||||
index d5e1b7bd61208647c122646a5e8ccd5548fc21e1..c4b4638819de81d8d187db4b324872d79cb9a5b1 100644
|
||||
--- a/chrome/browser/ui/browser.h
|
||||
+++ b/chrome/browser/ui/browser.h
|
||||
@@ -973,8 +973,7 @@ class Browser : public TabStripModelObserver,
|
||||
@@ -976,8 +976,7 @@ class Browser : public TabStripModelObserver,
|
||||
content::SiteInstance* source_site_instance,
|
||||
content::mojom::WindowContainerType window_container_type,
|
||||
const GURL& opener_url,
|
||||
@@ -218,10 +218,10 @@ index c5b0d3b23b8da318ae55fcac2515a1187f261469..16ed1f46c9afde0ff25750128b4fcff6
|
||||
void AddNewContents(content::WebContents* source,
|
||||
std::unique_ptr<content::WebContents> new_contents,
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index b21305c697648b577fda1da7d85d41ca72e56e0f..87aa67836b71b2beafc79ca534a1c9d6fca66d3c 100644
|
||||
index b8c0929a305a0c78ff0cc3c447019ca11905241a..69e6473166679bce52389be060dafc19096946c7 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -4660,8 +4660,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -4667,8 +4667,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
|
||||
if (delegate_ && delegate_->IsWebContentsCreationOverridden(
|
||||
source_site_instance, params.window_container_type,
|
||||
|
||||
@@ -7,7 +7,7 @@ By default, chromium sets up one v8 snapshot to be used in all v8 contexts. This
|
||||
to have a dedicated browser process v8 snapshot defined by the file `browser_v8_context_snapshot.bin`.
|
||||
|
||||
diff --git a/content/app/content_main_runner_impl.cc b/content/app/content_main_runner_impl.cc
|
||||
index aae7deac75e0157725d827d54204c451e0c2691e..e1686e6818d1354bb40001f92c425407dcb6711a 100644
|
||||
index ba2ec653757232519c442e9fa5f88441470c61a0..432e139370208f93e2af655dd2d5491ba4d15904 100644
|
||||
--- a/content/app/content_main_runner_impl.cc
|
||||
+++ b/content/app/content_main_runner_impl.cc
|
||||
@@ -45,6 +45,7 @@
|
||||
@@ -18,9 +18,9 @@ index aae7deac75e0157725d827d54204c451e0c2691e..e1686e6818d1354bb40001f92c425407
|
||||
#include "base/strings/string_number_conversions.h"
|
||||
#include "base/strings/string_util.h"
|
||||
#include "base/task/single_thread_task_runner.h"
|
||||
@@ -267,8 +268,13 @@ std::string GetSnapshotDataDescriptor(const base::CommandLine& command_line) {
|
||||
|
||||
#endif
|
||||
@@ -281,8 +282,13 @@ void AsanProcessInfoCB(const char*, bool*) {
|
||||
}
|
||||
#endif // defined(ADDRESS_SANITIZER)
|
||||
|
||||
-void LoadV8SnapshotFile(const base::CommandLine& command_line) {
|
||||
+void LoadV8SnapshotFile(const raw_ptr<ContentMainDelegate> delegate, const base::CommandLine& command_line) {
|
||||
@@ -33,7 +33,7 @@ index aae7deac75e0157725d827d54204c451e0c2691e..e1686e6818d1354bb40001f92c425407
|
||||
#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_MAC)
|
||||
base::FileDescriptorStore& file_descriptor_store =
|
||||
base::FileDescriptorStore::GetInstance();
|
||||
@@ -297,11 +303,12 @@ bool ShouldLoadV8Snapshot(const base::CommandLine& command_line,
|
||||
@@ -311,11 +317,12 @@ bool ShouldLoadV8Snapshot(const base::CommandLine& command_line,
|
||||
|
||||
#endif // V8_USE_EXTERNAL_STARTUP_DATA
|
||||
|
||||
@@ -48,7 +48,7 @@ index aae7deac75e0157725d827d54204c451e0c2691e..e1686e6818d1354bb40001f92c425407
|
||||
#endif // V8_USE_EXTERNAL_STARTUP_DATA
|
||||
}
|
||||
|
||||
@@ -977,7 +984,7 @@ int ContentMainRunnerImpl::Initialize(ContentMainParams params) {
|
||||
@@ -991,7 +998,7 @@ int ContentMainRunnerImpl::Initialize(ContentMainParams params) {
|
||||
return TerminateForFatalInitializationError();
|
||||
#endif // BUILDFLAG(IS_ANDROID) && (ICU_UTIL_DATA_IMPL == ICU_UTIL_DATA_FILE)
|
||||
|
||||
|
||||
@@ -6,10 +6,10 @@ Subject: disable_hidden.patch
|
||||
Electron uses this to disable background throttling for hidden windows.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
index 82fa8af158b3ef84ac8e5792d2c659569ce54ec4..209d69c3f2d000d88dafd23fc45134051f42ea5c 100644
|
||||
index fb013badaeaf5eac23b1468301476228f6dc1782..6c0fe34bb30f68d43e1e111d1f4bf24e7a3281e5 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
@@ -778,6 +778,9 @@ void RenderWidgetHostImpl::WasHidden() {
|
||||
@@ -777,6 +777,9 @@ void RenderWidgetHostImpl::WasHidden() {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -20,10 +20,10 @@ index 82fa8af158b3ef84ac8e5792d2c659569ce54ec4..209d69c3f2d000d88dafd23fc4513405
|
||||
blink::mojom::PointerLockResult::kWrongDocument);
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.h b/content/browser/renderer_host/render_widget_host_impl.h
|
||||
index b9e42fcbe284d47221744a71f00d33f3fd8a029e..753155ea33c7062705968b1a6b6f2a8e0d94b5f2 100644
|
||||
index 8e0d92a74d31758bb813b26ab906e80b5026a9ba..3365a20260fc6c489688a8647b0eea8649d06ddf 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.h
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.h
|
||||
@@ -993,6 +993,9 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
||||
@@ -996,6 +996,9 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
||||
// Requests a commit and forced redraw in the renderer compositor.
|
||||
void ForceRedrawForTesting();
|
||||
|
||||
@@ -34,7 +34,7 @@ index b9e42fcbe284d47221744a71f00d33f3fd8a029e..753155ea33c7062705968b1a6b6f2a8e
|
||||
// |routing_id| must not be MSG_ROUTING_NONE.
|
||||
// If this object outlives |delegate|, DetachDelegate() must be called when
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_view_aura.cc b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
index a2e0720681d6fdcbbed81e3602491a83bbb17bee..1bed3962a7ac89b815cb6c5827de39c3bfa2449b 100644
|
||||
index eb65b0b002dfd2ba820e7823ad7338cfa2f40c4c..41ed2610ae5bdfdc9b3f1e47df58140c71bff790 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
@@ -634,7 +634,7 @@ void RenderWidgetHostViewAura::HideImpl() {
|
||||
|
||||
@@ -32,7 +32,7 @@ index aa5edd1d07d97bee4912b14996ff804351240e94..8334b7eb6a3293c068f5234508f8dca7
|
||||
|
||||
} // namespace storage
|
||||
diff --git a/third_party/blink/public/mojom/dom_storage/storage_area.mojom b/third_party/blink/public/mojom/dom_storage/storage_area.mojom
|
||||
index 332be0811d86c7a265f440ab7719460160a22617..e3382d843599ef6017e0ac557919b3a41809f17d 100644
|
||||
index 5902d8217c1b98d182f68f4199be4830c6177e68..2517c37be979cfe25ec8592cdbf8e53bab100c42 100644
|
||||
--- a/third_party/blink/public/mojom/dom_storage/storage_area.mojom
|
||||
+++ b/third_party/blink/public/mojom/dom_storage/storage_area.mojom
|
||||
@@ -50,7 +50,8 @@ struct KeyValue {
|
||||
|
||||
@@ -33,7 +33,7 @@ index 0ab8187b0db8ae6db46d81738f653a2bc4c566f6..de3d55e85c22317f7f9375eb94d0d5d4
|
||||
|
||||
} // namespace net
|
||||
diff --git a/services/network/network_context.cc b/services/network/network_context.cc
|
||||
index 5bb46cf0ed165f216fa4bf2813dfe2de18b15e94..8a8a0d40970a9107a09d40ccc10ff5ccba33b095 100644
|
||||
index b068b0de6c5676f36a8e8532d4fd59f6815f4dd1..84840e53019ebe511b0c0b4176eeea2863ac624f 100644
|
||||
--- a/services/network/network_context.cc
|
||||
+++ b/services/network/network_context.cc
|
||||
@@ -1682,6 +1682,13 @@ void NetworkContext::SetNetworkConditions(
|
||||
@@ -51,10 +51,10 @@ index 5bb46cf0ed165f216fa4bf2813dfe2de18b15e94..8a8a0d40970a9107a09d40ccc10ff5cc
|
||||
// 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 06f2d96a0158348e151d90303a83a2ab263d4e5c..1a9baf9e7fb10373ed9469e13dd8119edab5c40b 100644
|
||||
index ec0e4a355e96394abe086325a6fdb37fcd3d1446..522f021835654e48146db4cf6ad0d862d9140056 100644
|
||||
--- a/services/network/network_context.h
|
||||
+++ b/services/network/network_context.h
|
||||
@@ -318,6 +318,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
@@ -317,6 +317,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
void CloseIdleConnections(CloseIdleConnectionsCallback callback) override;
|
||||
void SetNetworkConditions(const base::UnguessableToken& throttling_profile_id,
|
||||
mojom::NetworkConditionsPtr conditions) override;
|
||||
@@ -63,7 +63,7 @@ index 06f2d96a0158348e151d90303a83a2ab263d4e5c..1a9baf9e7fb10373ed9469e13dd8119e
|
||||
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 a19f7cfaa35d9097a660ba0e3d7e402b47a8c1a4..26fbe6d1b75d1fea503b2201399a8d88ef5bb2af 100644
|
||||
index 19f568b78c621ecbec64b8eb46c8c92d7af650f7..8abdfc8c32c7f3c05bd8436c4d4349af53852eaf 100644
|
||||
--- a/services/network/public/mojom/network_context.mojom
|
||||
+++ b/services/network/public/mojom/network_context.mojom
|
||||
@@ -1265,6 +1265,9 @@ interface NetworkContext {
|
||||
@@ -77,7 +77,7 @@ index a19f7cfaa35d9097a660ba0e3d7e402b47a8c1a4..26fbe6d1b75d1fea503b2201399a8d88
|
||||
SetAcceptLanguage(string new_accept_language);
|
||||
|
||||
diff --git a/services/network/test/test_network_context.h b/services/network/test/test_network_context.h
|
||||
index f421326b04a048a655fd0ae9c098aa7e52807162..460fe57899b02538f5ba5d608aefca3a57b3411a 100644
|
||||
index eb78d84ad3d6124313cf7b940425b0162d554fd6..80bfebc12978d976e239f6c81f1fff3aef5614c7 100644
|
||||
--- a/services/network/test/test_network_context.h
|
||||
+++ b/services/network/test/test_network_context.h
|
||||
@@ -147,6 +147,7 @@ class TestNetworkContext : public mojom::NetworkContext {
|
||||
|
||||
@@ -12,7 +12,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 884862490b783a9ae7705e2cefbdff3397758153..1c3a7d0eb3d9b1fa5ae7199fc8b71870063e4393 100644
|
||||
index e2f3e1171327eafb62d824c1241b0a06feb98312..f1e4c0eb81b0f23b3151e7426309315a9c2b0f26 100644
|
||||
--- a/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
+++ b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
@@ -168,6 +168,7 @@
|
||||
@@ -23,7 +23,7 @@ index 884862490b783a9ae7705e2cefbdff3397758153..1c3a7d0eb3d9b1fa5ae7199fc8b71870
|
||||
#include "third_party/blink/renderer/platform/graphics/image.h"
|
||||
#include "third_party/blink/renderer/platform/graphics/paint/cull_rect.h"
|
||||
#include "third_party/blink/renderer/platform/graphics/paint/paint_record_builder.h"
|
||||
@@ -1837,6 +1838,7 @@ void WebView::ApplyWebPreferences(const web_pref::WebPreferences& prefs,
|
||||
@@ -1839,6 +1840,7 @@ void WebView::ApplyWebPreferences(const web_pref::WebPreferences& prefs,
|
||||
#if BUILDFLAG(IS_MAC)
|
||||
web_view_impl->SetMaximumLegibleScale(
|
||||
prefs.default_maximum_page_scale_factor);
|
||||
|
||||
@@ -407,10 +407,10 @@ index 9dc2d5a33858da7c31fd87bbbabe3899301fa52d..ebf0bb23b9aedb7bf9eb8af52b4756db
|
||||
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 301824a7f83e9e7057279723eccd6c9c9ad44618..25e7e087e2ddf0e8fab1cd6f20a56790f7e406b2 100644
|
||||
index da35159332452f49f9e249804a6d7bd23379aba3..1f33d868bc368076ac1bda1e23fc595fd78f1e8a 100644
|
||||
--- a/url/url_util.cc
|
||||
+++ b/url/url_util.cc
|
||||
@@ -133,6 +133,9 @@ struct SchemeRegistry {
|
||||
@@ -130,6 +130,9 @@ struct SchemeRegistry {
|
||||
kMaterializedViewScheme,
|
||||
};
|
||||
|
||||
@@ -420,7 +420,7 @@ index 301824a7f83e9e7057279723eccd6c9c9ad44618..25e7e087e2ddf0e8fab1cd6f20a56790
|
||||
// Schemes with a predefined default custom handler.
|
||||
std::vector<SchemeWithHandler> predefined_handler_schemes;
|
||||
|
||||
@@ -714,6 +717,15 @@ const std::vector<std::string>& GetEmptyDocumentSchemes() {
|
||||
@@ -711,6 +714,15 @@ const std::vector<std::string>& GetEmptyDocumentSchemes() {
|
||||
return GetSchemeRegistry().empty_document_schemes;
|
||||
}
|
||||
|
||||
|
||||
@@ -628,7 +628,7 @@ index cb43aa14c9742f3788ae58c3e49b890cd532f327..6a738f7aade504f2ff3bb6647a0da8f8
|
||||
#if BUILDFLAG(IS_MAC)
|
||||
// Whether or not to disclaim TCC responsibility for the process, defaults to
|
||||
diff --git a/sandbox/policy/win/sandbox_win.cc b/sandbox/policy/win/sandbox_win.cc
|
||||
index be912517b5207d2b1e5a5feec385c9fb1df460cf..a62f28e380eaf3e592e0957d7ca9ed331042629a 100644
|
||||
index 24f4b08835b3fb8a447e569bcd0952b600759011..9e1d58f8621cedc886990935fd73539e666caf13 100644
|
||||
--- a/sandbox/policy/win/sandbox_win.cc
|
||||
+++ b/sandbox/policy/win/sandbox_win.cc
|
||||
@@ -693,11 +693,9 @@ base::win::ScopedHandle CreateUnsandboxedJob() {
|
||||
|
||||
@@ -112,7 +112,7 @@ index e1d4360ac8d0ee6dacdd36ed5a98e2c954bff31d..9e763a3af2088c8507922932288e5e4c
|
||||
string mime_type;
|
||||
|
||||
diff --git a/services/network/url_loader.cc b/services/network/url_loader.cc
|
||||
index cfa520eb7d16efa2c24268b21f1891577f9c5550..c14b5e2b8e3780222be058f950167e4fa247a576 100644
|
||||
index 48d72aa1908e951c07370146a6a96a3a92629835..2413d871aa6c8e775cd829b4b8d54d9977ce0a21 100644
|
||||
--- a/services/network/url_loader.cc
|
||||
+++ b/services/network/url_loader.cc
|
||||
@@ -707,6 +707,7 @@ URLLoader::URLLoader(
|
||||
|
||||
@@ -7,7 +7,7 @@ Subject: feat: filter out non-shareable windows in the current application in
|
||||
This patch ensures that windows protected via win.setContentProtection(true) do not appear in full display captures via desktopCapturer. This patch could be upstreamed but as the check is limited to in-process windows it doesn't make a lot of sense for Chromium itself. This patch currently has a limitation that it only function for windows created / protected BEFORE the stream is started. There is theoretical future work we can do via polling / observers to automatically update the SCContentFilter when new windows are made but for now this will solve 99+% of the problem and folks can re-order their logic a bit to get it working for their use cases.
|
||||
|
||||
diff --git a/content/browser/media/capture/screen_capture_kit_device_mac.mm b/content/browser/media/capture/screen_capture_kit_device_mac.mm
|
||||
index a1e225dc1e8756ace8881f2456b483587ad77ffe..aaedb706d330b109f57522c56e70fa8e102cd1c0 100644
|
||||
index 152b90019ed030b3ae10f3cc554311ade229a637..5c09b98b0c0ade9197a73186809ae4da28a12506 100644
|
||||
--- a/content/browser/media/capture/screen_capture_kit_device_mac.mm
|
||||
+++ b/content/browser/media/capture/screen_capture_kit_device_mac.mm
|
||||
@@ -182,8 +182,17 @@ void OnShareableContentCreated(SCShareableContent* content) {
|
||||
|
||||
@@ -23,10 +23,10 @@ Upstream bug https://bugs.chromium.org/p/chromium/issues/detail?id=1081397.
|
||||
Upstreamed at https://chromium-review.googlesource.com/c/chromium/src/+/3856266.
|
||||
|
||||
diff --git a/content/browser/renderer_host/navigation_request.cc b/content/browser/renderer_host/navigation_request.cc
|
||||
index 8297580ffc235c8ce24d030a1a5b14266c367c01..72468fe241cb8db70396358637072404657eb7d6 100644
|
||||
index 48b992034c890cca2b437d4486f57ddcb1236a78..e7820eff2adc3488c4d38c378944dc4d616df08a 100644
|
||||
--- a/content/browser/renderer_host/navigation_request.cc
|
||||
+++ b/content/browser/renderer_host/navigation_request.cc
|
||||
@@ -10533,6 +10533,12 @@ NavigationRequest::GetOriginForURLLoaderFactoryUncheckedWithDebugInfo() {
|
||||
@@ -10539,6 +10539,12 @@ NavigationRequest::GetOriginForURLLoaderFactoryUncheckedWithDebugInfo() {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -75,10 +75,10 @@ index ceced82cbd23b2dcd7fabf7d63028423f86e05c3..27d0b61a7b67d1c9d7e0699e287b7833
|
||||
|
||||
PictureInPictureOcclusionTracker*
|
||||
diff --git a/chrome/browser/ui/views/overlay/video_overlay_window_views.cc b/chrome/browser/ui/views/overlay/video_overlay_window_views.cc
|
||||
index 24f680b6c50d8e35f7a4650788dc1494d467f6d0..d5bb12b038e8fa68cd52129cafd2e7689cd2ae9a 100644
|
||||
index 507a695ba97c6321c4d1aa662bdd0206991e6c69..847447364a2ae158ae764a01f883e69b4907d031 100644
|
||||
--- a/chrome/browser/ui/views/overlay/video_overlay_window_views.cc
|
||||
+++ b/chrome/browser/ui/views/overlay/video_overlay_window_views.cc
|
||||
@@ -345,11 +345,13 @@ std::unique_ptr<VideoOverlayWindowViews> VideoOverlayWindowViews::Create(
|
||||
@@ -332,11 +332,13 @@ std::unique_ptr<VideoOverlayWindowViews> VideoOverlayWindowViews::Create(
|
||||
}
|
||||
#endif // BUILDFLAG(IS_WIN)
|
||||
|
||||
|
||||
@@ -9,10 +9,10 @@ focus node change via TextInputManager.
|
||||
chromium-bug: https://crbug.com/1369605
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_view_aura.cc b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
index 6c18d7fd13f447641490c375e0d3a5789b7f8c20..c1e702f9ec9b96bafe52d7cb586c84a4f6b5fba6 100644
|
||||
index d19f13ba781b24bf9863a0ff5b7d767b9c2ffcc6..7147e49f1eb9963b9d385e44e4b32871be9b404b 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
@@ -2940,6 +2940,12 @@ void RenderWidgetHostViewAura::OnTextSelectionChanged(
|
||||
@@ -2934,6 +2934,12 @@ void RenderWidgetHostViewAura::OnTextSelectionChanged(
|
||||
}
|
||||
}
|
||||
|
||||
@@ -87,10 +87,10 @@ index 0c7d5b2c1d3e97420913bd643bb2a524a76fc286..653793fa480f035ce11e079b370bf5ed
|
||||
// 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 f0d4891adfb86c1ff99fe52fb8b3911076f01e2a..b9ef74e8392fb8d0c117ed9d69a2dd82bcfb9a1a 100644
|
||||
index 8b47c0901b2d416ded059d64a133f8af377ce130..c2490a46dcb810c3b293b1da235f933d31931b49 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -9126,7 +9126,7 @@ void WebContentsImpl::OnFocusedElementChangedInFrame(
|
||||
@@ -9132,7 +9132,7 @@ void WebContentsImpl::OnFocusedElementChangedInFrame(
|
||||
"WebContentsImpl::OnFocusedElementChangedInFrame",
|
||||
"render_frame_host", frame);
|
||||
RenderWidgetHostViewBase* root_view =
|
||||
|
||||
@@ -11,10 +11,10 @@ This patch should be upstreamed as a conditional revert of the logic in desktop
|
||||
vs mobile runtimes. i.e. restore the old logic only on desktop platforms
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
index 55ba60eeb42b18047edc77cc8e201fbbc0f8a6c4..f0cc0a8dd2c68f6381ccf2c786df6a204b753e3c 100644
|
||||
index 5275c37f27ef61754f67c1b5fbcd4b126602929e..4f7fe9d81a30b08a0a5efc09517381311903eae8 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
@@ -2052,9 +2052,8 @@ RenderWidgetHostImpl::GetWidgetInputHandler() {
|
||||
@@ -2051,9 +2051,8 @@ RenderWidgetHostImpl::GetWidgetInputHandler() {
|
||||
void RenderWidgetHostImpl::NotifyScreenInfoChanged() {
|
||||
// The resize message (which may not happen immediately) will carry with it
|
||||
// the screen info as well as the new size (if the screen has changed scale
|
||||
|
||||
@@ -216,10 +216,10 @@ index 3dbdae2305f24878a26b21f010a1c031736db11c..c30a457bcc040f9995657f45049c496e
|
||||
mojom::blink::WantResultOption::kWantResult, wait_for_promise);
|
||||
}
|
||||
diff --git a/third_party/blink/renderer/core/frame/web_local_frame_impl.cc b/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
|
||||
index ae33f98cbe2410f853e705cf316517d802d2b834..7d934d8c2e505fc2729dd37ddb43ce38ce31c3e8 100644
|
||||
index 5381b7b4186972cfd609279511a7c4bd2168ac0d..c625f2f5fe38aad367ce69707290e7dd44f57529 100644
|
||||
--- a/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
|
||||
@@ -1084,14 +1084,15 @@ void WebLocalFrameImpl::RequestExecuteScript(
|
||||
@@ -1091,14 +1091,15 @@ void WebLocalFrameImpl::RequestExecuteScript(
|
||||
mojom::blink::EvaluationTiming evaluation_timing,
|
||||
mojom::blink::LoadEventBlockingOption blocking_option,
|
||||
WebScriptExecutionCallback callback,
|
||||
|
||||
@@ -6,10 +6,10 @@ 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 f84a935c95626b8c85d85253e7bb5a7942b7d3f0..d0e7ec487f76710b9d8a920c98afed45078e2055 100644
|
||||
index 4a4495b57d1ed318da95e0739897347fd816b879..9bf277ce26ebab689509f2f33e987963edfffe78 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_manager.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_manager.cc
|
||||
@@ -4372,6 +4372,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
@@ -4378,6 +4378,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
request->ResetStateForSiteInstanceChange();
|
||||
}
|
||||
|
||||
@@ -20,7 +20,7 @@ index f84a935c95626b8c85d85253e7bb5a7942b7d3f0..d0e7ec487f76710b9d8a920c98afed45
|
||||
}
|
||||
|
||||
diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h
|
||||
index d1506bc5ef109d04f07dc261c404d63068eddc7f..02af52fb8228c84df23f1fedfab11b356ccd04eb 100644
|
||||
index 223265d74f6c5056e5e6af6adcb115cf406f0c5f..92839a6865cbe4e035856c0162b29e5309a61b7e 100644
|
||||
--- a/content/public/browser/content_browser_client.h
|
||||
+++ b/content/public/browser/content_browser_client.h
|
||||
@@ -313,6 +313,11 @@ class CONTENT_EXPORT ContentBrowserClient {
|
||||
|
||||
@@ -6,7 +6,7 @@ Subject: gritsettings_resource_ids.patch
|
||||
Add electron resources file to the list of resource ids generation.
|
||||
|
||||
diff --git a/tools/gritsettings/resource_ids.spec b/tools/gritsettings/resource_ids.spec
|
||||
index 3e28b9ebe9b58466cd8aa43a601ad26d1d726394..1bd96ce0d82d6ad973844010c34e0b5d195ae772 100644
|
||||
index 753e09ca4d6876f5d4a601c0b98418314f274b9a..b7e40e5223c29b5e783af39e7a765ac73f823314 100644
|
||||
--- a/tools/gritsettings/resource_ids.spec
|
||||
+++ b/tools/gritsettings/resource_ids.spec
|
||||
@@ -1338,6 +1338,11 @@
|
||||
|
||||
@@ -11,7 +11,7 @@ If removing this patch causes no sync failures, it's safe to delete :+1:
|
||||
Ref https://chromium-review.googlesource.com/c/chromium/src/+/2953903
|
||||
|
||||
diff --git a/tools/clang/scripts/update.py b/tools/clang/scripts/update.py
|
||||
index ada1ebf645124bad2d8c714226ca01312e5aa73f..ffdff21e1497673a548f16a91102f4d8e817d15f 100755
|
||||
index 35b36c560150d608f28773552f35aeabd2a6f749..bc29b9751db5f962dc75bae5a7b85e261a14bee9 100755
|
||||
--- a/tools/clang/scripts/update.py
|
||||
+++ b/tools/clang/scripts/update.py
|
||||
@@ -304,6 +304,8 @@ def GetDefaultHostOs():
|
||||
|
||||
@@ -9,10 +9,10 @@ but due to the nature of electron, we need to load the v8 snapshot
|
||||
in the browser process.
|
||||
|
||||
diff --git a/content/app/content_main_runner_impl.cc b/content/app/content_main_runner_impl.cc
|
||||
index 78b9930f1ca5cfe61d3e0969c91d235205861613..aae7deac75e0157725d827d54204c451e0c2691e 100644
|
||||
index 8618985cc8e20c5d7bf2e7eb4d56fc21856378fd..ba2ec653757232519c442e9fa5f88441470c61a0 100644
|
||||
--- a/content/app/content_main_runner_impl.cc
|
||||
+++ b/content/app/content_main_runner_impl.cc
|
||||
@@ -288,11 +288,8 @@ void LoadV8SnapshotFile(const base::CommandLine& command_line) {
|
||||
@@ -302,11 +302,8 @@ void LoadV8SnapshotFile(const base::CommandLine& command_line) {
|
||||
|
||||
bool ShouldLoadV8Snapshot(const base::CommandLine& command_line,
|
||||
const std::string& process_type) {
|
||||
|
||||
@@ -353,7 +353,7 @@ index 6ebc4754ef986f5ae966ff7a3217ab77df78edf9..91147b8a42f731c645c318776933b4c1
|
||||
bool shouldShowWindowTitle = YES;
|
||||
if (_bridge)
|
||||
diff --git a/components/remote_cocoa/app_shim/native_widget_ns_window_bridge.mm b/components/remote_cocoa/app_shim/native_widget_ns_window_bridge.mm
|
||||
index 7fbc649a45bea2181523a1875f0112021f0b9251..e15f59c3dedf587df6664cef1913a8e789497bbd 100644
|
||||
index b3c087eda0561d94d205ef0cbbb341a7e2a34638..035202378209e32e6f7c630140367cda7a34e483 100644
|
||||
--- a/components/remote_cocoa/app_shim/native_widget_ns_window_bridge.mm
|
||||
+++ b/components/remote_cocoa/app_shim/native_widget_ns_window_bridge.mm
|
||||
@@ -627,10 +627,12 @@ NSUInteger CountBridgedWindows(NSArray* child_windows) {
|
||||
@@ -459,7 +459,7 @@ index 05dbd641ea4af9276be7f89627e4075153e667a9..a50cc9cd1502d7aaebdb7029fc5792fe
|
||||
return kAttributes;
|
||||
}
|
||||
diff --git a/content/browser/BUILD.gn b/content/browser/BUILD.gn
|
||||
index 7bccc6ce4874e8ac3caf594148756fbbdb5d57b3..8cba823f480c1b175631cd45c3d5b0e68b2b1c0c 100644
|
||||
index ae5a89f2f9070bf79d0e7ea7984050db5e4545b1..ed9d01d7b2914140d33443ee10f707c765c38fdd 100644
|
||||
--- a/content/browser/BUILD.gn
|
||||
+++ b/content/browser/BUILD.gn
|
||||
@@ -54,6 +54,7 @@ source_set("browser") {
|
||||
@@ -608,10 +608,10 @@ index 2ad8852bf38dbfbdc600a5a21b354385338eb81e..1e17e24f269fb6fc758a90fa11e33fce
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
diff --git a/content/common/BUILD.gn b/content/common/BUILD.gn
|
||||
index 6edbef34112ccae4e7e3e4f96ffacdb430234497..72d3fa4996b2d141bdf2ae703bc1d28fe7dfa7ea 100644
|
||||
index aa5bf488affb055f9eef527783f4319d5cb3ce01..eaf62d995e54803372728b17f1a7ab24d40f4504 100644
|
||||
--- a/content/common/BUILD.gn
|
||||
+++ b/content/common/BUILD.gn
|
||||
@@ -220,6 +220,7 @@ source_set("common") {
|
||||
@@ -217,6 +217,7 @@ source_set("common") {
|
||||
"//content:content_implementation",
|
||||
"//build/config:precompiled_headers",
|
||||
]
|
||||
@@ -700,7 +700,7 @@ index a119b4439bfb9218c7aaf09dca8e78527da7f20d..faa813b003940280c6eeb87e70173019
|
||||
|
||||
} // namespace content
|
||||
diff --git a/content/test/BUILD.gn b/content/test/BUILD.gn
|
||||
index 0f5d5c69bcab6feb8b2f3de86e3324d95f2efc31..c59fbd5d57055991d2c9a1d16633d1b8546634aa 100644
|
||||
index f010f10b32702c78a4e1cb931434e1a5393e11d3..baf0252f0ab6648a829c4453db17bc9466c53c45 100644
|
||||
--- a/content/test/BUILD.gn
|
||||
+++ b/content/test/BUILD.gn
|
||||
@@ -502,6 +502,7 @@ static_library("test_support") {
|
||||
@@ -727,7 +727,7 @@ index 0f5d5c69bcab6feb8b2f3de86e3324d95f2efc31..c59fbd5d57055991d2c9a1d16633d1b8
|
||||
|
||||
public_deps = [
|
||||
":test_interfaces",
|
||||
@@ -2965,6 +2968,7 @@ test("content_unittests") {
|
||||
@@ -2968,6 +2971,7 @@ test("content_unittests") {
|
||||
}
|
||||
|
||||
configs += [ "//build/config:precompiled_headers" ]
|
||||
@@ -761,7 +761,7 @@ index cfb175b6985ed81021b236fc2ce14064e23beba7..81116f63eb9443165721064c26bacc71
|
||||
|
||||
if (is_mac) {
|
||||
diff --git a/device/bluetooth/bluetooth_adapter_mac.mm b/device/bluetooth/bluetooth_adapter_mac.mm
|
||||
index 9d7b9d0b3a10a9b2cb87b892f6d1c952928669f5..b962993c83431af9d064a891d0f3d865dac70428 100644
|
||||
index 4244e70c523d584fb796f4ce741376c6f72531cd..25db1e83fefecd01820923e5d182b882426eebfd 100644
|
||||
--- a/device/bluetooth/bluetooth_adapter_mac.mm
|
||||
+++ b/device/bluetooth/bluetooth_adapter_mac.mm
|
||||
@@ -39,6 +39,7 @@
|
||||
@@ -791,7 +791,7 @@ index 9d7b9d0b3a10a9b2cb87b892f6d1c952928669f5..b962993c83431af9d064a891d0f3d865
|
||||
device_paired_status_callback_(
|
||||
base::BindRepeating(&IsDeviceSystemPaired)) {
|
||||
}
|
||||
@@ -310,8 +314,12 @@ bool IsDeviceSystemPaired(const std::string& device_address) {
|
||||
@@ -297,8 +301,12 @@ bool IsDeviceSystemPaired(const std::string& device_address) {
|
||||
}
|
||||
|
||||
bool BluetoothAdapterMac::SetPoweredImpl(bool powered) {
|
||||
@@ -817,7 +817,7 @@ index a4f541e3f4095a0f537137ae371555adc80c0023..f93f0b5bf8c47efbc67039d50e3bcd29
|
||||
if (is_ios) {
|
||||
sources += [ "image_transport_surface_ios.mm" ]
|
||||
diff --git a/gpu/ipc/service/image_transport_surface_overlay_mac.h b/gpu/ipc/service/image_transport_surface_overlay_mac.h
|
||||
index d75db1f8fbdf12cf07ba19e3f2c68136ef33f021..dc0238d5a78b434c722b84adf3dbbcebaa19e847 100644
|
||||
index 36322ddd3047f96569f35807541a37d3c6672b09..3162cb6e3dce2c44e5b1e5f33f9177da832d26aa 100644
|
||||
--- a/gpu/ipc/service/image_transport_surface_overlay_mac.h
|
||||
+++ b/gpu/ipc/service/image_transport_surface_overlay_mac.h
|
||||
@@ -23,7 +23,9 @@
|
||||
@@ -1617,7 +1617,7 @@ index cd6c9a924dce762ff935ef722c8873c974772225..b162795219e0fac3d9caa6bbfead126c
|
||||
sources += [
|
||||
"test/desktop_window_tree_host_win_test_api.cc",
|
||||
diff --git a/ui/views/cocoa/native_widget_mac_ns_window_host.h b/ui/views/cocoa/native_widget_mac_ns_window_host.h
|
||||
index 11eaaf61d4ca39a0e2a0fd8df0e7e671b33d6413..13ca9dfacc92702af348f137cb0b095e441a5245 100644
|
||||
index e92ca79bebffde146bd0d8778f126651f44e527e..298f06095ea598348eec489b0a4be737945b87de 100644
|
||||
--- a/ui/views/cocoa/native_widget_mac_ns_window_host.h
|
||||
+++ b/ui/views/cocoa/native_widget_mac_ns_window_host.h
|
||||
@@ -31,7 +31,9 @@
|
||||
@@ -1630,7 +1630,7 @@ index 11eaaf61d4ca39a0e2a0fd8df0e7e671b33d6413..13ca9dfacc92702af348f137cb0b095e
|
||||
@class NSView;
|
||||
|
||||
namespace remote_cocoa {
|
||||
@@ -470,10 +472,12 @@ class VIEWS_EXPORT NativeWidgetMacNSWindowHost
|
||||
@@ -475,10 +477,12 @@ class VIEWS_EXPORT NativeWidgetMacNSWindowHost
|
||||
mojo::AssociatedRemote<remote_cocoa::mojom::NativeWidgetNSWindow>
|
||||
remote_ns_window_remote_;
|
||||
|
||||
@@ -1644,7 +1644,7 @@ index 11eaaf61d4ca39a0e2a0fd8df0e7e671b33d6413..13ca9dfacc92702af348f137cb0b095e
|
||||
// Used to force the NSApplication's focused accessibility element to be the
|
||||
// views::Views accessibility tree when the NSView for this is focused.
|
||||
diff --git a/ui/views/cocoa/native_widget_mac_ns_window_host.mm b/ui/views/cocoa/native_widget_mac_ns_window_host.mm
|
||||
index 7e071a6aad7457265846f6316e4a72bcff7f1a0b..d81d117b7e2372d6ad6795a85f48e85f8f49efa0 100644
|
||||
index 8dc2fc9768da17f8635dce99da218450b231cafe..a88e24a51070ba906d3b858f8492ebe39d372c69 100644
|
||||
--- a/ui/views/cocoa/native_widget_mac_ns_window_host.mm
|
||||
+++ b/ui/views/cocoa/native_widget_mac_ns_window_host.mm
|
||||
@@ -345,7 +345,11 @@ void HandleAccelerator(const ui::Accelerator& accelerator,
|
||||
@@ -1671,7 +1671,7 @@ index 7e071a6aad7457265846f6316e4a72bcff7f1a0b..d81d117b7e2372d6ad6795a85f48e85f
|
||||
}
|
||||
|
||||
remote_cocoa::mojom::NativeWidgetNSWindow*
|
||||
@@ -1280,9 +1288,11 @@ void HandleAccelerator(const ui::Accelerator& accelerator,
|
||||
@@ -1297,9 +1305,11 @@ void HandleAccelerator(const ui::Accelerator& accelerator,
|
||||
// for PWAs. However this breaks accessibility on in-process windows,
|
||||
// so set it back to NO when a local window gains focus. See
|
||||
// https://crbug.com/41485830.
|
||||
@@ -1683,7 +1683,7 @@ index 7e071a6aad7457265846f6316e4a72bcff7f1a0b..d81d117b7e2372d6ad6795a85f48e85f
|
||||
// Explicitly set the keyboard accessibility state on regaining key
|
||||
// window status.
|
||||
if (is_key && is_content_first_responder)
|
||||
@@ -1442,17 +1452,20 @@ void HandleAccelerator(const ui::Accelerator& accelerator,
|
||||
@@ -1459,17 +1469,20 @@ void HandleAccelerator(const ui::Accelerator& accelerator,
|
||||
void NativeWidgetMacNSWindowHost::SetRemoteAccessibilityTokens(
|
||||
const std::vector<uint8_t>& window_token,
|
||||
const std::vector<uint8_t>& view_token) {
|
||||
@@ -1704,7 +1704,7 @@ index 7e071a6aad7457265846f6316e4a72bcff7f1a0b..d81d117b7e2372d6ad6795a85f48e85f
|
||||
*pid = getpid();
|
||||
id element_id = GetNativeViewAccessible();
|
||||
|
||||
@@ -1465,6 +1478,7 @@ void HandleAccelerator(const ui::Accelerator& accelerator,
|
||||
@@ -1482,6 +1495,7 @@ void HandleAccelerator(const ui::Accelerator& accelerator,
|
||||
}
|
||||
|
||||
*token = ui::RemoteAccessibility::GetTokenForLocalElement(element_id);
|
||||
|
||||
@@ -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 62333599b3f30db1f34f05cf27144da0623dcbcd..5bb46cf0ed165f216fa4bf2813dfe2de18b15e94 100644
|
||||
index df74825a6b9ace016cd78b091f2a8d5768b300cd..b068b0de6c5676f36a8e8532d4fd59f6815f4dd1 100644
|
||||
--- a/services/network/network_context.cc
|
||||
+++ b/services/network/network_context.cc
|
||||
@@ -156,6 +156,11 @@
|
||||
@@ -136,7 +136,7 @@ index 62333599b3f30db1f34f05cf27144da0623dcbcd..5bb46cf0ed165f216fa4bf2813dfe2de
|
||||
void NetworkContext::CreateURLLoaderFactory(
|
||||
mojo::PendingReceiver<mojom::URLLoaderFactory> receiver,
|
||||
mojom::URLLoaderFactoryParamsPtr params) {
|
||||
@@ -2427,6 +2532,9 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
|
||||
@@ -2425,6 +2530,9 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
|
||||
std::move(cert_verifier));
|
||||
cert_verifier = std::move(cert_verifier_with_trust_anchors);
|
||||
#endif // BUILDFLAG(IS_CHROMEOS)
|
||||
@@ -147,7 +147,7 @@ index 62333599b3f30db1f34f05cf27144da0623dcbcd..5bb46cf0ed165f216fa4bf2813dfe2de
|
||||
|
||||
builder.SetCertVerifier(IgnoreErrorsCertVerifier::MaybeWrapCertVerifier(
|
||||
diff --git a/services/network/network_context.h b/services/network/network_context.h
|
||||
index fd9e08cc896533c372e8cbf6be890beda2815d20..06f2d96a0158348e151d90303a83a2ab263d4e5c 100644
|
||||
index 0a890a1d65cae565fb1c3fd195682b2cae5195c1..ec0e4a355e96394abe086325a6fdb37fcd3d1446 100644
|
||||
--- a/services/network/network_context.h
|
||||
+++ b/services/network/network_context.h
|
||||
@@ -113,6 +113,7 @@ class URLMatcher;
|
||||
@@ -167,7 +167,7 @@ index fd9e08cc896533c372e8cbf6be890beda2815d20..06f2d96a0158348e151d90303a83a2ab
|
||||
void ResetURLLoaderFactories() override;
|
||||
void GetViaObliviousHttp(
|
||||
mojom::ObliviousHttpRequestPtr request,
|
||||
@@ -905,6 +908,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
@@ -904,6 +907,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
std::vector<base::OnceClosure> dismount_closures_;
|
||||
#endif // BUILDFLAG(IS_DIRECTORY_TRANSFER_REQUIRED)
|
||||
|
||||
@@ -177,7 +177,7 @@ index fd9e08cc896533c372e8cbf6be890beda2815d20..06f2d96a0158348e151d90303a83a2ab
|
||||
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 41d8b7b417dd1fb25a631c9caa9140c42b8af633..a19f7cfaa35d9097a660ba0e3d7e402b47a8c1a4 100644
|
||||
index c2babfc29eaf0e190939173a75f9f35d1816d6bc..19f568b78c621ecbec64b8eb46c8c92d7af650f7 100644
|
||||
--- a/services/network/public/mojom/network_context.mojom
|
||||
+++ b/services/network/public/mojom/network_context.mojom
|
||||
@@ -297,6 +297,16 @@ struct SocketBrokerRemotes {
|
||||
@@ -208,7 +208,7 @@ index 41d8b7b417dd1fb25a631c9caa9140c42b8af633..a19f7cfaa35d9097a660ba0e3d7e402b
|
||||
CreateURLLoaderFactory(pending_receiver<URLLoaderFactory> url_loader_factory,
|
||||
URLLoaderFactoryParams params);
|
||||
diff --git a/services/network/test/test_network_context.h b/services/network/test/test_network_context.h
|
||||
index 69e536043162ae5bc9abd50e0439d1fb3d3851ff..f421326b04a048a655fd0ae9c098aa7e52807162 100644
|
||||
index f9aabc3d30ed66012402ef23027092be7e806b65..eb78d84ad3d6124313cf7b940425b0162d554fd6 100644
|
||||
--- a/services/network/test/test_network_context.h
|
||||
+++ b/services/network/test/test_network_context.h
|
||||
@@ -62,6 +62,8 @@ class TestNetworkContext : public mojom::NetworkContext {
|
||||
|
||||
@@ -133,10 +133,10 @@ index 38c8cf36fdf9366121c7ada96c167a4c9664952e..03b37fb62655a355e104870a088e4222
|
||||
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 d9554e07228d5eba7525f39c2caec26fd2fa7092..63a6c487ef9557510e673a4a4a60436789358bdc 100644
|
||||
index 8aae7c95521896aa61305f323cb84a89be268987..65b4037388fb32d4217a3b4c9133c32ab74b0224 100644
|
||||
--- a/content/browser/renderer_host/render_process_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
@@ -2096,7 +2096,7 @@ void RenderProcessHostImpl::CreateNotificationService(
|
||||
@@ -1956,7 +1956,7 @@ void RenderProcessHostImpl::CreateNotificationService(
|
||||
case RenderProcessHost::NotificationServiceCreatorType::kSharedWorker:
|
||||
case RenderProcessHost::NotificationServiceCreatorType::kDedicatedWorker: {
|
||||
storage_partition_impl_->GetPlatformNotificationContext()->CreateService(
|
||||
@@ -145,7 +145,7 @@ index d9554e07228d5eba7525f39c2caec26fd2fa7092..63a6c487ef9557510e673a4a4a604367
|
||||
creator_type, std::move(receiver));
|
||||
break;
|
||||
}
|
||||
@@ -2104,7 +2104,7 @@ void RenderProcessHostImpl::CreateNotificationService(
|
||||
@@ -1964,7 +1964,7 @@ void RenderProcessHostImpl::CreateNotificationService(
|
||||
CHECK(rfh);
|
||||
|
||||
storage_partition_impl_->GetPlatformNotificationContext()->CreateService(
|
||||
|
||||
@@ -10,7 +10,7 @@ an about:blank check to this area.
|
||||
Ref: https://chromium-review.googlesource.com/c/chromium/src/+/5403876
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_frame_host_impl.cc b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
index 8bd7ac353d046b27358ce28eafe2dc93139a3b19..2c85ddab555bdf27763f80333114d472a92028dd 100644
|
||||
index fc9898b73ed34850da9c78efb26d7fc9ea840ecb..876ef1bea3a5901ee88e51c662fbb1ba232a9cdd 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
@@ -783,8 +783,8 @@ void VerifyThatBrowserAndRendererCalculatedOriginsToCommitMatch(
|
||||
|
||||
@@ -39,7 +39,7 @@ index d236578cefc347e772305ac7ec54b9734e4aa20b..6bb89cea3b6b91ec8ea351ed60c4e405
|
||||
ui::ImageModel::FromVectorIcon(*icon, kColorPipWindowForeground,
|
||||
kCloseButtonIconSize));
|
||||
diff --git a/chrome/browser/ui/views/overlay/video_overlay_window_views.cc b/chrome/browser/ui/views/overlay/video_overlay_window_views.cc
|
||||
index 48102b17ba779e1a3eb7755f04a7dfa5ebbe40fc..24f680b6c50d8e35f7a4650788dc1494d467f6d0 100644
|
||||
index c67f93efc462c2ac7b15ecb3a2ffb2daaccbd1cc..507a695ba97c6321c4d1aa662bdd0206991e6c69 100644
|
||||
--- a/chrome/browser/ui/views/overlay/video_overlay_window_views.cc
|
||||
+++ b/chrome/browser/ui/views/overlay/video_overlay_window_views.cc
|
||||
@@ -17,9 +17,11 @@
|
||||
@@ -61,9 +61,9 @@ index 48102b17ba779e1a3eb7755f04a7dfa5ebbe40fc..24f680b6c50d8e35f7a4650788dc1494
|
||||
-#if BUILDFLAG(IS_WIN)
|
||||
+#if 0
|
||||
#include "chrome/browser/shell_integration_win.h"
|
||||
#include "content/public/browser/render_widget_host_view.h"
|
||||
#include "ui/aura/window.h"
|
||||
@@ -313,7 +315,7 @@ std::unique_ptr<VideoOverlayWindowViews> VideoOverlayWindowViews::Create(
|
||||
#include "ui/aura/window_tree_host.h"
|
||||
@@ -310,7 +312,7 @@ std::unique_ptr<VideoOverlayWindowViews> VideoOverlayWindowViews::Create(
|
||||
overlay_window->Init(std::move(params));
|
||||
overlay_window->OnRootViewReady();
|
||||
|
||||
|
||||
@@ -861,10 +861,10 @@ index 14de029740ffbebe06d309651c1a2c007d9fb96b..e9bf9c5bef2a9235260e7d6c8d26d415
|
||||
ScriptingThrottler scripting_throttler_;
|
||||
|
||||
diff --git a/content/browser/BUILD.gn b/content/browser/BUILD.gn
|
||||
index 8cba823f480c1b175631cd45c3d5b0e68b2b1c0c..1d35b701fd722d601763c3df9b8503958c5e4461 100644
|
||||
index ed9d01d7b2914140d33443ee10f707c765c38fdd..57708df678f9f7b0a8c9bbb672363a9144bb7b56 100644
|
||||
--- a/content/browser/BUILD.gn
|
||||
+++ b/content/browser/BUILD.gn
|
||||
@@ -2965,8 +2965,9 @@ source_set("browser") {
|
||||
@@ -2974,8 +2974,9 @@ source_set("browser") {
|
||||
"//ppapi/shared_impl",
|
||||
]
|
||||
|
||||
|
||||
@@ -30,10 +30,10 @@ index e8738cf3a033f69a2e8eaf06f1a9f61bf83e9066..b3777cb41cb5c6b007122ae808732765
|
||||
// RenderWidgetHost on the primary main frame, and false otherwise.
|
||||
virtual bool IsWidgetForPrimaryMainFrame(RenderWidgetHostImpl*);
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
index 209d69c3f2d000d88dafd23fc45134051f42ea5c..55ba60eeb42b18047edc77cc8e201fbbc0f8a6c4 100644
|
||||
index 6c0fe34bb30f68d43e1e111d1f4bf24e7a3281e5..5275c37f27ef61754f67c1b5fbcd4b126602929e 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
@@ -1986,6 +1986,9 @@ void RenderWidgetHostImpl::SetCursor(const ui::Cursor& cursor) {
|
||||
@@ -1985,6 +1985,9 @@ void RenderWidgetHostImpl::SetCursor(const ui::Cursor& cursor) {
|
||||
if (view_) {
|
||||
view_->UpdateCursor(cursor);
|
||||
}
|
||||
@@ -44,10 +44,10 @@ index 209d69c3f2d000d88dafd23fc45134051f42ea5c..55ba60eeb42b18047edc77cc8e201fbb
|
||||
|
||||
void RenderWidgetHostImpl::ShowContextMenuAtPoint(
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index a7279d4ea1a7db8f50f85f935e1e06d0f0987bc5..b21305c697648b577fda1da7d85d41ca72e56e0f 100644
|
||||
index be7ff72576a6bb59f7a302d2034460f3ff002a69..b8c0929a305a0c78ff0cc3c447019ca11905241a 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -5445,6 +5445,11 @@ TextInputManager* WebContentsImpl::GetTextInputManager() {
|
||||
@@ -5452,6 +5452,11 @@ TextInputManager* WebContentsImpl::GetTextInputManager() {
|
||||
return text_input_manager_.get();
|
||||
}
|
||||
|
||||
@@ -60,7 +60,7 @@ index a7279d4ea1a7db8f50f85f935e1e06d0f0987bc5..b21305c697648b577fda1da7d85d41ca
|
||||
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 557f90197b6e268e12afd26d44c5bf3a7b5eb0de..9a12bdd6994ddb2e346a7c961d07b3281b68fb8b 100644
|
||||
index 5f6692b4c5db97120554c70c5eb6b57ead338d04..a3ad36ba34c9360f1a135379b1a6ad853041bc9f 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.h
|
||||
+++ b/content/browser/web_contents/web_contents_impl.h
|
||||
@@ -1090,6 +1090,7 @@ class CONTENT_EXPORT WebContentsImpl
|
||||
|
||||
@@ -24,7 +24,7 @@ index de78ee035a47f8929b9bf357cdb571964791d4ce..16ed90ca643a4d2f81e17e34c02fa3d9
|
||||
const blink::WebMouseEvent& event,
|
||||
const ui::LatencyInfo& latency) {
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_view_base.h b/content/browser/renderer_host/render_widget_host_view_base.h
|
||||
index 3da1345bb79d162ace0aa6ae73adc0db8bcc5a41..966a1b9e34ac9462f70957209746cfe2bf7321bc 100644
|
||||
index abb2812168104f912f1e30132ed188083f62c34e..3d2d66d60db936e5b25ccb51d2a1dab21a3e3060 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_base.h
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_base.h
|
||||
@@ -27,9 +27,11 @@
|
||||
@@ -51,8 +51,8 @@ index 3da1345bb79d162ace0aa6ae73adc0db8bcc5a41..966a1b9e34ac9462f70957209746cfe2
|
||||
+class WebContentsView;
|
||||
class WebContentsAccessibility;
|
||||
class DelegatedFrameHost;
|
||||
|
||||
@@ -226,6 +230,9 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
|
||||
class SyntheticGestureTarget;
|
||||
@@ -232,6 +236,9 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
|
||||
const gfx::Rect& keyboard_rect) override {}
|
||||
bool IsHTMLFormPopup() const override;
|
||||
|
||||
@@ -62,7 +62,7 @@ index 3da1345bb79d162ace0aa6ae73adc0db8bcc5a41..966a1b9e34ac9462f70957209746cfe2
|
||||
// This only needs to be overridden by RenderWidgetHostViewBase subclasses
|
||||
// that handle content embedded within other RenderWidgetHostViews.
|
||||
gfx::PointF TransformPointToRootCoordSpaceF(
|
||||
@@ -276,6 +283,11 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
|
||||
@@ -282,6 +289,11 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
|
||||
// non-embeddable derived views.
|
||||
virtual RenderWidgetHostViewBase* GetRootView();
|
||||
|
||||
|
||||
@@ -52,7 +52,7 @@ 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 f5591b65de4fe94119f1177ed1162aa47f1d69a8..b1aa9154f1013d420d10117817789869207bd098 100644
|
||||
index 6e3f0a148b8e4c216e7d96472353859a7d8cc737..d88de5e36d6013224566bef67118e455765cff46 100644
|
||||
--- a/chrome/BUILD.gn
|
||||
+++ b/chrome/BUILD.gn
|
||||
@@ -1559,7 +1559,7 @@ if (is_chrome_branded && !is_android) {
|
||||
|
||||
@@ -6,10 +6,10 @@ 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 4028103044ba8996e0c547795520f96a3470a6a6..864d37c74946129e380f1ff06278952ea73365ce 100644
|
||||
index e9c5df9cec4cc7d15285843098b858320de72a3a..4a9045b59475577eac62a4ce99d18fac0d5b7195 100644
|
||||
--- a/third_party/blink/renderer/modules/websockets/websocket_channel_impl.cc
|
||||
+++ b/third_party/blink/renderer/modules/websockets/websocket_channel_impl.cc
|
||||
@@ -96,6 +96,17 @@ enum WebSocketOpCode {
|
||||
@@ -98,6 +98,17 @@ enum WebSocketOpCode {
|
||||
kOpCodeBinary = 0x2,
|
||||
};
|
||||
|
||||
@@ -27,7 +27,7 @@ index 4028103044ba8996e0c547795520f96a3470a6a6..864d37c74946129e380f1ff06278952e
|
||||
} // namespace
|
||||
|
||||
void WebSocketChannelImpl::MessageDataDeleter::operator()(char* p) const {
|
||||
@@ -286,7 +297,10 @@ bool WebSocketChannelImpl::Connect(const KURL& url, const String& protocol) {
|
||||
@@ -288,7 +299,10 @@ bool WebSocketChannelImpl::Connect(const KURL& url, const String& protocol) {
|
||||
// even if the `WebSocketChannel` is closed.
|
||||
feature_handle_for_scheduler_ = scheduler->RegisterFeature(
|
||||
SchedulingPolicy::Feature::kWebSocket,
|
||||
|
||||
@@ -22,10 +22,10 @@ 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 63a6c487ef9557510e673a4a4a60436789358bdc..a7310f168d82cfb23590d2355921427f723bcf61 100644
|
||||
index 65b4037388fb32d4217a3b4c9133c32ab74b0224..42a6355b84456d717673a38f28d766112bbc0148 100644
|
||||
--- a/content/browser/renderer_host/render_process_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
@@ -1741,9 +1741,15 @@ bool RenderProcessHostImpl::Init() {
|
||||
@@ -1601,9 +1601,15 @@ bool RenderProcessHostImpl::Init() {
|
||||
std::unique_ptr<SandboxedProcessLauncherDelegate> sandbox_delegate =
|
||||
std::make_unique<RendererSandboxedProcessLauncherDelegateWin>(
|
||||
*cmd_line, IsPdf(), /*is_jit_disabled=*/IsPdf());
|
||||
@@ -42,7 +42,7 @@ index 63a6c487ef9557510e673a4a4a60436789358bdc..a7310f168d82cfb23590d2355921427f
|
||||
|
||||
auto file_data = std::make_unique<ChildProcessLauncherFileData>();
|
||||
diff --git a/content/browser/renderer_host/renderer_sandboxed_process_launcher_delegate.cc b/content/browser/renderer_host/renderer_sandboxed_process_launcher_delegate.cc
|
||||
index dce5ba05c3ba1d476e1dfecb27942fd5e913ff88..f77ac77e9942a567a47c229838150385975f0756 100644
|
||||
index 01c5da99e5bd8dd9d38e5cec9ad4f953e8167cbe..2005dc7c90d1851f9368a7ef3231f4cca52fafca 100644
|
||||
--- a/content/browser/renderer_host/renderer_sandboxed_process_launcher_delegate.cc
|
||||
+++ b/content/browser/renderer_host/renderer_sandboxed_process_launcher_delegate.cc
|
||||
@@ -35,6 +35,9 @@ namespace content {
|
||||
|
||||
@@ -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 87aa67836b71b2beafc79ca534a1c9d6fca66d3c..c3029038f3ba1c137fabd88b4a81189a1354c518 100644
|
||||
index 69e6473166679bce52389be060dafc19096946c7..ac8d2292e6e3c47e94cf863fa67b4de0c00be130 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -3650,6 +3650,13 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
|
||||
@@ -3657,6 +3657,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 87aa67836b71b2beafc79ca534a1c9d6fca66d3c..c3029038f3ba1c137fabd88b4a81189a
|
||||
std::unique_ptr<WebContentsViewDelegate> delegate =
|
||||
GetContentClient()->browser()->GetWebContentsViewDelegate(this);
|
||||
|
||||
@@ -3660,6 +3667,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
|
||||
@@ -3667,6 +3674,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
|
||||
view_ = CreateWebContentsView(this, std::move(delegate),
|
||||
&render_view_host_delegate_view_);
|
||||
}
|
||||
@@ -35,10 +35,10 @@ index 87aa67836b71b2beafc79ca534a1c9d6fca66d3c..c3029038f3ba1c137fabd88b4a81189a
|
||||
CHECK(view_.get());
|
||||
|
||||
diff --git a/content/public/browser/web_contents.h b/content/public/browser/web_contents.h
|
||||
index 0a3aa41c18f2141a0fb45ec6e424ef49f7ee607e..c20612d82ec0f922823b3f46244ad92138592c15 100644
|
||||
index 36c71b1c9b401438177034433b7f665031c763d5..322099129e42cb822a70700ef141f90fc6ecdc2b 100644
|
||||
--- a/content/public/browser/web_contents.h
|
||||
+++ b/content/public/browser/web_contents.h
|
||||
@@ -106,10 +106,13 @@ class BrowserContext;
|
||||
@@ -109,10 +109,13 @@ class BrowserContext;
|
||||
class BrowserPluginGuestDelegate;
|
||||
class RenderFrameHost;
|
||||
class RenderViewHost;
|
||||
@@ -52,7 +52,7 @@ index 0a3aa41c18f2141a0fb45ec6e424ef49f7ee607e..c20612d82ec0f922823b3f46244ad921
|
||||
class WebUI;
|
||||
struct DropData;
|
||||
struct MHTMLGenerationParams;
|
||||
@@ -256,6 +259,10 @@ class WebContents : public PageNavigator,
|
||||
@@ -259,6 +262,10 @@ class WebContents : public PageNavigator,
|
||||
network::mojom::WebSandboxFlags starting_sandbox_flags =
|
||||
network::mojom::WebSandboxFlags::kNone;
|
||||
|
||||
|
||||
@@ -15,10 +15,10 @@ 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 af4354e4417ecca880fabddb1f9368e877f14ee4..8bd7ac353d046b27358ce28eafe2dc93139a3b19 100644
|
||||
index 018f04380c2d04bfaaac138c2b059bda575036c8..fc9898b73ed34850da9c78efb26d7fc9ea840ecb 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
@@ -7713,6 +7713,17 @@ void RenderFrameHostImpl::EnterFullscreen(
|
||||
@@ -7716,6 +7716,17 @@ void RenderFrameHostImpl::EnterFullscreen(
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,10 +37,10 @@ index af4354e4417ecca880fabddb1f9368e877f14ee4..8bd7ac353d046b27358ce28eafe2dc93
|
||||
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 c3029038f3ba1c137fabd88b4a81189a1354c518..f0d4891adfb86c1ff99fe52fb8b3911076f01e2a 100644
|
||||
index ac8d2292e6e3c47e94cf863fa67b4de0c00be130..8b47c0901b2d416ded059d64a133f8af377ce130 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -3905,21 +3905,25 @@ KeyboardEventProcessingResult WebContentsImpl::PreHandleKeyboardEvent(
|
||||
@@ -3912,21 +3912,25 @@ KeyboardEventProcessingResult WebContentsImpl::PreHandleKeyboardEvent(
|
||||
const input::NativeWebKeyboardEvent& event) {
|
||||
OPTIONAL_TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("content.verbose"),
|
||||
"WebContentsImpl::PreHandleKeyboardEvent");
|
||||
@@ -78,7 +78,7 @@ index c3029038f3ba1c137fabd88b4a81189a1354c518..f0d4891adfb86c1ff99fe52fb8b39110
|
||||
}
|
||||
|
||||
bool WebContentsImpl::HandleMouseEvent(const blink::WebMouseEvent& event) {
|
||||
@@ -4076,7 +4080,7 @@ void WebContentsImpl::EnterFullscreenMode(
|
||||
@@ -4083,7 +4087,7 @@ void WebContentsImpl::EnterFullscreenMode(
|
||||
OPTIONAL_TRACE_EVENT0("content", "WebContentsImpl::EnterFullscreenMode");
|
||||
DCHECK(CanEnterFullscreenMode(requesting_frame));
|
||||
DCHECK(requesting_frame->IsActive());
|
||||
|
||||
@@ -26,10 +26,10 @@ index 7f934695ad22e27a02aba16a5ec1b0d99b03a603..5e99d69adde3cb32e588d94bef84ed2f
|
||||
// An empty URL is returned if the URL is not overriden.
|
||||
virtual GURL OverrideFlashEmbedWithHTML(const GURL& url);
|
||||
diff --git a/content/renderer/renderer_blink_platform_impl.cc b/content/renderer/renderer_blink_platform_impl.cc
|
||||
index e7807791da331e4fdec2810438151801c9a54e75..8301316da7b61ed3512ba1ab3330056ac9931f88 100644
|
||||
index 23a15a223206a2e99bd0ee7711e9592e3749fe7c..d0cc959bb3a2bacf43d4acff26df9582055efa61 100644
|
||||
--- a/content/renderer/renderer_blink_platform_impl.cc
|
||||
+++ b/content/renderer/renderer_blink_platform_impl.cc
|
||||
@@ -854,6 +854,12 @@ void RendererBlinkPlatformImpl::WillStopWorkerThread() {
|
||||
@@ -871,6 +871,12 @@ void RendererBlinkPlatformImpl::WillStopWorkerThread() {
|
||||
WorkerThreadRegistry::Instance()->WillStopCurrentWorkerThread();
|
||||
}
|
||||
|
||||
|
||||
@@ -35,10 +35,10 @@ index 5e99d69adde3cb32e588d94bef84ed2ff7ab9334..f3ecba82c33a27e0a0b8e28948880154
|
||||
// from the worker thread.
|
||||
virtual void WillDestroyWorkerContextOnWorkerThread(
|
||||
diff --git a/content/renderer/renderer_blink_platform_impl.cc b/content/renderer/renderer_blink_platform_impl.cc
|
||||
index 8301316da7b61ed3512ba1ab3330056ac9931f88..6e476ba63472134ffec92318d6b00e0c1f7daf31 100644
|
||||
index d0cc959bb3a2bacf43d4acff26df9582055efa61..9269bd0a139304467c295984aacefd6e5d19f98f 100644
|
||||
--- a/content/renderer/renderer_blink_platform_impl.cc
|
||||
+++ b/content/renderer/renderer_blink_platform_impl.cc
|
||||
@@ -866,6 +866,12 @@ void RendererBlinkPlatformImpl::WorkerContextCreated(
|
||||
@@ -883,6 +883,12 @@ void RendererBlinkPlatformImpl::WorkerContextCreated(
|
||||
worker);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
remove_allcan_read_write.patch
|
||||
use_new_constructor_for_scriptorigin_when_17_x.patch
|
||||
fix_define_nan_copyablepersistenttraits_for_v8_12_5.patch
|
||||
remove_deprecated_v8_isolate_idlenotificationdeadline.patch
|
||||
remove_several_apis_deprecated_in_version_12_6.patch
|
||||
apply_allcan_read_write_test.patch
|
||||
apply_allcan_read_write.patch
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Samuel Attard <marshallofsound@electronjs.org>
|
||||
Date: Tue, 18 Jun 2024 15:59:42 -0700
|
||||
Subject: Remove AllCan Read/Write
|
||||
From: Keeley Hammond <khammond@slack-corp.com>
|
||||
Date: Thu, 20 Jun 2024 14:42:08 -0700
|
||||
Subject: Remove Allcan Read Write
|
||||
|
||||
Check for NODE_21_0_MODULE_VERSION
|
||||
|
||||
Refs https://chromium-review.googlesource.com/c/v8/v8/+/5006387
|
||||
Should be upstreamed.
|
||||
@@ -15,9 +17,10 @@ Steps for upstreaming this patch:
|
||||
- Get a new module version assigned for Electron 29 in nodejs/node
|
||||
- Update NODE_21_0_MODULE_VERSION to the new version number
|
||||
- Upstream patch to nodejs/nan before Electron 29 is branched
|
||||
- Ensure that methodswithdata-test.js uses LF line endings
|
||||
|
||||
diff --git a/nan.h b/nan.h
|
||||
index 2a68349448c163fa29af327a03b11678e61f5789..6c4fe9e46f69234100e7e634826b38c9e3e17e37 100644
|
||||
index 9a9112afe0cc94ce58ed3cce9763ace7c160a932..f4865a77e60d5105ed2426037984ddcbfa58bbca 100644
|
||||
--- a/nan.h
|
||||
+++ b/nan.h
|
||||
@@ -47,6 +47,7 @@
|
||||
@@ -28,7 +31,7 @@ index 2a68349448c163fa29af327a03b11678e61f5789..6c4fe9e46f69234100e7e634826b38c9
|
||||
|
||||
#ifdef _MSC_VER
|
||||
# define NAN_HAS_CPLUSPLUS_11 (_MSC_VER >= 1800)
|
||||
@@ -2517,7 +2518,9 @@ NAN_DEPRECATED inline void SetAccessor(
|
||||
@@ -2525,7 +2526,9 @@ NAN_DEPRECATED inline void SetAccessor(
|
||||
, GetterCallback getter
|
||||
, SetterCallback setter
|
||||
, v8::Local<v8::Value> data
|
||||
@@ -38,7 +41,7 @@ index 2a68349448c163fa29af327a03b11678e61f5789..6c4fe9e46f69234100e7e634826b38c9
|
||||
, v8::PropertyAttribute attribute
|
||||
, imp::Sig signature) {
|
||||
HandleScope scope;
|
||||
@@ -2545,17 +2548,28 @@ NAN_DEPRECATED inline void SetAccessor(
|
||||
@@ -2553,17 +2556,28 @@ NAN_DEPRECATED inline void SetAccessor(
|
||||
obj->SetInternalField(imp::kDataIndex, data);
|
||||
}
|
||||
|
||||
@@ -67,7 +70,7 @@ index 2a68349448c163fa29af327a03b11678e61f5789..6c4fe9e46f69234100e7e634826b38c9
|
||||
}
|
||||
|
||||
inline void SetAccessor(
|
||||
@@ -2564,7 +2578,9 @@ inline void SetAccessor(
|
||||
@@ -2572,7 +2586,9 @@ inline void SetAccessor(
|
||||
, GetterCallback getter
|
||||
, SetterCallback setter = 0
|
||||
, v8::Local<v8::Value> data = v8::Local<v8::Value>()
|
||||
@@ -77,7 +80,7 @@ index 2a68349448c163fa29af327a03b11678e61f5789..6c4fe9e46f69234100e7e634826b38c9
|
||||
, v8::PropertyAttribute attribute = v8::None) {
|
||||
HandleScope scope;
|
||||
|
||||
@@ -2591,14 +2607,25 @@ inline void SetAccessor(
|
||||
@@ -2599,14 +2615,25 @@ inline void SetAccessor(
|
||||
obj->SetInternalField(imp::kDataIndex, data);
|
||||
}
|
||||
|
||||
@@ -103,7 +106,7 @@ index 2a68349448c163fa29af327a03b11678e61f5789..6c4fe9e46f69234100e7e634826b38c9
|
||||
}
|
||||
|
||||
inline bool SetAccessor(
|
||||
@@ -2634,7 +2661,15 @@ inline bool SetAccessor(
|
||||
@@ -2642,7 +2669,15 @@ inline bool SetAccessor(
|
||||
, New<v8::External>(reinterpret_cast<void *>(setter)));
|
||||
}
|
||||
|
||||
@@ -139,24 +142,47 @@ index e6ad45737e2ac18da3fa936b1de618e7389933bc..025f5b66774c2f5fe0ccb98c91fc714d
|
||||
t.equal(derived.prop2, 'setting a new value')
|
||||
- t.equal(settergetter.prop2, 'setting a new value')
|
||||
})
|
||||
diff --git a/test/js/methodswithdata-test.js b/test/js/methodswithdata-test.js
|
||||
index 9f4fc5246f1ca3d8faadc9a72d49e14a6a190e32..795538510431fb3b633be37f916d4ce1955c808a 100644
|
||||
--- a/test/js/methodswithdata-test.js
|
||||
+++ b/test/js/methodswithdata-test.js
|
||||
@@ -16,7 +16,7 @@ test('SetMethod with data', function (t) {
|
||||
});
|
||||
|
||||
test('accessors with data', function (t) {
|
||||
- t.plan(7)
|
||||
+ t.plan(6)
|
||||
var settergetter = bindings.create()
|
||||
t.equal(settergetter.prop1, 'this is property 1')
|
||||
t.ok(settergetter.prop2 === '')
|
||||
@@ -33,6 +33,5 @@ test('accessors with data', function (t) {
|
||||
t.equal(derived.prop1, 'this is property 1')
|
||||
derived.prop2 = 'setting a new value'
|
||||
t.equal(derived.prop2, 'setting a new value')
|
||||
- t.equal(settergetter.prop2, 'setting a new value')
|
||||
})
|
||||
|
||||
diff --git a/test/js/methodswithdatalf-test.js b/test/js/methodswithdatalf-test.js
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..5db3fae7e075b3428810948bdcfee5b8b97c343c
|
||||
--- /dev/null
|
||||
+++ b/test/js/methodswithdatalf-test.js
|
||||
@@ -0,0 +1,37 @@
|
||||
+/*********************************************************************
|
||||
+ * NAN - Native Abstractions for Node.js
|
||||
+ *
|
||||
+ * Copyright (c) 2019 NAN contributors
|
||||
+ *
|
||||
+ * MIT License <https://github.com/nodejs/nan/blob/master/LICENSE.md>
|
||||
+ ********************************************************************/
|
||||
+
|
||||
+const test = require('tap').test
|
||||
+ , testRoot = require('path').resolve(__dirname, '..')
|
||||
+ , bindings = require('bindings')({ module_root: testRoot, bindings: 'methodswithdata' })
|
||||
+
|
||||
+test('SetMethod with data', function (t) {
|
||||
+ t.plan(1);
|
||||
+ t.ok(bindings.testWithData());
|
||||
+});
|
||||
+
|
||||
+test('accessors with data', function (t) {
|
||||
+ t.plan(7)
|
||||
+ var settergetter = bindings.create()
|
||||
+ t.equal(settergetter.prop1, 'this is property 1')
|
||||
+ t.ok(settergetter.prop2 === '')
|
||||
+ settergetter.prop2 = 'setting a value'
|
||||
+ t.equal(settergetter.prop2, 'setting a value')
|
||||
+ t.equal(settergetter.log(),
|
||||
+ 'New()\n' +
|
||||
+ 'Prop1:GETTER(this is property 1)\n' +
|
||||
+ 'Prop2:GETTER()\n' +
|
||||
+ 'Prop2:SETTER(setting a value)\n' +
|
||||
+ 'Prop2:GETTER(setting a value)\n'
|
||||
+ )
|
||||
+ var derived = Object.create(settergetter)
|
||||
+ t.equal(derived.prop1, 'this is property 1')
|
||||
+ derived.prop2 = 'setting a new value'
|
||||
+ t.equal(derived.prop2, 'setting a new value')
|
||||
+ t.equal(settergetter.prop2, 'setting a new value')
|
||||
+ })
|
||||
\ No newline at end of file
|
||||
58
patches/nan/apply_allcan_read_write_test.patch
Normal file
58
patches/nan/apply_allcan_read_write_test.patch
Normal file
@@ -0,0 +1,58 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Alice Zhao <alice@makenotion.com>
|
||||
Date: Thu, 20 Jun 2024 14:50:13 -0700
|
||||
Subject: test: delete test file for allcan_read_write patch
|
||||
|
||||
Refs https://chromium-review.googlesource.com/c/v8/v8/+/5006387
|
||||
Should be upstreamed.
|
||||
|
||||
This patch is seperated from the apply_allcan_read_write.patch
|
||||
because the file itself has CRLF line endings and need to be patched
|
||||
seperately. When this patch is removed, also remove the eol=crlf
|
||||
exception in .gitattributes.
|
||||
|
||||
diff --git a/test/js/methodswithdata-test.js b/test/js/methodswithdata-test.js
|
||||
deleted file mode 100644
|
||||
index 9f4fc5246f1ca3d8faadc9a72d49e14a6a190e32..0000000000000000000000000000000000000000
|
||||
--- a/test/js/methodswithdata-test.js
|
||||
+++ /dev/null
|
||||
@@ -1,38 +0,0 @@
|
||||
-/*********************************************************************
|
||||
- * NAN - Native Abstractions for Node.js
|
||||
- *
|
||||
- * Copyright (c) 2019 NAN contributors
|
||||
- *
|
||||
- * MIT License <https://github.com/nodejs/nan/blob/master/LICENSE.md>
|
||||
- ********************************************************************/
|
||||
-
|
||||
-const test = require('tap').test
|
||||
- , testRoot = require('path').resolve(__dirname, '..')
|
||||
- , bindings = require('bindings')({ module_root: testRoot, bindings: 'methodswithdata' })
|
||||
-
|
||||
-test('SetMethod with data', function (t) {
|
||||
- t.plan(1);
|
||||
- t.ok(bindings.testWithData());
|
||||
-});
|
||||
-
|
||||
-test('accessors with data', function (t) {
|
||||
- t.plan(7)
|
||||
- var settergetter = bindings.create()
|
||||
- t.equal(settergetter.prop1, 'this is property 1')
|
||||
- t.ok(settergetter.prop2 === '')
|
||||
- settergetter.prop2 = 'setting a value'
|
||||
- t.equal(settergetter.prop2, 'setting a value')
|
||||
- t.equal(settergetter.log(),
|
||||
- 'New()\n' +
|
||||
- 'Prop1:GETTER(this is property 1)\n' +
|
||||
- 'Prop2:GETTER()\n' +
|
||||
- 'Prop2:SETTER(setting a value)\n' +
|
||||
- 'Prop2:GETTER(setting a value)\n'
|
||||
- )
|
||||
- var derived = Object.create(settergetter)
|
||||
- t.equal(derived.prop1, 'this is property 1')
|
||||
- derived.prop2 = 'setting a new value'
|
||||
- t.equal(derived.prop2, 'setting a new value')
|
||||
- t.equal(settergetter.prop2, 'setting a new value')
|
||||
- })
|
||||
-
|
||||
\ No newline at end of file
|
||||
@@ -52,3 +52,4 @@ src_remove_dependency_on_wrapper-descriptor-based_cppheap.patch
|
||||
test_update_v8-stats_test_for_v8_12_6.patch
|
||||
chore_remove_calls_to_v8_functioncallbackinfo_holder.patch
|
||||
src_do_not_use_soon-to-be-deprecated_v8_api.patch
|
||||
fix_add_property_query_interceptors.patch
|
||||
|
||||
574
patches/node/fix_add_property_query_interceptors.patch
Normal file
574
patches/node/fix_add_property_query_interceptors.patch
Normal file
@@ -0,0 +1,574 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: VerteDinde <vertedinde@electronjs.org>
|
||||
Date: Mon, 24 Jun 2024 21:48:40 -0700
|
||||
Subject: fix: add property query interceptors
|
||||
|
||||
This commit cherry-picks an upstream interceptor API change
|
||||
from node-v8/canary to accomodate V8's upstream changes to old
|
||||
interceptor APIs.
|
||||
|
||||
Node PR: https://github.com/nodejs/node-v8/commit/d1f18b0bf16efbc1e54ba04a54735ce4683cb936
|
||||
CL: https://chromium-review.googlesource.com/c/v8/v8/+/5630388
|
||||
|
||||
This patch can be removed when the node change is incorporated into main.
|
||||
|
||||
diff --git a/src/node_contextify.cc b/src/node_contextify.cc
|
||||
index f6969e635f692b17b4efca1dfbee086a0199db6e..6ace71b04e9da761c77838dde2abd8088abcb6c4 100644
|
||||
--- a/src/node_contextify.cc
|
||||
+++ b/src/node_contextify.cc
|
||||
@@ -49,6 +49,7 @@ using v8::FunctionTemplate;
|
||||
using v8::HandleScope;
|
||||
using v8::IndexedPropertyHandlerConfiguration;
|
||||
using v8::Int32;
|
||||
+using v8::Intercepted;
|
||||
using v8::Isolate;
|
||||
using v8::Just;
|
||||
using v8::Local;
|
||||
@@ -457,14 +458,15 @@ bool ContextifyContext::IsStillInitializing(const ContextifyContext* ctx) {
|
||||
}
|
||||
|
||||
// static
|
||||
-void ContextifyContext::PropertyGetterCallback(
|
||||
- Local<Name> property,
|
||||
- const PropertyCallbackInfo<Value>& args) {
|
||||
+Intercepted ContextifyContext::PropertyGetterCallback(
|
||||
+ Local<Name> property, const PropertyCallbackInfo<Value>& args) {
|
||||
Environment* env = Environment::GetCurrent(args);
|
||||
ContextifyContext* ctx = ContextifyContext::Get(args);
|
||||
|
||||
// Still initializing
|
||||
- if (IsStillInitializing(ctx)) return;
|
||||
+ if (IsStillInitializing(ctx)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
Local<Context> context = ctx->context();
|
||||
Local<Object> sandbox = ctx->sandbox();
|
||||
@@ -488,18 +490,22 @@ void ContextifyContext::PropertyGetterCallback(
|
||||
rv = ctx->global_proxy();
|
||||
|
||||
args.GetReturnValue().Set(rv);
|
||||
+ return Intercepted::kYes;
|
||||
}
|
||||
+ return Intercepted::kNo;
|
||||
}
|
||||
|
||||
// static
|
||||
-void ContextifyContext::PropertySetterCallback(
|
||||
+Intercepted ContextifyContext::PropertySetterCallback(
|
||||
Local<Name> property,
|
||||
Local<Value> value,
|
||||
- const PropertyCallbackInfo<Value>& args) {
|
||||
+ const PropertyCallbackInfo<void>& args) {
|
||||
ContextifyContext* ctx = ContextifyContext::Get(args);
|
||||
|
||||
// Still initializing
|
||||
- if (IsStillInitializing(ctx)) return;
|
||||
+ if (IsStillInitializing(ctx)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
Local<Context> context = ctx->context();
|
||||
PropertyAttribute attributes = PropertyAttribute::None;
|
||||
@@ -517,8 +523,9 @@ void ContextifyContext::PropertySetterCallback(
|
||||
(static_cast<int>(attributes) &
|
||||
static_cast<int>(PropertyAttribute::ReadOnly));
|
||||
|
||||
- if (read_only)
|
||||
- return;
|
||||
+ if (read_only) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
// true for x = 5
|
||||
// false for this.x = 5
|
||||
@@ -537,11 +544,16 @@ void ContextifyContext::PropertySetterCallback(
|
||||
|
||||
bool is_declared = is_declared_on_global_proxy || is_declared_on_sandbox;
|
||||
if (!is_declared && args.ShouldThrowOnError() && is_contextual_store &&
|
||||
- !is_function)
|
||||
- return;
|
||||
+ !is_function) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
- if (!is_declared && property->IsSymbol()) return;
|
||||
- if (ctx->sandbox()->Set(context, property, value).IsNothing()) return;
|
||||
+ if (!is_declared && property->IsSymbol()) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
+ if (ctx->sandbox()->Set(context, property, value).IsNothing()) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
Local<Value> desc;
|
||||
if (is_declared_on_sandbox &&
|
||||
@@ -555,19 +567,23 @@ void ContextifyContext::PropertySetterCallback(
|
||||
// We have to specify the return value for any contextual or get/set
|
||||
// property
|
||||
if (desc_obj->HasOwnProperty(context, env->get_string()).FromMaybe(false) ||
|
||||
- desc_obj->HasOwnProperty(context, env->set_string()).FromMaybe(false))
|
||||
+ desc_obj->HasOwnProperty(context, env->set_string()).FromMaybe(false)) {
|
||||
args.GetReturnValue().Set(value);
|
||||
+ return Intercepted::kYes;
|
||||
+ }
|
||||
}
|
||||
+ return Intercepted::kNo;
|
||||
}
|
||||
|
||||
// static
|
||||
-void ContextifyContext::PropertyDescriptorCallback(
|
||||
- Local<Name> property,
|
||||
- const PropertyCallbackInfo<Value>& args) {
|
||||
+Intercepted ContextifyContext::PropertyDescriptorCallback(
|
||||
+ Local<Name> property, const PropertyCallbackInfo<Value>& args) {
|
||||
ContextifyContext* ctx = ContextifyContext::Get(args);
|
||||
|
||||
// Still initializing
|
||||
- if (IsStillInitializing(ctx)) return;
|
||||
+ if (IsStillInitializing(ctx)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
Local<Context> context = ctx->context();
|
||||
|
||||
@@ -577,19 +593,23 @@ void ContextifyContext::PropertyDescriptorCallback(
|
||||
Local<Value> desc;
|
||||
if (sandbox->GetOwnPropertyDescriptor(context, property).ToLocal(&desc)) {
|
||||
args.GetReturnValue().Set(desc);
|
||||
+ return Intercepted::kYes;
|
||||
}
|
||||
}
|
||||
+ return Intercepted::kNo;
|
||||
}
|
||||
|
||||
// static
|
||||
-void ContextifyContext::PropertyDefinerCallback(
|
||||
+Intercepted ContextifyContext::PropertyDefinerCallback(
|
||||
Local<Name> property,
|
||||
const PropertyDescriptor& desc,
|
||||
- const PropertyCallbackInfo<Value>& args) {
|
||||
+ const PropertyCallbackInfo<void>& args) {
|
||||
ContextifyContext* ctx = ContextifyContext::Get(args);
|
||||
|
||||
// Still initializing
|
||||
- if (IsStillInitializing(ctx)) return;
|
||||
+ if (IsStillInitializing(ctx)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
Local<Context> context = ctx->context();
|
||||
Isolate* isolate = context->GetIsolate();
|
||||
@@ -608,7 +628,7 @@ void ContextifyContext::PropertyDefinerCallback(
|
||||
// If the property is set on the global as neither writable nor
|
||||
// configurable, don't change it on the global or sandbox.
|
||||
if (is_declared && read_only && dont_delete) {
|
||||
- return;
|
||||
+ return Intercepted::kNo;
|
||||
}
|
||||
|
||||
Local<Object> sandbox = ctx->sandbox();
|
||||
@@ -631,6 +651,9 @@ void ContextifyContext::PropertyDefinerCallback(
|
||||
desc.has_set() ? desc.set() : Undefined(isolate).As<Value>());
|
||||
|
||||
define_prop_on_sandbox(&desc_for_sandbox);
|
||||
+ // TODO(https://github.com/nodejs/node/issues/52634): this should return
|
||||
+ // kYes to behave according to the expected semantics.
|
||||
+ return Intercepted::kNo;
|
||||
} else {
|
||||
Local<Value> value =
|
||||
desc.has_value() ? desc.value() : Undefined(isolate).As<Value>();
|
||||
@@ -642,26 +665,32 @@ void ContextifyContext::PropertyDefinerCallback(
|
||||
PropertyDescriptor desc_for_sandbox(value);
|
||||
define_prop_on_sandbox(&desc_for_sandbox);
|
||||
}
|
||||
+ // TODO(https://github.com/nodejs/node/issues/52634): this should return
|
||||
+ // kYes to behave according to the expected semantics.
|
||||
+ return Intercepted::kNo;
|
||||
}
|
||||
}
|
||||
|
||||
// static
|
||||
-void ContextifyContext::PropertyDeleterCallback(
|
||||
- Local<Name> property,
|
||||
- const PropertyCallbackInfo<Boolean>& args) {
|
||||
+Intercepted ContextifyContext::PropertyDeleterCallback(
|
||||
+ Local<Name> property, const PropertyCallbackInfo<Boolean>& args) {
|
||||
ContextifyContext* ctx = ContextifyContext::Get(args);
|
||||
|
||||
// Still initializing
|
||||
- if (IsStillInitializing(ctx)) return;
|
||||
+ if (IsStillInitializing(ctx)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
Maybe<bool> success = ctx->sandbox()->Delete(ctx->context(), property);
|
||||
|
||||
- if (success.FromMaybe(false))
|
||||
- return;
|
||||
+ if (success.FromMaybe(false)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
// Delete failed on the sandbox, intercept and do not delete on
|
||||
// the global object.
|
||||
args.GetReturnValue().Set(false);
|
||||
+ return Intercepted::kYes;
|
||||
}
|
||||
|
||||
// static
|
||||
@@ -681,76 +710,84 @@ void ContextifyContext::PropertyEnumeratorCallback(
|
||||
}
|
||||
|
||||
// static
|
||||
-void ContextifyContext::IndexedPropertyGetterCallback(
|
||||
- uint32_t index,
|
||||
- const PropertyCallbackInfo<Value>& args) {
|
||||
+Intercepted ContextifyContext::IndexedPropertyGetterCallback(
|
||||
+ uint32_t index, const PropertyCallbackInfo<Value>& args) {
|
||||
ContextifyContext* ctx = ContextifyContext::Get(args);
|
||||
|
||||
// Still initializing
|
||||
- if (IsStillInitializing(ctx)) return;
|
||||
+ if (IsStillInitializing(ctx)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
- ContextifyContext::PropertyGetterCallback(
|
||||
+ return ContextifyContext::PropertyGetterCallback(
|
||||
Uint32ToName(ctx->context(), index), args);
|
||||
}
|
||||
|
||||
-
|
||||
-void ContextifyContext::IndexedPropertySetterCallback(
|
||||
+Intercepted ContextifyContext::IndexedPropertySetterCallback(
|
||||
uint32_t index,
|
||||
Local<Value> value,
|
||||
- const PropertyCallbackInfo<Value>& args) {
|
||||
+ const PropertyCallbackInfo<void>& args) {
|
||||
ContextifyContext* ctx = ContextifyContext::Get(args);
|
||||
|
||||
// Still initializing
|
||||
- if (IsStillInitializing(ctx)) return;
|
||||
+ if (IsStillInitializing(ctx)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
- ContextifyContext::PropertySetterCallback(
|
||||
+ return ContextifyContext::PropertySetterCallback(
|
||||
Uint32ToName(ctx->context(), index), value, args);
|
||||
}
|
||||
|
||||
// static
|
||||
-void ContextifyContext::IndexedPropertyDescriptorCallback(
|
||||
- uint32_t index,
|
||||
- const PropertyCallbackInfo<Value>& args) {
|
||||
+Intercepted ContextifyContext::IndexedPropertyDescriptorCallback(
|
||||
+ uint32_t index, const PropertyCallbackInfo<Value>& args) {
|
||||
ContextifyContext* ctx = ContextifyContext::Get(args);
|
||||
|
||||
// Still initializing
|
||||
- if (IsStillInitializing(ctx)) return;
|
||||
+ if (IsStillInitializing(ctx)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
- ContextifyContext::PropertyDescriptorCallback(
|
||||
+ return ContextifyContext::PropertyDescriptorCallback(
|
||||
Uint32ToName(ctx->context(), index), args);
|
||||
}
|
||||
|
||||
|
||||
-void ContextifyContext::IndexedPropertyDefinerCallback(
|
||||
+Intercepted ContextifyContext::IndexedPropertyDefinerCallback(
|
||||
uint32_t index,
|
||||
const PropertyDescriptor& desc,
|
||||
- const PropertyCallbackInfo<Value>& args) {
|
||||
+ const PropertyCallbackInfo<void>& args) {
|
||||
ContextifyContext* ctx = ContextifyContext::Get(args);
|
||||
|
||||
// Still initializing
|
||||
- if (IsStillInitializing(ctx)) return;
|
||||
+ if (IsStillInitializing(ctx)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
- ContextifyContext::PropertyDefinerCallback(
|
||||
+ return ContextifyContext::PropertyDefinerCallback(
|
||||
Uint32ToName(ctx->context(), index), desc, args);
|
||||
}
|
||||
|
||||
// static
|
||||
-void ContextifyContext::IndexedPropertyDeleterCallback(
|
||||
- uint32_t index,
|
||||
- const PropertyCallbackInfo<Boolean>& args) {
|
||||
+Intercepted ContextifyContext::IndexedPropertyDeleterCallback(
|
||||
+ uint32_t index, const PropertyCallbackInfo<Boolean>& args) {
|
||||
ContextifyContext* ctx = ContextifyContext::Get(args);
|
||||
|
||||
// Still initializing
|
||||
- if (IsStillInitializing(ctx)) return;
|
||||
+ if (IsStillInitializing(ctx)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
Maybe<bool> success = ctx->sandbox()->Delete(ctx->context(), index);
|
||||
|
||||
- if (success.FromMaybe(false))
|
||||
- return;
|
||||
+ if (success.FromMaybe(false)) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
|
||||
// Delete failed on the sandbox, intercept and do not delete on
|
||||
// the global object.
|
||||
args.GetReturnValue().Set(false);
|
||||
+ return Intercepted::kYes;
|
||||
}
|
||||
|
||||
void ContextifyScript::CreatePerIsolateProperties(
|
||||
diff --git a/src/node_contextify.h b/src/node_contextify.h
|
||||
index d42b5e0c544e726fc3f6d8392a554df9aa480fe9..ea2d513463057715127cb4b4f2d66b4cfcf71351 100644
|
||||
--- a/src/node_contextify.h
|
||||
+++ b/src/node_contextify.h
|
||||
@@ -107,42 +107,39 @@ class ContextifyContext : public BaseObject {
|
||||
const v8::FunctionCallbackInfo<v8::Value>& args);
|
||||
static void WeakCallback(
|
||||
const v8::WeakCallbackInfo<ContextifyContext>& data);
|
||||
- static void PropertyGetterCallback(
|
||||
+ static v8::Intercepted PropertyGetterCallback(
|
||||
v8::Local<v8::Name> property,
|
||||
const v8::PropertyCallbackInfo<v8::Value>& args);
|
||||
- static void PropertySetterCallback(
|
||||
+ static v8::Intercepted PropertySetterCallback(
|
||||
v8::Local<v8::Name> property,
|
||||
v8::Local<v8::Value> value,
|
||||
- const v8::PropertyCallbackInfo<v8::Value>& args);
|
||||
- static void PropertyDescriptorCallback(
|
||||
+ const v8::PropertyCallbackInfo<void>& args);
|
||||
+ static v8::Intercepted PropertyDescriptorCallback(
|
||||
v8::Local<v8::Name> property,
|
||||
const v8::PropertyCallbackInfo<v8::Value>& args);
|
||||
- static void PropertyDefinerCallback(
|
||||
+ static v8::Intercepted PropertyDefinerCallback(
|
||||
v8::Local<v8::Name> property,
|
||||
const v8::PropertyDescriptor& desc,
|
||||
- const v8::PropertyCallbackInfo<v8::Value>& args);
|
||||
- static void PropertyDeleterCallback(
|
||||
+ const v8::PropertyCallbackInfo<void>& args);
|
||||
+ static v8::Intercepted PropertyDeleterCallback(
|
||||
v8::Local<v8::Name> property,
|
||||
const v8::PropertyCallbackInfo<v8::Boolean>& args);
|
||||
static void PropertyEnumeratorCallback(
|
||||
const v8::PropertyCallbackInfo<v8::Array>& args);
|
||||
- static void IndexedPropertyGetterCallback(
|
||||
- uint32_t index,
|
||||
- const v8::PropertyCallbackInfo<v8::Value>& args);
|
||||
- static void IndexedPropertySetterCallback(
|
||||
+ static v8::Intercepted IndexedPropertyGetterCallback(
|
||||
+ uint32_t index, const v8::PropertyCallbackInfo<v8::Value>& args);
|
||||
+ static v8::Intercepted IndexedPropertySetterCallback(
|
||||
uint32_t index,
|
||||
v8::Local<v8::Value> value,
|
||||
- const v8::PropertyCallbackInfo<v8::Value>& args);
|
||||
- static void IndexedPropertyDescriptorCallback(
|
||||
- uint32_t index,
|
||||
- const v8::PropertyCallbackInfo<v8::Value>& args);
|
||||
- static void IndexedPropertyDefinerCallback(
|
||||
+ const v8::PropertyCallbackInfo<void>& args);
|
||||
+ static v8::Intercepted IndexedPropertyDescriptorCallback(
|
||||
+ uint32_t index, const v8::PropertyCallbackInfo<v8::Value>& args);
|
||||
+ static v8::Intercepted IndexedPropertyDefinerCallback(
|
||||
uint32_t index,
|
||||
const v8::PropertyDescriptor& desc,
|
||||
- const v8::PropertyCallbackInfo<v8::Value>& args);
|
||||
- static void IndexedPropertyDeleterCallback(
|
||||
- uint32_t index,
|
||||
- const v8::PropertyCallbackInfo<v8::Boolean>& args);
|
||||
+ const v8::PropertyCallbackInfo<void>& args);
|
||||
+ static v8::Intercepted IndexedPropertyDeleterCallback(
|
||||
+ uint32_t index, const v8::PropertyCallbackInfo<v8::Boolean>& args);
|
||||
|
||||
v8::Global<v8::Context> context_;
|
||||
std::unique_ptr<v8::MicrotaskQueue> microtask_queue_;
|
||||
diff --git a/src/node_env_var.cc b/src/node_env_var.cc
|
||||
index bce7ae07214ddf970a530db29ed6970e14b7a5ed..85f82180d48d6cfd7738cd7b1e504f23b38153e8 100644
|
||||
--- a/src/node_env_var.cc
|
||||
+++ b/src/node_env_var.cc
|
||||
@@ -16,6 +16,7 @@ using v8::DontEnum;
|
||||
using v8::FunctionTemplate;
|
||||
using v8::HandleScope;
|
||||
using v8::Integer;
|
||||
+using v8::Intercepted;
|
||||
using v8::Isolate;
|
||||
using v8::Just;
|
||||
using v8::Local;
|
||||
@@ -336,24 +337,27 @@ Maybe<bool> KVStore::AssignToObject(v8::Isolate* isolate,
|
||||
return Just(true);
|
||||
}
|
||||
|
||||
-static void EnvGetter(Local<Name> property,
|
||||
- const PropertyCallbackInfo<Value>& info) {
|
||||
+static Intercepted EnvGetter(Local<Name> property,
|
||||
+ const PropertyCallbackInfo<Value>& info) {
|
||||
Environment* env = Environment::GetCurrent(info);
|
||||
CHECK(env->has_run_bootstrapping_code());
|
||||
if (property->IsSymbol()) {
|
||||
- return info.GetReturnValue().SetUndefined();
|
||||
+ info.GetReturnValue().SetUndefined();
|
||||
+ return Intercepted::kYes;
|
||||
}
|
||||
CHECK(property->IsString());
|
||||
MaybeLocal<String> value_string =
|
||||
env->env_vars()->Get(env->isolate(), property.As<String>());
|
||||
if (!value_string.IsEmpty()) {
|
||||
info.GetReturnValue().Set(value_string.ToLocalChecked());
|
||||
+ return Intercepted::kYes;
|
||||
}
|
||||
+ return Intercepted::kNo;
|
||||
}
|
||||
|
||||
-static void EnvSetter(Local<Name> property,
|
||||
- Local<Value> value,
|
||||
- const PropertyCallbackInfo<Value>& info) {
|
||||
+static Intercepted EnvSetter(Local<Name> property,
|
||||
+ Local<Value> value,
|
||||
+ const PropertyCallbackInfo<void>& info) {
|
||||
Environment* env = Environment::GetCurrent(info);
|
||||
CHECK(env->has_run_bootstrapping_code());
|
||||
// calling env->EmitProcessEnvWarning() sets a variable indicating that
|
||||
@@ -369,35 +373,40 @@ static void EnvSetter(Local<Name> property,
|
||||
"the "
|
||||
"value to a string before setting process.env with it.",
|
||||
"DEP0104")
|
||||
- .IsNothing())
|
||||
- return;
|
||||
+ .IsNothing()) {
|
||||
+ return Intercepted::kNo;
|
||||
+ }
|
||||
}
|
||||
|
||||
Local<String> key;
|
||||
Local<String> value_string;
|
||||
if (!property->ToString(env->context()).ToLocal(&key) ||
|
||||
!value->ToString(env->context()).ToLocal(&value_string)) {
|
||||
- return;
|
||||
+ return Intercepted::kNo;
|
||||
}
|
||||
|
||||
env->env_vars()->Set(env->isolate(), key, value_string);
|
||||
|
||||
- // Whether it worked or not, always return value.
|
||||
- info.GetReturnValue().Set(value);
|
||||
+ return Intercepted::kYes;
|
||||
}
|
||||
|
||||
-static void EnvQuery(Local<Name> property,
|
||||
- const PropertyCallbackInfo<Integer>& info) {
|
||||
+static Intercepted EnvQuery(Local<Name> property,
|
||||
+ const PropertyCallbackInfo<Integer>& info) {
|
||||
Environment* env = Environment::GetCurrent(info);
|
||||
CHECK(env->has_run_bootstrapping_code());
|
||||
if (property->IsString()) {
|
||||
int32_t rc = env->env_vars()->Query(env->isolate(), property.As<String>());
|
||||
- if (rc != -1) info.GetReturnValue().Set(rc);
|
||||
+ if (rc != -1) {
|
||||
+ // Return attributes for the property.
|
||||
+ info.GetReturnValue().Set(v8::None);
|
||||
+ return Intercepted::kYes;
|
||||
+ }
|
||||
}
|
||||
+ return Intercepted::kNo;
|
||||
}
|
||||
|
||||
-static void EnvDeleter(Local<Name> property,
|
||||
- const PropertyCallbackInfo<Boolean>& info) {
|
||||
+static Intercepted EnvDeleter(Local<Name> property,
|
||||
+ const PropertyCallbackInfo<Boolean>& info) {
|
||||
Environment* env = Environment::GetCurrent(info);
|
||||
CHECK(env->has_run_bootstrapping_code());
|
||||
if (property->IsString()) {
|
||||
@@ -407,6 +416,7 @@ static void EnvDeleter(Local<Name> property,
|
||||
// process.env never has non-configurable properties, so always
|
||||
// return true like the tc39 delete operator.
|
||||
info.GetReturnValue().Set(true);
|
||||
+ return Intercepted::kYes;
|
||||
}
|
||||
|
||||
static void EnvEnumerator(const PropertyCallbackInfo<Array>& info) {
|
||||
@@ -417,9 +427,9 @@ static void EnvEnumerator(const PropertyCallbackInfo<Array>& info) {
|
||||
env->env_vars()->Enumerate(env->isolate()));
|
||||
}
|
||||
|
||||
-static void EnvDefiner(Local<Name> property,
|
||||
- const PropertyDescriptor& desc,
|
||||
- const PropertyCallbackInfo<Value>& info) {
|
||||
+static Intercepted EnvDefiner(Local<Name> property,
|
||||
+ const PropertyDescriptor& desc,
|
||||
+ const PropertyCallbackInfo<void>& info) {
|
||||
Environment* env = Environment::GetCurrent(info);
|
||||
if (desc.has_value()) {
|
||||
if (!desc.has_writable() ||
|
||||
@@ -430,6 +440,7 @@ static void EnvDefiner(Local<Name> property,
|
||||
"configurable, writable,"
|
||||
" and enumerable "
|
||||
"data descriptor");
|
||||
+ return Intercepted::kYes;
|
||||
} else if (!desc.configurable() ||
|
||||
!desc.enumerable() ||
|
||||
!desc.writable()) {
|
||||
@@ -438,6 +449,7 @@ static void EnvDefiner(Local<Name> property,
|
||||
"configurable, writable,"
|
||||
" and enumerable "
|
||||
"data descriptor");
|
||||
+ return Intercepted::kYes;
|
||||
} else {
|
||||
return EnvSetter(property, desc.value(), info);
|
||||
}
|
||||
@@ -447,12 +459,14 @@ static void EnvDefiner(Local<Name> property,
|
||||
"'process.env' does not accept an"
|
||||
" accessor(getter/setter)"
|
||||
" descriptor");
|
||||
+ return Intercepted::kYes;
|
||||
} else {
|
||||
THROW_ERR_INVALID_OBJECT_DEFINE_PROPERTY(env,
|
||||
"'process.env' only accepts a "
|
||||
"configurable, writable,"
|
||||
" and enumerable "
|
||||
"data descriptor");
|
||||
+ return Intercepted::kYes;
|
||||
}
|
||||
}
|
||||
|
||||
diff --git a/src/node_external_reference.h b/src/node_external_reference.h
|
||||
index 24f0c6771720d8a6cdb684a0d562d01564d433f7..a1ad176c45f1900fb248650eb8533df4690bcf29 100644
|
||||
--- a/src/node_external_reference.h
|
||||
+++ b/src/node_external_reference.h
|
||||
@@ -65,16 +65,17 @@ class ExternalReferenceRegistry {
|
||||
V(v8::FunctionCallback) \
|
||||
V(v8::AccessorNameGetterCallback) \
|
||||
V(v8::AccessorNameSetterCallback) \
|
||||
- V(v8::GenericNamedPropertyDefinerCallback) \
|
||||
- V(v8::GenericNamedPropertyDeleterCallback) \
|
||||
- V(v8::GenericNamedPropertyEnumeratorCallback) \
|
||||
- V(v8::GenericNamedPropertyQueryCallback) \
|
||||
- V(v8::GenericNamedPropertySetterCallback) \
|
||||
- V(v8::IndexedPropertySetterCallback) \
|
||||
- V(v8::IndexedPropertyDefinerCallback) \
|
||||
- V(v8::IndexedPropertyDeleterCallback) \
|
||||
- V(v8::IndexedPropertyQueryCallback) \
|
||||
- V(v8::IndexedPropertyDescriptorCallback) \
|
||||
+ V(v8::NamedPropertyGetterCallback) \
|
||||
+ V(v8::NamedPropertyDefinerCallback) \
|
||||
+ V(v8::NamedPropertyDeleterCallback) \
|
||||
+ V(v8::NamedPropertyEnumeratorCallback) \
|
||||
+ V(v8::NamedPropertyQueryCallback) \
|
||||
+ V(v8::NamedPropertySetterCallback) \
|
||||
+ V(v8::IndexedPropertyGetterCallbackV2) \
|
||||
+ V(v8::IndexedPropertySetterCallbackV2) \
|
||||
+ V(v8::IndexedPropertyDefinerCallbackV2) \
|
||||
+ V(v8::IndexedPropertyDeleterCallbackV2) \
|
||||
+ V(v8::IndexedPropertyQueryCallbackV2) \
|
||||
V(const v8::String::ExternalStringResourceBase*)
|
||||
|
||||
#define V(ExternalReferenceType) \
|
||||
@@ -46,10 +46,10 @@ index 170429bf163b02963c0d59de4cd2b19bedf2e54a..c131d78dc92a37b92ef4608f8954bff4
|
||||
V8_INLINE static void* GetAlignedPointerFromInternalField(
|
||||
const BasicTracedReference<Object>& object, int index) {
|
||||
diff --git a/src/api/api.cc b/src/api/api.cc
|
||||
index ee8a201844be1435f0003301327d4e39e0c613c7..efe804450daa94760472e90c983537f021f475a5 100644
|
||||
index 88991b5bc332f44079ae1868e67a20f79033f864..babf2f5aa9c6eacc02a4d56e77dc751c838ea657 100644
|
||||
--- a/src/api/api.cc
|
||||
+++ b/src/api/api.cc
|
||||
@@ -6279,14 +6279,33 @@ Local<Data> v8::Object::SlowGetInternalField(int index) {
|
||||
@@ -6277,14 +6277,33 @@ Local<Data> v8::Object::SlowGetInternalField(int index) {
|
||||
isolate);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import * as cp from 'node:child_process';
|
||||
import * as fs from 'fs-extra';
|
||||
import * as fs from 'node:fs';
|
||||
import * as os from 'node:os';
|
||||
import * as path from 'node:path';
|
||||
|
||||
@@ -48,7 +48,7 @@ const main = async () => {
|
||||
];
|
||||
|
||||
const webpackTargetsWithDeps = await Promise.all(webpackTargets.map(async webpackTarget => {
|
||||
const tmpDir = await fs.mkdtemp(path.resolve(os.tmpdir(), 'electron-filenames-'));
|
||||
const tmpDir = await fs.promises.mkdtemp(path.resolve(os.tmpdir(), 'electron-filenames-'));
|
||||
const child = cp.spawn('node', [
|
||||
'./node_modules/webpack-cli/bin/cli.js',
|
||||
'--config', `./build/webpack/${webpackTarget.config}`,
|
||||
@@ -89,7 +89,7 @@ const main = async () => {
|
||||
// Make the generated list easier to read
|
||||
.sort()
|
||||
};
|
||||
await fs.remove(tmpDir);
|
||||
await fs.promises.rm(tmpDir, { force: true, recursive: true });
|
||||
return webpackTargetWithDeps;
|
||||
}));
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
const asar = require('@electron/asar');
|
||||
const assert = require('node:assert');
|
||||
const fs = require('fs-extra');
|
||||
const fs = require('node:fs');
|
||||
const os = require('node:os');
|
||||
const path = require('node:path');
|
||||
|
||||
@@ -41,12 +41,12 @@ try {
|
||||
// Copy all files to a tmp dir to avoid including scrap files in the ASAR
|
||||
for (const file of files) {
|
||||
const newLocation = path.resolve(tmpPath, path.relative(base[0], file));
|
||||
fs.mkdirsSync(path.dirname(newLocation));
|
||||
fs.mkdirSync(path.dirname(newLocation), { recursive: true });
|
||||
fs.writeFileSync(newLocation, fs.readFileSync(file));
|
||||
}
|
||||
} catch (err) {
|
||||
console.error('Unexpected error while generating ASAR', err);
|
||||
fs.remove(tmpPath)
|
||||
fs.promises.rm(tmpPath, { force: true, recursive: true })
|
||||
.then(() => process.exit(1))
|
||||
.catch(() => process.exit(1));
|
||||
return;
|
||||
@@ -59,5 +59,5 @@ asar.createPackageWithOptions(tmpPath, out[0], {})
|
||||
console.error('Unexpected error while generating ASAR', err);
|
||||
process.exit(1);
|
||||
};
|
||||
fs.remove(tmpPath).then(exit).catch(exit);
|
||||
}).then(() => fs.remove(tmpPath));
|
||||
fs.promises.rm(tmpPath, { force: true, recursive: true }).then(exit).catch(exit);
|
||||
}).then(() => fs.promises.rm(tmpPath, { force: true, recursive: true }));
|
||||
|
||||
@@ -252,8 +252,10 @@ const LINTERS = [{
|
||||
|
||||
const allOk = filenames.length > 0 && filenames.map(f => {
|
||||
const patchText = fs.readFileSync(f, 'utf8');
|
||||
const subjectAndDescription = /Subject: (.*?)\n\n([\s\S]*?)\s*(?=diff)/ms.exec(patchText);
|
||||
if (!subjectAndDescription[2]) {
|
||||
|
||||
const regex = /Subject: (.*?)\n\n([\s\S]*?)\s*(?=diff)/ms;
|
||||
const subjectAndDescription = regex.exec(patchText);
|
||||
if (!subjectAndDescription?.[2]) {
|
||||
console.warn(`Patch file '${f}' has no description. Every patch must contain a justification for why the patch exists and the plan for its removal.`);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
const { ElectronVersions, Installer } = require('@electron/fiddle-core');
|
||||
const childProcess = require('node:child_process');
|
||||
const crypto = require('node:crypto');
|
||||
const fs = require('fs-extra');
|
||||
const fs = require('node:fs');
|
||||
const { hashElement } = require('folder-hash');
|
||||
const os = require('node:os');
|
||||
const path = require('node:path');
|
||||
@@ -216,7 +216,7 @@ async function installSpecModules (dir) {
|
||||
env.npm_config_nodedir = path.resolve(BASE, `out/${utils.getOutDir({ shouldLog: true })}/gen/node_headers`);
|
||||
}
|
||||
if (fs.existsSync(path.resolve(dir, 'node_modules'))) {
|
||||
await fs.remove(path.resolve(dir, 'node_modules'));
|
||||
await fs.promises.rm(path.resolve(dir, 'node_modules'), { force: true, recursive: true });
|
||||
}
|
||||
const { status } = childProcess.spawnSync(NPX_CMD, [`yarn@${YARN_VERSION}`, 'install', '--frozen-lockfile'], {
|
||||
env,
|
||||
|
||||
@@ -30,10 +30,9 @@ class ElectronMainDelegate : public content::ContentMainDelegate {
|
||||
ElectronMainDelegate(const ElectronMainDelegate&) = delete;
|
||||
ElectronMainDelegate& operator=(const ElectronMainDelegate&) = delete;
|
||||
|
||||
base::StringPiece GetBrowserV8SnapshotFilename() override;
|
||||
|
||||
protected:
|
||||
// content::ContentMainDelegate:
|
||||
base::StringPiece GetBrowserV8SnapshotFilename() override;
|
||||
std::optional<int> BasicStartupComplete() override;
|
||||
void PreSandboxStartup() override;
|
||||
void SandboxInitialized(const std::string& process_type) override;
|
||||
|
||||
@@ -36,7 +36,7 @@ class AutoUpdater : public gin::Wrappable<AutoUpdater>,
|
||||
AutoUpdater();
|
||||
~AutoUpdater() override;
|
||||
|
||||
// Delegate implementations.
|
||||
// auto_updater::Delegate:
|
||||
void OnError(const std::string& message) override;
|
||||
void OnError(const std::string& message,
|
||||
const int code,
|
||||
|
||||
@@ -18,6 +18,7 @@ class MenuMac : public Menu {
|
||||
explicit MenuMac(gin::Arguments* args);
|
||||
~MenuMac() override;
|
||||
|
||||
// Menu
|
||||
void PopupAt(BaseWindow* window,
|
||||
int x,
|
||||
int y,
|
||||
|
||||
@@ -21,6 +21,7 @@ class MenuViews : public Menu {
|
||||
~MenuViews() override;
|
||||
|
||||
protected:
|
||||
// Menu
|
||||
void PopupAt(BaseWindow* window,
|
||||
int x,
|
||||
int y,
|
||||
|
||||
@@ -159,6 +159,8 @@ std::string SystemPreferences::GetMediaAccessStatus(
|
||||
}
|
||||
|
||||
void SystemPreferences::InitializeWindow() {
|
||||
if (electron::IsUtilityProcess())
|
||||
return;
|
||||
// Wait until app is ready before creating sys color listener
|
||||
// Creating this listener before the app is ready causes global shortcuts
|
||||
// to not fire
|
||||
|
||||
@@ -155,6 +155,7 @@ class JSLayoutManager : public views::LayoutManagerBase {
|
||||
: layout_callback_(std::move(layout_callback)) {}
|
||||
~JSLayoutManager() override {}
|
||||
|
||||
// views::LayoutManagerBase
|
||||
views::ProposedLayout CalculateProposedLayout(
|
||||
const views::SizeBounds& size_bounds) const override {
|
||||
v8::Isolate* isolate = JavascriptEnvironment::GetIsolate();
|
||||
|
||||
@@ -170,7 +170,9 @@ class WebContents : public ExclusiveAccessContext,
|
||||
void Close(std::optional<gin_helper::Dictionary> options);
|
||||
base::WeakPtr<WebContents> GetWeakPtr() { return weak_factory_.GetWeakPtr(); }
|
||||
|
||||
// BackgroundThrottlingSource
|
||||
bool GetBackgroundThrottling() const override;
|
||||
|
||||
void SetBackgroundThrottling(bool allowed);
|
||||
int GetProcessID() const;
|
||||
base::ProcessId GetOSProcessID() const;
|
||||
@@ -345,6 +347,7 @@ class WebContents : public ExclusiveAccessContext,
|
||||
const base::FilePath& file_path);
|
||||
v8::Local<v8::Promise> GetProcessMemoryInfo(v8::Isolate* isolate);
|
||||
|
||||
// content::WebContentsDelegate:
|
||||
bool HandleContextMenu(content::RenderFrameHost& render_frame_host,
|
||||
const content::ContextMenuParams& params) override;
|
||||
|
||||
|
||||
@@ -46,11 +46,12 @@ class FrameSubscriber : private content::WebContentsObserver,
|
||||
void AttachToHost(content::RenderWidgetHost* host);
|
||||
void DetachFromHost();
|
||||
|
||||
// content::WebContentsObserver
|
||||
void RenderFrameCreated(content::RenderFrameHost* render_frame_host) override;
|
||||
void PrimaryPageChanged(content::Page& page) override;
|
||||
void RenderViewDeleted(content::RenderViewHost* host) override;
|
||||
|
||||
// viz::mojom::FrameSinkVideoConsumer implementation.
|
||||
// viz::mojom::FrameSinkVideoConsumer
|
||||
void OnFrameCaptured(
|
||||
::media::mojom::VideoBufferHandlePtr data,
|
||||
::media::mojom::VideoFrameInfoPtr info,
|
||||
|
||||
@@ -30,6 +30,8 @@ class GPUInfoEnumerator final : public gpu::GPUInfo::Enumerator {
|
||||
public:
|
||||
GPUInfoEnumerator();
|
||||
~GPUInfoEnumerator() override;
|
||||
|
||||
// gpu::GPUInfo::Enumerator
|
||||
void AddInt64(const char* name, int64_t value) override;
|
||||
void AddInt(const char* name, int value) override;
|
||||
void AddString(const char* name, const std::string& value) override;
|
||||
|
||||
@@ -31,6 +31,7 @@ class GPUInfoManager : private content::GpuDataManagerObserver {
|
||||
void FetchBasicInfo(gin_helper::Promise<base::Value> promise);
|
||||
|
||||
private:
|
||||
// content::GpuDataManagerObserver
|
||||
void OnGpuInfoUpdate() override;
|
||||
|
||||
base::Value::Dict EnumerateGPUInfo(gpu::GPUInfo gpu_info) const;
|
||||
|
||||
@@ -76,8 +76,11 @@ void MessagePort::PostMessage(gin::Arguments* args) {
|
||||
return;
|
||||
}
|
||||
|
||||
electron::SerializeV8Value(args->isolate(), message_value,
|
||||
&transferable_message);
|
||||
if (!electron::SerializeV8Value(args->isolate(), message_value,
|
||||
&transferable_message)) {
|
||||
// SerializeV8Value sets an exception.
|
||||
return;
|
||||
}
|
||||
|
||||
v8::Local<v8::Value> transferables;
|
||||
std::vector<gin::Handle<MessagePort>> wrapped_ports;
|
||||
|
||||
@@ -51,7 +51,6 @@ class BrowserProcessImpl : public BrowserProcess {
|
||||
|
||||
static void ApplyProxyModeFromCommandLine(ValueMapPrefStore* pref_store);
|
||||
|
||||
BuildState* GetBuildState() override;
|
||||
void PostEarlyInitialization();
|
||||
void PreCreateThreads();
|
||||
void PreMainMessageLoopRun();
|
||||
@@ -68,6 +67,8 @@ class BrowserProcessImpl : public BrowserProcess {
|
||||
}
|
||||
#endif
|
||||
|
||||
// BrowserProcess
|
||||
BuildState* GetBuildState() override;
|
||||
void EndSession() override {}
|
||||
void FlushLocalStateAndReply(base::OnceClosure reply) override {}
|
||||
bool IsShuttingDown() override;
|
||||
|
||||
@@ -30,6 +30,7 @@ class AutofillDriver : public mojom::ElectronAutofillDriver {
|
||||
mojo::PendingAssociatedReceiver<mojom::ElectronAutofillDriver>
|
||||
pending_receiver);
|
||||
|
||||
// mojom::ElectronAutofillDriver
|
||||
void ShowAutofillPopup(const gfx::RectF& bounds,
|
||||
const std::vector<std::u16string>& values,
|
||||
const std::vector<std::u16string>& labels) override;
|
||||
|
||||
@@ -135,6 +135,8 @@ class LinuxUiGetterImpl : public ui::LinuxUiGetter {
|
||||
public:
|
||||
LinuxUiGetterImpl() = default;
|
||||
~LinuxUiGetterImpl() override = default;
|
||||
|
||||
// ui::LinuxUiGetter
|
||||
ui::LinuxUiTheme* GetForWindow(aura::Window* window) override {
|
||||
return GetForProfile(nullptr);
|
||||
}
|
||||
|
||||
@@ -19,8 +19,8 @@ class ElectronNavigationThrottle : public content::NavigationThrottle {
|
||||
ElectronNavigationThrottle& operator=(const ElectronNavigationThrottle&) =
|
||||
delete;
|
||||
|
||||
// content::NavigationThrottle
|
||||
ElectronNavigationThrottle::ThrottleCheckResult WillStartRequest() override;
|
||||
|
||||
ElectronNavigationThrottle::ThrottleCheckResult WillRedirectRequest()
|
||||
override;
|
||||
|
||||
|
||||
@@ -91,6 +91,8 @@ class ExtensionActionFunction : public ExtensionFunction {
|
||||
protected:
|
||||
ExtensionActionFunction();
|
||||
~ExtensionActionFunction() override;
|
||||
|
||||
// ExtensionFunction
|
||||
ResponseAction Run() override;
|
||||
|
||||
virtual ResponseAction RunExtensionAction() = 0;
|
||||
|
||||
@@ -17,7 +17,7 @@ class ElectronManagementAPIDelegate : public extensions::ManagementAPIDelegate {
|
||||
ElectronManagementAPIDelegate();
|
||||
~ElectronManagementAPIDelegate() override;
|
||||
|
||||
// ManagementAPIDelegate.
|
||||
// extensions::ManagementAPIDelegate
|
||||
bool LaunchAppFunctionDelegate(
|
||||
const extensions::Extension* extension,
|
||||
content::BrowserContext* context) const override;
|
||||
|
||||
@@ -21,6 +21,7 @@ class ElectronExtensionsBrowserAPIProvider
|
||||
ElectronExtensionsBrowserAPIProvider& operator=(
|
||||
const ElectronExtensionsBrowserAPIProvider&) = delete;
|
||||
|
||||
// ExtensionsBrowserAPIProvider
|
||||
void RegisterExtensionFunctions(ExtensionFunctionRegistry* registry) override;
|
||||
};
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ class ElectronKioskDelegate : public extensions::KioskDelegate {
|
||||
ElectronKioskDelegate();
|
||||
~ElectronKioskDelegate() override;
|
||||
|
||||
// KioskDelegate overrides:
|
||||
// extensions::KioskDelegate
|
||||
bool IsAutoLaunchedKioskApp(const extensions::ExtensionId& id) const override;
|
||||
};
|
||||
|
||||
|
||||
@@ -185,6 +185,7 @@ class NativeWindowClientView : public views::ClientView {
|
||||
NativeWindowClientView(const NativeWindowClientView&) = delete;
|
||||
NativeWindowClientView& operator=(const NativeWindowClientView&) = delete;
|
||||
|
||||
// views::ClientView
|
||||
views::CloseRequestResult OnWindowCloseRequested() override {
|
||||
window_->NotifyWindowCloseButtonClicked();
|
||||
return views::CloseRequestResult::kCannotClose;
|
||||
|
||||
@@ -25,6 +25,7 @@ class AsarFileValidator : public mojo::FilteredDataSource::Filter {
|
||||
AsarFileValidator(const AsarFileValidator&) = delete;
|
||||
AsarFileValidator& operator=(const AsarFileValidator&) = delete;
|
||||
|
||||
// mojo::FilteredDataSource::Filter
|
||||
void OnRead(base::span<char> buffer,
|
||||
mojo::FileDataSource::ReadResult* result) override;
|
||||
|
||||
|
||||
@@ -16,6 +16,7 @@ class NotificationPresenterLinux : public NotificationPresenter {
|
||||
~NotificationPresenterLinux() override;
|
||||
|
||||
private:
|
||||
// NotificationPresenter
|
||||
Notification* CreateNotificationObject(
|
||||
NotificationDelegate* delegate) override;
|
||||
};
|
||||
|
||||
@@ -21,6 +21,7 @@ class NotificationPresenterMac : public NotificationPresenter {
|
||||
~NotificationPresenterMac() override;
|
||||
|
||||
private:
|
||||
// NotificationPresenter
|
||||
Notification* CreateNotificationObject(
|
||||
NotificationDelegate* delegate) override;
|
||||
|
||||
|
||||
@@ -53,6 +53,7 @@ class NotificationDelegateImpl final : public electron::NotificationDelegate {
|
||||
NotificationDelegateImpl(const NotificationDelegateImpl&) = delete;
|
||||
NotificationDelegateImpl& operator=(const NotificationDelegateImpl&) = delete;
|
||||
|
||||
// electron::NotificationDelegate
|
||||
void NotificationDestroyed() override { delete this; }
|
||||
|
||||
void NotificationClick() override {
|
||||
|
||||
@@ -41,6 +41,7 @@ class NotificationPresenterWin : public NotificationPresenter {
|
||||
std::wstring SaveIconToFilesystem(const SkBitmap& icon, const GURL& origin);
|
||||
|
||||
private:
|
||||
// NotificationPresenter
|
||||
Notification* CreateNotificationObject(
|
||||
NotificationDelegate* delegate) override;
|
||||
|
||||
|
||||
@@ -120,12 +120,17 @@ class ToastEventHandler : public RuntimeClass<RuntimeClassFlags<ClassicCom>,
|
||||
ToastEventHandler(const ToastEventHandler&) = delete;
|
||||
ToastEventHandler& operator=(const ToastEventHandler&) = delete;
|
||||
|
||||
// DesktopToastActivatedEventHandler
|
||||
IFACEMETHODIMP Invoke(
|
||||
ABI::Windows::UI::Notifications::IToastNotification* sender,
|
||||
IInspectable* args) override;
|
||||
|
||||
// DesktopToastDismissedEventHandler
|
||||
IFACEMETHODIMP Invoke(
|
||||
ABI::Windows::UI::Notifications::IToastNotification* sender,
|
||||
ABI::Windows::UI::Notifications::IToastDismissedEventArgs* e) override;
|
||||
|
||||
// DesktopToastFailedEventHandler
|
||||
IFACEMETHODIMP Invoke(
|
||||
ABI::Windows::UI::Notifications::IToastNotification* sender,
|
||||
ABI::Windows::UI::Notifications::IToastFailedEventArgs* e) override;
|
||||
|
||||
@@ -63,6 +63,7 @@ class OffScreenHostDisplayClient : public viz::HostDisplayClient {
|
||||
void SetActive(bool active);
|
||||
|
||||
private:
|
||||
// viz::HostDisplayClient
|
||||
#if BUILDFLAG(IS_MAC)
|
||||
void OnDisplayReceivedCALayerParams(
|
||||
const gfx::CALayerParams& ca_layer_params) override;
|
||||
|
||||
@@ -135,6 +135,7 @@ class ElectronDelegatedFrameHostClient
|
||||
ElectronDelegatedFrameHostClient& operator=(
|
||||
const ElectronDelegatedFrameHostClient&) = delete;
|
||||
|
||||
// content::DelegatedFrameHostClient
|
||||
ui::Layer* DelegatedFrameHostGetLayer() const override {
|
||||
return view_->root_layer();
|
||||
}
|
||||
|
||||
@@ -121,7 +121,6 @@ class OffScreenRenderWidgetHostView
|
||||
#endif // BUILDFLAG(IS_MAC)
|
||||
|
||||
// content::RenderWidgetHostViewBase:
|
||||
|
||||
void UpdateFrameSinkIdRegistration() override;
|
||||
void InvalidateLocalSurfaceIdAndAllocationGroup() override;
|
||||
void ResetFallbackToFirstNavigationSurface() override;
|
||||
|
||||
@@ -29,6 +29,7 @@ class ElectronSerialDelegate : public content::SerialDelegate,
|
||||
ElectronSerialDelegate(const ElectronSerialDelegate&) = delete;
|
||||
ElectronSerialDelegate& operator=(const ElectronSerialDelegate&) = delete;
|
||||
|
||||
// content::SerialDelegate:
|
||||
std::unique_ptr<content::SerialChooser> RunChooser(
|
||||
content::RenderFrameHost* frame,
|
||||
std::vector<blink::mojom::SerialPortFilterPtr> filters,
|
||||
|
||||
@@ -137,6 +137,7 @@ class FileChooserDialog : public ui::SelectFileDialog::Listener {
|
||||
RunOpenDialogImpl(settings);
|
||||
}
|
||||
|
||||
// ui::SelectFileDialog::Listener
|
||||
void FileSelected(const ui::SelectedFileInfo& file,
|
||||
int index,
|
||||
void* params) override {
|
||||
|
||||
@@ -242,6 +242,7 @@ class InspectableWebContents::NetworkResourceLoader
|
||||
response_headers_ = response_head.headers;
|
||||
}
|
||||
|
||||
// network::SimpleURLLoaderStreamConsumer
|
||||
void OnDataReceived(base::StringPiece chunk,
|
||||
base::OnceClosure resume) override {
|
||||
bool encoded = !base::IsStringUTF8(chunk);
|
||||
|
||||
@@ -182,6 +182,7 @@ class GtkMessageBox : private NativeWindowObserver {
|
||||
Show();
|
||||
}
|
||||
|
||||
// NativeWindowObserver
|
||||
void OnWindowClosed() override {
|
||||
parent_->RemoveObserver(this);
|
||||
parent_ = nullptr;
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user