mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
Compare commits
68 Commits
feat/promp
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b417696d6b | ||
|
|
4203d7688f | ||
|
|
62e637275a | ||
|
|
28c0eb29df | ||
|
|
8a730e2aec | ||
|
|
044be7ce40 | ||
|
|
7245c6a3f0 | ||
|
|
b484b0bde9 | ||
|
|
6c8a910232 | ||
|
|
cc3d4f5f58 | ||
|
|
b711ce7b04 | ||
|
|
adf9a6e303 | ||
|
|
6744293e96 | ||
|
|
0d3342debf | ||
|
|
157cdac4b9 | ||
|
|
4dfada86ce | ||
|
|
df81a1d4ac | ||
|
|
c3e3958668 | ||
|
|
afd5fb4a60 | ||
|
|
8679522922 | ||
|
|
0828de3ccd | ||
|
|
6b5a4ff66c | ||
|
|
ca28023d4d | ||
|
|
e60441ad60 | ||
|
|
a189425373 | ||
|
|
7eccea1315 | ||
|
|
2e74ad2c68 | ||
|
|
9ba299afff | ||
|
|
6df2228ea0 | ||
|
|
a29674e4cf | ||
|
|
81dd0f42e1 | ||
|
|
6aaf490aa5 | ||
|
|
b8f25c4ced | ||
|
|
9fafc81e88 | ||
|
|
4d05010945 | ||
|
|
c3189e9886 | ||
|
|
983ebdd6de | ||
|
|
b9c08ef9c2 | ||
|
|
9f3cc9122c | ||
|
|
e66e4ca02c | ||
|
|
6ed3198ba8 | ||
|
|
903e65e048 | ||
|
|
fef2fd2941 | ||
|
|
4d8fd31e5f | ||
|
|
96486a4102 | ||
|
|
3f8238b92c | ||
|
|
64c5440eec | ||
|
|
30cf60a935 | ||
|
|
ec30e4cdae | ||
|
|
40033db422 | ||
|
|
c3d441cf7d | ||
|
|
14583d22e6 | ||
|
|
68bfe49120 | ||
|
|
2c6332a7d6 | ||
|
|
ddc1bd9553 | ||
|
|
12109371d3 | ||
|
|
69891d04bf | ||
|
|
188813e206 | ||
|
|
8b768b8211 | ||
|
|
82b97ddf5b | ||
|
|
16f408a502 | ||
|
|
246aa63910 | ||
|
|
230f02faf2 | ||
|
|
1362d7b94d | ||
|
|
877fe479b5 | ||
|
|
f41438ff73 | ||
|
|
c6e201c965 | ||
|
|
156a4e610c |
@@ -35,7 +35,7 @@
|
||||
"ms-vscode.cpptools",
|
||||
"mutantdino.resourcemonitor",
|
||||
"dsanders11.vscode-electron-build-tools",
|
||||
"dbaeumer.vscode-eslint",
|
||||
"oxc.oxc-vscode",
|
||||
"shakram02.bash-beautify",
|
||||
"marshallofsound.gnls-electron"
|
||||
],
|
||||
|
||||
@@ -1,79 +0,0 @@
|
||||
{
|
||||
"root": true,
|
||||
"extends": "standard",
|
||||
"parser": "@typescript-eslint/parser",
|
||||
"plugins": ["@typescript-eslint"],
|
||||
"env": {
|
||||
"browser": true
|
||||
},
|
||||
"rules": {
|
||||
"semi": ["error", "always"],
|
||||
"no-var": "error",
|
||||
"no-unused-vars": "off",
|
||||
"guard-for-in": "error",
|
||||
"@typescript-eslint/no-unused-vars": ["error", {
|
||||
"vars": "all",
|
||||
"args": "after-used",
|
||||
"ignoreRestSiblings": true
|
||||
}],
|
||||
"prefer-const": ["error", {
|
||||
"destructuring": "all"
|
||||
}],
|
||||
"n/no-callback-literal": "off",
|
||||
"import/newline-after-import": "error",
|
||||
"import/order": ["error", {
|
||||
"alphabetize": {
|
||||
"order": "asc"
|
||||
},
|
||||
"newlines-between": "always",
|
||||
"pathGroups": [
|
||||
{
|
||||
"pattern": "@electron/internal/**",
|
||||
"group": "external",
|
||||
"position": "before"
|
||||
},
|
||||
{
|
||||
"pattern": "@electron/**",
|
||||
"group": "external",
|
||||
"position": "before"
|
||||
},
|
||||
{
|
||||
"pattern": "{electron,electron/**}",
|
||||
"group": "external",
|
||||
"position": "before"
|
||||
}
|
||||
],
|
||||
"pathGroupsExcludedImportTypes": [],
|
||||
"distinctGroup": true,
|
||||
"groups": [
|
||||
"external",
|
||||
"builtin",
|
||||
["sibling", "parent"],
|
||||
"index",
|
||||
"type"
|
||||
]
|
||||
}]
|
||||
},
|
||||
"parserOptions": {
|
||||
"ecmaVersion": 6,
|
||||
"sourceType": "module"
|
||||
},
|
||||
"overrides": [
|
||||
{
|
||||
"files": "*.ts",
|
||||
"rules": {
|
||||
"no-undef": "off",
|
||||
"no-redeclare": "off",
|
||||
"@typescript-eslint/no-redeclare": ["error"],
|
||||
"no-use-before-define": "off"
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": "*.d.ts",
|
||||
"rules": {
|
||||
"no-useless-constructor": "off",
|
||||
"@typescript-eslint/no-unused-vars": "off"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
32
.github/actions/build-electron/action.yml
vendored
32
.github/actions/build-electron/action.yml
vendored
@@ -48,19 +48,15 @@ runs:
|
||||
shell: bash
|
||||
run: echo "::add-matcher::src/electron/.github/problem-matchers/clang.json"
|
||||
- name: Download previous object checksums
|
||||
uses: dawidd6/action-download-artifact@09b07ec687d10771279a426c79925ee415c12906 # v17
|
||||
if: ${{ (github.event_name == 'push' || github.event_name == 'pull_request') && inputs.is-asan != 'true' }}
|
||||
with:
|
||||
name: object_checksums_${{ inputs.artifact-platform }}_${{ inputs.target-arch }}
|
||||
commit: ${{ case(github.event_name == 'push', github.event.before, github.event.pull_request.base.sha) }}
|
||||
path: src
|
||||
if_no_artifact_found: ignore
|
||||
- name: Move previous object checksums
|
||||
shell: bash
|
||||
run: |
|
||||
if [ -f src/object-checksums_${{ inputs.artifact-platform }}_${{ inputs.target-arch }}.json ]; then
|
||||
mv src/object-checksums_${{ inputs.artifact-platform }}_${{ inputs.target-arch }}.json src/previous-object-checksums.json
|
||||
fi
|
||||
if: ${{ (github.event_name == 'push' || github.event_name == 'pull_request') && inputs.is-asan != 'true' }}
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ github.token }}
|
||||
ARTIFACT_NAME: object-checksums.${{ inputs.artifact-platform }}_${{ inputs.target-arch }}.json
|
||||
SEARCH_BRANCH: ${{ case(github.event_name == 'push', github.ref_name, github.event.pull_request.base.ref) }}
|
||||
REPO: ${{ github.repository }}
|
||||
OUTPUT_PATH: src/previous-object-checksums.json
|
||||
run: node src/electron/.github/actions/build-electron/download-previous-object-checksums.mjs
|
||||
- name: Build Electron ${{ inputs.step-suffix }}
|
||||
if: ${{ inputs.target-platform != 'win' }}
|
||||
shell: bash
|
||||
@@ -232,7 +228,17 @@ runs:
|
||||
if: ${{ inputs.is-release == 'true' }}
|
||||
run: |
|
||||
cd src
|
||||
gn gen out/ffmpeg --args="import(\"//electron/build/args/ffmpeg.gn\") use_remoteexec=true use_siso=true $GN_EXTRA_ARGS"
|
||||
# Reuse the hermetic mac_sdk_path that `e build` wrote for out/Default so
|
||||
# out/ffmpeg builds against the same SDK instead of the runner's system Xcode.
|
||||
# The path has to live under root_build_dir, so copy the symlink tree and
|
||||
# rewrite Default -> ffmpeg.
|
||||
MAC_SDK_ARG=""
|
||||
if [ "$(uname)" = "Darwin" ]; then
|
||||
mkdir -p out/ffmpeg
|
||||
cp -a out/Default/xcode_links out/ffmpeg/
|
||||
MAC_SDK_ARG=$(sed -n 's|^\(mac_sdk_path = "//out/\)Default/|\1ffmpeg/|p' out/Default/args.gn)
|
||||
fi
|
||||
gn gen out/ffmpeg --args="import(\"//electron/build/args/ffmpeg.gn\") use_remoteexec=true use_siso=true $MAC_SDK_ARG $GN_EXTRA_ARGS"
|
||||
e build --target electron:electron_ffmpeg_zip -C ../../out/ffmpeg
|
||||
- name: Remove Clang problem matcher
|
||||
shell: bash
|
||||
|
||||
82
.github/actions/build-electron/download-previous-object-checksums.mjs
vendored
Normal file
82
.github/actions/build-electron/download-previous-object-checksums.mjs
vendored
Normal file
@@ -0,0 +1,82 @@
|
||||
import { Octokit } from '@octokit/rest';
|
||||
|
||||
import { writeFileSync } from 'node:fs';
|
||||
|
||||
const token = process.env.GITHUB_TOKEN;
|
||||
const repo = process.env.REPO;
|
||||
const artifactName = process.env.ARTIFACT_NAME;
|
||||
const branch = process.env.SEARCH_BRANCH;
|
||||
const outputPath = process.env.OUTPUT_PATH;
|
||||
|
||||
const required = { GITHUB_TOKEN: token, REPO: repo, ARTIFACT_NAME: artifactName, SEARCH_BRANCH: branch, OUTPUT_PATH: outputPath };
|
||||
const missing = Object.entries(required).filter(([, v]) => !v).map(([k]) => k);
|
||||
if (missing.length > 0) {
|
||||
console.error(`Missing required environment variables: ${missing.join(', ')}`);
|
||||
process.exit(1);
|
||||
}
|
||||
|
||||
const [owner, repoName] = repo.split('/');
|
||||
const octokit = new Octokit({ auth: token });
|
||||
|
||||
async function main () {
|
||||
console.log(`Searching for artifact '${artifactName}' on branch '${branch}'...`);
|
||||
|
||||
// Resolve the "Build" workflow name to an ID, mirroring how `gh run list --workflow` works
|
||||
// under the hood (it uses /repos/{owner}/{repo}/actions/workflows/{id}/runs).
|
||||
const { data: workflows } = await octokit.actions.listRepoWorkflows({ owner, repo: repoName });
|
||||
const buildWorkflow = workflows.workflows.find((w) => w.name === 'Build');
|
||||
if (!buildWorkflow) {
|
||||
console.log('Could not find "Build" workflow, continuing without previous checksums');
|
||||
return;
|
||||
}
|
||||
|
||||
const { data: runs } = await octokit.actions.listWorkflowRuns({
|
||||
owner,
|
||||
repo: repoName,
|
||||
workflow_id: buildWorkflow.id,
|
||||
branch,
|
||||
status: 'completed',
|
||||
event: 'push',
|
||||
per_page: 20,
|
||||
exclude_pull_requests: true
|
||||
});
|
||||
|
||||
for (const run of runs.workflow_runs) {
|
||||
const { data: artifacts } = await octokit.actions.listWorkflowRunArtifacts({
|
||||
owner,
|
||||
repo: repoName,
|
||||
run_id: run.id,
|
||||
name: artifactName
|
||||
});
|
||||
|
||||
if (artifacts.artifacts.length > 0) {
|
||||
const artifact = artifacts.artifacts[0];
|
||||
console.log(`Found artifact in run ${run.id} (artifact ID: ${artifact.id}), downloading...`);
|
||||
|
||||
// Non-archived artifacts are still downloaded from the /zip endpoint
|
||||
const response = await octokit.actions.downloadArtifact({
|
||||
owner,
|
||||
repo: repoName,
|
||||
artifact_id: artifact.id,
|
||||
archive_format: 'zip'
|
||||
});
|
||||
|
||||
if (response.headers['content-type'] !== 'application/json') {
|
||||
console.error(`Unexpected content type for artifact download: ${response.headers['content-type']}`);
|
||||
console.error('Expected application/json, continuing without previous checksums');
|
||||
return;
|
||||
}
|
||||
|
||||
writeFileSync(outputPath, JSON.stringify(response.data));
|
||||
console.log('Downloaded previous object checksums successfully');
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
console.log(`No previous object checksums found in last ${runs.workflow_runs.length} runs, continuing without them`);
|
||||
}
|
||||
|
||||
main().catch((err) => {
|
||||
console.error('Failed to download previous object checksums, continuing without them:', err.message);
|
||||
process.exit(0);
|
||||
});
|
||||
28
.github/actions/checkout/action.yml
vendored
28
.github/actions/checkout/action.yml
vendored
@@ -28,7 +28,7 @@ runs:
|
||||
shell: bash
|
||||
run: |
|
||||
node src/electron/script/generate-deps-hash.js
|
||||
DEPSHASH="v1-src-cache-$(cat src/electron/.depshash)"
|
||||
DEPSHASH="v2-src-cache-$(cat src/electron/.depshash)"
|
||||
echo "DEPSHASH=$DEPSHASH" >> $GITHUB_ENV
|
||||
echo "CACHE_FILE=$DEPSHASH.tar" >> $GITHUB_ENV
|
||||
if [ "${{ inputs.target-platform }}" = "win" ]; then
|
||||
@@ -109,7 +109,7 @@ runs:
|
||||
echo "target_os=['$TARGET_OS']" >> ./.gclient
|
||||
fi
|
||||
|
||||
ELECTRON_USE_THREE_WAY_MERGE_FOR_PATCHES=1 e d gclient sync --with_branch_heads --with_tags -vv
|
||||
ELECTRON_DEPOT_TOOLS_WIN_TOOLCHAIN=0 DEPOT_TOOLS_WIN_TOOLCHAIN=0 ELECTRON_USE_THREE_WAY_MERGE_FOR_PATCHES=1 e d gclient sync --with_branch_heads --with_tags
|
||||
if [[ "${{ inputs.is-release }}" != "true" ]]; then
|
||||
# Re-export all the patches to check if there were changes.
|
||||
python3 src/electron/script/export_all_patches.py src/electron/patches/config.json
|
||||
@@ -187,21 +187,35 @@ runs:
|
||||
shell: bash
|
||||
run: |
|
||||
echo "Uncompressed src size: $(du -sh src | cut -f1 -d' ')"
|
||||
tar -cf $CACHE_FILE src
|
||||
# Named .tar but zstd-compressed; the sas-sidecar's filename allowlist
|
||||
# only permits .tar/.tgz so we keep the extension and decode on restore.
|
||||
tar -cf - src | zstd -T0 --long=30 -f -o $CACHE_FILE
|
||||
echo "Compressed src to $(du -sh $CACHE_FILE | cut -f1 -d' ')"
|
||||
cp ./$CACHE_FILE $CACHE_DRIVE/
|
||||
- name: Persist Src Cache
|
||||
if: ${{ steps.check-cache.outputs.cache_exists == 'false' && inputs.use-cache == 'true' }}
|
||||
shell: bash
|
||||
run: |
|
||||
final_cache_path=$CACHE_DRIVE/$CACHE_FILE
|
||||
# Upload to a run-unique temp name first so concurrent readers never
|
||||
# observe a partially-written file, and an interrupted copy can't leave
|
||||
# a truncated file at the final path. Orphaned temp files get swept by
|
||||
# the clean-orphaned-cache-uploads workflow.
|
||||
tmp_cache_path=$final_cache_path.upload-${GITHUB_RUN_ID}-${GITHUB_RUN_ATTEMPT}
|
||||
echo "Uploading to temp path: $tmp_cache_path"
|
||||
cp ./$CACHE_FILE $tmp_cache_path
|
||||
|
||||
echo "Using cache key: $DEPSHASH"
|
||||
echo "Checking path: $final_cache_path"
|
||||
if [ -f "$final_cache_path" ]; then
|
||||
echo "Cache already persisted at $final_cache_path by a concurrent run; discarding ours"
|
||||
rm -f $tmp_cache_path
|
||||
else
|
||||
mv -f $tmp_cache_path $final_cache_path
|
||||
echo "Cache key persisted in $final_cache_path"
|
||||
fi
|
||||
|
||||
if [ ! -f "$final_cache_path" ]; then
|
||||
echo "Cache key not found"
|
||||
exit 1
|
||||
else
|
||||
echo "Cache key persisted in $final_cache_path"
|
||||
fi
|
||||
- name: Wait for active SSH sessions
|
||||
shell: bash
|
||||
|
||||
1
.github/actions/fix-sync/action.yml
vendored
1
.github/actions/fix-sync/action.yml
vendored
@@ -27,6 +27,7 @@ runs:
|
||||
python3 src/tools/clang/scripts/update.py
|
||||
# Refs https://chromium-review.googlesource.com/c/chromium/src/+/6667681
|
||||
python3 src/tools/clang/scripts/update.py --package objdump
|
||||
python3 src/tools/clang/scripts/update.py --package clang-tidy
|
||||
- name: Fix esbuild
|
||||
if: ${{ inputs.target-platform != 'linux' }}
|
||||
uses: ./src/electron/.github/actions/cipd-install
|
||||
|
||||
@@ -15,7 +15,7 @@ runs:
|
||||
git config --global core.preloadindex true
|
||||
git config --global core.longpaths true
|
||||
fi
|
||||
export BUILD_TOOLS_SHA=a0cc95a1884a631559bcca0c948465b725d9295a
|
||||
export BUILD_TOOLS_SHA=1b7bd25dae4a780bb3170fff56c9327b53aaf7eb
|
||||
npm i -g @electron/build-tools
|
||||
# Update depot_tools to ensure python
|
||||
e d update_depot_tools
|
||||
@@ -29,4 +29,4 @@ runs:
|
||||
else
|
||||
echo "$HOME/.electron_build_tools/third_party/depot_tools" >> $GITHUB_PATH
|
||||
echo "$HOME/.electron_build_tools/third_party/depot_tools/python-bin" >> $GITHUB_PATH
|
||||
fi
|
||||
fi
|
||||
|
||||
2
.github/actions/restore-cache-aks/action.yml
vendored
2
.github/actions/restore-cache-aks/action.yml
vendored
@@ -31,7 +31,7 @@ runs:
|
||||
fi
|
||||
|
||||
mkdir temp-cache
|
||||
tar -xf $cache_path -C temp-cache
|
||||
zstd -d --long=30 -c $cache_path | tar -xf - -C temp-cache
|
||||
echo "Unzipped cache is $(du -sh temp-cache/src | cut -f1)"
|
||||
|
||||
if [ -d "temp-cache/src" ]; then
|
||||
|
||||
25
.github/actions/restore-cache-azcopy/action.yml
vendored
25
.github/actions/restore-cache-azcopy/action.yml
vendored
@@ -61,9 +61,9 @@ runs:
|
||||
echo "Cache is empty - exiting"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
||||
mkdir temp-cache
|
||||
tar -xf $DEPSHASH.tar -C temp-cache
|
||||
zstd -d --long=30 -c $DEPSHASH.tar | tar -xf - -C temp-cache
|
||||
echo "Unzipped cache is $(du -sh temp-cache/src | cut -f1)"
|
||||
|
||||
if [ -d "temp-cache/src" ]; then
|
||||
@@ -85,19 +85,17 @@ runs:
|
||||
|
||||
- name: Unzip and Ensure Src Cache (Windows)
|
||||
if: ${{ inputs.target-platform == 'win' }}
|
||||
shell: powershell
|
||||
shell: bash
|
||||
run: |
|
||||
$src_cache = "$env:DEPSHASH.tar"
|
||||
$cache_size = $(Get-Item $src_cache).length
|
||||
Write-Host "Downloaded cache is $cache_size"
|
||||
if ($cache_size -eq 0) {
|
||||
Write-Host "Cache is empty - exiting"
|
||||
echo "Downloaded cache is $(du -sh $DEPSHASH.tar | cut -f1)"
|
||||
if [ `du $DEPSHASH.tar | cut -f1` = "0" ]; then
|
||||
echo "Cache is empty - exiting"
|
||||
exit 1
|
||||
}
|
||||
fi
|
||||
|
||||
$TEMP_DIR=New-Item -ItemType Directory -Path temp-cache
|
||||
$TEMP_DIR_PATH = $TEMP_DIR.FullName
|
||||
C:\ProgramData\Chocolatey\bin\7z.exe -y -snld20 x $src_cache -o"$TEMP_DIR_PATH"
|
||||
mkdir temp-cache
|
||||
zstd -d --long=30 -c $DEPSHASH.tar | tar -xf - -C temp-cache
|
||||
rm -f $DEPSHASH.tar
|
||||
|
||||
- name: Move Src Cache (Windows)
|
||||
if: ${{ inputs.target-platform == 'win' }}
|
||||
@@ -112,9 +110,6 @@ runs:
|
||||
Write-Host "Relocating Cache"
|
||||
Remove-Item -Recurse -Force src
|
||||
Move-Item temp-cache\src src
|
||||
|
||||
Write-Host "Deleting zip file"
|
||||
Remove-Item -Force $src_cache
|
||||
}
|
||||
if (-Not (Test-Path "src\third_party\blink")) {
|
||||
Write-Host "Cache was not correctly restored - exiting"
|
||||
|
||||
22
.github/problem-matchers/eslint-stylish.json
vendored
22
.github/problem-matchers/eslint-stylish.json
vendored
@@ -1,22 +0,0 @@
|
||||
{
|
||||
"problemMatcher": [
|
||||
{
|
||||
"owner": "eslint-stylish",
|
||||
"pattern": [
|
||||
{
|
||||
"regexp": "^\\s*([^\\s].*)$",
|
||||
"file": 1
|
||||
},
|
||||
{
|
||||
"regexp": "^\\s+(\\d+):(\\d+)\\s+(error|warning|info)\\s+(.*)\\s\\s+(.*)$",
|
||||
"line": 1,
|
||||
"column": 2,
|
||||
"severity": 3,
|
||||
"message": 4,
|
||||
"code": 5,
|
||||
"loop": true
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
29
.github/workflows/build.yml
vendored
29
.github/workflows/build.yml
vendored
@@ -442,34 +442,7 @@ jobs:
|
||||
contents: read
|
||||
needs: [docs-only, macos-x64, macos-arm64, linux-x64, linux-x64-asan, linux-arm, linux-arm64, windows-x64, windows-x86, windows-arm64]
|
||||
if: always() && github.repository == 'electron/electron' && !contains(needs.*.result, 'failure')
|
||||
steps:
|
||||
steps:
|
||||
- name: GitHub Actions Jobs Done
|
||||
run: |
|
||||
echo "All GitHub Actions Jobs are done"
|
||||
|
||||
check-signed-commits:
|
||||
name: Check signed commits in green PR
|
||||
needs: gha-done
|
||||
if: ${{ contains(github.event.pull_request.labels.*.name, 'needs-signed-commits')}}
|
||||
runs-on: ubuntu-slim
|
||||
permissions:
|
||||
contents: read
|
||||
pull-requests: write
|
||||
steps:
|
||||
- name: Check signed commits in PR
|
||||
uses: 1Password/check-signed-commits-action@ed2885f3ed2577a4f5d3c3fe895432a557d23d52 # v1
|
||||
with:
|
||||
comment: |
|
||||
⚠️ This PR contains unsigned commits. This repository enforces [commit signatures](https://docs.github.com/en/authentication/managing-commit-signature-verification)
|
||||
for all incoming PRs. To get your PR merged, please sign those commits
|
||||
(`git rebase --exec 'git commit -S --amend --no-edit -n' @{upstream}`) and force push them to this branch
|
||||
(`git push --force-with-lease`)
|
||||
|
||||
For more information on signing commits, see GitHub's documentation on [Telling Git about your signing key](https://docs.github.com/en/authentication/managing-commit-signature-verification/telling-git-about-your-signing-key).
|
||||
|
||||
- name: Remove needs-signed-commits label
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
PR_URL: ${{ github.event.pull_request.html_url }}
|
||||
run: |
|
||||
gh pr edit $PR_URL --remove-label needs-signed-commits
|
||||
|
||||
32
.github/workflows/clean-orphaned-cache-uploads.yml
vendored
Normal file
32
.github/workflows/clean-orphaned-cache-uploads.yml
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
name: Clean Orphaned Cache Uploads
|
||||
|
||||
# Description:
|
||||
# Sweeps orphaned in-flight upload temp files left on the src-cache volumes
|
||||
# by checkout/action.yml when its cp-to-share step dies before the rename.
|
||||
# A successful upload finishes in minutes, so anything older than 4h is dead.
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: "0 */4 * * *"
|
||||
workflow_dispatch:
|
||||
|
||||
permissions: {}
|
||||
|
||||
jobs:
|
||||
clean-orphaned-uploads:
|
||||
if: github.repository == 'electron/electron'
|
||||
runs-on: electron-arc-centralus-linux-amd64-32core
|
||||
permissions:
|
||||
contents: read
|
||||
container:
|
||||
image: ghcr.io/electron/build:bc2f48b2415a670de18d13605b1cf0eb5fdbaae1
|
||||
options: --user root
|
||||
volumes:
|
||||
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
|
||||
- /mnt/win-cache:/mnt/win-cache
|
||||
steps:
|
||||
- name: Remove Orphaned Upload Temp Files
|
||||
shell: bash
|
||||
run: |
|
||||
find /mnt/cross-instance-cache -maxdepth 1 -type f -name '*.tar.upload-*' -mmin +240 -print -delete
|
||||
find /mnt/win-cache -maxdepth 1 -type f -name '*.tar.upload-*' -mmin +240 -print -delete
|
||||
127
.github/workflows/clean-src-cache.yml
vendored
127
.github/workflows/clean-src-cache.yml
vendored
@@ -7,6 +7,7 @@ name: Clean Source Cache
|
||||
on:
|
||||
schedule:
|
||||
- cron: "0 0 * * *"
|
||||
workflow_dispatch:
|
||||
|
||||
permissions: {}
|
||||
|
||||
@@ -16,6 +17,8 @@ jobs:
|
||||
runs-on: electron-arc-centralus-linux-amd64-32core
|
||||
permissions:
|
||||
contents: read
|
||||
env:
|
||||
DD_API_KEY: ${{ secrets.DD_API_KEY }}
|
||||
container:
|
||||
image: ghcr.io/electron/build:bc2f48b2415a670de18d13605b1cf0eb5fdbaae1
|
||||
options: --user root
|
||||
@@ -23,12 +26,130 @@ jobs:
|
||||
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
|
||||
- /mnt/win-cache:/mnt/win-cache
|
||||
steps:
|
||||
- name: Get Disk Space Before Cleanup
|
||||
id: disk-before
|
||||
shell: bash
|
||||
run: |
|
||||
echo "Disk space before cleanup:"
|
||||
df -h /mnt/cross-instance-cache
|
||||
df -h /mnt/win-cache
|
||||
CROSS_FREE_BEFORE=$(df -k /mnt/cross-instance-cache | tail -1 | awk '{print $4}')
|
||||
CROSS_TOTAL=$(df -k /mnt/cross-instance-cache | tail -1 | awk '{print $2}')
|
||||
WIN_FREE_BEFORE=$(df -k /mnt/win-cache | tail -1 | awk '{print $4}')
|
||||
WIN_TOTAL=$(df -k /mnt/win-cache | tail -1 | awk '{print $2}')
|
||||
echo "cross_free_kb=$CROSS_FREE_BEFORE" >> $GITHUB_OUTPUT
|
||||
echo "cross_total_kb=$CROSS_TOTAL" >> $GITHUB_OUTPUT
|
||||
echo "win_free_kb=$WIN_FREE_BEFORE" >> $GITHUB_OUTPUT
|
||||
echo "win_total_kb=$WIN_TOTAL" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Cleanup Source Cache
|
||||
shell: bash
|
||||
run: |
|
||||
df -h /mnt/cross-instance-cache
|
||||
find /mnt/cross-instance-cache -type f -mtime +15 -delete
|
||||
find /mnt/win-cache -type f -mtime +15 -delete
|
||||
|
||||
- name: Get Disk Space After Cleanup
|
||||
id: disk-after
|
||||
shell: bash
|
||||
run: |
|
||||
echo "Disk space after cleanup:"
|
||||
df -h /mnt/cross-instance-cache
|
||||
df -h /mnt/win-cache
|
||||
find /mnt/win-cache -type f -mtime +15 -delete
|
||||
df -h /mnt/win-cache
|
||||
CROSS_FREE_AFTER=$(df -k /mnt/cross-instance-cache | tail -1 | awk '{print $4}')
|
||||
WIN_FREE_AFTER=$(df -k /mnt/win-cache | tail -1 | awk '{print $4}')
|
||||
echo "cross_free_kb=$CROSS_FREE_AFTER" >> $GITHUB_OUTPUT
|
||||
echo "win_free_kb=$WIN_FREE_AFTER" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Log Disk Space to Datadog
|
||||
if: ${{ env.DD_API_KEY != '' }}
|
||||
shell: bash
|
||||
env:
|
||||
CROSS_FREE_BEFORE: ${{ steps.disk-before.outputs.cross_free_kb }}
|
||||
CROSS_FREE_AFTER: ${{ steps.disk-after.outputs.cross_free_kb }}
|
||||
CROSS_TOTAL: ${{ steps.disk-before.outputs.cross_total_kb }}
|
||||
WIN_FREE_BEFORE: ${{ steps.disk-before.outputs.win_free_kb }}
|
||||
WIN_FREE_AFTER: ${{ steps.disk-after.outputs.win_free_kb }}
|
||||
WIN_TOTAL: ${{ steps.disk-before.outputs.win_total_kb }}
|
||||
run: |
|
||||
TIMESTAMP=$(date +%s)
|
||||
|
||||
CROSS_FREE_BEFORE_GB=$(awk "BEGIN {printf \"%.2f\", $CROSS_FREE_BEFORE / 1024 / 1024}")
|
||||
CROSS_FREE_AFTER_GB=$(awk "BEGIN {printf \"%.2f\", $CROSS_FREE_AFTER / 1024 / 1024}")
|
||||
CROSS_FREED_GB=$(awk "BEGIN {printf \"%.2f\", ($CROSS_FREE_AFTER - $CROSS_FREE_BEFORE) / 1024 / 1024}")
|
||||
CROSS_TOTAL_GB=$(awk "BEGIN {printf \"%.2f\", $CROSS_TOTAL / 1024 / 1024}")
|
||||
|
||||
WIN_FREE_BEFORE_GB=$(awk "BEGIN {printf \"%.2f\", $WIN_FREE_BEFORE / 1024 / 1024}")
|
||||
WIN_FREE_AFTER_GB=$(awk "BEGIN {printf \"%.2f\", $WIN_FREE_AFTER / 1024 / 1024}")
|
||||
WIN_FREED_GB=$(awk "BEGIN {printf \"%.2f\", ($WIN_FREE_AFTER - $WIN_FREE_BEFORE) / 1024 / 1024}")
|
||||
WIN_TOTAL_GB=$(awk "BEGIN {printf \"%.2f\", $WIN_TOTAL / 1024 / 1024}")
|
||||
|
||||
echo "cross-instance-cache: free before=${CROSS_FREE_BEFORE_GB}GB, after=${CROSS_FREE_AFTER_GB}GB, freed=${CROSS_FREED_GB}GB, total=${CROSS_TOTAL_GB}GB"
|
||||
echo "win-cache: free before=${WIN_FREE_BEFORE_GB}GB, after=${WIN_FREE_AFTER_GB}GB, freed=${WIN_FREED_GB}GB, total=${WIN_TOTAL_GB}GB"
|
||||
|
||||
curl -s -X POST "https://api.datadoghq.com/api/v2/series" \
|
||||
-H "Content-Type: application/json" \
|
||||
-H "DD-API-KEY: ${DD_API_KEY}" \
|
||||
-d @- << EOF
|
||||
{
|
||||
"series": [
|
||||
{
|
||||
"metric": "electron.src_cache.disk.free_space_before_cleanup_gb",
|
||||
"points": [{"timestamp": ${TIMESTAMP}, "value": ${CROSS_FREE_BEFORE_GB}}],
|
||||
"type": 3,
|
||||
"unit": "gigabyte",
|
||||
"tags": ["volume:cross-instance-cache", "platform:linux"]
|
||||
},
|
||||
{
|
||||
"metric": "electron.src_cache.disk.free_space_after_cleanup_gb",
|
||||
"points": [{"timestamp": ${TIMESTAMP}, "value": ${CROSS_FREE_AFTER_GB}}],
|
||||
"type": 3,
|
||||
"unit": "gigabyte",
|
||||
"tags": ["volume:cross-instance-cache", "platform:linux"]
|
||||
},
|
||||
{
|
||||
"metric": "electron.src_cache.disk.space_freed_gb",
|
||||
"points": [{"timestamp": ${TIMESTAMP}, "value": ${CROSS_FREED_GB}}],
|
||||
"type": 3,
|
||||
"unit": "gigabyte",
|
||||
"tags": ["volume:cross-instance-cache", "platform:linux"]
|
||||
},
|
||||
{
|
||||
"metric": "electron.src_cache.disk.total_space_gb",
|
||||
"points": [{"timestamp": ${TIMESTAMP}, "value": ${CROSS_TOTAL_GB}}],
|
||||
"type": 3,
|
||||
"unit": "gigabyte",
|
||||
"tags": ["volume:cross-instance-cache", "platform:linux"]
|
||||
},
|
||||
{
|
||||
"metric": "electron.src_cache.disk.free_space_before_cleanup_gb",
|
||||
"points": [{"timestamp": ${TIMESTAMP}, "value": ${WIN_FREE_BEFORE_GB}}],
|
||||
"type": 3,
|
||||
"unit": "gigabyte",
|
||||
"tags": ["volume:win-cache", "platform:linux"]
|
||||
},
|
||||
{
|
||||
"metric": "electron.src_cache.disk.free_space_after_cleanup_gb",
|
||||
"points": [{"timestamp": ${TIMESTAMP}, "value": ${WIN_FREE_AFTER_GB}}],
|
||||
"type": 3,
|
||||
"unit": "gigabyte",
|
||||
"tags": ["volume:win-cache", "platform:linux"]
|
||||
},
|
||||
{
|
||||
"metric": "electron.src_cache.disk.space_freed_gb",
|
||||
"points": [{"timestamp": ${TIMESTAMP}, "value": ${WIN_FREED_GB}}],
|
||||
"type": 3,
|
||||
"unit": "gigabyte",
|
||||
"tags": ["volume:win-cache", "platform:linux"]
|
||||
},
|
||||
{
|
||||
"metric": "electron.src_cache.disk.total_space_gb",
|
||||
"points": [{"timestamp": ${TIMESTAMP}, "value": ${WIN_TOTAL_GB}}],
|
||||
"type": 3,
|
||||
"unit": "gigabyte",
|
||||
"tags": ["volume:win-cache", "platform:linux"]
|
||||
}
|
||||
]
|
||||
}
|
||||
EOF
|
||||
|
||||
echo "Disk space metrics logged to Datadog"
|
||||
|
||||
@@ -35,7 +35,7 @@ jobs:
|
||||
- name: Generate DEPS Hash
|
||||
run: |
|
||||
node src/electron/script/generate-deps-hash.js
|
||||
DEPSHASH=v1-src-cache-$(cat src/electron/.depshash)
|
||||
DEPSHASH=v2-src-cache-$(cat src/electron/.depshash)
|
||||
echo "DEPSHASH=$DEPSHASH" >> $GITHUB_ENV
|
||||
echo "CACHE_PATH=$DEPSHASH.tar" >> $GITHUB_ENV
|
||||
- name: Restore src cache via AKS
|
||||
|
||||
5
.github/workflows/pipeline-electron-lint.yml
vendored
5
.github/workflows/pipeline-electron-lint.yml
vendored
@@ -50,7 +50,7 @@ jobs:
|
||||
echo "::error::Invalid chromium_revision: $chromium_revision"
|
||||
exit 1
|
||||
fi
|
||||
gn_version="$(curl -sL -b ~/.gitcookies "https://chromium.googlesource.com/chromium/src/+/${chromium_revision}/DEPS?format=TEXT" | base64 -d | grep gn_version | head -n1 | cut -d\' -f4)"
|
||||
gn_version="$(curl -sL "https://raw.githubusercontent.com/chromium/chromium/refs/tags/${chromium_revision}/DEPS" | grep gn_version | head -n1 | cut -d\' -f4)"
|
||||
|
||||
cipd ensure -ensure-file - -root . <<-CIPD
|
||||
\$ServiceURL https://chrome-infra-packages.appspot.com/
|
||||
@@ -70,13 +70,12 @@ jobs:
|
||||
fi
|
||||
|
||||
mkdir -p src/buildtools
|
||||
curl -sL -b ~/.gitcookies "https://chromium.googlesource.com/chromium/src/+/${chromium_revision}/buildtools/DEPS?format=TEXT" | base64 -d > src/buildtools/DEPS
|
||||
curl -sL "https://raw.githubusercontent.com/chromium/chromium/refs/tags/${chromium_revision}/buildtools/DEPS" > src/buildtools/DEPS
|
||||
|
||||
gclient sync --spec="solutions=[{'name':'src/buildtools','url':None,'deps_file':'DEPS','custom_vars':{'process_deps':True},'managed':False}]"
|
||||
- name: Add problem matchers
|
||||
shell: bash
|
||||
run: |
|
||||
echo "::add-matcher::src/electron/.github/problem-matchers/eslint-stylish.json"
|
||||
echo "::add-matcher::src/electron/.github/problem-matchers/markdownlint.json"
|
||||
- name: Run Lint
|
||||
shell: bash
|
||||
|
||||
@@ -156,7 +156,7 @@ jobs:
|
||||
- name: Generate DEPS Hash
|
||||
run: |
|
||||
node src/electron/script/generate-deps-hash.js
|
||||
DEPSHASH=v1-src-cache-$(cat src/electron/.depshash)
|
||||
DEPSHASH=v2-src-cache-$(cat src/electron/.depshash)
|
||||
echo "DEPSHASH=$DEPSHASH" >> $GITHUB_ENV
|
||||
echo "CACHE_PATH=$DEPSHASH.tar" >> $GITHUB_ENV
|
||||
- name: Restore src cache via AZCopy
|
||||
|
||||
@@ -80,7 +80,7 @@ jobs:
|
||||
- name: Generate DEPS Hash
|
||||
run: |
|
||||
node src/electron/script/generate-deps-hash.js
|
||||
DEPSHASH=v1-src-cache-$(cat src/electron/.depshash)
|
||||
DEPSHASH=v2-src-cache-$(cat src/electron/.depshash)
|
||||
echo "DEPSHASH=$DEPSHASH" >> $GITHUB_ENV
|
||||
echo "CACHE_PATH=$DEPSHASH.tar" >> $GITHUB_ENV
|
||||
- name: Restore src cache via AZCopy
|
||||
|
||||
@@ -81,7 +81,7 @@ jobs:
|
||||
- name: Generate DEPS Hash
|
||||
run: |
|
||||
node src/electron/script/generate-deps-hash.js
|
||||
DEPSHASH=v1-src-cache-$(cat src/electron/.depshash)
|
||||
DEPSHASH=v2-src-cache-$(cat src/electron/.depshash)
|
||||
echo "DEPSHASH=$DEPSHASH" >> $GITHUB_ENV
|
||||
echo "CACHE_PATH=$DEPSHASH.tar" >> $GITHUB_ENV
|
||||
- name: Restore src cache via AZCopy
|
||||
|
||||
@@ -165,7 +165,7 @@ jobs:
|
||||
- name: Generate DEPS Hash
|
||||
run: |
|
||||
node src/electron/script/generate-deps-hash.js
|
||||
DEPSHASH=v1-src-cache-$(cat src/electron/.depshash)
|
||||
DEPSHASH=v2-src-cache-$(cat src/electron/.depshash)
|
||||
echo "DEPSHASH=$DEPSHASH" >> $GITHUB_ENV
|
||||
echo "CACHE_PATH=$DEPSHASH.tar" >> $GITHUB_ENV
|
||||
- name: Restore src cache via AZCopy
|
||||
|
||||
2
.github/workflows/pr-triage-automation.yml
vendored
2
.github/workflows/pr-triage-automation.yml
vendored
@@ -17,11 +17,13 @@ jobs:
|
||||
name: Set status to Needs Review
|
||||
if: >-
|
||||
(github.event_name == 'pull_request_target'
|
||||
&& github.event.pull_request.state == 'open'
|
||||
&& github.event.pull_request.draft != true
|
||||
&& !contains(github.event.pull_request.labels.*.name, 'wip ⚒')
|
||||
&& (github.event.action == 'synchronize' || github.event.action == 'review_requested'))
|
||||
|| (github.event_name == 'issue_comment'
|
||||
&& github.event.issue.pull_request
|
||||
&& github.event.issue.state == 'open'
|
||||
&& !contains(github.event.issue.labels.*.name, 'wip ⚒')
|
||||
&& github.event.comment.user.login == github.event.issue.user.login)
|
||||
runs-on: ubuntu-slim
|
||||
|
||||
4
.github/workflows/pull-request-labeled.yml
vendored
4
.github/workflows/pull-request-labeled.yml
vendored
@@ -50,7 +50,7 @@ jobs:
|
||||
field-value: ✅ Reviewed
|
||||
pull-request-labeled-ai-pr:
|
||||
name: ai-pr label added
|
||||
if: github.event.label.name == 'ai-pr'
|
||||
if: github.event.label.name == 'ai-pr' && github.event.pull_request.state != 'closed'
|
||||
runs-on: ubuntu-latest
|
||||
permissions: {}
|
||||
steps:
|
||||
@@ -72,7 +72,7 @@ jobs:
|
||||
|
||||
Hello @${{ github.event.pull_request.user.login }}. Due to the high amount of AI spam PRs we receive, if a PR is detected to be majority AI-generated without disclosure and untested, we will automatically close the PR.
|
||||
|
||||
We welcome the use of AI tools, as long as the PR meets our quality standards and has clearly been built and tested. If you believe your PR was closed in error, we welcome you to resubmit. However, please read our [CONTRIBUTING.md](http://contributing.md/) carefully before reopening. Thanks for your contribution.
|
||||
We welcome the use of AI tools, as long as the PR meets our quality standards and has clearly been built and tested. If you believe your PR was closed in error, we welcome you to resubmit. However, please read our [CONTRIBUTING.md](https://github.com/electron/electron/blob/main/CONTRIBUTING.md) and [AI Tool Policy](https://github.com/electron/governance/blob/main/policy/ai.md) carefully before reopening. Thanks for your contribution.
|
||||
- name: Close the pull request
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ steps.generate-token.outputs.token }}
|
||||
|
||||
@@ -13,7 +13,6 @@ permissions: {}
|
||||
jobs:
|
||||
check-signed-commits:
|
||||
name: Check signed commits in PR
|
||||
if: ${{ !contains(github.event.pull_request.labels.*.name, 'needs-signed-commits')}}
|
||||
runs-on: ubuntu-slim
|
||||
permissions:
|
||||
contents: read
|
||||
@@ -23,9 +22,9 @@ jobs:
|
||||
uses: 1Password/check-signed-commits-action@ed2885f3ed2577a4f5d3c3fe895432a557d23d52 # v1
|
||||
with:
|
||||
comment: |
|
||||
⚠️ This PR contains unsigned commits. This repository enforces [commit signatures](https://docs.github.com/en/authentication/managing-commit-signature-verification)
|
||||
for all incoming PRs. To get your PR merged, please sign those commits
|
||||
(`git rebase --exec 'git commit -S --amend --no-edit -n' @{upstream}`) and force push them to this branch
|
||||
⚠️ This PR contains unsigned commits. This repository enforces [commit signatures](https://docs.github.com/en/authentication/managing-commit-signature-verification)
|
||||
for all incoming PRs. To get your PR merged, please sign those commits
|
||||
(`git rebase --exec 'git commit -S --amend --no-edit -n' @{upstream}`) and force push them to this branch
|
||||
(`git push --force-with-lease`)
|
||||
|
||||
For more information on signing commits, see GitHub's documentation on [Telling Git about your signing key](https://docs.github.com/en/authentication/managing-commit-signature-verification/telling-git-about-your-signing-key).
|
||||
@@ -37,3 +36,11 @@ jobs:
|
||||
PR_URL: ${{ github.event.pull_request.html_url }}
|
||||
run: |
|
||||
gh pr edit $PR_URL --add-label needs-signed-commits
|
||||
|
||||
- name: Remove needs-signed-commits label
|
||||
if: ${{ success() && contains(github.event.pull_request.labels.*.name, 'needs-signed-commits') }}
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
PR_URL: ${{ github.event.pull_request.html_url }}
|
||||
run: |
|
||||
gh pr edit $PR_URL --remove-label needs-signed-commits
|
||||
|
||||
329
.oxlintrc.json
Normal file
329
.oxlintrc.json
Normal file
@@ -0,0 +1,329 @@
|
||||
{
|
||||
"$schema": "./node_modules/oxlint/configuration_schema.json",
|
||||
"plugins": [
|
||||
"typescript",
|
||||
"import",
|
||||
"node",
|
||||
"promise",
|
||||
"unicorn"
|
||||
],
|
||||
"jsPlugins": [
|
||||
{
|
||||
"name": "no-only-tests",
|
||||
"specifier": "./script/lint-plugins/no-only-tests.mjs"
|
||||
}
|
||||
],
|
||||
"categories": {
|
||||
"correctness": "off"
|
||||
},
|
||||
"options": {
|
||||
"typeAware": false
|
||||
},
|
||||
"env": {
|
||||
"builtin": true,
|
||||
"browser": true
|
||||
},
|
||||
"ignorePatterns": [
|
||||
".github/workflows/node_modules",
|
||||
"spec/node_modules",
|
||||
"spec/fixtures/native-addon",
|
||||
"shell/browser/resources/win/resource.h",
|
||||
"shell/common/node_includes.h",
|
||||
"spec/fixtures/pages/jquery-3.6.0.min.js"
|
||||
],
|
||||
"rules": {
|
||||
"no-var": "error",
|
||||
"accessor-pairs": [
|
||||
"error",
|
||||
{
|
||||
"setWithoutGet": true,
|
||||
"enforceForClassMembers": true
|
||||
}
|
||||
],
|
||||
"array-callback-return": [
|
||||
"error",
|
||||
{
|
||||
"allowImplicit": false,
|
||||
"checkForEach": false
|
||||
}
|
||||
],
|
||||
"constructor-super": "error",
|
||||
"curly": [
|
||||
"error",
|
||||
"multi-line"
|
||||
],
|
||||
"default-case-last": "error",
|
||||
"eqeqeq": [
|
||||
"error",
|
||||
"always",
|
||||
{
|
||||
"null": "ignore"
|
||||
}
|
||||
],
|
||||
"new-cap": [
|
||||
"error",
|
||||
{
|
||||
"newIsCap": true,
|
||||
"capIsNew": false,
|
||||
"properties": true
|
||||
}
|
||||
],
|
||||
"no-array-constructor": "error",
|
||||
"no-async-promise-executor": "error",
|
||||
"no-caller": "error",
|
||||
"no-case-declarations": "error",
|
||||
"no-class-assign": "error",
|
||||
"no-compare-neg-zero": "error",
|
||||
"no-cond-assign": "error",
|
||||
"no-const-assign": "error",
|
||||
"no-constant-condition": [
|
||||
"error",
|
||||
{
|
||||
"checkLoops": false
|
||||
}
|
||||
],
|
||||
"no-control-regex": "error",
|
||||
"no-debugger": "error",
|
||||
"no-delete-var": "error",
|
||||
"no-dupe-class-members": "error",
|
||||
"no-dupe-keys": "error",
|
||||
"no-duplicate-case": "error",
|
||||
"no-useless-backreference": "error",
|
||||
"no-empty": [
|
||||
"error",
|
||||
{
|
||||
"allowEmptyCatch": true
|
||||
}
|
||||
],
|
||||
"no-empty-character-class": "error",
|
||||
"no-empty-pattern": "error",
|
||||
"no-eval": "error",
|
||||
"no-ex-assign": "error",
|
||||
"no-extend-native": "error",
|
||||
"no-extra-bind": "error",
|
||||
"no-extra-boolean-cast": "error",
|
||||
"no-fallthrough": "error",
|
||||
"no-func-assign": "error",
|
||||
"no-global-assign": "error",
|
||||
"no-import-assign": "error",
|
||||
"no-invalid-regexp": "error",
|
||||
"no-irregular-whitespace": "error",
|
||||
"no-iterator": "error",
|
||||
"no-labels": [
|
||||
"error",
|
||||
{
|
||||
"allowLoop": false,
|
||||
"allowSwitch": false
|
||||
}
|
||||
],
|
||||
"no-lone-blocks": "error",
|
||||
"no-loss-of-precision": "error",
|
||||
"no-misleading-character-class": "error",
|
||||
"no-prototype-builtins": "error",
|
||||
"no-useless-catch": "error",
|
||||
"no-useless-constructor": "error",
|
||||
"no-use-before-define": [
|
||||
"error",
|
||||
{
|
||||
"functions": false,
|
||||
"classes": false,
|
||||
"variables": false
|
||||
}
|
||||
],
|
||||
"no-multi-str": "error",
|
||||
"no-new": "error",
|
||||
"no-new-func": "error",
|
||||
"no-new-wrappers": "error",
|
||||
"no-obj-calls": "error",
|
||||
"no-proto": "error",
|
||||
"no-redeclare": [
|
||||
"error"
|
||||
],
|
||||
"no-regex-spaces": "error",
|
||||
"no-return-assign": [
|
||||
"error",
|
||||
"except-parens"
|
||||
],
|
||||
"no-self-assign": [
|
||||
"error",
|
||||
{
|
||||
"props": true
|
||||
}
|
||||
],
|
||||
"no-self-compare": "error",
|
||||
"no-sequences": "error",
|
||||
"no-shadow-restricted-names": "error",
|
||||
"no-sparse-arrays": "error",
|
||||
"no-template-curly-in-string": "error",
|
||||
"no-this-before-super": "error",
|
||||
"no-throw-literal": "error",
|
||||
"no-unexpected-multiline": "error",
|
||||
"no-unmodified-loop-condition": "error",
|
||||
"no-unneeded-ternary": [
|
||||
"error",
|
||||
{
|
||||
"defaultAssignment": false
|
||||
}
|
||||
],
|
||||
"no-unreachable": "error",
|
||||
"no-unsafe-finally": "error",
|
||||
"no-unsafe-negation": "error",
|
||||
"no-unused-vars": [
|
||||
"error",
|
||||
{
|
||||
"vars": "all",
|
||||
"args": "after-used",
|
||||
"argsIgnorePattern": "^_",
|
||||
"ignoreRestSiblings": true
|
||||
}
|
||||
],
|
||||
"no-useless-call": "error",
|
||||
"no-useless-computed-key": "error",
|
||||
"no-useless-escape": "error",
|
||||
"no-useless-rename": "error",
|
||||
"no-useless-return": "error",
|
||||
"no-void": "error",
|
||||
"no-with": "error",
|
||||
"prefer-const": [
|
||||
"error",
|
||||
{
|
||||
"destructuring": "all"
|
||||
}
|
||||
],
|
||||
"prefer-promise-reject-errors": "error",
|
||||
"symbol-description": "error",
|
||||
"unicode-bom": [
|
||||
"error",
|
||||
"never"
|
||||
],
|
||||
"use-isnan": [
|
||||
"error",
|
||||
{
|
||||
"enforceForSwitchCase": true,
|
||||
"enforceForIndexOf": true
|
||||
}
|
||||
],
|
||||
"valid-typeof": [
|
||||
"error",
|
||||
{
|
||||
"requireStringLiterals": true
|
||||
}
|
||||
],
|
||||
"yoda": [
|
||||
"error",
|
||||
"never"
|
||||
],
|
||||
"import/export": "error",
|
||||
"import/first": "error",
|
||||
"import/no-absolute-path": [
|
||||
"error",
|
||||
{
|
||||
"esmodule": true,
|
||||
"commonjs": true,
|
||||
"amd": false
|
||||
}
|
||||
],
|
||||
"import/no-duplicates": "error",
|
||||
"import/no-named-default": "error",
|
||||
"import/no-webpack-loader-syntax": "error",
|
||||
"promise/param-names": "error",
|
||||
"guard-for-in": "error",
|
||||
"node/handle-callback-err": [
|
||||
"error",
|
||||
"^(err|error)$"
|
||||
],
|
||||
"node/no-exports-assign": "error",
|
||||
"node/no-new-require": "error",
|
||||
"node/no-path-concat": "error"
|
||||
},
|
||||
"overrides": [
|
||||
{
|
||||
"files": ["**/*.ts", "**/*.tsx", "**/*.mts", "**/*.cts"],
|
||||
"rules": {
|
||||
"no-use-before-define": "off"
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": ["lib/browser/**", "lib/utility/**"],
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"paths": ["electron", "electron/renderer"],
|
||||
"patterns": [
|
||||
"./*",
|
||||
"../*",
|
||||
"@electron/internal/isolated_renderer/*",
|
||||
"@electron/internal/renderer/*",
|
||||
"@electron/internal/sandboxed_worker/*",
|
||||
"@electron/internal/worker/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": [
|
||||
"lib/renderer/**",
|
||||
"lib/worker/**",
|
||||
"lib/preload_realm/**",
|
||||
"lib/sandboxed_renderer/**",
|
||||
"lib/isolated_renderer/**"
|
||||
],
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"paths": ["electron", "electron/main"],
|
||||
"patterns": ["./*", "../*", "@electron/internal/browser/*"]
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": ["lib/common/**"],
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"paths": ["electron", "electron/main", "electron/renderer"],
|
||||
"patterns": [
|
||||
"./*",
|
||||
"../*",
|
||||
"@electron/internal/browser/*",
|
||||
"@electron/internal/isolated_renderer/*",
|
||||
"@electron/internal/renderer/*",
|
||||
"@electron/internal/sandboxed_worker/*",
|
||||
"@electron/internal/worker/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": [
|
||||
"build/**",
|
||||
"script/**",
|
||||
"docs/**",
|
||||
"default_app/**",
|
||||
"spec/**"
|
||||
],
|
||||
"rules": {
|
||||
"unicorn/prefer-node-protocol": "error"
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": ["spec/**/*.ts", "spec/**/*.js", "spec/**/*.mjs"],
|
||||
"rules": {
|
||||
"no-only-tests/no-only-tests": "error"
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": ["**/*.d.ts"],
|
||||
"rules": {
|
||||
"no-useless-constructor": "off",
|
||||
"no-unused-vars": "off"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
1
BUILD.gn
1
BUILD.gn
@@ -775,6 +775,7 @@ source_set("electron_lib") {
|
||||
"//components/zoom",
|
||||
"//extensions/browser",
|
||||
"//extensions/browser/api:api_provider",
|
||||
"//extensions/browser/mime_handler:stream_info",
|
||||
"//extensions/browser/updater",
|
||||
"//extensions/common",
|
||||
"//extensions/common:core_api_provider",
|
||||
|
||||
12
CLAUDE.md
12
CLAUDE.md
@@ -1,5 +1,14 @@
|
||||
# Electron Development Guide
|
||||
|
||||
## Running node_modules binaries
|
||||
|
||||
**Never use `npx`.** It is considered dangerous because it can silently fetch and execute arbitrary packages from the registry. Always run binaries through one of these safer mechanisms instead:
|
||||
|
||||
1. **Preferred** — spawn the executable directly from `node_modules/.bin/<tool>` (or the platform equivalent on Windows). This is what `script/lint.js` does for `oxlint`.
|
||||
2. **Acceptable** — invoke via `yarn <tool>` or `yarn run <tool>`, which resolves to the locally installed version without the registry fallback that `npx` performs.
|
||||
|
||||
This rule applies to shell commands you run yourself and to any scripts you author or modify in this repo.
|
||||
|
||||
## Project Overview
|
||||
|
||||
Electron is a framework for building cross-platform desktop applications using web technologies. It embeds Chromium for rendering and Node.js for backend functionality.
|
||||
@@ -201,12 +210,13 @@ gh label list --repo electron/electron --search target/ --json name,color --jq '
|
||||
## Code Style
|
||||
|
||||
**C++:** Follows Chromium style, enforced by clang-format
|
||||
**TypeScript/JavaScript:** ESLint configuration in `.eslintrc.json`
|
||||
**TypeScript/JavaScript:** [oxlint](https://oxc.rs/docs/guide/usage/linter) configuration in `.oxlintrc.json`
|
||||
|
||||
**Linting:**
|
||||
|
||||
```bash
|
||||
npm run lint # Run all linters
|
||||
npm run lint:js # Run oxlint over all JS/TS/MJS sources
|
||||
npm run lint:clang-format # C++ formatting
|
||||
npm run lint:api-history # Validate API history YAML blocks in docs
|
||||
```
|
||||
|
||||
2
DEPS
2
DEPS
@@ -2,7 +2,7 @@ gclient_gn_args_from = 'src'
|
||||
|
||||
vars = {
|
||||
'chromium_version':
|
||||
'148.0.7763.0',
|
||||
'148.0.7778.0',
|
||||
'node_version':
|
||||
'v24.14.1',
|
||||
'nan_version':
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
{
|
||||
"plugins": [
|
||||
"import"
|
||||
],
|
||||
"rules": {
|
||||
"import/enforce-node-protocol-usage": ["error", "always"]
|
||||
}
|
||||
}
|
||||
@@ -144,6 +144,8 @@ static_library("chrome") {
|
||||
"//chrome/browser/ui/views/overlay/toggle_camera_button.h",
|
||||
"//chrome/browser/ui/views/overlay/toggle_microphone_button.cc",
|
||||
"//chrome/browser/ui/views/overlay/toggle_microphone_button.h",
|
||||
"//chrome/browser/ui/views/overlay/toggle_mute_button.cc",
|
||||
"//chrome/browser/ui/views/overlay/toggle_mute_button.h",
|
||||
"//chrome/browser/ui/views/overlay/video_overlay_window_views.cc",
|
||||
"//chrome/browser/ui/views/overlay/video_overlay_window_views.h",
|
||||
"//chrome/browser/ui/views/picture_in_picture/picture_in_picture_bounds_change_animation.cc",
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
{
|
||||
"plugins": [
|
||||
"import"
|
||||
],
|
||||
"rules": {
|
||||
"import/enforce-node-protocol-usage": ["error", "always"]
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
import { shell } from 'electron/common';
|
||||
import { app, dialog, BrowserWindow, ipcMain } from 'electron/main';
|
||||
import { app, dialog, BrowserWindow, ipcMain, Menu } from 'electron/main';
|
||||
|
||||
import * as path from 'node:path';
|
||||
import * as url from 'node:url';
|
||||
@@ -11,6 +11,53 @@ app.on('window-all-closed', () => {
|
||||
app.quit();
|
||||
});
|
||||
|
||||
const isMac = process.platform === 'darwin';
|
||||
|
||||
app.whenReady().then(() => {
|
||||
const helpMenu: Electron.MenuItemConstructorOptions = {
|
||||
role: 'help',
|
||||
submenu: [
|
||||
{
|
||||
label: 'Learn More',
|
||||
click: async () => {
|
||||
await shell.openExternal('https://electronjs.org');
|
||||
}
|
||||
},
|
||||
{
|
||||
label: 'Documentation',
|
||||
click: async () => {
|
||||
const version = process.versions.electron;
|
||||
await shell.openExternal(`https://github.com/electron/electron/tree/v${version}/docs#readme`);
|
||||
}
|
||||
},
|
||||
{
|
||||
label: 'Community Discussions',
|
||||
click: async () => {
|
||||
await shell.openExternal('https://discord.gg/electronjs');
|
||||
}
|
||||
},
|
||||
{
|
||||
label: 'Search Issues',
|
||||
click: async () => {
|
||||
await shell.openExternal('https://github.com/electron/electron/issues');
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
const macAppMenu: Electron.MenuItemConstructorOptions = { role: 'appMenu' };
|
||||
const template: Electron.MenuItemConstructorOptions[] = [
|
||||
...(isMac ? [macAppMenu] : []),
|
||||
{ role: 'fileMenu' },
|
||||
{ role: 'editMenu' },
|
||||
{ role: 'viewMenu' },
|
||||
{ role: 'windowMenu' },
|
||||
helpMenu
|
||||
];
|
||||
|
||||
Menu.setApplicationMenu(Menu.buildFromTemplate(template));
|
||||
});
|
||||
|
||||
function decorateURL (url: string) {
|
||||
// safely add `?utm_source=default_app
|
||||
const parsedUrl = new URL(url);
|
||||
|
||||
@@ -1,35 +0,0 @@
|
||||
{
|
||||
"extends": "standard",
|
||||
"plugins": [
|
||||
"import",
|
||||
"markdown"
|
||||
],
|
||||
"overrides": [
|
||||
{
|
||||
"files": ["*.md", "**/*.md"],
|
||||
"processor": "markdown/markdown"
|
||||
}
|
||||
],
|
||||
"rules": {
|
||||
"@typescript-eslint/no-unused-vars": "off",
|
||||
"import/order": ["error", {
|
||||
"alphabetize": {
|
||||
"order": "asc"
|
||||
},
|
||||
"newlines-between": "always",
|
||||
"pathGroups": [
|
||||
{
|
||||
"pattern": "{electron,electron/**}",
|
||||
"group": "builtin",
|
||||
"position": "before"
|
||||
}
|
||||
],
|
||||
"pathGroupsExcludedImportTypes": []
|
||||
}],
|
||||
"n/no-callback-literal": "off",
|
||||
"no-undef": "off",
|
||||
"no-unused-expressions": "off",
|
||||
"no-unused-vars": "off",
|
||||
"import/enforce-node-protocol-usage": ["error", "always"]
|
||||
}
|
||||
}
|
||||
@@ -148,3 +148,34 @@ added:
|
||||
-->
|
||||
|
||||
Unregisters all of the global shortcuts.
|
||||
|
||||
### `globalShortcut.setSuspended(suspended)`
|
||||
|
||||
<!--
|
||||
```YAML history
|
||||
added:
|
||||
- pr-url: https://github.com/electron/electron/pull/50425
|
||||
```
|
||||
-->
|
||||
|
||||
* `suspended` boolean - Whether global shortcut handling should be suspended.
|
||||
|
||||
Suspends or resumes global shortcut handling. When suspended, all registered
|
||||
global shortcuts will stop listening for key presses. When resumed, all
|
||||
previously registered shortcuts will begin listening again. New shortcut
|
||||
registrations will fail while handling is suspended.
|
||||
|
||||
This can be useful when you want to temporarily allow the user to press key
|
||||
combinations without your application intercepting them, for example while
|
||||
displaying a UI to rebind shortcuts.
|
||||
|
||||
### `globalShortcut.isSuspended()`
|
||||
|
||||
<!--
|
||||
```YAML history
|
||||
added:
|
||||
- pr-url: https://github.com/electron/electron/pull/50425
|
||||
```
|
||||
-->
|
||||
|
||||
Returns `boolean` - Whether global shortcut handling is currently suspended.
|
||||
|
||||
@@ -44,8 +44,8 @@ See [`Menu`](menu.md) for examples.
|
||||
menu items.
|
||||
* `registerAccelerator` boolean (optional) _Linux_ _Windows_ - If false, the accelerator won't be registered
|
||||
with the system, but it will still be displayed. Defaults to true.
|
||||
* `sharingItem` SharingItem (optional) _macOS_ - The item to share when the `role` is `shareMenu`.
|
||||
* `submenu` (MenuItemConstructorOptions[] | [Menu](menu.md)) (optional) - Should be specified
|
||||
* `sharingItem` [SharingItem](structures/sharing-item.md) (optional) _macOS_ - The item to share when the `role` is `shareMenu`.
|
||||
* `submenu` ([MenuItemConstructorOptions](#new-menuitemoptions)[] | [Menu](menu.md)) (optional) - Should be specified
|
||||
for `submenu` type menu items. If `submenu` is specified, the `type: 'submenu'` can be omitted.
|
||||
If the value is not a [`Menu`](menu.md) then it will be automatically converted to one using
|
||||
`Menu.buildFromTemplate`.
|
||||
@@ -89,7 +89,7 @@ A `Function` that is fired when the MenuItem receives a click event.
|
||||
It can be called with `menuItem.click(event, focusedWindow, focusedWebContents)`.
|
||||
|
||||
* `event` [KeyboardEvent](structures/keyboard-event.md)
|
||||
* `focusedWindow` [BaseWindow](browser-window.md)
|
||||
* `focusedWindow` [BaseWindow](base-window.md)
|
||||
* `focusedWebContents` [WebContents](web-contents.md)
|
||||
|
||||
#### `menuItem.submenu`
|
||||
@@ -110,11 +110,11 @@ A `string` (optional) indicating the item's role, if set. Can be `undo`, `redo`,
|
||||
|
||||
#### `menuItem.accelerator`
|
||||
|
||||
An `Accelerator | null` indicating the item's accelerator, if set.
|
||||
An [`Accelerator | null`](../tutorial/keyboard-shortcuts.md#accelerators) indicating the item's accelerator, if set.
|
||||
|
||||
#### `menuItem.userAccelerator` _Readonly_ _macOS_
|
||||
|
||||
An `Accelerator | null` indicating the item's [user-assigned accelerator](https://developer.apple.com/documentation/appkit/nsmenuitem/1514850-userkeyequivalent?language=objc) for the menu item.
|
||||
An [`Accelerator | null`](../tutorial/keyboard-shortcuts.md#accelerators) indicating the item's [user-assigned accelerator](https://developer.apple.com/documentation/appkit/nsmenuitem/1514850-userkeyequivalent?language=objc) for the menu item.
|
||||
|
||||
> [!NOTE]
|
||||
> This property is only initialized after the `MenuItem` has been added to a `Menu`. Either via `Menu.buildFromTemplate` or via `Menu.append()/insert()`. Accessing before initialization will just return `null`.
|
||||
@@ -170,7 +170,7 @@ This property can be dynamically changed.
|
||||
|
||||
#### `menuItem.sharingItem` _macOS_
|
||||
|
||||
A `SharingItem` indicating the item to share when the `role` is `shareMenu`.
|
||||
A [`SharingItem`](structures/sharing-item.md) indicating the item to share when the `role` is `shareMenu`.
|
||||
|
||||
This property can be dynamically changed.
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@ this has the additional effect of removing the menu bar from the window.
|
||||
|
||||
> [!NOTE]
|
||||
> The default menu will be created automatically if the app does not set one.
|
||||
> It contains standard items such as `File`, `Edit`, `View`, `Window` and `Help`.
|
||||
> It contains standard items such as `File`, `Edit`, `View`, and `Window`.
|
||||
|
||||
#### `Menu.getApplicationMenu()`
|
||||
|
||||
@@ -70,7 +70,7 @@ for more information on macOS' native actions.
|
||||
|
||||
#### `Menu.buildFromTemplate(template)`
|
||||
|
||||
- `template` (MenuItemConstructorOptions | [MenuItem](menu-item.md))[]
|
||||
- `template` ([MenuItemConstructorOptions](menu-item.md#new-menuitemoptions) | [MenuItem](menu-item.md))[]
|
||||
|
||||
Returns [`Menu`](menu.md)
|
||||
|
||||
@@ -162,7 +162,7 @@ Emitted when a popup is closed either manually or with `menu.closePopup()`.
|
||||
|
||||
#### `menu.items`
|
||||
|
||||
A `MenuItem[]` array containing the menu's items.
|
||||
A [`MenuItem[]`](menu-item.md) array containing the menu's items.
|
||||
|
||||
Each `Menu` consists of multiple [`MenuItem`](menu-item.md) instances and each `MenuItem`
|
||||
can nest a `Menu` into its `submenu` property.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
These are the style guidelines for coding in Electron.
|
||||
|
||||
You can run `npm run lint` to show any style issues detected by `cpplint` and
|
||||
`eslint`.
|
||||
`oxlint`.
|
||||
|
||||
## General Code
|
||||
|
||||
|
||||
@@ -79,7 +79,7 @@ $ ../../electron/script/git-import-patches ../../electron/patches/node
|
||||
$ ../../electron/script/git-export-patches -o ../../electron/patches/node
|
||||
```
|
||||
|
||||
Note that `git-import-patches` will mark the commit that was `HEAD` when it was run as `refs/patches/upstream-head`. This lets you keep track of which commits are from Electron patches (those that come after `refs/patches/upstream-head`) and which commits are in upstream (those before `refs/patches/upstream-head`).
|
||||
Note that `git-import-patches` will mark the commit that was `HEAD` when it was run as `refs/patches/upstream-head` (and a checkout-specific `refs/patches/upstream-head-<hash>` so that gclient worktrees sharing a `.git/refs` directory don't clobber each other). This lets you keep track of which commits are from Electron patches (those that come after `refs/patches/upstream-head`) and which commits are in upstream (those before `refs/patches/upstream-head`).
|
||||
|
||||
#### Resolving conflicts
|
||||
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
{
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"paths": [
|
||||
"electron",
|
||||
"electron/renderer"
|
||||
],
|
||||
"patterns": [
|
||||
"./*",
|
||||
"../*",
|
||||
"@electron/internal/isolated_renderer/*",
|
||||
"@electron/internal/renderer/*",
|
||||
"@electron/internal/sandboxed_worker/*",
|
||||
"@electron/internal/worker/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -73,6 +73,7 @@ export async function getSources (args: Electron.SourcesOptions) {
|
||||
|
||||
capturer._onerror = (error: string) => {
|
||||
stopRunning();
|
||||
// eslint-disable-next-line prefer-promise-reject-errors
|
||||
reject(error);
|
||||
};
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
import { shell } from 'electron/common';
|
||||
import { app, Menu } from 'electron/main';
|
||||
import { Menu } from 'electron/main';
|
||||
|
||||
const isMac = process.platform === 'darwin';
|
||||
|
||||
@@ -12,47 +11,13 @@ export const setApplicationMenuWasSet = () => {
|
||||
export const setDefaultApplicationMenu = () => {
|
||||
if (applicationMenuWasSet) return;
|
||||
|
||||
const helpMenu: Electron.MenuItemConstructorOptions = {
|
||||
role: 'help',
|
||||
submenu: app.isPackaged
|
||||
? []
|
||||
: [
|
||||
{
|
||||
label: 'Learn More',
|
||||
click: async () => {
|
||||
await shell.openExternal('https://electronjs.org');
|
||||
}
|
||||
},
|
||||
{
|
||||
label: 'Documentation',
|
||||
click: async () => {
|
||||
const version = process.versions.electron;
|
||||
await shell.openExternal(`https://github.com/electron/electron/tree/v${version}/docs#readme`);
|
||||
}
|
||||
},
|
||||
{
|
||||
label: 'Community Discussions',
|
||||
click: async () => {
|
||||
await shell.openExternal('https://discord.gg/electronjs');
|
||||
}
|
||||
},
|
||||
{
|
||||
label: 'Search Issues',
|
||||
click: async () => {
|
||||
await shell.openExternal('https://github.com/electron/electron/issues');
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
const macAppMenu: Electron.MenuItemConstructorOptions = { role: 'appMenu' };
|
||||
const template: Electron.MenuItemConstructorOptions[] = [
|
||||
...(isMac ? [macAppMenu] : []),
|
||||
{ role: 'fileMenu' },
|
||||
{ role: 'editMenu' },
|
||||
{ role: 'viewMenu' },
|
||||
{ role: 'windowMenu' },
|
||||
helpMenu
|
||||
{ role: 'windowMenu' }
|
||||
];
|
||||
|
||||
const menu = Menu.buildFromTemplate(template);
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
{
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"paths": [
|
||||
"electron",
|
||||
"electron/main",
|
||||
"electron/renderer"
|
||||
],
|
||||
"patterns": [
|
||||
"./*",
|
||||
"../*",
|
||||
"@electron/internal/browser/*",
|
||||
"@electron/internal/isolated_renderer/*",
|
||||
"@electron/internal/renderer/*",
|
||||
"@electron/internal/sandboxed_worker/*",
|
||||
"@electron/internal/worker/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
{
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"paths": [
|
||||
"electron",
|
||||
"electron/main"
|
||||
],
|
||||
"patterns": [
|
||||
"./*",
|
||||
"../*",
|
||||
"@electron/internal/browser/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
{
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"paths": [
|
||||
"electron",
|
||||
"electron/main"
|
||||
],
|
||||
"patterns": [
|
||||
"./*",
|
||||
"../*",
|
||||
"@electron/internal/browser/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
{
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"paths": [
|
||||
"electron",
|
||||
"electron/main"
|
||||
],
|
||||
"patterns": [
|
||||
"./*",
|
||||
"../*",
|
||||
"@electron/internal/browser/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
{
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"paths": [
|
||||
"electron",
|
||||
"electron/main"
|
||||
],
|
||||
"patterns": [
|
||||
"./*",
|
||||
"../*",
|
||||
"@electron/internal/browser/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -90,6 +90,7 @@ export function executeSandboxedPreloadScripts (context: PreloadContext, preload
|
||||
if (contents) {
|
||||
runPreloadScript(context, contents);
|
||||
} else if (error) {
|
||||
// eslint-disable-next-line no-throw-literal
|
||||
throw error;
|
||||
}
|
||||
} catch (error) {
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
{
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"paths": [
|
||||
"electron",
|
||||
"electron/renderer"
|
||||
],
|
||||
"patterns": [
|
||||
"./*",
|
||||
"../*",
|
||||
"@electron/internal/isolated_renderer/*",
|
||||
"@electron/internal/renderer/*",
|
||||
"@electron/internal/sandboxed_worker/*",
|
||||
"@electron/internal/worker/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
{
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"paths": [
|
||||
"electron",
|
||||
"electron/main"
|
||||
],
|
||||
"patterns": [
|
||||
"./*",
|
||||
"../*",
|
||||
"@electron/internal/browser/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -6,7 +6,7 @@
|
||||
"install-electron": "install.js"
|
||||
},
|
||||
"dependencies": {
|
||||
"@electron/get": "^2.0.0",
|
||||
"@electron/get": "^4.0.3",
|
||||
"@types/node": "^24.9.0",
|
||||
"extract-zip": "^2.0.1"
|
||||
},
|
||||
|
||||
15
package.json
15
package.json
@@ -13,7 +13,7 @@
|
||||
"@electron/lint-roller": "^3.2.0",
|
||||
"@electron/typescript-definitions": "^9.1.5",
|
||||
"@hurdlegroup/robotjs": "^0.12.3",
|
||||
"@octokit/rest": "^20.1.2",
|
||||
"@octokit/rest": "^22.0.1",
|
||||
"@primer/octicons": "^10.0.0",
|
||||
"@sentry/cli": "1.72.0",
|
||||
"@types/minimist": "^1.2.5",
|
||||
@@ -21,20 +21,10 @@
|
||||
"@types/semver": "^7.5.8",
|
||||
"@types/stream-json": "^1.7.8",
|
||||
"@types/temp": "^0.9.4",
|
||||
"@typescript-eslint/eslint-plugin": "^8.32.1",
|
||||
"@typescript-eslint/parser": "^8.7.0",
|
||||
"@xmldom/xmldom": "^0.8.11",
|
||||
"@xmldom/xmldom": "^0.8.12",
|
||||
"buffer": "^6.0.3",
|
||||
"chalk": "^4.1.0",
|
||||
"check-for-leaks": "^1.2.1",
|
||||
"eslint": "^8.57.1",
|
||||
"eslint-config-standard": "^17.1.0",
|
||||
"eslint-plugin-import": "^2.32.0",
|
||||
"eslint-plugin-markdown": "^5.1.0",
|
||||
"eslint-plugin-mocha": "^10.5.0",
|
||||
"eslint-plugin-n": "^17.24.0",
|
||||
"eslint-plugin-node": "^11.1.0",
|
||||
"eslint-plugin-promise": "^6.6.0",
|
||||
"events": "^3.2.0",
|
||||
"folder-hash": "^4.1.2",
|
||||
"got": "^11.8.5",
|
||||
@@ -44,6 +34,7 @@
|
||||
"minimist": "^1.2.8",
|
||||
"node-gyp": "^11.4.2",
|
||||
"null-loader": "^4.0.1",
|
||||
"oxlint": "^1.57.0",
|
||||
"pre-flight": "^2.0.0",
|
||||
"process": "^0.11.10",
|
||||
"semver": "^7.6.3",
|
||||
|
||||
@@ -10,10 +10,10 @@ this patch is required to provide ripemd160 support in the nodejs crypto
|
||||
module.
|
||||
|
||||
diff --git a/crypto/digest/digest_extra.cc b/crypto/digest/digest_extra.cc
|
||||
index 17961ba6bd9de78b5b1b1008eb1f73babd49d0e7..6a870dce37df8f49106c24b183308a2c7a03fd7d 100644
|
||||
index d38e0c1132da60ec96c3a5c2416ff07589f03b80..cd60baaf22a8d5dc20544d861d36b7d74d986e7b 100644
|
||||
--- a/crypto/digest/digest_extra.cc
|
||||
+++ b/crypto/digest/digest_extra.cc
|
||||
@@ -47,6 +47,7 @@ static const struct nid_to_digest nid_to_digest_mapping[] = {
|
||||
@@ -48,6 +48,7 @@ static const struct nid_to_digest nid_to_digest_mapping[] = {
|
||||
{NID_sha512, EVP_sha512, SN_sha512, LN_sha512},
|
||||
{NID_sha512_256, EVP_sha512_256, SN_sha512_256, LN_sha512_256},
|
||||
{NID_md5_sha1, EVP_md5_sha1, SN_md5_sha1, LN_md5_sha1},
|
||||
@@ -62,10 +62,10 @@ index a246a51103701e0ac8a0722324350a462f95bcc9..ddf0a90337d4e40de09bc345cf959dff
|
||||
+
|
||||
#undef CHECK
|
||||
diff --git a/decrepit/evp/evp_do_all.cc b/decrepit/evp/evp_do_all.cc
|
||||
index feaf17c72cecb8099bc11ac10747fbad719ddca9..891a73f229e3f0838cb2fa99b8fb24fdeac1962b 100644
|
||||
index 584b1390a841cc1b1dcb69e16d8242a88e4bb9cb..637aeccb8de8d793eabc38e32bef6834ac0e6ad3 100644
|
||||
--- a/decrepit/evp/evp_do_all.cc
|
||||
+++ b/decrepit/evp/evp_do_all.cc
|
||||
@@ -79,6 +79,7 @@ void EVP_MD_do_all_sorted(void (*callback)(const EVP_MD *cipher,
|
||||
@@ -82,6 +82,7 @@ void EVP_MD_do_all_sorted(void (*callback)(const EVP_MD *md,
|
||||
callback(EVP_sha384(), "SHA384", nullptr, arg);
|
||||
callback(EVP_sha512(), "SHA512", nullptr, arg);
|
||||
callback(EVP_sha512_256(), "SHA512-256", nullptr, arg);
|
||||
@@ -73,16 +73,16 @@ index feaf17c72cecb8099bc11ac10747fbad719ddca9..891a73f229e3f0838cb2fa99b8fb24fd
|
||||
|
||||
callback(EVP_md4(), "md4", nullptr, arg);
|
||||
callback(EVP_md5(), "md5", nullptr, arg);
|
||||
@@ -88,6 +89,7 @@ void EVP_MD_do_all_sorted(void (*callback)(const EVP_MD *cipher,
|
||||
@@ -91,6 +92,7 @@ void EVP_MD_do_all_sorted(void (*callback)(const EVP_MD *md,
|
||||
callback(EVP_sha384(), "sha384", nullptr, arg);
|
||||
callback(EVP_sha512(), "sha512", nullptr, arg);
|
||||
callback(EVP_sha512_256(), "sha512-256", nullptr, arg);
|
||||
+ callback(EVP_ripemd160(), "ripemd160", nullptr, arg);
|
||||
}
|
||||
|
||||
void EVP_MD_do_all(void (*callback)(const EVP_MD *cipher, const char *name,
|
||||
void EVP_MD_do_all(void (*callback)(const EVP_MD *md, const char *name,
|
||||
diff --git a/include/openssl/digest.h b/include/openssl/digest.h
|
||||
index 40670234682ac00dec268dea43f0ee1e39e8684f..293fbc9faf01ea0ca4e58b0a65b14597fe4916a6 100644
|
||||
index 62ad57368cb3059ee25df08bb07876fef499de2e..322daef194b3c7b73011419bb74bccb311eb03a5 100644
|
||||
--- a/include/openssl/digest.h
|
||||
+++ b/include/openssl/digest.h
|
||||
@@ -48,6 +48,9 @@ OPENSSL_EXPORT const EVP_MD *EVP_blake2b256(void);
|
||||
|
||||
@@ -64,10 +64,10 @@ index dabc54aa13745600a62e57ecbb427e48a4565282..ce213e00573102ce9405a794d3c140d9
|
||||
|
||||
const EVP_CIPHER *EVP_get_cipherbynid(int nid) {
|
||||
diff --git a/decrepit/evp/evp_do_all.cc b/decrepit/evp/evp_do_all.cc
|
||||
index 891a73f229e3f0838cb2fa99b8fb24fdeac1962b..f7d0c5dc66f016eb9338c15e7f5ef59e6de2969d 100644
|
||||
index 637aeccb8de8d793eabc38e32bef6834ac0e6ad3..c5dd0b18d7338457e47ae47088d9822472b24212 100644
|
||||
--- a/decrepit/evp/evp_do_all.cc
|
||||
+++ b/decrepit/evp/evp_do_all.cc
|
||||
@@ -20,8 +20,10 @@ void EVP_CIPHER_do_all_sorted(void (*callback)(const EVP_CIPHER *cipher,
|
||||
@@ -23,8 +23,10 @@ void EVP_CIPHER_do_all_sorted(void (*callback)(const EVP_CIPHER *cipher,
|
||||
const char *unused, void *arg),
|
||||
void *arg) {
|
||||
callback(EVP_aes_128_cbc(), "AES-128-CBC", nullptr, arg);
|
||||
@@ -78,7 +78,7 @@ index 891a73f229e3f0838cb2fa99b8fb24fdeac1962b..f7d0c5dc66f016eb9338c15e7f5ef59e
|
||||
callback(EVP_aes_128_ctr(), "AES-128-CTR", nullptr, arg);
|
||||
callback(EVP_aes_192_ctr(), "AES-192-CTR", nullptr, arg);
|
||||
callback(EVP_aes_256_ctr(), "AES-256-CTR", nullptr, arg);
|
||||
@@ -34,9 +36,13 @@ void EVP_CIPHER_do_all_sorted(void (*callback)(const EVP_CIPHER *cipher,
|
||||
@@ -37,9 +39,13 @@ void EVP_CIPHER_do_all_sorted(void (*callback)(const EVP_CIPHER *cipher,
|
||||
callback(EVP_aes_128_gcm(), "AES-128-GCM", nullptr, arg);
|
||||
callback(EVP_aes_192_gcm(), "AES-192-GCM", nullptr, arg);
|
||||
callback(EVP_aes_256_gcm(), "AES-256-GCM", nullptr, arg);
|
||||
@@ -92,7 +92,7 @@ index 891a73f229e3f0838cb2fa99b8fb24fdeac1962b..f7d0c5dc66f016eb9338c15e7f5ef59e
|
||||
callback(EVP_des_ede_cbc(), "DES-EDE-CBC", nullptr, arg);
|
||||
callback(EVP_des_ede3_cbc(), "DES-EDE3-CBC", nullptr, arg);
|
||||
callback(EVP_rc2_cbc(), "RC2-CBC", nullptr, arg);
|
||||
@@ -44,8 +50,10 @@ void EVP_CIPHER_do_all_sorted(void (*callback)(const EVP_CIPHER *cipher,
|
||||
@@ -47,8 +53,10 @@ void EVP_CIPHER_do_all_sorted(void (*callback)(const EVP_CIPHER *cipher,
|
||||
|
||||
// OpenSSL returns everything twice, the second time in lower case.
|
||||
callback(EVP_aes_128_cbc(), "aes-128-cbc", nullptr, arg);
|
||||
@@ -103,7 +103,7 @@ index 891a73f229e3f0838cb2fa99b8fb24fdeac1962b..f7d0c5dc66f016eb9338c15e7f5ef59e
|
||||
callback(EVP_aes_128_ctr(), "aes-128-ctr", nullptr, arg);
|
||||
callback(EVP_aes_192_ctr(), "aes-192-ctr", nullptr, arg);
|
||||
callback(EVP_aes_256_ctr(), "aes-256-ctr", nullptr, arg);
|
||||
@@ -58,9 +66,13 @@ void EVP_CIPHER_do_all_sorted(void (*callback)(const EVP_CIPHER *cipher,
|
||||
@@ -61,9 +69,13 @@ void EVP_CIPHER_do_all_sorted(void (*callback)(const EVP_CIPHER *cipher,
|
||||
callback(EVP_aes_128_gcm(), "aes-128-gcm", nullptr, arg);
|
||||
callback(EVP_aes_192_gcm(), "aes-192-gcm", nullptr, arg);
|
||||
callback(EVP_aes_256_gcm(), "aes-256-gcm", nullptr, arg);
|
||||
|
||||
@@ -125,7 +125,6 @@ feat_separate_content_settings_callback_for_sync_and_async_clipboard.patch
|
||||
fix_win32_synchronous_spellcheck.patch
|
||||
chore_grandfather_in_electron_views_and_delegates.patch
|
||||
refactor_patch_electron_permissiontypes_into_blink.patch
|
||||
revert_views_remove_desktopwindowtreehostwin_window_enlargement.patch
|
||||
fix_add_macos_memory_query_fallback_to_avoid_crash.patch
|
||||
fix_resolve_dynamic_background_material_update_issue_on_windows_11.patch
|
||||
feat_add_support_for_embedder_snapshot_validation.patch
|
||||
@@ -150,3 +149,4 @@ fix_use_fresh_lazynow_for_onendworkitemimpl_after_didruntask.patch
|
||||
fix_pulseaudio_stream_and_icon_names.patch
|
||||
fix_fire_menu_popup_start_for_dynamically_created_aria_menus.patch
|
||||
feat_allow_enabling_extensions_on_custom_protocols.patch
|
||||
fix_initialize_com_on_desktopmedialistcapturethread_on_windows.patch
|
||||
|
||||
@@ -33,7 +33,7 @@ index 26619daf25f3cc455d2dba7b5f16c9449e6103c1..387fca1b54b818a5af435e96bf8f435e
|
||||
client->PostSandboxInitialized();
|
||||
}
|
||||
diff --git a/content/public/gpu/content_gpu_client.h b/content/public/gpu/content_gpu_client.h
|
||||
index e5389b44df98ab1a5c976524a66a26c763e5c436..4a183b4959fae18e6875440e6570b8ada6823d81 100644
|
||||
index ad511f0966c29e46a1e4c07e09c3172b38c7c906..ca3a35d213147c6fcb9fbbbe118c15a3075875fa 100644
|
||||
--- a/content/public/gpu/content_gpu_client.h
|
||||
+++ b/content/public/gpu/content_gpu_client.h
|
||||
@@ -36,6 +36,10 @@ class CONTENT_EXPORT ContentGpuClient {
|
||||
|
||||
@@ -23,10 +23,10 @@ index 3f8cf4edc7448e6b584adae8fcbb872d27377126..1d03dc809d4c18f24314d94811e0bf52
|
||||
int32_t world_id) {}
|
||||
virtual void DidClearWindowObject() {}
|
||||
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
|
||||
index 0e64b0a0ac8387ab15b201a9fc0f0fd36cd5ab29..f28214d369138eb854a556165f0a946c07cfdb9c 100644
|
||||
index ab959e66f8841d7367863bb13d6c7a0854d0df23..5279ba15f45bd7634b5f24553ad64c0069318cc0 100644
|
||||
--- a/content/renderer/render_frame_impl.cc
|
||||
+++ b/content/renderer/render_frame_impl.cc
|
||||
@@ -4731,6 +4731,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local<v8::Context> context,
|
||||
@@ -4733,6 +4733,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local<v8::Context> context,
|
||||
observer.DidCreateScriptContext(context, world_id);
|
||||
}
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ Subject: allow disabling blink scheduler throttling per RenderView
|
||||
This allows us to disable throttling for hidden windows.
|
||||
|
||||
diff --git a/content/browser/renderer_host/navigation_controller_impl_unittest.cc b/content/browser/renderer_host/navigation_controller_impl_unittest.cc
|
||||
index 29d5b174e122cbd140554687548106ead8f8e8d9..da74da96c3fe35a0f3838f04bca08846f7b41abe 100644
|
||||
index f5a6ffc61f6cdff3897a97003b74838aac27e2a1..9b10aeb457a010db0ab89211610ea97b1a364453 100644
|
||||
--- a/content/browser/renderer_host/navigation_controller_impl_unittest.cc
|
||||
+++ b/content/browser/renderer_host/navigation_controller_impl_unittest.cc
|
||||
@@ -168,6 +168,12 @@ class MockPageBroadcast : public blink::mojom::PageBroadcast {
|
||||
@@ -51,7 +51,7 @@ index 89fed16c112d55c13a9f23695e2898d630f7d815..b7f486337f46daac015644525c9870f5
|
||||
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 79bd8d43a71731e5076196877448462656a04d48..b5d7f50817f503956f19fcea687b5b0751268b44 100644
|
||||
index 53ec5cd693539d74424c683f78e953e85c13c098..ccfe78580c2acb9a3afa43d246e1a83cc0e28598 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
@@ -655,8 +655,8 @@ void RenderWidgetHostViewAura::ShowImpl(PageVisibilityState page_visibility) {
|
||||
@@ -116,7 +116,7 @@ index 932658273154ef2e022358e493a8e7c00c86e732..57bbfb5cde62c9496c351c861880a189
|
||||
// Visibility -----------------------------------------------------------
|
||||
|
||||
diff --git a/third_party/blink/renderer/core/exported/web_view_impl.cc b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
index 611ecffa47703196dc40550b1e920afc4c1be716..be26284387dcfa4e72592862f313a2c7e9a81d1b 100644
|
||||
index b5a7e1b177f031837f670c26bff7394315eb6ea5..ed63aa041733e2fb09d77a219c93c322985cc81e 100644
|
||||
--- a/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
+++ b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
@@ -2471,6 +2471,10 @@ void WebViewImpl::SetPageLifecycleStateInternal(
|
||||
@@ -130,7 +130,7 @@ index 611ecffa47703196dc40550b1e920afc4c1be716..be26284387dcfa4e72592862f313a2c7
|
||||
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 &&
|
||||
@@ -4163,10 +4167,23 @@ PageScheduler* WebViewImpl::Scheduler() const {
|
||||
@@ -4170,10 +4174,23 @@ PageScheduler* WebViewImpl::Scheduler() const {
|
||||
return GetPage()->GetPageScheduler();
|
||||
}
|
||||
|
||||
@@ -155,7 +155,7 @@ index 611ecffa47703196dc40550b1e920afc4c1be716..be26284387dcfa4e72592862f313a2c7
|
||||
// Do not throttle if the page should be painting.
|
||||
bool is_visible =
|
||||
diff --git a/third_party/blink/renderer/core/exported/web_view_impl.h b/third_party/blink/renderer/core/exported/web_view_impl.h
|
||||
index 8d5c7349c360726778e37976fc54d660d7424f1f..96ee25c8ae4b50ab265bd698517efe15e2f1f44d 100644
|
||||
index b2ad789e53146b06e0e416f2dcf384cf7e9c17ae..838c67ac5b02c427858febbfbddf25fb03632b37 100644
|
||||
--- a/third_party/blink/renderer/core/exported/web_view_impl.h
|
||||
+++ b/third_party/blink/renderer/core/exported/web_view_impl.h
|
||||
@@ -446,6 +446,7 @@ class CORE_EXPORT WebViewImpl final : public WebView,
|
||||
|
||||
@@ -8,10 +8,10 @@ WebPreferences of in-process child windows, rather than relying on
|
||||
process-level command line switches, as before.
|
||||
|
||||
diff --git a/third_party/blink/common/web_preferences/web_preferences_mojom_traits.cc b/third_party/blink/common/web_preferences/web_preferences_mojom_traits.cc
|
||||
index c6552b25ffba3bf8d806d8bf2410a89533c9bef1..9920c3146c6cf700414a679e80087c469395eee9 100644
|
||||
index 9ab1b47509c8b72b7844e83f1d69499d13e26837..8fe07713a01123cc21d2649f8a3e9347a49a2bb8 100644
|
||||
--- a/third_party/blink/common/web_preferences/web_preferences_mojom_traits.cc
|
||||
+++ b/third_party/blink/common/web_preferences/web_preferences_mojom_traits.cc
|
||||
@@ -150,6 +150,19 @@ bool StructTraits<blink::mojom::WebPreferencesDataView,
|
||||
@@ -149,6 +149,19 @@ bool StructTraits<blink::mojom::WebPreferencesDataView,
|
||||
out->v8_cache_options = data.v8_cache_options();
|
||||
out->record_whole_document = data.record_whole_document();
|
||||
out->stylus_handwriting_enabled = data.stylus_handwriting_enabled();
|
||||
@@ -32,7 +32,7 @@ index c6552b25ffba3bf8d806d8bf2410a89533c9bef1..9920c3146c6cf700414a679e80087c46
|
||||
out->accelerated_video_decode_enabled =
|
||||
data.accelerated_video_decode_enabled();
|
||||
diff --git a/third_party/blink/public/common/web_preferences/web_preferences.h b/third_party/blink/public/common/web_preferences/web_preferences.h
|
||||
index 1188e60da33c292febf45be4cd6055671c21b4aa..43a1e777536ce2079d81deb5c7f440a1ba9b43d9 100644
|
||||
index efcb7d9457045c2d58ecec4b68d7c4547cb5d08a..e37fa2e8cb0896e61ef11259df13d97b8fbff548 100644
|
||||
--- a/third_party/blink/public/common/web_preferences/web_preferences.h
|
||||
+++ b/third_party/blink/public/common/web_preferences/web_preferences.h
|
||||
@@ -10,6 +10,7 @@
|
||||
@@ -64,7 +64,7 @@ index 1188e60da33c292febf45be4cd6055671c21b4aa..43a1e777536ce2079d81deb5c7f440a1
|
||||
// chrome, except for the cases where it would require lots of extra work for
|
||||
// the embedder to use the same default value.
|
||||
diff --git a/third_party/blink/public/common/web_preferences/web_preferences_mojom_traits.h b/third_party/blink/public/common/web_preferences/web_preferences_mojom_traits.h
|
||||
index ac91e8bad952dad5fc6ff673ffd19b0edd30bdb2..0f1715711056c83bb53e03dd8b675cb40a0c42cc 100644
|
||||
index fade1dd1310d8339fff45b9ae74ebff4673eec37..ea3f8f3e30f76ebf71ed470f43e4f61995829932 100644
|
||||
--- a/third_party/blink/public/common/web_preferences/web_preferences_mojom_traits.h
|
||||
+++ b/third_party/blink/public/common/web_preferences/web_preferences_mojom_traits.h
|
||||
@@ -8,6 +8,7 @@
|
||||
@@ -129,7 +129,7 @@ index ac91e8bad952dad5fc6ff673ffd19b0edd30bdb2..0f1715711056c83bb53e03dd8b675cb4
|
||||
return r.cookie_enabled;
|
||||
}
|
||||
diff --git a/third_party/blink/public/mojom/webpreferences/web_preferences.mojom b/third_party/blink/public/mojom/webpreferences/web_preferences.mojom
|
||||
index 0ed21e64a0b43580feb99166953babfb633d5af6..f06db564760e8f7e785bb3d6d4b80270a8783a23 100644
|
||||
index c637783517d250b7aa6f34af11fd3ca804a2a705..0268d33da3150a37ca8206695a5f324d8fde22e6 100644
|
||||
--- a/third_party/blink/public/mojom/webpreferences/web_preferences.mojom
|
||||
+++ b/third_party/blink/public/mojom/webpreferences/web_preferences.mojom
|
||||
@@ -4,6 +4,7 @@
|
||||
|
||||
@@ -15,7 +15,7 @@ Refs changes in:
|
||||
This patch reverts the changes to fix associated crashes in Electron.
|
||||
|
||||
diff --git a/third_party/blink/renderer/core/frame/frame.cc b/third_party/blink/renderer/core/frame/frame.cc
|
||||
index 901b727ed898cdd840df5ff7e2380fbee5d7fde2..1caacaeed9ddf1162cfa393fe4a7c86ac27f674a 100644
|
||||
index 9827a89c56141596fde57b78f9c9894f273db83e..cedb4bd8217a0ad3ab07d85421e1850bc4d910f5 100644
|
||||
--- a/third_party/blink/renderer/core/frame/frame.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/frame.cc
|
||||
@@ -135,14 +135,6 @@ bool Frame::Detach(FrameDetachType type) {
|
||||
@@ -49,7 +49,7 @@ index 901b727ed898cdd840df5ff7e2380fbee5d7fde2..1caacaeed9ddf1162cfa393fe4a7c86a
|
||||
// its owning reference back to our owning LocalFrame.
|
||||
client_->Detached(type);
|
||||
diff --git a/third_party/blink/renderer/core/frame/local_frame.cc b/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
index 802c876dd85d8100fc3d6e634ad4e390fd48747f..abe5b3c6e5eadf30f3e00013fceddaa0ead36cb1 100644
|
||||
index 4c38cd881b5a81b7939f61688f05949be799f008..8970537416e171d513bc9c015706fb18a574eab6 100644
|
||||
--- a/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
@@ -758,10 +758,6 @@ bool LocalFrame::DetachImpl(FrameDetachType type) {
|
||||
|
||||
@@ -8,7 +8,7 @@ categories in use are known / declared. This patch is required for us
|
||||
to introduce a new Electron category for Electron-specific tracing.
|
||||
|
||||
diff --git a/base/trace_event/builtin_categories.h b/base/trace_event/builtin_categories.h
|
||||
index 39168e90fd6ea68e562f0a2c6d8ba1162bc29e71..1b2b58497541b06857bc8f0d79172e8106003845 100644
|
||||
index 440349df6c5767fe3f93b51f78b33bf9d3bb5c1a..85c6f973788938b6a48a7a89e9fa803dc1030580 100644
|
||||
--- a/base/trace_event/builtin_categories.h
|
||||
+++ b/base/trace_event/builtin_categories.h
|
||||
@@ -133,6 +133,7 @@ PERFETTO_DEFINE_CATEGORIES_IN_NAMESPACE_WITH_ATTRS(
|
||||
|
||||
@@ -11,10 +11,10 @@ if we ever align our .pak file generation with Chrome we can remove this
|
||||
patch.
|
||||
|
||||
diff --git a/chrome/BUILD.gn b/chrome/BUILD.gn
|
||||
index 9a5b03af14d68c0c64380f84901aaeef11757ccb..933c03f197a8510c168775d5f8d19ebf375389d2 100644
|
||||
index 0af4d4b75d0519fabcb5d48bd9d5bd465bc80e92..eb6b23655afaa268f25d99301a0853aaecd23652 100644
|
||||
--- a/chrome/BUILD.gn
|
||||
+++ b/chrome/BUILD.gn
|
||||
@@ -201,11 +201,16 @@ if (!is_android && !is_mac) {
|
||||
@@ -201,6 +201,12 @@ if (!is_android && !is_mac) {
|
||||
"common/crash_keys.h",
|
||||
]
|
||||
|
||||
@@ -27,29 +27,11 @@ index 9a5b03af14d68c0c64380f84901aaeef11757ccb..933c03f197a8510c168775d5f8d19ebf
|
||||
deps += [
|
||||
":chrome_dll",
|
||||
":chrome_exe_version",
|
||||
":copy_first_run",
|
||||
- ":packed_resources_integrity_header",
|
||||
":visual_elements_resources",
|
||||
"//base",
|
||||
"//build:branding_buildflags",
|
||||
diff --git a/chrome/browser/BUILD.gn b/chrome/browser/BUILD.gn
|
||||
index 5768066ed65810d14d8ad4b6839c6c632af6bb57..d8d4e66f1c96f630e60001425d16fc4d6e22212b 100644
|
||||
--- a/chrome/browser/BUILD.gn
|
||||
+++ b/chrome/browser/BUILD.gn
|
||||
@@ -4455,7 +4455,7 @@ static_library("browser") {
|
||||
]
|
||||
}
|
||||
|
||||
- if (!is_win) {
|
||||
+ if (!is_win && !is_electron_build) {
|
||||
# On Windows, the hashes are embedded in //chrome:chrome_initial rather
|
||||
# than here in :chrome_dll.
|
||||
deps += [ "//chrome:packed_resources_integrity_header" ]
|
||||
diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn
|
||||
index 98ce26437751543c5c93574bc9561409e214d8a8..853eda4503954de04d50caba63f55fd74f390069 100644
|
||||
index e91f97276866bd500720962c74acaca2c22fff7c..22867153821d2b1e83feb1a2a7a6b8c26ba776eb 100644
|
||||
--- a/chrome/test/BUILD.gn
|
||||
+++ b/chrome/test/BUILD.gn
|
||||
@@ -7718,9 +7718,12 @@ test("unit_tests") {
|
||||
@@ -7737,6 +7737,10 @@ test("unit_tests") {
|
||||
"//chrome/notification_helper",
|
||||
]
|
||||
|
||||
@@ -59,11 +41,8 @@ index 98ce26437751543c5c93574bc9561409e214d8a8..853eda4503954de04d50caba63f55fd7
|
||||
+
|
||||
deps += [
|
||||
"//chrome:other_version",
|
||||
- "//chrome:packed_resources_integrity_header",
|
||||
"//chrome//services/util_win:unit_tests",
|
||||
"//chrome/app:chrome_dll_resources",
|
||||
"//chrome/app:win_unit_tests",
|
||||
@@ -8723,6 +8726,10 @@ test("unit_tests") {
|
||||
@@ -8711,6 +8715,10 @@ test("unit_tests") {
|
||||
"../browser/performance_manager/policies/background_tab_loading_policy_unittest.cc",
|
||||
]
|
||||
|
||||
@@ -74,11 +53,12 @@ index 98ce26437751543c5c93574bc9561409e214d8a8..853eda4503954de04d50caba63f55fd7
|
||||
sources += [
|
||||
# The importer code is not used on Android.
|
||||
"../common/importer/firefox_importer_utils_unittest.cc",
|
||||
@@ -8779,7 +8786,6 @@ test("unit_tests") {
|
||||
@@ -8767,7 +8775,7 @@ test("unit_tests") {
|
||||
# TODO(crbug.com/417513088): Maybe merge with the non-android `deps` declaration above?
|
||||
deps += [
|
||||
"../browser/screen_ai:screen_ai_install_state",
|
||||
- "//chrome:packed_resources_integrity_header",
|
||||
- "//chrome:packed_resources",
|
||||
+
|
||||
"//chrome/browser/apps:icon_standardizer",
|
||||
"//chrome/browser/apps/app_service",
|
||||
"//chrome/browser/apps/app_service:app_registry_cache_waiter",
|
||||
|
||||
@@ -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 914b06175825f79c03d34e0bdb1c3749a934bfdb..89f4af078c151adc1d9d471056bacab5dace0833 100644
|
||||
index ac474e220d411dec278c40448f038b25e6788d2a..e4ff8f11bed9e53f3134068492ac94b4c9bb4df2 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
@@ -10170,6 +10170,7 @@ void RenderFrameHostImpl::CreateNewWindow(
|
||||
@@ -10228,6 +10228,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 914b06175825f79c03d34e0bdb1c3749a934bfdb..89f4af078c151adc1d9d471056bacab5
|
||||
&no_javascript_access);
|
||||
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index 299324868f7bf88c7105015c1925881b06ec40a6..d40eb3c0670a9b3053db7773cef229adae8ecbec 100644
|
||||
index 3e0c8bd308d8a947a2bd295a2d83e385e53853fb..4e91b3aeb5630476c660e8814e2fd9d92c5a9ca1 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -5497,6 +5497,10 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -5501,6 +5501,10 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
create_params.initially_hidden = renderer_started_hidden;
|
||||
create_params.initial_popup_url = params.target_url;
|
||||
|
||||
@@ -35,7 +35,7 @@ index 299324868f7bf88c7105015c1925881b06ec40a6..d40eb3c0670a9b3053db7773cef229ad
|
||||
// Even though all codepaths leading here are in response to a renderer
|
||||
// trying to open a new window, if the new window ends up in a different
|
||||
// browsing instance, then the RenderViewHost, RenderWidgetHost,
|
||||
@@ -5551,6 +5555,12 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -5555,6 +5559,12 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
// Sets the newly created WebContents WindowOpenDisposition.
|
||||
new_contents_impl->original_window_open_disposition_ = params.disposition;
|
||||
|
||||
@@ -48,7 +48,7 @@ index 299324868f7bf88c7105015c1925881b06ec40a6..d40eb3c0670a9b3053db7773cef229ad
|
||||
// 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
|
||||
@@ -5592,12 +5602,6 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -5596,12 +5606,6 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
AddWebContentsDestructionObserver(new_contents_impl);
|
||||
}
|
||||
|
||||
@@ -77,10 +77,10 @@ index 444fa7009d0db33470cac9ab9cfdc23ceacec942..ab9aeb852e5ea89583284386d9a78a3e
|
||||
|
||||
// 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 836d27b82b0798be4a17484903284810d86e4ff9..b06cd802b7e9bedf038a0b84fd1f242c1664a6ed 100644
|
||||
index e806de04ca92cb8351e9a242a5241c0d4286da97..d0b3e4bc348921df7e6446dbc1f14860b8a84d87 100644
|
||||
--- a/content/public/browser/content_browser_client.cc
|
||||
+++ b/content/public/browser/content_browser_client.cc
|
||||
@@ -874,6 +874,8 @@ bool ContentBrowserClient::CanCreateWindow(
|
||||
@@ -854,6 +854,8 @@ bool ContentBrowserClient::CanCreateWindow(
|
||||
const std::string& frame_name,
|
||||
WindowOpenDisposition disposition,
|
||||
const blink::mojom::WindowFeatures& features,
|
||||
@@ -90,7 +90,7 @@ index 836d27b82b0798be4a17484903284810d86e4ff9..b06cd802b7e9bedf038a0b84fd1f242c
|
||||
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 7032139f91aadab0e854182d95eb97422a4182b3..f6ceaf652707d355780d8009339a42bbc271bd07 100644
|
||||
index 70588ccd619ac7969918771bccf5c054320e4f6f..eb684232648424fab4ba73b1fc813b0b3f8b809b 100644
|
||||
--- a/content/public/browser/content_browser_client.h
|
||||
+++ b/content/public/browser/content_browser_client.h
|
||||
@@ -205,6 +205,7 @@ class NetworkService;
|
||||
@@ -101,7 +101,7 @@ index 7032139f91aadab0e854182d95eb97422a4182b3..f6ceaf652707d355780d8009339a42bb
|
||||
} // namespace network
|
||||
|
||||
namespace sandbox {
|
||||
@@ -1457,6 +1458,8 @@ class CONTENT_EXPORT ContentBrowserClient {
|
||||
@@ -1406,6 +1407,8 @@ class CONTENT_EXPORT ContentBrowserClient {
|
||||
const std::string& frame_name,
|
||||
WindowOpenDisposition disposition,
|
||||
const blink::mojom::WindowFeatures& features,
|
||||
@@ -170,10 +170,10 @@ index 0650197909d484b8a0f48ab61b22471c71bce0e8..29c380d7845aab1a7b3417e0d3940ea0
|
||||
// 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 017007ee611e3cbb718085096b38c60677c0863c..0e64b0a0ac8387ab15b201a9fc0f0fd36cd5ab29 100644
|
||||
index 5936c5eaa081abde7f7c26cc990a122622e46908..ab959e66f8841d7367863bb13d6c7a0854d0df23 100644
|
||||
--- a/content/renderer/render_frame_impl.cc
|
||||
+++ b/content/renderer/render_frame_impl.cc
|
||||
@@ -6842,6 +6842,10 @@ WebView* RenderFrameImpl::CreateNewWindow(
|
||||
@@ -6845,6 +6845,10 @@ WebView* RenderFrameImpl::CreateNewWindow(
|
||||
params->started_by_ad =
|
||||
GetWebFrame()->IsAdFrame() || GetWebFrame()->IsAdScriptInStack();
|
||||
|
||||
@@ -185,10 +185,10 @@ index 017007ee611e3cbb718085096b38c60677c0863c..0e64b0a0ac8387ab15b201a9fc0f0fd3
|
||||
// moved on send.
|
||||
bool is_background_tab =
|
||||
diff --git a/content/web_test/browser/web_test_content_browser_client.cc b/content/web_test/browser/web_test_content_browser_client.cc
|
||||
index 7a57cb3a1414a77704c42ae01a9dc89fae4ad4a3..769601c2749f0781317f668cf806042db626c348 100644
|
||||
index 9453418ab164904cb9d75930d649abe21b94bb03..b2acd05882e8dfb04e5a75b249705c1a15209056 100644
|
||||
--- a/content/web_test/browser/web_test_content_browser_client.cc
|
||||
+++ b/content/web_test/browser/web_test_content_browser_client.cc
|
||||
@@ -539,6 +539,8 @@ bool WebTestContentBrowserClient::CanCreateWindow(
|
||||
@@ -540,6 +540,8 @@ bool WebTestContentBrowserClient::CanCreateWindow(
|
||||
const std::string& frame_name,
|
||||
WindowOpenDisposition disposition,
|
||||
const blink::mojom::WindowFeatures& features,
|
||||
@@ -224,10 +224,10 @@ index d92bab531c12c62a5321a23f4a0cb89691668127..2060e04795ba8e7a923fd0fe3485b8c5
|
||||
|
||||
} // namespace blink
|
||||
diff --git a/third_party/blink/renderer/core/frame/local_dom_window.cc b/third_party/blink/renderer/core/frame/local_dom_window.cc
|
||||
index 87856b74d5e0a323b8527d783316d1aab1cf9b1e..9f0d95954ed3d7c7e3ac4825f31ee55255e0c46f 100644
|
||||
index 51f03729c2d40a225dbcfc42091d44f78f77d971..780ee21199701b01a97932cd4a59aeb5db98017b 100644
|
||||
--- a/third_party/blink/renderer/core/frame/local_dom_window.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/local_dom_window.cc
|
||||
@@ -2366,6 +2366,8 @@ DOMWindow* LocalDOMWindow::open(v8::Isolate* isolate,
|
||||
@@ -2342,6 +2342,8 @@ DOMWindow* LocalDOMWindow::open(v8::Isolate* isolate,
|
||||
WebWindowFeatures window_features =
|
||||
GetWindowFeaturesFromString(features, entered_window);
|
||||
|
||||
|
||||
@@ -8,10 +8,10 @@ electron objects that extend gin::Wrappable and gets
|
||||
allocated on the cpp heap
|
||||
|
||||
diff --git a/gin/public/wrappable_pointer_tags.h b/gin/public/wrappable_pointer_tags.h
|
||||
index fee622ebde42211de6f702b754cfa38595df5a1c..6b524632ebb405e473cf4fe8e253bd13bf7b67e5 100644
|
||||
index fee622ebde42211de6f702b754cfa38595df5a1c..9f7e1b1b8d871721891255c1f21de825d0df1e30 100644
|
||||
--- a/gin/public/wrappable_pointer_tags.h
|
||||
+++ b/gin/public/wrappable_pointer_tags.h
|
||||
@@ -77,7 +77,20 @@ enum WrappablePointerTag : uint16_t {
|
||||
@@ -77,7 +77,21 @@ enum WrappablePointerTag : uint16_t {
|
||||
kWebAXObjectProxy, // content::WebAXObjectProxy
|
||||
kWrappedExceptionHandler, // extensions::WrappedExceptionHandler
|
||||
kIndigoContext, // indigo::IndigoContext
|
||||
@@ -24,6 +24,7 @@ index fee622ebde42211de6f702b754cfa38595df5a1c..6b524632ebb405e473cf4fe8e253bd13
|
||||
+ kElectronNetLog, // electron::api::NetLog
|
||||
+ kElectronPowerMonitor, // electron::api::PowerMonitor
|
||||
+ kElectronPowerSaveBlocker, // electron::api::PowerSaveBlocker
|
||||
+ kElectronProtocol, // electron::api::Protocol
|
||||
+ kElectronReplyChannel, // gin_helper::internal::ReplyChannel
|
||||
+ kElectronScreen, // electron::api::Screen
|
||||
+ kElectronSession, // electron::api::Session
|
||||
|
||||
@@ -34,10 +34,10 @@ index 1d03dc809d4c18f24314d94811e0bf527aa7b5b4..16030bcecb2e39b8870144ce7c3d11dd
|
||||
virtual void DidClearWindowObject() {}
|
||||
virtual void DidChangeScrollOffset() {}
|
||||
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
|
||||
index f28214d369138eb854a556165f0a946c07cfdb9c..7fb428cfdda42d1aac6922f2ed6f37369d4979e2 100644
|
||||
index 5279ba15f45bd7634b5f24553ad64c0069318cc0..2840f22e2b8b4aae09a06774a70f2ec7340536d9 100644
|
||||
--- a/content/renderer/render_frame_impl.cc
|
||||
+++ b/content/renderer/render_frame_impl.cc
|
||||
@@ -4737,10 +4737,11 @@ void RenderFrameImpl::DidInstallConditionalFeatures(
|
||||
@@ -4739,10 +4739,11 @@ void RenderFrameImpl::DidInstallConditionalFeatures(
|
||||
observer.DidInstallConditionalFeatures(context, world_id);
|
||||
}
|
||||
|
||||
@@ -103,7 +103,7 @@ index 8482d7fab12634e6b9a8d5f9bab6c7e428bb99ee..4f131fbfc9350352bce4430f92b9f2cf
|
||||
void WillInitializeWorkerContext() override;
|
||||
void WillDestroyWorkerContext(v8::Local<v8::Context> context) override;
|
||||
diff --git a/extensions/renderer/dispatcher.cc b/extensions/renderer/dispatcher.cc
|
||||
index df4634ffecb4b58885374199a863092bfdecf681..33e0ed7a7beae556328ec8bff5e8101acc4b3d26 100644
|
||||
index fd3960fce4c61c5c530c817bd12e1ba1698b8db6..48a159d7d5ea57b4533fdaf38fe79a74c490207a 100644
|
||||
--- a/extensions/renderer/dispatcher.cc
|
||||
+++ b/extensions/renderer/dispatcher.cc
|
||||
@@ -530,6 +530,7 @@ void Dispatcher::DidInitializeServiceWorkerContextOnWorkerThread(
|
||||
@@ -259,10 +259,10 @@ index 5a0f42b4b7e5eb67d476c948caa201ee6fc7b3ca..1a0562ad9ccfd414d6295b597b9d8094
|
||||
bool AllowScriptExtensions() override { return false; }
|
||||
|
||||
diff --git a/third_party/blink/renderer/modules/service_worker/service_worker_global_scope_proxy.cc b/third_party/blink/renderer/modules/service_worker/service_worker_global_scope_proxy.cc
|
||||
index f8bcd6fada82f9f0d473fa02799d0218c0e53b0b..765f10c71c50f2d89f8cdaf06d07ce4a53ef298c 100644
|
||||
index abbabcb7e2767ddef7e5bcda7812471282474260..e9e4864dbb1433d70344c58c4aeac6a906c50e02 100644
|
||||
--- a/third_party/blink/renderer/modules/service_worker/service_worker_global_scope_proxy.cc
|
||||
+++ b/third_party/blink/renderer/modules/service_worker/service_worker_global_scope_proxy.cc
|
||||
@@ -182,6 +182,7 @@ void ServiceWorkerGlobalScopeProxy::WillEvaluateScript() {
|
||||
@@ -181,6 +181,7 @@ void ServiceWorkerGlobalScopeProxy::WillEvaluateScript() {
|
||||
ScriptState::Scope scope(
|
||||
WorkerGlobalScope()->ScriptController()->GetScriptState());
|
||||
Client().WillEvaluateScript(
|
||||
|
||||
@@ -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 b53745dd0a4011fb15ab16d61f9a6effd5c03598..185520358c4839834d34b584de0e60d34afe01fc 100644
|
||||
index a1bb1a46029020d26d7bb88d314c5c5e5a967063..66c325724421c5315e89c0a02c19459f1dcb239d 100644
|
||||
--- a/base/threading/thread_restrictions.h
|
||||
+++ b/base/threading/thread_restrictions.h
|
||||
@@ -133,6 +133,7 @@ class KeyStorageLinux;
|
||||
@@ -28,7 +28,7 @@ index b53745dd0a4011fb15ab16d61f9a6effd5c03598..185520358c4839834d34b584de0e60d3
|
||||
namespace enterprise_connectors {
|
||||
class LinuxKeyRotationCommand;
|
||||
} // namespace enterprise_connectors
|
||||
@@ -583,6 +587,7 @@ class BASE_EXPORT ScopedAllowBlocking {
|
||||
@@ -585,6 +589,7 @@ class BASE_EXPORT ScopedAllowBlocking {
|
||||
friend class ::DesktopNotificationBalloon;
|
||||
friend class ::FirefoxProfileLock;
|
||||
friend class ::GaiaConfig;
|
||||
@@ -36,7 +36,7 @@ index b53745dd0a4011fb15ab16d61f9a6effd5c03598..185520358c4839834d34b584de0e60d3
|
||||
friend class ::ProfileImpl;
|
||||
friend class ::ScopedAllowBlockingForProfile;
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
@@ -628,6 +633,7 @@ class BASE_EXPORT ScopedAllowBlocking {
|
||||
@@ -630,6 +635,7 @@ class BASE_EXPORT ScopedAllowBlocking {
|
||||
friend class cronet::CronetPrefsManager;
|
||||
friend class crypto::ScopedAllowBlockingForNSS; // http://crbug.com/59847
|
||||
friend class drive::FakeDriveService;
|
||||
|
||||
@@ -14,10 +14,10 @@ track down the source of this problem & figure out if we can fix it
|
||||
by changing something in Electron.
|
||||
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index 97af9d9d374b9145e0e8a05cd5e48a621e2b0e87..a10a56827e0d277dfcc5bc8e72f90f7539ed50fd 100644
|
||||
index aaa2b2229dac8c5e8cf590300b436082f6c3773b..e12758010f5c243d2fb9c733b74bcb0eea89f5da 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -5468,7 +5468,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -5472,7 +5472,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
: IsGuest();
|
||||
// While some guest types do not have a guest SiteInstance, the ones that
|
||||
// don't all override WebContents creation above.
|
||||
|
||||
@@ -80,10 +80,10 @@ index 39fa45f0a0f9076bd7ac0be6f455dd540a276512..3d0381d463eed73470b28085830f2a23
|
||||
content::WebContents* source,
|
||||
const content::OpenURLParams& params,
|
||||
diff --git a/chrome/browser/ui/browser.cc b/chrome/browser/ui/browser.cc
|
||||
index e7fe85a1eae545b1bdcfd81d23ec607a42f3941a..d33125fb7e76b15d68d3c88be319f5ca93f82163 100644
|
||||
index 8f8852b2af1acfa4ec985fd1c8b50563b991b12a..c2f2903545b191c5ab13462bf330efce37d7d08c 100644
|
||||
--- a/chrome/browser/ui/browser.cc
|
||||
+++ b/chrome/browser/ui/browser.cc
|
||||
@@ -2292,7 +2292,8 @@ bool Browser::IsWebContentsCreationOverridden(
|
||||
@@ -2310,7 +2310,8 @@ bool Browser::IsWebContentsCreationOverridden(
|
||||
content::mojom::WindowContainerType window_container_type,
|
||||
const GURL& opener_url,
|
||||
const std::string& frame_name,
|
||||
@@ -93,7 +93,7 @@ index e7fe85a1eae545b1bdcfd81d23ec607a42f3941a..d33125fb7e76b15d68d3c88be319f5ca
|
||||
if (HasActorTaskPreventingNewWebContents(profile(), opener)) {
|
||||
// If an ExecutionEngine is acting on the opener, prevent it from creating a
|
||||
// new WebContents. We'll instead force the navigation to happen in the same
|
||||
@@ -2305,7 +2306,7 @@ bool Browser::IsWebContentsCreationOverridden(
|
||||
@@ -2323,7 +2324,7 @@ bool Browser::IsWebContentsCreationOverridden(
|
||||
return (window_container_type ==
|
||||
content::mojom::WindowContainerType::BACKGROUND &&
|
||||
ShouldCreateBackgroundContents(source_site_instance, opener_url,
|
||||
@@ -103,10 +103,10 @@ index e7fe85a1eae545b1bdcfd81d23ec607a42f3941a..d33125fb7e76b15d68d3c88be319f5ca
|
||||
|
||||
WebContents* Browser::CreateCustomWebContents(
|
||||
diff --git a/chrome/browser/ui/browser.h b/chrome/browser/ui/browser.h
|
||||
index b78f6ff36aaf1f541fedb8e2cb652f69227c506e..a8c426b0c1099822e9f2396981bf347d9318c451 100644
|
||||
index acdb28d61badaf549c47e107f4795e1e2adc37c9..b6aca0bf802f2146d09d2a872ff9e091e659f95f 100644
|
||||
--- a/chrome/browser/ui/browser.h
|
||||
+++ b/chrome/browser/ui/browser.h
|
||||
@@ -917,8 +917,7 @@ class Browser : public TabStripModelObserver,
|
||||
@@ -915,8 +915,7 @@ class Browser : public TabStripModelObserver,
|
||||
content::SiteInstance* source_site_instance,
|
||||
content::mojom::WindowContainerType window_container_type,
|
||||
const GURL& opener_url,
|
||||
@@ -223,10 +223,10 @@ index b969f1d97b7e3396119b579cfbe61e19ff7d2dd4..b8d6169652da28266a514938b45b39c5
|
||||
content::WebContents* AddNewContents(
|
||||
content::WebContents* source,
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index e70e2ecc3d0c5563a47f7b8a38a4face1d78d6d5..3b3f3ec690311d2f6e20fee8cf280c26bef77e76 100644
|
||||
index d43e75c20aca09080f4223d339c88381f030c504..8cd59445bae73ff0193e4512d7c36740cbad847f 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -5432,8 +5432,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
@@ -5436,8 +5436,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
||||
if (delegate_ &&
|
||||
delegate_->IsWebContentsCreationOverridden(
|
||||
opener, source_site_instance, params.window_container_type,
|
||||
@@ -357,7 +357,7 @@ index f459dddeb3f8f3a33ffead0e96fba791d18a0108..f7a229b186774ca3a01f2d747eab139a
|
||||
content::RenderFrameHost* opener,
|
||||
content::SiteInstance* source_site_instance,
|
||||
diff --git a/fuchsia_web/webengine/browser/frame_impl.cc b/fuchsia_web/webengine/browser/frame_impl.cc
|
||||
index 3b50b6b3616ead57de44d309a306db09dce82c65..c709f13b7c0bac9f41cac745678aaee04c1caf46 100644
|
||||
index 9c1fb0b2ed4f013ef6108a9844b22f6bfe697621..ef4991adc766d53b03d280395630b83ced38c2e8 100644
|
||||
--- a/fuchsia_web/webengine/browser/frame_impl.cc
|
||||
+++ b/fuchsia_web/webengine/browser/frame_impl.cc
|
||||
@@ -585,8 +585,7 @@ bool FrameImpl::IsWebContentsCreationOverridden(
|
||||
@@ -399,10 +399,10 @@ index ae616fa9c352413e23fb509b3e12e0e4fab5a094..0efa65f7d4346cfe78d2f27ba55a0526
|
||||
->options()
|
||||
->block_new_web_contents();
|
||||
diff --git a/ui/views/controls/webview/web_dialog_view.cc b/ui/views/controls/webview/web_dialog_view.cc
|
||||
index 20555af0857f1e8ea8227d71245fb95c5e95679a..a6df69bc877046214bf693ceff3c60036e8767ed 100644
|
||||
index a7d370220136f2c31afd70644ada26f1768b2e0d..e08dd61b20c68398b0532f5ae74e0ffd5968c19b 100644
|
||||
--- a/ui/views/controls/webview/web_dialog_view.cc
|
||||
+++ b/ui/views/controls/webview/web_dialog_view.cc
|
||||
@@ -489,8 +489,7 @@ bool WebDialogView::IsWebContentsCreationOverridden(
|
||||
@@ -490,8 +490,7 @@ bool WebDialogView::IsWebContentsCreationOverridden(
|
||||
content::SiteInstance* source_site_instance,
|
||||
content::mojom::WindowContainerType window_container_type,
|
||||
const GURL& opener_url,
|
||||
|
||||
@@ -7,12 +7,12 @@ 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 b795a9dbf898570a7cd8469ee386c4edf4bfa275..449940fe1b6969576f1b2c21d7719620e578e8a8 100644
|
||||
index e795339c000cf695ca05c6d3c736678fa47df21e..bbcad80a8efdac88c26ececeaf4023152631b662 100644
|
||||
--- a/content/app/content_main_runner_impl.cc
|
||||
+++ b/content/app/content_main_runner_impl.cc
|
||||
@@ -277,8 +277,13 @@ void AsanProcessInfoCB(const char* reason,
|
||||
}
|
||||
#endif // defined(ADDRESS_SANITIZER)
|
||||
@@ -261,8 +261,13 @@ std::string GetSnapshotDataDescriptor(const base::CommandLine& command_line) {
|
||||
|
||||
#endif
|
||||
|
||||
-void LoadV8SnapshotFile(const base::CommandLine& command_line) {
|
||||
+void LoadV8SnapshotFile(const raw_ptr<ContentMainDelegate> delegate, const base::CommandLine& command_line) {
|
||||
@@ -79,10 +79,10 @@ index 8c318a31454c57b0e8db3770a36c45be427f053c..6f809c9672448ed9797e3c9da492ad2c
|
||||
friend class ContentClientCreator;
|
||||
friend class ContentClientInitializer;
|
||||
diff --git a/gin/v8_initializer.cc b/gin/v8_initializer.cc
|
||||
index 136e728c4c7981c9180304a43d75b2f003161664..aef4af8ce2a3352535a1ea2f4777e839c4811817 100644
|
||||
index cd1f308815685d28c506b5c9eb87b24107fa220b..58b708b0f7716f0d12ad1135ba65125cab1303a4 100644
|
||||
--- a/gin/v8_initializer.cc
|
||||
+++ b/gin/v8_initializer.cc
|
||||
@@ -634,8 +634,7 @@ void V8Initializer::GetV8ExternalSnapshotData(const char** snapshot_data_out,
|
||||
@@ -630,8 +630,7 @@ void V8Initializer::GetV8ExternalSnapshotData(const char** snapshot_data_out,
|
||||
|
||||
#if defined(V8_USE_EXTERNAL_STARTUP_DATA)
|
||||
|
||||
@@ -92,7 +92,7 @@ index 136e728c4c7981c9180304a43d75b2f003161664..aef4af8ce2a3352535a1ea2f4777e839
|
||||
if (g_mapped_snapshot) {
|
||||
// TODO(crbug.com/40558459): Confirm not loading different type of snapshot
|
||||
// files in a process.
|
||||
@@ -644,10 +643,17 @@ void V8Initializer::LoadV8Snapshot(V8SnapshotFileType snapshot_file_type) {
|
||||
@@ -640,10 +639,17 @@ void V8Initializer::LoadV8Snapshot(V8SnapshotFileType snapshot_file_type) {
|
||||
|
||||
base::MemoryMappedFile::Region file_region;
|
||||
base::File file =
|
||||
|
||||
@@ -6,10 +6,10 @@ Subject: fix: disabling compositor recycling
|
||||
Compositor recycling is useful for Chrome because there can be many tabs and spinning up a compositor for each one would be costly. In practice, Chrome uses the parent compositor code path of browser_compositor_view_mac.mm; the NSView of each tab is detached when it's hidden and attached when it's shown. For Electron, there is no parent compositor, so we're forced into the "own compositor" code path, which seems to be non-optimal and pretty ruthless in terms of the release of resources. Electron has no real concept of multiple tabs per window, so it should be okay to disable this ruthless recycling altogether in Electron.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_view_mac.mm b/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
index 0747a20b283151a75c524dc0fa74c7b799725e54..7541f191cc20c10a6bb85a7bd5f3eaa71051a519 100644
|
||||
index 886b3e87e9041931d3cb59ef775b5012e8e2f908..9287bde2d8c0eaa00c29fca974111b3f32b6e813 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
@@ -592,7 +592,11 @@
|
||||
@@ -597,7 +597,11 @@
|
||||
}
|
||||
|
||||
host()->WasHidden();
|
||||
|
||||
@@ -6,10 +6,10 @@ Subject: disable_hidden.patch
|
||||
Electron uses this to disable background throttling for hidden windows.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
index be97442111503ac8ca75171f2d195a0a18f9d7eb..5e7d992ba2144d32f8eb1c6fa5233c68954318e1 100644
|
||||
index fe46ebe4e5bcda2eff543aa5b5a2310628a3ea5a..8df679251dc314a94079fcc9d4edd7fab12873d4 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
@@ -810,6 +810,10 @@ void RenderWidgetHostImpl::WasHidden() {
|
||||
@@ -818,6 +818,10 @@ void RenderWidgetHostImpl::WasHidden() {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -21,10 +21,10 @@ index be97442111503ac8ca75171f2d195a0a18f9d7eb..5e7d992ba2144d32f8eb1c6fa5233c68
|
||||
// Prompts should remain open and functional across tab switches.
|
||||
if (!delegate_ || !delegate_->IsWaitingForPointerLockPrompt(this)) {
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.h b/content/browser/renderer_host/render_widget_host_impl.h
|
||||
index 8fc7d892a54e0890e86b01713f0cf6b75aa14ab0..d60b540934b290e9303b1dacfa990e85ce47b4e0 100644
|
||||
index 37b2ca1000ead76ec7e403bf1e2dc647bcee74ce..1312c87909729ac59ea661321c10862f34072f95 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.h
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.h
|
||||
@@ -1042,6 +1042,8 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
||||
@@ -1059,6 +1059,8 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
||||
|
||||
base::TimeDelta GetHungRendererDelayForTesting();
|
||||
|
||||
@@ -34,10 +34,10 @@ index 8fc7d892a54e0890e86b01713f0cf6b75aa14ab0..d60b540934b290e9303b1dacfa990e85
|
||||
// |routing_id| must not be IPC::mojom::kRoutingIdNone.
|
||||
// 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 95f75a24fa3e799dc4227e6438b1d0cc316ba4b9..79bd8d43a71731e5076196877448462656a04d48 100644
|
||||
index 550a2090d11ea151d8003610cb39a8035c5d299c..53ec5cd693539d74424c683f78e953e85c13c098 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
@@ -719,7 +719,7 @@ void RenderWidgetHostViewAura::HideImpl() {
|
||||
@@ -712,7 +712,7 @@ void RenderWidgetHostViewAura::HideImpl() {
|
||||
CHECK(visibility_ == Visibility::HIDDEN ||
|
||||
visibility_ == Visibility::OCCLUDED);
|
||||
|
||||
|
||||
@@ -33,10 +33,10 @@ index 0ab8187b0db8ae6db46d81738f653a2bc4c566f6..de3d55e85c22317f7f9375eb94d0d5d4
|
||||
|
||||
} // namespace net
|
||||
diff --git a/services/network/network_context.cc b/services/network/network_context.cc
|
||||
index 4efd5407479b9e5ee6af84a4cd6d26895d8b19f7..498c877f3f159729eae4857b5210b913eec962d0 100644
|
||||
index cf1001557f2f59747ceb394ab2c93b4bf379dafb..2e16a8d19e1ccfbfc838ed33ecac3375f1e81b17 100644
|
||||
--- a/services/network/network_context.cc
|
||||
+++ b/services/network/network_context.cc
|
||||
@@ -1965,6 +1965,13 @@ void NetworkContext::SetNetworkConditions(
|
||||
@@ -1994,6 +1994,13 @@ void NetworkContext::SetNetworkConditions(
|
||||
std::move(network_conditions));
|
||||
}
|
||||
|
||||
@@ -51,10 +51,10 @@ index 4efd5407479b9e5ee6af84a4cd6d26895d8b19f7..498c877f3f159729eae4857b5210b913
|
||||
// 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 912e4d60647f6376dfef62d18998b556bc7efa32..53082e9f0bfb98c1267fc034fa34e157b4c04d9b 100644
|
||||
index 04e6e884dccbb680a39f2b9c8a54de162e056a30..672dd48040586190b761e2db554ba0767d254f62 100644
|
||||
--- a/services/network/network_context.h
|
||||
+++ b/services/network/network_context.h
|
||||
@@ -331,6 +331,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
@@ -332,6 +332,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
void SetNetworkConditions(
|
||||
const base::UnguessableToken& throttling_profile_id,
|
||||
std::vector<mojom::MatchedNetworkConditionsPtr> conditions) override;
|
||||
@@ -63,10 +63,10 @@ index 912e4d60647f6376dfef62d18998b556bc7efa32..53082e9f0bfb98c1267fc034fa34e157
|
||||
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 63d410dd356594a5928ed2f84b05b403bf3367f0..ca47c9cb58d5d69faade9f85d1e63683d79cb5e3 100644
|
||||
index 6c43c2985123525793dd6b60c9d7d7c1db7fdf04..7493bd8dd37b36a3e7a96b1373619fee0b6a9d8e 100644
|
||||
--- a/services/network/public/mojom/network_context.mojom
|
||||
+++ b/services/network/public/mojom/network_context.mojom
|
||||
@@ -1291,6 +1291,9 @@ interface NetworkContext {
|
||||
@@ -1299,6 +1299,9 @@ interface NetworkContext {
|
||||
SetNetworkConditions(mojo_base.mojom.UnguessableToken throttling_profile_id,
|
||||
array<MatchedNetworkConditions> conditions);
|
||||
|
||||
@@ -77,7 +77,7 @@ index 63d410dd356594a5928ed2f84b05b403bf3367f0..ca47c9cb58d5d69faade9f85d1e63683
|
||||
SetAcceptLanguage(string new_accept_language);
|
||||
|
||||
diff --git a/services/network/test/test_network_context.h b/services/network/test/test_network_context.h
|
||||
index bc26f449109b3be84490fbb3569e36aa4aca8c4b..d273faec6c235cb7d29f0f7fb90affdca7240e51 100644
|
||||
index b472be0acdc0cd4971e6e0a9e623bc1c84d07a02..f328a3aa2df9f5c6163a5023a5df157350d3707f 100644
|
||||
--- a/services/network/test/test_network_context.h
|
||||
+++ b/services/network/test/test_network_context.h
|
||||
@@ -156,6 +156,7 @@ class TestNetworkContext : public mojom::NetworkContext {
|
||||
|
||||
@@ -15,7 +15,7 @@ Ideally we could add an embedder observer pattern here but that can be
|
||||
done in future work.
|
||||
|
||||
diff --git a/third_party/blink/renderer/core/exported/web_view_impl.cc b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
index be26284387dcfa4e72592862f313a2c7e9a81d1b..efe1cbfcb6f39f4bf744dd830281bf528ebd1659 100644
|
||||
index ed63aa041733e2fb09d77a219c93c322985cc81e..ea23d47128d4e974353ea5a976a72d4fa0600e2b 100644
|
||||
--- a/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
+++ b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
||||
@@ -1855,6 +1855,8 @@ void WebView::ApplyWebPreferences(const web_pref::WebPreferences& prefs,
|
||||
|
||||
@@ -17,11 +17,11 @@ which removed range-requests-supported on non-http protocols. See https://issues
|
||||
for more information.
|
||||
|
||||
diff --git a/third_party/blink/renderer/platform/media/multi_buffer_data_source.cc b/third_party/blink/renderer/platform/media/multi_buffer_data_source.cc
|
||||
index f697f85d7e3e9eeeab249a6d4e8ef8383c5c0d72..a5f35e7782c047b147458e569924de0fd30db7ce 100644
|
||||
index 0af2ad19954bd868f6b92616da869b350f088103..efc53247962f166f2b441f76c7a2c94d8ceb979a 100644
|
||||
--- a/third_party/blink/renderer/platform/media/multi_buffer_data_source.cc
|
||||
+++ b/third_party/blink/renderer/platform/media/multi_buffer_data_source.cc
|
||||
@@ -11,8 +11,10 @@
|
||||
#include "base/containers/adapters.h"
|
||||
@@ -12,8 +12,10 @@
|
||||
#include "base/functional/callback_helpers.h"
|
||||
#include "base/location.h"
|
||||
#include "base/memory/raw_span.h"
|
||||
+#include "base/no_destructor.h"
|
||||
@@ -31,7 +31,7 @@ index f697f85d7e3e9eeeab249a6d4e8ef8383c5c0d72..a5f35e7782c047b147458e569924de0f
|
||||
#include "media/base/media_log.h"
|
||||
#include "net/base/net_errors.h"
|
||||
#include "third_party/blink/renderer/platform/media/buffered_data_source_host_impl.h"
|
||||
@@ -69,6 +71,10 @@ constexpr base::TimeDelta kSeekDelay = base::Milliseconds(20);
|
||||
@@ -70,6 +72,10 @@ constexpr base::TimeDelta kSeekDelay = base::Milliseconds(20);
|
||||
|
||||
} // namespace
|
||||
|
||||
@@ -42,7 +42,7 @@ index f697f85d7e3e9eeeab249a6d4e8ef8383c5c0d72..a5f35e7782c047b147458e569924de0f
|
||||
class MultiBufferDataSource::ReadOperation {
|
||||
public:
|
||||
ReadOperation() = delete;
|
||||
@@ -136,13 +142,29 @@ MultiBufferDataSource::~MultiBufferDataSource() {
|
||||
@@ -137,13 +143,29 @@ MultiBufferDataSource::~MultiBufferDataSource() {
|
||||
DCHECK(render_task_runner_->BelongsToCurrentThread());
|
||||
}
|
||||
|
||||
@@ -74,18 +74,18 @@ index f697f85d7e3e9eeeab249a6d4e8ef8383c5c0d72..a5f35e7782c047b147458e569924de0f
|
||||
|
||||
void MultiBufferDataSource::SetReader(
|
||||
diff --git a/third_party/blink/renderer/platform/media/multi_buffer_data_source.h b/third_party/blink/renderer/platform/media/multi_buffer_data_source.h
|
||||
index 5100bd21163f9ceadb728ed5306dcf8320e528a8..c2ee03ca6a75a2fef1ce778e663a74bda608acb4 100644
|
||||
index 470b6015dad4063375175324f49afb3548cdf0dd..61b633d65eaa76f98fd0d858d490b12077646ad2 100644
|
||||
--- a/third_party/blink/renderer/platform/media/multi_buffer_data_source.h
|
||||
+++ b/third_party/blink/renderer/platform/media/multi_buffer_data_source.h
|
||||
@@ -18,6 +18,7 @@
|
||||
@@ -19,6 +19,7 @@
|
||||
#include "media/base/data_source.h"
|
||||
#include "media/base/ranges.h"
|
||||
#include "media/base/tuneable.h"
|
||||
+#include "third_party/blink/public/platform/web_common.h"
|
||||
#include "third_party/blink/renderer/platform/media/buffered_data_source_host_impl.h"
|
||||
#include "third_party/blink/renderer/platform/media/url_index.h"
|
||||
#include "third_party/blink/renderer/platform/platform_export.h"
|
||||
#include "third_party/blink/renderer/platform/wtf/vector.h"
|
||||
@@ -35,6 +36,8 @@ namespace blink {
|
||||
@@ -37,6 +38,8 @@ namespace blink {
|
||||
class BufferedDataSourceHost;
|
||||
class MultiBufferReader;
|
||||
|
||||
@@ -94,7 +94,7 @@ index 5100bd21163f9ceadb728ed5306dcf8320e528a8..c2ee03ca6a75a2fef1ce778e663a74bd
|
||||
// A data source capable of loading URLs and buffering the data using an
|
||||
// in-memory sliding window.
|
||||
//
|
||||
@@ -64,6 +67,8 @@ class PLATFORM_EXPORT MultiBufferDataSource
|
||||
@@ -94,6 +97,8 @@ class PLATFORM_EXPORT MultiBufferDataSource
|
||||
return url_data_->mime_type();
|
||||
}
|
||||
|
||||
|
||||
@@ -6,10 +6,10 @@ Subject: feat: add support for embedder snapshot validation
|
||||
IsValid is not exposed despite being commented as for embedders, this exposes something that works for us.
|
||||
|
||||
diff --git a/gin/v8_initializer.cc b/gin/v8_initializer.cc
|
||||
index aef4af8ce2a3352535a1ea2f4777e839c4811817..d5d861292c399a18ec0af66e2d726619c939875e 100644
|
||||
index 58b708b0f7716f0d12ad1135ba65125cab1303a4..eefaec3dac8de00ec89f4310cbc3fc91e84b3961 100644
|
||||
--- a/gin/v8_initializer.cc
|
||||
+++ b/gin/v8_initializer.cc
|
||||
@@ -76,11 +76,23 @@ bool GenerateEntropy(unsigned char* buffer, size_t amount) {
|
||||
@@ -75,11 +75,23 @@ bool GenerateEntropy(unsigned char* buffer, size_t amount) {
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -33,7 +33,7 @@ index aef4af8ce2a3352535a1ea2f4777e839c4811817..d5d861292c399a18ec0af66e2d726619
|
||||
} else {
|
||||
data->data = nullptr;
|
||||
data->raw_size = 0;
|
||||
@@ -226,6 +238,10 @@ constexpr std::string_view kV8FlagParam = "V8FlagParam";
|
||||
@@ -225,6 +237,10 @@ constexpr std::string_view kV8FlagParam = "V8FlagParam";
|
||||
|
||||
} // namespace
|
||||
|
||||
|
||||
@@ -16,10 +16,10 @@ It also:
|
||||
This may be partially upstreamed to Chromium in the future.
|
||||
|
||||
diff --git a/ui/gtk/select_file_dialog_linux_gtk.cc b/ui/gtk/select_file_dialog_linux_gtk.cc
|
||||
index 3894f32763f6de0dd8523ccb75516b6d7ef2d788..6674bd0e8aeabf1d2c356239ce874181b230f085 100644
|
||||
index adf2a5491699639d4547015278c69e96e911d602..9eaec5331bde260824ffa73cf044783fef274233 100644
|
||||
--- a/ui/gtk/select_file_dialog_linux_gtk.cc
|
||||
+++ b/ui/gtk/select_file_dialog_linux_gtk.cc
|
||||
@@ -271,8 +271,12 @@ void SelectFileDialogLinuxGtk::SelectFileImpl(
|
||||
@@ -272,8 +272,12 @@ void SelectFileDialogLinuxGtk::SelectFileImpl(
|
||||
case SELECT_EXISTING_FOLDER:
|
||||
dialog = CreateSelectFolderDialog(type, title_string, default_path,
|
||||
owning_window);
|
||||
@@ -34,7 +34,7 @@ index 3894f32763f6de0dd8523ccb75516b6d7ef2d788..6674bd0e8aeabf1d2c356239ce874181
|
||||
break;
|
||||
case SELECT_OPEN_FILE:
|
||||
dialog = CreateFileOpenDialog(title_string, default_path, owning_window);
|
||||
@@ -419,9 +423,11 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateFileOpenHelper(
|
||||
@@ -420,9 +424,11 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateFileOpenHelper(
|
||||
const std::string& title,
|
||||
const base::FilePath& default_path,
|
||||
gfx::NativeWindow parent) {
|
||||
@@ -47,7 +47,7 @@ index 3894f32763f6de0dd8523ccb75516b6d7ef2d788..6674bd0e8aeabf1d2c356239ce874181
|
||||
SetGtkTransientForAura(dialog, parent, platform_);
|
||||
AddFilters(GTK_FILE_CHOOSER(dialog));
|
||||
|
||||
@@ -437,6 +443,7 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateFileOpenHelper(
|
||||
@@ -438,6 +444,7 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateFileOpenHelper(
|
||||
GtkFileChooserSetCurrentFolder(GTK_FILE_CHOOSER(dialog),
|
||||
*last_opened_path());
|
||||
}
|
||||
@@ -55,7 +55,7 @@ index 3894f32763f6de0dd8523ccb75516b6d7ef2d788..6674bd0e8aeabf1d2c356239ce874181
|
||||
return dialog;
|
||||
}
|
||||
|
||||
@@ -452,11 +459,15 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateSelectFolderDialog(
|
||||
@@ -453,11 +460,15 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateSelectFolderDialog(
|
||||
? l10n_util::GetStringUTF8(IDS_SELECT_UPLOAD_FOLDER_DIALOG_TITLE)
|
||||
: l10n_util::GetStringUTF8(IDS_SELECT_FOLDER_DIALOG_TITLE);
|
||||
}
|
||||
@@ -76,7 +76,7 @@ index 3894f32763f6de0dd8523ccb75516b6d7ef2d788..6674bd0e8aeabf1d2c356239ce874181
|
||||
|
||||
GtkWidget* dialog = GtkFileChooserDialogNew(
|
||||
title_string.c_str(), nullptr, GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER,
|
||||
@@ -478,7 +489,8 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateSelectFolderDialog(
|
||||
@@ -479,7 +490,8 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateSelectFolderDialog(
|
||||
gtk_file_filter_add_mime_type(only_folders, "inode/directory");
|
||||
gtk_file_filter_add_mime_type(only_folders, "text/directory");
|
||||
gtk_file_chooser_add_filter(chooser, only_folders);
|
||||
@@ -86,7 +86,7 @@ index 3894f32763f6de0dd8523ccb75516b6d7ef2d788..6674bd0e8aeabf1d2c356239ce874181
|
||||
return dialog;
|
||||
}
|
||||
|
||||
@@ -515,10 +527,11 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateSaveAsDialog(
|
||||
@@ -516,10 +528,11 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateSaveAsDialog(
|
||||
std::string title_string =
|
||||
!title.empty() ? title
|
||||
: l10n_util::GetStringUTF8(IDS_SAVE_AS_DIALOG_TITLE);
|
||||
@@ -100,7 +100,7 @@ index 3894f32763f6de0dd8523ccb75516b6d7ef2d788..6674bd0e8aeabf1d2c356239ce874181
|
||||
kResponseTypeAccept);
|
||||
SetGtkTransientForAura(dialog, parent, platform_);
|
||||
|
||||
@@ -544,9 +557,10 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateSaveAsDialog(
|
||||
@@ -545,9 +558,10 @@ GtkWidget* SelectFileDialogLinuxGtk::CreateSaveAsDialog(
|
||||
gtk_file_chooser_set_select_multiple(GTK_FILE_CHOOSER(dialog), FALSE);
|
||||
// Overwrite confirmation is always enabled in GTK4.
|
||||
if (!GtkCheckVersion(4)) {
|
||||
@@ -113,7 +113,7 @@ index 3894f32763f6de0dd8523ccb75516b6d7ef2d788..6674bd0e8aeabf1d2c356239ce874181
|
||||
return dialog;
|
||||
}
|
||||
|
||||
@@ -602,15 +616,29 @@ void SelectFileDialogLinuxGtk::OnSelectSingleFolderDialogResponse(
|
||||
@@ -603,15 +617,29 @@ void SelectFileDialogLinuxGtk::OnSelectSingleFolderDialogResponse(
|
||||
void SelectFileDialogLinuxGtk::OnSelectMultiFileDialogResponse(
|
||||
GtkWidget* dialog,
|
||||
int response_id) {
|
||||
|
||||
@@ -262,7 +262,7 @@ index 68a3095a49caf472c83b93b5cef66e5549a2d7cc..aa371ba5576f9fbaf5558e39704f7eb8
|
||||
+
|
||||
} // namespace content
|
||||
diff --git a/content/browser/renderer_host/code_cache_host_impl.cc b/content/browser/renderer_host/code_cache_host_impl.cc
|
||||
index 2b75860754f8192141f61aa78c2ab5008eb795f1..d94d681e42948324a4eb179977a56862b7119d70 100644
|
||||
index a3c5e2ccc611dbab868099b377b05d28422055fe..eb0412e5ebf43b7ce7558d629cb27db967bb86ec 100644
|
||||
--- a/content/browser/renderer_host/code_cache_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/code_cache_host_impl.cc
|
||||
@@ -4,6 +4,7 @@
|
||||
@@ -270,10 +270,10 @@ index 2b75860754f8192141f61aa78c2ab5008eb795f1..d94d681e42948324a4eb179977a56862
|
||||
#include "content/browser/renderer_host/code_cache_host_impl.h"
|
||||
|
||||
+#include <algorithm>
|
||||
#include <stdint.h>
|
||||
|
||||
#include <optional>
|
||||
#include <string_view>
|
||||
#include <utility>
|
||||
@@ -42,6 +43,7 @@
|
||||
@@ -51,6 +52,7 @@
|
||||
#include "third_party/perfetto/include/perfetto/tracing/track_event_args.h"
|
||||
#include "url/gurl.h"
|
||||
#include "url/origin.h"
|
||||
@@ -281,7 +281,7 @@ index 2b75860754f8192141f61aa78c2ab5008eb795f1..d94d681e42948324a4eb179977a56862
|
||||
|
||||
using blink::mojom::CacheStorageError;
|
||||
|
||||
@@ -56,6 +58,10 @@ enum class Operation {
|
||||
@@ -65,6 +67,10 @@ enum class Operation {
|
||||
kWrite,
|
||||
};
|
||||
|
||||
@@ -289,10 +289,10 @@ index 2b75860754f8192141f61aa78c2ab5008eb795f1..d94d681e42948324a4eb179977a56862
|
||||
+ return std::ranges::contains(url::GetCodeCacheSchemes(), process_lock.GetProcessLockURL().scheme());
|
||||
+}
|
||||
+
|
||||
// TODO(crbug.com/492899973): Refactor to use `RenderFrameHost*`.
|
||||
bool CheckSecurityForAccessingCodeCacheData(const GURL& resource_url,
|
||||
ChildProcessId render_process_id,
|
||||
Operation operation) {
|
||||
@@ -67,42 +73,56 @@ bool CheckSecurityForAccessingCodeCacheData(const GURL& resource_url,
|
||||
@@ -77,42 +83,56 @@ bool CheckSecurityForAccessingCodeCacheData(const GURL& resource_url,
|
||||
ChildProcessSecurityPolicyImpl::GetInstance()->GetProcessLock(
|
||||
render_process_id);
|
||||
|
||||
@@ -372,7 +372,7 @@ index 2b75860754f8192141f61aa78c2ab5008eb795f1..d94d681e42948324a4eb179977a56862
|
||||
}
|
||||
|
||||
if (operation == Operation::kWrite) {
|
||||
@@ -190,6 +210,7 @@ std::optional<GURL> GetOriginLock(ChildProcessId render_process_id) {
|
||||
@@ -200,6 +220,7 @@ std::optional<GURL> GetOriginLock(ChildProcessId render_process_id) {
|
||||
process_lock.MatchesScheme(url::kHttpsScheme) ||
|
||||
process_lock.MatchesScheme(content::kChromeUIScheme) ||
|
||||
process_lock.MatchesScheme(content::kChromeUIUntrustedScheme) ||
|
||||
|
||||
@@ -44,10 +44,10 @@ index 57ed3cf54b2921df09ad84906b3da7527c6080bb..ffe3a0894c612adaa429a783827c8503
|
||||
class WebRequestEventRouter : public KeyedService {
|
||||
public:
|
||||
diff --git a/extensions/common/extension.cc b/extensions/common/extension.cc
|
||||
index 731994059b8900e7cec46acfb9d17f18c3b8ed89..c32aee04fa1788ae26a0f9a0c5b9d2afb94c84c6 100644
|
||||
index 542bc99fbaace39351a6f991a7702d0c77c891eb..9fef3d7fe3108cca843100967489f1cc1b6b4589 100644
|
||||
--- a/extensions/common/extension.cc
|
||||
+++ b/extensions/common/extension.cc
|
||||
@@ -222,7 +222,8 @@ const int Extension::kValidHostPermissionSchemes =
|
||||
@@ -223,7 +223,8 @@ const int Extension::kValidHostPermissionSchemes =
|
||||
URLPattern::SCHEME_CHROMEUI | URLPattern::SCHEME_HTTP |
|
||||
URLPattern::SCHEME_HTTPS | URLPattern::SCHEME_FILE |
|
||||
URLPattern::SCHEME_FTP | URLPattern::SCHEME_WS | URLPattern::SCHEME_WSS |
|
||||
|
||||
@@ -46,7 +46,7 @@ index e2771b7b281274cdcb601a5bc78a948ad592087b..48d116823a28213e50775f378e6ce04c
|
||||
// OnStop is called by StopAndDeAllocate.
|
||||
virtual void OnStop() = 0;
|
||||
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 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96da84524da 100644
|
||||
index 64ffc2642c003c8fb7f133ee43ba3e20d48ea543..92846d1b45c04c324014474ec6c02e71fe939fa7 100644
|
||||
--- a/content/browser/media/capture/screen_capture_kit_device_mac.mm
|
||||
+++ b/content/browser/media/capture/screen_capture_kit_device_mac.mm
|
||||
@@ -31,6 +31,61 @@
|
||||
@@ -134,21 +134,24 @@ index 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96d
|
||||
_errorCallback = errorCallback;
|
||||
}
|
||||
return self;
|
||||
@@ -264,12 +323,11 @@ class API_AVAILABLE(macos(12.3)) ScreenCaptureKitDeviceMac
|
||||
@@ -264,14 +323,12 @@ class API_AVAILABLE(macos(12.3)) ScreenCaptureKitDeviceMac
|
||||
|
||||
explicit ScreenCaptureKitDeviceMac(
|
||||
const DesktopMediaID& source,
|
||||
- bool is_native_picker,
|
||||
- SCContentFilter* filter,
|
||||
+ [[maybe_unused]] bool is_native_picker,
|
||||
+ [[maybe_unused]] SCContentFilter* filter,
|
||||
StreamCallback stream_created_callback,
|
||||
std::unique_ptr<content::PipScreenCaptureCoordinatorProxy>
|
||||
pip_screen_capture_coordinator_proxy)
|
||||
: source_(source),
|
||||
- is_native_picker_session_(is_native_picker),
|
||||
- filter_(filter),
|
||||
stream_created_callback_(std::move(stream_created_callback)),
|
||||
device_task_runner_(base::SingleThreadTaskRunner::GetCurrentDefault()),
|
||||
pip_screen_capture_coordinator_proxy_(
|
||||
@@ -278,21 +336,43 @@ explicit ScreenCaptureKitDeviceMac(
|
||||
@@ -280,21 +337,43 @@ explicit ScreenCaptureKitDeviceMac(
|
||||
device_task_runner_,
|
||||
base::BindRepeating(&ScreenCaptureKitDeviceMac::OnStreamSample,
|
||||
weak_factory_.GetWeakPtr()));
|
||||
@@ -192,7 +195,7 @@ index 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96d
|
||||
DCHECK(device_task_runner_->RunsTasksInCurrentSequence());
|
||||
if (pip_screen_capture_coordinator_proxy_) {
|
||||
pip_screen_capture_coordinator_proxy_->RemoveObserver(this);
|
||||
@@ -383,7 +463,7 @@ void CreateStream(SCContentFilter* filter) {
|
||||
@@ -385,7 +464,7 @@ void CreateStream(SCContentFilter* filter) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -201,7 +204,7 @@ index 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96d
|
||||
// Update the content size. This step is neccessary when used together
|
||||
// with SCContentSharingPicker. If the Chrome picker is used, it will
|
||||
// change to retina resolution if applicable.
|
||||
@@ -392,6 +472,9 @@ void CreateStream(SCContentFilter* filter) {
|
||||
@@ -394,6 +473,9 @@ void CreateStream(SCContentFilter* filter) {
|
||||
filter.contentRect.size.height * filter.pointPixelScale);
|
||||
}
|
||||
|
||||
@@ -211,7 +214,7 @@ index 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96d
|
||||
gfx::RectF dest_rect_in_frame;
|
||||
actual_capture_format_ = capture_params().requested_format;
|
||||
actual_capture_format_.pixel_format = media::PIXEL_FORMAT_NV12;
|
||||
@@ -405,6 +488,7 @@ void CreateStream(SCContentFilter* filter) {
|
||||
@@ -407,6 +489,7 @@ void CreateStream(SCContentFilter* filter) {
|
||||
stream_ = [[SCStream alloc] initWithFilter:filter
|
||||
configuration:config
|
||||
delegate:helper_];
|
||||
@@ -219,7 +222,7 @@ index 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96d
|
||||
{
|
||||
NSError* error = nil;
|
||||
bool add_stream_output_result =
|
||||
@@ -564,7 +648,7 @@ void OnStreamError(NSError* _Nullable error) {
|
||||
@@ -566,7 +649,7 @@ void OnStreamError(NSError* _Nullable error) {
|
||||
if (fullscreen_module_) {
|
||||
fullscreen_module_->Reset();
|
||||
}
|
||||
@@ -228,7 +231,7 @@ index 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96d
|
||||
} else {
|
||||
std::string error_string =
|
||||
base::StrCat({"Stream delegate called didStopWithError: ",
|
||||
@@ -654,23 +738,41 @@ void OnStateChanged(
|
||||
@@ -656,32 +739,41 @@ void OnStateChanged(
|
||||
}
|
||||
|
||||
// IOSurfaceCaptureDeviceBase:
|
||||
@@ -239,16 +242,12 @@ index 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96d
|
||||
- // SCContentSharingPicker is used where filter_ is set on creation.
|
||||
- CreateStream(filter_);
|
||||
- } else {
|
||||
- // Chrome picker is used.
|
||||
- auto content_callback = base::BindPostTask(
|
||||
- device_task_runner_,
|
||||
- base::BindRepeating(
|
||||
- &ScreenCaptureKitDeviceMac::OnShareableContentCreated,
|
||||
- weak_factory_.GetWeakPtr()));
|
||||
- auto handler = ^(SCShareableContent* content, NSError* error) {
|
||||
- content_callback.Run(content);
|
||||
- };
|
||||
- [SCShareableContent getShareableContentWithCompletionHandler:handler];
|
||||
- if (is_native_picker_session_) {
|
||||
- client()->OnError(
|
||||
- media::VideoCaptureError::kScreenCaptureKitFailedStartCapture,
|
||||
- FROM_HERE,
|
||||
- "Native picker session failed to start due to missing authorized "
|
||||
- "filter");
|
||||
+
|
||||
+ if (@available(macOS 15.0, *)) {
|
||||
+ constexpr bool DefaultUseNativePicker = true;
|
||||
@@ -269,8 +268,19 @@ index 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96d
|
||||
+ }];
|
||||
+ picker.defaultConfiguration.excludedWindowIDs = exclude_ns_windows;
|
||||
+ [picker present];
|
||||
+ return;
|
||||
+ }
|
||||
return;
|
||||
}
|
||||
- // Fall back to user-selected window/screen discovery for
|
||||
- // non-native-picker sessions.
|
||||
- auto content_callback = base::BindPostTask(
|
||||
- device_task_runner_,
|
||||
- base::BindRepeating(
|
||||
- &ScreenCaptureKitDeviceMac::OnShareableContentCreated,
|
||||
- weak_factory_.GetWeakPtr()));
|
||||
- auto handler = ^(SCShareableContent* content, NSError* error) {
|
||||
- content_callback.Run(content);
|
||||
- };
|
||||
- [SCShareableContent getShareableContentWithCompletionHandler:handler];
|
||||
}
|
||||
+
|
||||
+ auto content_callback = base::BindPostTask(
|
||||
@@ -285,16 +295,17 @@ index 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96d
|
||||
}
|
||||
void OnStop() override {
|
||||
DCHECK(device_task_runner_->RunsTasksInCurrentSequence());
|
||||
@@ -729,7 +831,7 @@ void ResetStreamTo(SCWindow* window) override {
|
||||
@@ -740,8 +832,7 @@ void ResetStreamTo(SCWindow* window) override {
|
||||
|
||||
private:
|
||||
const DesktopMediaID source_;
|
||||
- const bool is_native_picker_session_;
|
||||
- SCContentFilter* const filter_;
|
||||
+ static int active_streams_;
|
||||
StreamCallback stream_created_callback_;
|
||||
const scoped_refptr<base::SingleThreadTaskRunner> device_task_runner_;
|
||||
|
||||
@@ -746,6 +848,10 @@ void ResetStreamTo(SCWindow* window) override {
|
||||
@@ -758,6 +849,10 @@ void ResetStreamTo(SCWindow* window) override {
|
||||
// Helper class that acts as output and delegate for `stream_`.
|
||||
ScreenCaptureKitDeviceHelper* __strong helper_;
|
||||
|
||||
@@ -305,7 +316,7 @@ index 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96d
|
||||
// This is used to detect when a captured presentation enters fullscreen mode.
|
||||
// If this happens, the module will call the ResetStreamTo function.
|
||||
std::unique_ptr<ScreenCaptureKitFullscreenModule> fullscreen_module_;
|
||||
@@ -760,6 +866,8 @@ void ResetStreamTo(SCWindow* window) override {
|
||||
@@ -772,6 +867,8 @@ void ResetStreamTo(SCWindow* window) override {
|
||||
base::WeakPtrFactory<ScreenCaptureKitDeviceMac> weak_factory_{this};
|
||||
};
|
||||
|
||||
@@ -315,10 +326,10 @@ index 7a6d2d086fa02fbb0dd97d89967a196a4ebb739e..aca6125a965328163c2012514157c96d
|
||||
|
||||
// Although ScreenCaptureKit is available in 12.3 there were some bugs that
|
||||
diff --git a/content/browser/renderer_host/media/in_process_video_capture_device_launcher.cc b/content/browser/renderer_host/media/in_process_video_capture_device_launcher.cc
|
||||
index 61f32838233a7ce75dc24a9011a5fe6b3ab44507..9e3755d0eb3a039ed99d15a9f205d6d483f89253 100644
|
||||
index 0f6531fd1c7784867b2b4e6d72d042bee4bff579..1c7b00d6b1929b807649d7a00f963195bf3f4ea1 100644
|
||||
--- a/content/browser/renderer_host/media/in_process_video_capture_device_launcher.cc
|
||||
+++ b/content/browser/renderer_host/media/in_process_video_capture_device_launcher.cc
|
||||
@@ -320,8 +320,16 @@ void InProcessVideoCaptureDeviceLauncher::LaunchDeviceAsync(
|
||||
@@ -321,8 +321,16 @@ void InProcessVideoCaptureDeviceLauncher::LaunchDeviceAsync(
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -336,7 +347,7 @@ index 61f32838233a7ce75dc24a9011a5fe6b3ab44507..9e3755d0eb3a039ed99d15a9f205d6d4
|
||||
// For the other capturers, when a bug reports the type of capture it's
|
||||
// easy enough to determine which capturer was used, but it's a little
|
||||
// fuzzier with window capture.
|
||||
@@ -337,13 +345,15 @@ void InProcessVideoCaptureDeviceLauncher::LaunchDeviceAsync(
|
||||
@@ -338,13 +346,15 @@ void InProcessVideoCaptureDeviceLauncher::LaunchDeviceAsync(
|
||||
}
|
||||
#endif // defined(USE_AURA) || BUILDFLAG(IS_MAC)
|
||||
|
||||
|
||||
@@ -167,7 +167,7 @@ index 34b4e7c1b449312e9cb517be192a39a6b5286e3c..4f39415717f423b9a87f83779851e08b
|
||||
FinishStartSandboxedProcessOnLauncherThread,
|
||||
this));
|
||||
diff --git a/content/browser/service_host/service_process_host_impl.cc b/content/browser/service_host/service_process_host_impl.cc
|
||||
index d9c14f91747bde0e76056d7f2f2ada166e67f994..09335acac17f526fb8d8e42e4b2d993b11045786 100644
|
||||
index 4c0b23afb38066f4d29ead2d5705ae2b58ddca34..b79eb508bdfc1ae08dce254cfa57ab6c9b7bfc8a 100644
|
||||
--- a/content/browser/service_host/service_process_host_impl.cc
|
||||
+++ b/content/browser/service_host/service_process_host_impl.cc
|
||||
@@ -69,6 +69,21 @@ void LaunchServiceProcess(mojo::GenericPendingReceiver receiver,
|
||||
@@ -584,10 +584,10 @@ index 4159eef9e1f54c82ac0d8ad6437925dd3c6fa3ec..b835257f686635b91f80c2d6651fb735
|
||||
#if BUILDFLAG(IS_MAC)
|
||||
// Whether or not to disclaim TCC responsibility for the process, defaults to
|
||||
diff --git a/content/public/browser/service_process_host.cc b/content/public/browser/service_process_host.cc
|
||||
index d1bc550a891979e2d41d8d5b18a2f9287468e460..5d255f628788bc8b40d8df0039b08c06ffec8730 100644
|
||||
index a3970c9358d7e03b58e646c85a488d97609c44fd..1afc67fab97a3bb9515afefb8a3f051147d1d678 100644
|
||||
--- a/content/public/browser/service_process_host.cc
|
||||
+++ b/content/public/browser/service_process_host.cc
|
||||
@@ -53,12 +53,62 @@ ServiceProcessHost::Options::WithExtraCommandLineSwitches(
|
||||
@@ -53,6 +53,26 @@ ServiceProcessHost::Options::WithExtraCommandLineSwitches(
|
||||
return *this;
|
||||
}
|
||||
|
||||
@@ -614,6 +614,7 @@ index d1bc550a891979e2d41d8d5b18a2f9287468e460..5d255f628788bc8b40d8df0039b08c06
|
||||
ServiceProcessHost::Options& ServiceProcessHost::Options::WithProcessCallback(
|
||||
base::OnceCallback<void(const base::Process&)> callback) {
|
||||
process_callback = std::move(callback);
|
||||
@@ -68,6 +88,36 @@ ServiceProcessHost::Options& ServiceProcessHost::Options::WithObserver(
|
||||
return *this;
|
||||
}
|
||||
|
||||
@@ -651,18 +652,18 @@ index d1bc550a891979e2d41d8d5b18a2f9287468e460..5d255f628788bc8b40d8df0039b08c06
|
||||
ServiceProcessHost::Options&
|
||||
ServiceProcessHost::Options::WithPreloadedLibraries(
|
||||
diff --git a/content/public/browser/service_process_host.h b/content/public/browser/service_process_host.h
|
||||
index 0062d2cb6634b8b29977a0312516b1b13936b40a..888ff36d70c83010f1f45e9eeb2dd6b573158db5 100644
|
||||
index ea68aa0d16c46ad53b63e10027e81503610051d9..ac1ffa290b59d964931a312a911efbecc5eb04ac 100644
|
||||
--- a/content/public/browser/service_process_host.h
|
||||
+++ b/content/public/browser/service_process_host.h
|
||||
@@ -14,6 +14,7 @@
|
||||
#include "base/command_line.h"
|
||||
@@ -15,6 +15,7 @@
|
||||
#include "base/functional/callback.h"
|
||||
#include "base/memory/weak_ptr.h"
|
||||
#include "base/observer_list_types.h"
|
||||
+#include "base/process/launch.h"
|
||||
#include "base/process/process_handle.h"
|
||||
#include "content/common/content_export.h"
|
||||
#include "content/public/browser/service_process_info.h"
|
||||
@@ -28,6 +29,10 @@
|
||||
@@ -29,6 +30,10 @@
|
||||
#include "base/types/pass_key.h"
|
||||
#endif // BUILDFLAG(IS_WIN)
|
||||
|
||||
@@ -673,7 +674,7 @@ index 0062d2cb6634b8b29977a0312516b1b13936b40a..888ff36d70c83010f1f45e9eeb2dd6b5
|
||||
namespace base {
|
||||
class Process;
|
||||
} // namespace base
|
||||
@@ -94,11 +99,40 @@ class CONTENT_EXPORT ServiceProcessHost {
|
||||
@@ -98,6 +103,16 @@ class CONTENT_EXPORT ServiceProcessHost {
|
||||
// Specifies extra command line switches to append before launch.
|
||||
Options& WithExtraCommandLineSwitches(std::vector<std::string> switches);
|
||||
|
||||
@@ -690,8 +691,10 @@ index 0062d2cb6634b8b29977a0312516b1b13936b40a..888ff36d70c83010f1f45e9eeb2dd6b5
|
||||
// Specifies a callback to be invoked with service process once it's
|
||||
// launched. Will be on UI thread.
|
||||
Options& WithProcessCallback(
|
||||
base::OnceCallback<void(const base::Process&)>);
|
||||
|
||||
@@ -111,6 +126,24 @@ class CONTENT_EXPORT ServiceProcessHost {
|
||||
// the service process terminates, notifications are silently skipped.
|
||||
// Will be called on the UI thread.
|
||||
Options& WithObserver(base::WeakPtr<Observer> observer);
|
||||
+ // Specifies the working directory for the launched process.
|
||||
+ Options& WithCurrentDirectory(const base::FilePath& cwd);
|
||||
+
|
||||
@@ -710,11 +713,10 @@ index 0062d2cb6634b8b29977a0312516b1b13936b40a..888ff36d70c83010f1f45e9eeb2dd6b5
|
||||
+ // Specifies if the process should disclaim TCC responsibility.
|
||||
+ Options& WithDisclaimResponsibility(bool disclaim_responsibility);
|
||||
+#endif // BUILDFLAG(IS_MAC)
|
||||
+
|
||||
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
// Specifies libraries to preload before the sandbox is locked down. Paths
|
||||
// should be absolute paths. Libraries will be preloaded before sandbox
|
||||
@@ -127,11 +161,26 @@ class CONTENT_EXPORT ServiceProcessHost {
|
||||
@@ -140,12 +173,27 @@ class CONTENT_EXPORT ServiceProcessHost {
|
||||
std::optional<GURL> site;
|
||||
std::optional<int> child_flags;
|
||||
std::vector<std::string> extra_switches;
|
||||
@@ -725,6 +727,7 @@ index 0062d2cb6634b8b29977a0312516b1b13936b40a..888ff36d70c83010f1f45e9eeb2dd6b5
|
||||
+ base::FileHandleMappingVector fds_to_remap;
|
||||
+#endif
|
||||
base::OnceCallback<void(const base::Process&)> process_callback;
|
||||
base::WeakPtr<Observer> observer;
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
std::vector<base::FilePath> preload_libraries;
|
||||
#endif // BUILDFLAG(IS_WIN)
|
||||
@@ -740,7 +743,7 @@ index 0062d2cb6634b8b29977a0312516b1b13936b40a..888ff36d70c83010f1f45e9eeb2dd6b5
|
||||
+#endif // BUILDFLAG(IS_MAC)
|
||||
};
|
||||
|
||||
// An interface which can be implemented and registered/unregistered with
|
||||
// An interface which can be implemented and used with
|
||||
diff --git a/sandbox/policy/win/sandbox_win.cc b/sandbox/policy/win/sandbox_win.cc
|
||||
index 5c92eec064e36fa4be5a57a769a4091a18e3396d..b705450708560c0ae8b386d7efdb5c526964c629 100644
|
||||
--- a/sandbox/policy/win/sandbox_win.cc
|
||||
|
||||
@@ -46,10 +46,10 @@ index 6e60de1319c5506d7180719fa230ab9cf537b832..e570e335fbd413340ddedeee423eca71
|
||||
'internal-forced-visited-'):
|
||||
internal_visited_order = 0
|
||||
diff --git a/third_party/blink/renderer/core/css/css_properties.json5 b/third_party/blink/renderer/core/css/css_properties.json5
|
||||
index e76332fdb029e2f69dca8d78d9e404ac9d2645e4..dd6d931bdae88f37cbaffa98be2c367aa22c2b61 100644
|
||||
index f46a4e31e0ea81f362be1c06bc23f6e6cb15d967..1a7874271e123d4fadd8ae694394061fc0c73cfe 100644
|
||||
--- a/third_party/blink/renderer/core/css/css_properties.json5
|
||||
+++ b/third_party/blink/renderer/core/css/css_properties.json5
|
||||
@@ -9640,6 +9640,27 @@
|
||||
@@ -9643,6 +9643,27 @@
|
||||
property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"],
|
||||
},
|
||||
|
||||
@@ -91,10 +91,10 @@ index 2afe18e9e4a5404ed184aeedc1c02a313853f463..7c3b0c2da6ded539764ce59bc43f49e9
|
||||
return a.EmptyCells() == b.EmptyCells();
|
||||
case CSSPropertyID::kFill:
|
||||
diff --git a/third_party/blink/renderer/core/css/properties/longhands/longhands_custom.cc b/third_party/blink/renderer/core/css/properties/longhands/longhands_custom.cc
|
||||
index ea8c1f5306615873d4ddfcf4f39596da463abef9..b4ca263ba8775ca497ff32a3cf2b1183b3112e9f 100644
|
||||
index 65c9b1f3a73d3822371f09b0cb764c63aaeb8a31..6e3737cf147252c6999ddcb887309682a91787d6 100644
|
||||
--- a/third_party/blink/renderer/core/css/properties/longhands/longhands_custom.cc
|
||||
+++ b/third_party/blink/renderer/core/css/properties/longhands/longhands_custom.cc
|
||||
@@ -13311,5 +13311,36 @@ const CSSValue* InternalEmptyLineHeight::ParseSingleValue(
|
||||
@@ -13328,5 +13328,36 @@ const CSSValue* InternalEmptyLineHeight::ParseSingleValue(
|
||||
CSSValueID::kNone>(stream);
|
||||
}
|
||||
|
||||
@@ -203,10 +203,10 @@ index 19cda703154dab9397827ab6ea66c2ca446c644d..dd5943c511886f4e39b2e7f10e67e60f
|
||||
return result;
|
||||
}
|
||||
diff --git a/third_party/blink/renderer/platform/BUILD.gn b/third_party/blink/renderer/platform/BUILD.gn
|
||||
index 1dabdf691606af0057ea12180b2033f958d7d526..356679c4750a8a7d3ed1efb57ca78bdaa6d5380a 100644
|
||||
index 87f64f5c2cfd4bdc8aca697f6115effed091b86e..a11c5cb976077e53a6c3d456d2583f16fb58e415 100644
|
||||
--- a/third_party/blink/renderer/platform/BUILD.gn
|
||||
+++ b/third_party/blink/renderer/platform/BUILD.gn
|
||||
@@ -1674,6 +1674,8 @@ component("platform") {
|
||||
@@ -1675,6 +1675,8 @@ component("platform") {
|
||||
"widget/widget_base.h",
|
||||
"widget/widget_base_client.h",
|
||||
"windows_keyboard_codes.h",
|
||||
@@ -314,7 +314,7 @@ index 18f283e625101318ee14b50e6e765dfd1c9a1a44..44a3a55974c9e4b9e715574075f25661
|
||||
|
||||
auto DrawAsSinglePath = [&]() {
|
||||
diff --git a/third_party/blink/renderer/platform/runtime_enabled_features.json5 b/third_party/blink/renderer/platform/runtime_enabled_features.json5
|
||||
index ad362e769ff503cd3a7213e5ab6c7ecdbaa284b6..06f787da512e66fef5d9d3eaed7a67cf87f384b6 100644
|
||||
index 89301f737c6a1f4043a47366db604967159b7cb6..0f6417f6933f3f71f39b4a06ac229efd3ac7634b 100644
|
||||
--- a/third_party/blink/renderer/platform/runtime_enabled_features.json5
|
||||
+++ b/third_party/blink/renderer/platform/runtime_enabled_features.json5
|
||||
@@ -215,6 +215,10 @@
|
||||
|
||||
@@ -8,10 +8,10 @@ rendering with the viz compositor by way of a custom HostDisplayClient
|
||||
and LayeredWindowUpdater.
|
||||
|
||||
diff --git a/components/viz/host/host_display_client.cc b/components/viz/host/host_display_client.cc
|
||||
index b153c538488b7b77af0630a454604d9fb7eba487..1b97bfae745d3aeaa4ebd3d3a0dfc64f48da0d70 100644
|
||||
index 65df78d7f2a311633e8512f46efa005c41930873..1978ac9a080c63f8e9aa323c7215051890c55f00 100644
|
||||
--- a/components/viz/host/host_display_client.cc
|
||||
+++ b/components/viz/host/host_display_client.cc
|
||||
@@ -49,9 +49,9 @@ void HostDisplayClient::OnDisplayReceivedCALayerParams(
|
||||
@@ -50,9 +50,9 @@ void HostDisplayClient::OnDisplayReceivedCALayerParams(
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -22,7 +22,7 @@ index b153c538488b7b77af0630a454604d9fb7eba487..1b97bfae745d3aeaa4ebd3d3a0dfc64f
|
||||
if (!NeedsToUseLayerWindow(widget_)) {
|
||||
DLOG(ERROR) << "HWND shouldn't be using a layered window";
|
||||
return;
|
||||
@@ -59,7 +59,15 @@ void HostDisplayClient::CreateLayeredWindowUpdater(
|
||||
@@ -60,7 +60,15 @@ void HostDisplayClient::CreateLayeredWindowUpdater(
|
||||
|
||||
layered_window_updater_ =
|
||||
std::make_unique<LayeredWindowUpdaterImpl>(widget_, std::move(receiver));
|
||||
@@ -90,7 +90,7 @@ index 8af69cac78b7488d28f1f05ccb174793fe5148cd..9f74e511c263d147b5fbe81fe100d217
|
||||
private:
|
||||
const HWND hwnd_;
|
||||
diff --git a/components/viz/service/BUILD.gn b/components/viz/service/BUILD.gn
|
||||
index 2aa6ad756b0a146f35516930d4452358d0f8dd07..2e2d9ac683a72de4b0e6f6f95c4ccd99319109f8 100644
|
||||
index 3f9d9afc88b7622c28ba2167c305e2a54affb8d3..2c281a88630706c28ccf71e74851fcbae91ccdcb 100644
|
||||
--- a/components/viz/service/BUILD.gn
|
||||
+++ b/components/viz/service/BUILD.gn
|
||||
@@ -176,6 +176,8 @@ viz_component("service") {
|
||||
@@ -508,10 +508,10 @@ index 0000000000000000000000000000000000000000..e1a22ee881c0fd679ac2d2d4d11a3c93
|
||||
+
|
||||
+#endif // COMPONENTS_VIZ_SERVICE_DISPLAY_EMBEDDER_SOFTWARE_OUTPUT_DEVICE_PROXY_H_
|
||||
diff --git a/components/viz/service/display_embedder/software_output_device_win.cc b/components/viz/service/display_embedder/software_output_device_win.cc
|
||||
index b5154321105f08335b67ad2d552afa61337a4976..cb28230d9a8da6bd2259ef0c898013293421ac56 100644
|
||||
index 4f9e8946fa02d859e92a6896beba82721914f868..78486eaa993ee7ffd5188b31503de7dda1158297 100644
|
||||
--- a/components/viz/service/display_embedder/software_output_device_win.cc
|
||||
+++ b/components/viz/service/display_embedder/software_output_device_win.cc
|
||||
@@ -156,7 +156,7 @@ void SoftwareOutputDeviceWinProxy::EndPaintDelegated(
|
||||
@@ -158,7 +158,7 @@ void SoftwareOutputDeviceWinProxy::EndPaintDelegated(
|
||||
if (!canvas_)
|
||||
return;
|
||||
|
||||
|
||||
@@ -11,10 +11,10 @@ ServiceProcessHost::Observer functions, but we need to pass the exit code to
|
||||
the observer.
|
||||
|
||||
diff --git a/content/browser/service_host/service_process_tracker.cc b/content/browser/service_host/service_process_tracker.cc
|
||||
index fb41c8dfd147a90d7d581b49ad7f909d947cb214..ae0dce9d1dde14f1562adac7d324635983bb4c09 100644
|
||||
index c7b620b9dd25c7842470c4827bd55c81c5816e05..a5f72f8bd55e7a2a43e792f91878de52f09fb988 100644
|
||||
--- a/content/browser/service_host/service_process_tracker.cc
|
||||
+++ b/content/browser/service_host/service_process_tracker.cc
|
||||
@@ -51,7 +51,8 @@ void ServiceProcessTracker::NotifyTerminated(ServiceProcessId id) {
|
||||
@@ -67,7 +67,8 @@ void ServiceProcessTracker::NotifyTerminated(ServiceProcessId id) {
|
||||
|
||||
void ServiceProcessTracker::NotifyCrashed(
|
||||
ServiceProcessId id,
|
||||
@@ -24,22 +24,19 @@ index fb41c8dfd147a90d7d581b49ad7f909d947cb214..ae0dce9d1dde14f1562adac7d3246359
|
||||
DCHECK_CURRENTLY_ON(BrowserThread::UI);
|
||||
auto iter = processes_.find(id);
|
||||
CHECK(iter != processes_.end());
|
||||
@@ -65,7 +66,9 @@ void ServiceProcessTracker::NotifyCrashed(
|
||||
break;
|
||||
@@ -82,6 +83,7 @@ void ServiceProcessTracker::NotifyCrashed(
|
||||
}
|
||||
for (auto& observer : observers_) {
|
||||
- observer.OnServiceProcessCrashed(iter->second.Duplicate());
|
||||
+ auto params = iter->second.Duplicate();
|
||||
+ params.set_exit_code(exit_code);
|
||||
+ observer.OnServiceProcessCrashed(params);
|
||||
|
||||
auto info_dup = iter->second.Duplicate();
|
||||
+ info_dup.set_exit_code(exit_code);
|
||||
for (auto& obs : observers_) {
|
||||
obs.OnServiceProcessCrashed(info_dup);
|
||||
}
|
||||
processes_.erase(iter);
|
||||
}
|
||||
diff --git a/content/browser/service_host/service_process_tracker.h b/content/browser/service_host/service_process_tracker.h
|
||||
index 9a5179c4eeacf8bbfb2d831b4301836df490f3a8..511fc9b9d5ce14a1b5ef457a1047e40d3bb64273 100644
|
||||
index 899fa2680af1c3c491b110cdd2154abe2695bebe..bfd3a4837f361b106e46849e8be2675066387448 100644
|
||||
--- a/content/browser/service_host/service_process_tracker.h
|
||||
+++ b/content/browser/service_host/service_process_tracker.h
|
||||
@@ -36,7 +36,8 @@ class ServiceProcessTracker {
|
||||
@@ -40,7 +40,8 @@ class ServiceProcessTracker {
|
||||
void NotifyTerminated(ServiceProcessId id);
|
||||
|
||||
void NotifyCrashed(ServiceProcessId id,
|
||||
@@ -50,11 +47,11 @@ index 9a5179c4eeacf8bbfb2d831b4301836df490f3a8..511fc9b9d5ce14a1b5ef457a1047e40d
|
||||
void AddObserver(ServiceProcessHost::Observer* observer);
|
||||
|
||||
diff --git a/content/browser/service_host/utility_process_client.cc b/content/browser/service_host/utility_process_client.cc
|
||||
index 99da7eee3cb1a09b984832211bceee385147aec2..5e4bd537d94ad26c8d309ebfb63845a8d3d11dae 100644
|
||||
index 6bb0ad536c4b8ddd32461e54b93471e8a055c5ea..c549032bd6ac0c161e05f6ace5ec0390fda95258 100644
|
||||
--- a/content/browser/service_host/utility_process_client.cc
|
||||
+++ b/content/browser/service_host/utility_process_client.cc
|
||||
@@ -40,7 +40,7 @@ void UtilityProcessClient::OnProcessTerminatedNormally() {
|
||||
process_info_->service_process_id());
|
||||
@@ -42,7 +42,7 @@ void UtilityProcessClient::OnProcessTerminatedNormally() {
|
||||
GetServiceProcessTracker().NotifyTerminated(*service_process_id_);
|
||||
}
|
||||
|
||||
-void UtilityProcessClient::OnProcessCrashed(CrashType type) {
|
||||
@@ -62,19 +59,19 @@ index 99da7eee3cb1a09b984832211bceee385147aec2..5e4bd537d94ad26c8d309ebfb63845a8
|
||||
// TODO(crbug.com/40654042): It is unclear how we can observe
|
||||
// |OnProcessCrashed()| without observing |OnProcessLaunched()| first, but
|
||||
// it can happen on Android. Ignore the notification in this case.
|
||||
@@ -49,6 +49,6 @@ void UtilityProcessClient::OnProcessCrashed(CrashType type) {
|
||||
@@ -50,6 +50,6 @@ void UtilityProcessClient::OnProcessCrashed(CrashType type) {
|
||||
return;
|
||||
}
|
||||
|
||||
GetServiceProcessTracker().NotifyCrashed(process_info_->service_process_id(),
|
||||
- type);
|
||||
+ type, exit_code);
|
||||
- GetServiceProcessTracker().NotifyCrashed(*service_process_id_, type);
|
||||
+ GetServiceProcessTracker().NotifyCrashed(*service_process_id_, type, exit_code);
|
||||
}
|
||||
} // namespace content
|
||||
diff --git a/content/browser/service_host/utility_process_client.h b/content/browser/service_host/utility_process_client.h
|
||||
index 2648adb1cf38ab557b66ffd0e3034b26b04d76d6..98eab587f343f6ca472efc3d4e7b31b2b8821417 100644
|
||||
index 97a0f76571caf19e39d861bf188da9173fc2f8f6..e651e9b2f9a35265da00432cf2ffdc5857c1fa08 100644
|
||||
--- a/content/browser/service_host/utility_process_client.h
|
||||
+++ b/content/browser/service_host/utility_process_client.h
|
||||
@@ -36,7 +36,7 @@ class UtilityProcessClient : public UtilityProcessHost::Client {
|
||||
@@ -39,7 +39,7 @@ class UtilityProcessClient : public UtilityProcessHost::Client {
|
||||
|
||||
void OnProcessTerminatedNormally() override;
|
||||
|
||||
|
||||
@@ -7,10 +7,10 @@ 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 2af7eba21cd2347b23c53402e9c593a66ae5e76b..7a6d2d086fa02fbb0dd97d89967a196a4ebb739e 100644
|
||||
index f7523cf4dcc40b13499d1e425ce7b67f2d907cc9..64ffc2642c003c8fb7f133ee43ba3e20d48ea543 100644
|
||||
--- a/content/browser/media/capture/screen_capture_kit_device_mac.mm
|
||||
+++ b/content/browser/media/capture/screen_capture_kit_device_mac.mm
|
||||
@@ -320,6 +320,31 @@ void OnShareableContentCreated(SCShareableContent* content) {
|
||||
@@ -322,6 +322,31 @@ void OnShareableContentCreated(SCShareableContent* content) {
|
||||
source_.id == webrtc::kFullDesktopScreenId) {
|
||||
NSArray<SCWindow*>* excluded_windows = GetWindowsToExclude(
|
||||
content, pip_screen_capture_coordinator_proxy_.get(), source_);
|
||||
|
||||
@@ -10,7 +10,7 @@ relying on a process-wide command line switch. The value is also
|
||||
propagated to nested workers via WorkerSettings::Copy.
|
||||
|
||||
diff --git a/third_party/blink/renderer/core/workers/dedicated_worker.cc b/third_party/blink/renderer/core/workers/dedicated_worker.cc
|
||||
index d6a7c7ef529a82b8c0c843fc40ebe84737a86b75..27931353780db0753381755e72db43aacb4ca0b1 100644
|
||||
index 7ea6daec53a497bf867d799e041bf6ae7191ef7b..15940624940d5c629c40319f45c59282713bec17 100644
|
||||
--- a/third_party/blink/renderer/core/workers/dedicated_worker.cc
|
||||
+++ b/third_party/blink/renderer/core/workers/dedicated_worker.cc
|
||||
@@ -37,6 +37,7 @@
|
||||
@@ -21,7 +21,7 @@ index d6a7c7ef529a82b8c0c843fc40ebe84737a86b75..27931353780db0753381755e72db43aa
|
||||
#include "third_party/blink/renderer/core/inspector/inspector_trace_events.h"
|
||||
#include "third_party/blink/renderer/core/inspector/main_thread_debugger.h"
|
||||
#include "third_party/blink/renderer/core/loader/document_loader.h"
|
||||
@@ -564,6 +565,12 @@ DedicatedWorker::CreateGlobalScopeCreationParams(
|
||||
@@ -572,6 +573,12 @@ DedicatedWorker::CreateGlobalScopeCreationParams(
|
||||
auto* frame = window->GetFrame();
|
||||
parent_devtools_token = frame->GetDevToolsFrameToken();
|
||||
settings = std::make_unique<WorkerSettings>(frame->GetSettings());
|
||||
|
||||
@@ -103,7 +103,7 @@ index b124d53fdd245f055f57ad00250112e2637e1cd1..31158388db2df745af999adc9d07fc92
|
||||
NUM,
|
||||
MIN_VALUE = MIDI_SYSEX,
|
||||
diff --git a/third_party/blink/public/mojom/permissions/permission.mojom b/third_party/blink/public/mojom/permissions/permission.mojom
|
||||
index c48068128289331a2a710477e503f01e025e95ce..4db723aa22dbfee46b0048b47f67050cdb83c3c1 100644
|
||||
index e2cf6a8b2d35dd06b8133ce08210add04fafdaed..507eaa61fb8e83727807e6917ba0c9a3e23f9d31 100644
|
||||
--- a/third_party/blink/public/mojom/permissions/permission.mojom
|
||||
+++ b/third_party/blink/public/mojom/permissions/permission.mojom
|
||||
@@ -47,7 +47,7 @@ enum PermissionName {
|
||||
|
||||
@@ -139,10 +139,10 @@ index a258b94a8122c74b6f98f4b88b710371291fcfe4..2bcee4b775a2a39fbbe3c070a5db6081
|
||||
|
||||
// Register the CGWindowID (used to identify this window for video capture)
|
||||
diff --git a/ui/views/widget/widget.cc b/ui/views/widget/widget.cc
|
||||
index 15ac80346e99e6568f08123a857db68c80a76439..8f89d58119ea7cafdf600524d5affdce01aad81a 100644
|
||||
index 75a82bc82ebe8e7b5b51b760cf4258cfd65a2df5..4b29c955c3347e2907c0d064834d917cc95ac546 100644
|
||||
--- a/ui/views/widget/widget.cc
|
||||
+++ b/ui/views/widget/widget.cc
|
||||
@@ -224,6 +224,18 @@ ui::ZOrderLevel Widget::InitParams::EffectiveZOrderLevel() const {
|
||||
@@ -238,6 +238,18 @@ ui::ZOrderLevel Widget::InitParams::EffectiveZOrderLevel() const {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -161,7 +161,7 @@ index 15ac80346e99e6568f08123a857db68c80a76439..8f89d58119ea7cafdf600524d5affdce
|
||||
void Widget::InitParams::SetParent(Widget* parent_widget) {
|
||||
SetParent(parent_widget->GetNativeView());
|
||||
}
|
||||
@@ -471,6 +483,7 @@ void Widget::Init(InitParams params) {
|
||||
@@ -494,6 +506,7 @@ void Widget::Init(InitParams params) {
|
||||
|
||||
params.child |= (params.type == InitParams::TYPE_CONTROL);
|
||||
is_top_level_ = !params.child;
|
||||
@@ -170,7 +170,7 @@ index 15ac80346e99e6568f08123a857db68c80a76439..8f89d58119ea7cafdf600524d5affdce
|
||||
|
||||
if (params.opacity == views::Widget::InitParams::WindowOpacity::kInferred &&
|
||||
diff --git a/ui/views/widget/widget.h b/ui/views/widget/widget.h
|
||||
index 155ce12ba83e70810d07f92aa3dd0f915f5af438..4f26255bf89ccc77d7de69ec70028db20dfcf26e 100644
|
||||
index 93a47570d4854a3136fc4ac7f46d2f3d5c55db6c..78b720d556fb4f3f316baedaa70e56b1a171ab6a 100644
|
||||
--- a/ui/views/widget/widget.h
|
||||
+++ b/ui/views/widget/widget.h
|
||||
@@ -324,6 +324,11 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,
|
||||
@@ -185,7 +185,7 @@ index 155ce12ba83e70810d07f92aa3dd0f915f5af438..4f26255bf89ccc77d7de69ec70028db2
|
||||
// Returns the z-order level, based on the overriding |z_order| but also
|
||||
// taking into account special levels due to |type|.
|
||||
ui::ZOrderLevel EffectiveZOrderLevel() const;
|
||||
@@ -504,6 +509,9 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,
|
||||
@@ -501,6 +506,9 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,
|
||||
// If true then the widget uses software compositing.
|
||||
bool force_software_compositing = false;
|
||||
|
||||
@@ -195,7 +195,7 @@ index 155ce12ba83e70810d07f92aa3dd0f915f5af438..4f26255bf89ccc77d7de69ec70028db2
|
||||
// If set, the window size will follow the content preferred size.
|
||||
bool autosize = false;
|
||||
|
||||
@@ -1297,6 +1305,11 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,
|
||||
@@ -1285,6 +1293,11 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,
|
||||
// with it. TYPE_CONTROL and TYPE_TOOLTIP is not considered top level.
|
||||
bool is_top_level() const { return is_top_level_; }
|
||||
|
||||
@@ -207,7 +207,7 @@ index 155ce12ba83e70810d07f92aa3dd0f915f5af438..4f26255bf89ccc77d7de69ec70028db2
|
||||
// True if the window size will follow the content preferred size.
|
||||
bool is_autosized() const { return is_autosized_; }
|
||||
|
||||
@@ -1742,6 +1755,9 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,
|
||||
@@ -1730,6 +1743,9 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,
|
||||
// If true, the mouse is currently down.
|
||||
bool is_mouse_button_pressed_ = false;
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ Check for broken links by confirming the file exists before setting its utime.
|
||||
This patch should be upstreamed & removed.
|
||||
|
||||
diff --git a/tools/clang/scripts/update.py b/tools/clang/scripts/update.py
|
||||
index 31e2b5775021564b7c80b6756020973141c08530..88446019ce1a98eab8a648220e5ed0cac623c1e9 100755
|
||||
index 5bce95d5ea98c9a6522905f5c237fc5934fe2800..761df90191dd6444d64caf30e2a14c54c8ab536f 100755
|
||||
--- a/tools/clang/scripts/update.py
|
||||
+++ b/tools/clang/scripts/update.py
|
||||
@@ -201,10 +201,9 @@ def DownloadAndUnpack(url, output_dir, path_prefixes=None, is_known_zip=False):
|
||||
|
||||
@@ -28,10 +28,10 @@ The patch should be removed in favor of either:
|
||||
Upstream bug https://bugs.chromium.org/p/chromium/issues/detail?id=1081397.
|
||||
|
||||
diff --git a/content/browser/renderer_host/navigation_request.cc b/content/browser/renderer_host/navigation_request.cc
|
||||
index 2c6da5e24cd1f32bdfcc582596565c43a17caa43..9d33a840c7d87ee1768159d51a556169026da910 100644
|
||||
index 7532fbb742624d86c342df29a7621867fa99180b..45cbb6bcaf16307a6949473ddb62a2be95031199 100644
|
||||
--- a/content/browser/renderer_host/navigation_request.cc
|
||||
+++ b/content/browser/renderer_host/navigation_request.cc
|
||||
@@ -11876,6 +11876,11 @@ url::Origin NavigationRequest::GetOriginForURLLoaderFactoryUnchecked() {
|
||||
@@ -11915,6 +11915,11 @@ url::Origin NavigationRequest::GetOriginForURLLoaderFactoryUnchecked() {
|
||||
target_rph_id);
|
||||
}
|
||||
|
||||
@@ -44,7 +44,7 @@ index 2c6da5e24cd1f32bdfcc582596565c43a17caa43..9d33a840c7d87ee1768159d51a556169
|
||||
// origin of |common_params.url| and/or |common_params.initiator_origin|.
|
||||
url::Origin resolved_origin = url::Origin::Resolve(
|
||||
diff --git a/third_party/blink/renderer/core/loader/document_loader.cc b/third_party/blink/renderer/core/loader/document_loader.cc
|
||||
index eed944992965d7d353f9a1e9063166e5b8e24006..cf5bda8696ca35bd2e37dc8578d72c94793972e3 100644
|
||||
index 1fd466b975fc5347e01bf5f6368e0b4fe89f7c5f..b77eb4ae99103d84ac6f1cb53fd1fe94814c7d05 100644
|
||||
--- a/third_party/blink/renderer/core/loader/document_loader.cc
|
||||
+++ b/third_party/blink/renderer/core/loader/document_loader.cc
|
||||
@@ -2357,6 +2357,7 @@ Frame* DocumentLoader::CalculateOwnerFrame() {
|
||||
|
||||
@@ -48,10 +48,10 @@ index a5570988c3721d9f6bd05c402a7658d3af6f2c2c..54aaffde30c14a27068f89b6de6123ab
|
||||
|
||||
[window setOccluded:[self isWindowOccluded:window
|
||||
diff --git a/content/app_shim_remote_cocoa/web_contents_view_cocoa.mm b/content/app_shim_remote_cocoa/web_contents_view_cocoa.mm
|
||||
index 1ef2c9052262eccdbc40030746a858b7f30ac469..34708d45274f95b5f35cdefad98ad4a1c3c28e1c 100644
|
||||
index da2786e0c5617e44459a1f8b5eade60642277989..0f5f787869fb12391291e8e408d08b1f66390dd5 100644
|
||||
--- a/content/app_shim_remote_cocoa/web_contents_view_cocoa.mm
|
||||
+++ b/content/app_shim_remote_cocoa/web_contents_view_cocoa.mm
|
||||
@@ -477,7 +477,8 @@ - (void)updateWebContentsVisibility {
|
||||
@@ -481,7 +481,8 @@ - (void)updateWebContentsVisibility {
|
||||
Visibility visibility = Visibility::kVisible;
|
||||
if ([self isHiddenOrHasHiddenAncestor] || ![self window])
|
||||
visibility = Visibility::kHidden;
|
||||
@@ -61,7 +61,7 @@ index 1ef2c9052262eccdbc40030746a858b7f30ac469..34708d45274f95b5f35cdefad98ad4a1
|
||||
visibility = Visibility::kOccluded;
|
||||
|
||||
[self updateWebContentsVisibility:visibility];
|
||||
@@ -521,11 +522,12 @@ - (void)viewWillMoveToWindow:(NSWindow*)newWindow {
|
||||
@@ -525,11 +526,12 @@ - (void)viewWillMoveToWindow:(NSWindow*)newWindow {
|
||||
}
|
||||
|
||||
- (void)windowChangedOcclusionState:(NSNotification*)aNotification {
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Charles Kerr <charles@charleskerr.com>
|
||||
Date: Tue, 24 Mar 2026 16:33:20 -0500
|
||||
Subject: fix: initialize COM on DesktopMediaListCaptureThread on Windows
|
||||
|
||||
On Windows, the DesktopMediaListCaptureThread runs with a UI message
|
||||
pump that doesn't initialize COM. When WebRTC's window capturer
|
||||
enumerates windows, interacting with UWP/Metro windows causes twinapi.dll
|
||||
to internally call ::CoCreateInstance(), which hits Chromium's
|
||||
DCheckedCoCreateInstance hook and triggers a crash.
|
||||
|
||||
This patch fixes the crash by ensuring COM is initialized on the
|
||||
capture thread by calling `init_com_with_mta(false)`.
|
||||
|
||||
diff --git a/chrome/browser/media/webrtc/native_desktop_media_list.cc b/chrome/browser/media/webrtc/native_desktop_media_list.cc
|
||||
index 9a8ebb4edfb92d9fe28ae4b87463a68547ea1ab3..13446d9849c54f1bfe515c3db4d69dd181ec6d39 100644
|
||||
--- a/chrome/browser/media/webrtc/native_desktop_media_list.cc
|
||||
+++ b/chrome/browser/media/webrtc/native_desktop_media_list.cc
|
||||
@@ -786,6 +786,13 @@ NativeDesktopMediaList::NativeDesktopMediaList(
|
||||
base::MessagePumpType thread_type = base::MessagePumpType::UI;
|
||||
#else
|
||||
base::MessagePumpType thread_type = base::MessagePumpType::DEFAULT;
|
||||
+#endif
|
||||
+#if BUILDFLAG(IS_WIN)
|
||||
+ // On Windows, window enumeration via webrtc::DesktopCapturer may interact
|
||||
+ // with UWP/Metro windows through twinapi.dll, which internally calls
|
||||
+ // CoCreateInstance. Initialize COM on this thread to prevent crashes in
|
||||
+ // Chromium's DCheckedCoCreateInstance hook.
|
||||
+ thread_.init_com_with_mta(false);
|
||||
#endif
|
||||
thread_.StartWithOptions(base::Thread::Options(thread_type, 0));
|
||||
|
||||
@@ -83,7 +83,7 @@ index cccf164d978761dac8148d11fbddfbeb9ecfb048..295a16cd4f1e369c78d34b4da24ea3c8
|
||||
|
||||
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 c9214d904f2ef51e42369b28a2055c5f2f3bcce1..7981a2517b9bd0b0863e7e2bb8511f40f45d9a21 100644
|
||||
index 2efbb38c338884cd47de75b3e4411e87137f31f1..ff0acc5b26b0df07002a4508bc5b51fa86bd5bde 100644
|
||||
--- a/chrome/browser/ui/views/overlay/video_overlay_window_views.cc
|
||||
+++ b/chrome/browser/ui/views/overlay/video_overlay_window_views.cc
|
||||
@@ -444,11 +444,13 @@ std::unique_ptr<VideoOverlayWindowViews> VideoOverlayWindowViews::Create(
|
||||
|
||||
@@ -44,10 +44,10 @@ index c7794d6a969b407281db12acc027a933a4a82921..382d01ab2f0ad774f7c0d1dc214dd45b
|
||||
}
|
||||
return ret;
|
||||
diff --git a/content/browser/renderer_host/legacy_render_widget_host_win.h b/content/browser/renderer_host/legacy_render_widget_host_win.h
|
||||
index 185391c70440d89f96030fdb4a8d60b90d4c4ffa..9ee57fdc726a37500d44e5f52371e6a35d06cd43 100644
|
||||
index 661a8123862860c88ce1eb78eae6691f38c2bdd9..705cda18d0b669249ff4ace161b53a105db2c806 100644
|
||||
--- a/content/browser/renderer_host/legacy_render_widget_host_win.h
|
||||
+++ b/content/browser/renderer_host/legacy_render_widget_host_win.h
|
||||
@@ -97,6 +97,7 @@ class CONTENT_EXPORT LegacyRenderWidgetHostHWND
|
||||
@@ -101,6 +101,7 @@ class CONTENT_EXPORT LegacyRenderWidgetHostHWND
|
||||
CR_MESSAGE_HANDLER_EX(WM_NCHITTEST, OnNCHitTest)
|
||||
CR_MESSAGE_RANGE_HANDLER_EX(WM_NCMOUSEMOVE, WM_NCXBUTTONDBLCLK,
|
||||
OnMouseRange)
|
||||
|
||||
@@ -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 b5d7f50817f503956f19fcea687b5b0751268b44..bed70819558af52b34135fdb4a3ec4e72e840ace 100644
|
||||
index ccfe78580c2acb9a3afa43d246e1a83cc0e28598..30218b43ce1d57e45e9c265de4edcdce496cda79 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
@@ -3411,6 +3411,12 @@ void RenderWidgetHostViewAura::OnTextSelectionChanged(
|
||||
@@ -3403,6 +3403,12 @@ void RenderWidgetHostViewAura::OnTextSelectionChanged(
|
||||
}
|
||||
}
|
||||
|
||||
@@ -26,10 +26,10 @@ index b5d7f50817f503956f19fcea687b5b0751268b44..bed70819558af52b34135fdb4a3ec4e7
|
||||
RenderWidgetHostViewAura* popup_child_host_view) {
|
||||
popup_child_host_view_ = popup_child_host_view;
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_view_aura.h b/content/browser/renderer_host/render_widget_host_view_aura.h
|
||||
index d6153a1765013e4b53ffc58818b2f30c41e17960..16e391f33028a77f4768bd6ed84c22721f8b998b 100644
|
||||
index 448104cb33edbf6f2c046c4adbac3185eb4c9cb1..47b2677d2878cb9d5544798ddc49b54d270e1688 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_aura.h
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_aura.h
|
||||
@@ -663,6 +663,8 @@ class CONTENT_EXPORT RenderWidgetHostViewAura
|
||||
@@ -662,6 +662,8 @@ class CONTENT_EXPORT RenderWidgetHostViewAura
|
||||
RenderWidgetHostViewBase* updated_view) override;
|
||||
void OnTextSelectionChanged(TextInputManager* text_input_mangager,
|
||||
RenderWidgetHostViewBase* updated_view) override;
|
||||
@@ -39,10 +39,10 @@ index d6153a1765013e4b53ffc58818b2f30c41e17960..16e391f33028a77f4768bd6ed84c2272
|
||||
// Detaches |this| from the input method object.
|
||||
// is_removed flag is true if this is called while the window is
|
||||
diff --git a/content/browser/renderer_host/text_input_manager.cc b/content/browser/renderer_host/text_input_manager.cc
|
||||
index 705a2ee24e463a65784a48844d7c9c26ae7b48db..87bf9b64616688152bd681cb57cefbc68a46d618 100644
|
||||
index 86dff7f91f1934d699371f49ee71fea458eb9822..5eda935a18ebabc0a76f99069f6c6a754139f8cc 100644
|
||||
--- a/content/browser/renderer_host/text_input_manager.cc
|
||||
+++ b/content/browser/renderer_host/text_input_manager.cc
|
||||
@@ -184,6 +184,7 @@ void TextInputManager::UpdateTextInputState(
|
||||
@@ -185,6 +185,7 @@ void TextInputManager::UpdateTextInputState(
|
||||
|
||||
if (text_input_state.type == ui::TEXT_INPUT_TYPE_NONE &&
|
||||
active_view_ != view) {
|
||||
@@ -50,7 +50,7 @@ index 705a2ee24e463a65784a48844d7c9c26ae7b48db..87bf9b64616688152bd681cb57cefbc6
|
||||
// We reached here because an IPC is received to reset the TextInputState
|
||||
// for |view|. But |view| != |active_view_|, which suggests that at least
|
||||
// one other view has become active and we have received the corresponding
|
||||
@@ -474,6 +475,12 @@ void TextInputManager::NotifyObserversAboutInputStateUpdate(
|
||||
@@ -475,6 +476,12 @@ void TextInputManager::NotifyObserversAboutInputStateUpdate(
|
||||
observer.OnUpdateTextInputStateCalled(this, updated_view, did_update_state);
|
||||
}
|
||||
|
||||
@@ -87,10 +87,10 @@ index a4768b51dae6817c9e9a467e9b16e827e0bfebda..83c42b5062aa8193fe2f56e407abe67d
|
||||
// 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 a5ee18ca614737289102db206870e0b11d5caf91..97af9d9d374b9145e0e8a05cd5e48a621e2b0e87 100644
|
||||
index e039e2c82ad75ca4b95763414f7aafb6d3a3dbf2..aaa2b2229dac8c5e8cf590300b436082f6c3773b 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -10433,7 +10433,7 @@ void WebContentsImpl::OnFocusedElementChangedInFrame(
|
||||
@@ -10437,7 +10437,7 @@ void WebContentsImpl::OnFocusedElementChangedInFrame(
|
||||
"WebContentsImpl::OnFocusedElementChangedInFrame",
|
||||
"render_frame_host", frame);
|
||||
RenderWidgetHostViewBase* root_view =
|
||||
|
||||
@@ -8,10 +8,10 @@ such as the background turning black when maximizing the window and
|
||||
dynamic background material settings not taking effect.
|
||||
|
||||
diff --git a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
|
||||
index d1e06b675b19226cf3b78e1aada8d8f2d684fada..ce810555b8501797643987916a728cad8f5adaa5 100644
|
||||
index e4da40256ce94d6a0896792a8ef2faa18e1fa5d2..3a5833fcc018f32e86c0a95a42937fb9ac6c5a40 100644
|
||||
--- a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
|
||||
+++ b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
|
||||
@@ -184,6 +184,10 @@ void DesktopWindowTreeHostWin::FinishTouchDrag(gfx::Point screen_point) {
|
||||
@@ -167,6 +167,10 @@ void DesktopWindowTreeHostWin::FinishTouchDrag(gfx::Point screen_point) {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,7 +23,7 @@ index d1e06b675b19226cf3b78e1aada8d8f2d684fada..ce810555b8501797643987916a728cad
|
||||
|
||||
void DesktopWindowTreeHostWin::Init(const Widget::InitParams& params) {
|
||||
diff --git a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h
|
||||
index a40bd9f25fa07a553c011cf19f155f8158f4ae5f..ae2baec731b5fcd8be97f2177d23b860d67ab8bc 100644
|
||||
index 27322ef34edf3fa8bfbd20b1baddcaf3b7555618..b8d1fa863fd05ebc3ab8ac5ef8c4d81361ce45fe 100644
|
||||
--- a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h
|
||||
+++ b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h
|
||||
@@ -93,6 +93,8 @@ class VIEWS_EXPORT DesktopWindowTreeHostWin
|
||||
|
||||
@@ -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 4ff55ddc2286fff096a7e2bcdfb87d8795d7ce1c..e3fa1bdc048a59dd64dae19b2372119335686643 100644
|
||||
index 06599737a290ba4c52a7d36725aef565d49800bd..fe26e2aeba6fc03201373693d4afa2b78c89e54a 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
@@ -2148,9 +2148,8 @@ RenderWidgetHostImpl::GetWidgetInputHandler() {
|
||||
@@ -2155,9 +2155,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
|
||||
|
||||
@@ -59,10 +59,10 @@ index cba373664bec3a32abad6fe0396bd67b53b7e67f..a54f1b3351efd2d8f324436f7f35cd43
|
||||
|
||||
#endif // THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_SCRIPT_EXECUTION_CALLBACK_H_
|
||||
diff --git a/third_party/blink/renderer/core/frame/local_frame.cc b/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
index abe5b3c6e5eadf30f3e00013fceddaa0ead36cb1..12f1ee3a6a5d213ef3a7e94b5a3828006aad14bb 100644
|
||||
index 8970537416e171d513bc9c015706fb18a574eab6..5bb9fb14dc617edbbf9390ef53c6a8553692539b 100644
|
||||
--- a/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
@@ -3196,6 +3196,7 @@ void LocalFrame::RequestExecuteScript(
|
||||
@@ -3207,6 +3207,7 @@ void LocalFrame::RequestExecuteScript(
|
||||
mojom::blink::EvaluationTiming evaluation_timing,
|
||||
mojom::blink::LoadEventBlockingOption blocking_option,
|
||||
WebScriptExecutionCallback callback,
|
||||
@@ -70,7 +70,7 @@ index abe5b3c6e5eadf30f3e00013fceddaa0ead36cb1..12f1ee3a6a5d213ef3a7e94b5a382800
|
||||
BackForwardCacheAware back_forward_cache_aware,
|
||||
mojom::blink::WantResultOption want_result_option,
|
||||
mojom::blink::PromiseResultOption promise_behavior) {
|
||||
@@ -3253,7 +3254,7 @@ void LocalFrame::RequestExecuteScript(
|
||||
@@ -3264,7 +3265,7 @@ void LocalFrame::RequestExecuteScript(
|
||||
PausableScriptExecutor::CreateAndRun(
|
||||
script_state, std::move(script_sources), execute_script_policy,
|
||||
user_gesture, evaluation_timing, blocking_option, want_result_option,
|
||||
@@ -211,7 +211,7 @@ index f2c94689450f0333a144ccf82cf147c194896e6b..1c2e9fe36c297f7d614d9ca290e4d13c
|
||||
const mojom::blink::UserActivationOption user_activation_option_;
|
||||
const mojom::blink::LoadEventBlockingOption blocking_option_;
|
||||
diff --git a/third_party/blink/renderer/core/frame/web_frame_test.cc b/third_party/blink/renderer/core/frame/web_frame_test.cc
|
||||
index dec0b09e07c568b74b5ba25e8e3cb9f5b5cf7070..f28392d50ded3bb1ecb891314a989f1c07167bf6 100644
|
||||
index 7d4039de028e6c7ef87e93792961c338032b261d..41d0a336dc4c91c74c57383f9203f7bca7675b66 100644
|
||||
--- a/third_party/blink/renderer/core/frame/web_frame_test.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/web_frame_test.cc
|
||||
@@ -300,6 +300,7 @@ void ExecuteScriptsInMainWorld(
|
||||
|
||||
@@ -6,7 +6,7 @@ Subject: fix: select the first menu item when opened via keyboard
|
||||
This fixes an accessibility issue where the root view is 'focused' to the screen reader instead of the first menu item as with all other native menus. This patch will be upstreamed.
|
||||
|
||||
diff --git a/ui/views/controls/menu/menu_controller.cc b/ui/views/controls/menu/menu_controller.cc
|
||||
index c58f75ab1bfbac5613f6ff6edefe97ee0ea2e62b..fff637dd324a4837a918013ec00cfe2a9de7495d 100644
|
||||
index 63f140c698fb1e5ba1f93c24bfe19bc3f87cec19..ea1824d09b37f6404985ffb048ce196ad5811507 100644
|
||||
--- a/ui/views/controls/menu/menu_controller.cc
|
||||
+++ b/ui/views/controls/menu/menu_controller.cc
|
||||
@@ -724,6 +724,16 @@ void MenuController::Run(Widget* parent,
|
||||
@@ -26,7 +26,7 @@ index c58f75ab1bfbac5613f6ff6edefe97ee0ea2e62b..fff637dd324a4837a918013ec00cfe2a
|
||||
if (button_controller) {
|
||||
pressed_lock_ = button_controller->TakeLock(
|
||||
false, ui::LocatedEvent::FromIfValid(event));
|
||||
@@ -2529,18 +2539,15 @@ void MenuController::OpenMenuImpl(MenuItemView* item, bool show) {
|
||||
@@ -2535,18 +2545,15 @@ void MenuController::OpenMenuImpl(MenuItemView* item, bool show) {
|
||||
}
|
||||
item->GetSubmenu()->ShowAt(params);
|
||||
|
||||
|
||||
@@ -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 ae9db54b624893f8876c5ddf0e0179fbb78431aa..83508e07b43a8734981cee9c6cd51fc33037c968 100644
|
||||
index f9179c9f42b16b5c73b7102700410f2d1b83aeab..abce85bb4fb63d1662bbc9ad28a1047f97c6d3c4 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_manager.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_manager.cc
|
||||
@@ -4870,6 +4870,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
@@ -4913,6 +4913,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
request->ResetStateForSiteInstanceChange();
|
||||
}
|
||||
|
||||
@@ -20,7 +20,7 @@ index ae9db54b624893f8876c5ddf0e0179fbb78431aa..83508e07b43a8734981cee9c6cd51fc3
|
||||
}
|
||||
|
||||
diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h
|
||||
index f6ceaf652707d355780d8009339a42bbc271bd07..22699ec734293d1a6da22868bf5701fab1ab3fe7 100644
|
||||
index eb684232648424fab4ba73b1fc813b0b3f8b809b..42b6fe4eb2c1db7afd6379ae07c1062856ed958e 100644
|
||||
--- a/content/public/browser/content_browser_client.h
|
||||
+++ b/content/public/browser/content_browser_client.h
|
||||
@@ -350,6 +350,11 @@ class CONTENT_EXPORT ContentBrowserClient {
|
||||
|
||||
@@ -41,10 +41,10 @@ index 3909e70dc1425c2cb02624f4b3017784a2ae6c9d..a57b92f02085d6392e6d9d0cc037df6b
|
||||
// Returns whether `Initialize` has already been invoked in the process.
|
||||
// Initialization is a one-way operation (i.e., this method cannot return
|
||||
diff --git a/gin/v8_initializer.cc b/gin/v8_initializer.cc
|
||||
index 6146bd47bf3203b97084438ab51f96d515c74b55..136e728c4c7981c9180304a43d75b2f003161664 100644
|
||||
index f32f4077d56ff38e96ff825633fd908242b2ab7a..cd1f308815685d28c506b5c9eb87b24107fa220b 100644
|
||||
--- a/gin/v8_initializer.cc
|
||||
+++ b/gin/v8_initializer.cc
|
||||
@@ -529,7 +529,8 @@ void SetFeatureFlags() {
|
||||
@@ -525,7 +525,8 @@ void SetFeatureFlags() {
|
||||
void V8Initializer::Initialize(IsolateHolder::ScriptMode mode,
|
||||
const std::string& js_command_line_flags,
|
||||
bool disallow_v8_feature_flag_overrides,
|
||||
@@ -54,7 +54,7 @@ index 6146bd47bf3203b97084438ab51f96d515c74b55..136e728c4c7981c9180304a43d75b2f0
|
||||
static bool v8_is_initialized = false;
|
||||
if (v8_is_initialized)
|
||||
return;
|
||||
@@ -544,7 +545,8 @@ void V8Initializer::Initialize(IsolateHolder::ScriptMode mode,
|
||||
@@ -540,7 +541,8 @@ void V8Initializer::Initialize(IsolateHolder::ScriptMode mode,
|
||||
}
|
||||
SetFlags(mode, js_command_line_flags);
|
||||
|
||||
|
||||
@@ -6,10 +6,10 @@ 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 98b18d9e8129f2b06c4633b4ff74320fa2dee5f6..2f9bbe7578ce8e255a4aed6dd9dacea245640795 100644
|
||||
index ffd47250ce5a6a75471bb65aaf3d65b550be3586..e75f89f05ba0e3cc29d857f76244d777efdf1b84 100644
|
||||
--- a/tools/gritsettings/resource_ids.spec
|
||||
+++ b/tools/gritsettings/resource_ids.spec
|
||||
@@ -1670,6 +1670,11 @@
|
||||
@@ -1678,6 +1678,11 @@
|
||||
"includes": [12000],
|
||||
},
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@ system font by checking if it's kCTFontPriorityAttribute is set to
|
||||
system priority.
|
||||
|
||||
diff --git a/base/BUILD.gn b/base/BUILD.gn
|
||||
index 2fea06e3d762884df05e74c0cef98990c302f814..fbadbe444df1b58e9e9cb985d30d009b661802ec 100644
|
||||
index aad39d792791fb1e17d7a529eb234f74fdb65b09..95262f1cb611bfa9ac61321312b0aa5a979900cd 100644
|
||||
--- a/base/BUILD.gn
|
||||
+++ b/base/BUILD.gn
|
||||
@@ -1086,6 +1086,7 @@ component("base") {
|
||||
@@ -129,10 +129,10 @@ index 416e541436d201aabca26cdbf7e8477103bd014c..8c5f92b03d67e5f0587b0e9420969061
|
||||
}
|
||||
|
||||
diff --git a/base/allocator/partition_allocator/src/partition_alloc/BUILD.gn b/base/allocator/partition_allocator/src/partition_alloc/BUILD.gn
|
||||
index 1f8256fdf364c34406fd5639057acca8d52cb474..2df7110c18569323199ec227891362c248237b2f 100644
|
||||
index 51a9d1fef7b2dbfef69f8474d74d45b69f16219d..cd61d8ae6ac772f8b8c28157e21b439cdb87dcca 100644
|
||||
--- a/base/allocator/partition_allocator/src/partition_alloc/BUILD.gn
|
||||
+++ b/base/allocator/partition_allocator/src/partition_alloc/BUILD.gn
|
||||
@@ -974,6 +974,7 @@ if (is_clang_or_gcc) {
|
||||
@@ -978,6 +978,7 @@ if (is_clang_or_gcc) {
|
||||
":allocator_base",
|
||||
":allocator_core",
|
||||
":buildflags",
|
||||
@@ -869,7 +869,7 @@ index d58c5eff9f8fbca96d0912ab9a19d06974fd8016..94ee727830545ff1576685722c0fd0dd
|
||||
|
||||
void NativeWidgetNSWindowBridge::SetColorMode(
|
||||
diff --git a/components/viz/service/BUILD.gn b/components/viz/service/BUILD.gn
|
||||
index e3e8dc95624d9ad2d1428986694ca562f5fd6d64..2aa6ad756b0a146f35516930d4452358d0f8dd07 100644
|
||||
index 42a96534b0d6ec220626b888bfc97f382dfc1210..3f9d9afc88b7622c28ba2167c305e2a54affb8d3 100644
|
||||
--- a/components/viz/service/BUILD.gn
|
||||
+++ b/components/viz/service/BUILD.gn
|
||||
@@ -390,6 +390,7 @@ viz_component("service") {
|
||||
@@ -974,7 +974,7 @@ index 664e12c07204feeb5be16581fe51e8adc4b898dd..38159d146cdf71f84611d58e2983418a
|
||||
return kAttributes;
|
||||
}
|
||||
diff --git a/content/browser/BUILD.gn b/content/browser/BUILD.gn
|
||||
index 431c4151c4c76f99ea2ec21b9f019e6bf123df79..9f9d8feff59b03b15e289e6fbc9474920d89a12c 100644
|
||||
index 718b28f411f7c32af45dc1e1cf4b4deeba78b06b..3a2189e97b99b2b2cf0308feeeddb9a249b3edb5 100644
|
||||
--- a/content/browser/BUILD.gn
|
||||
+++ b/content/browser/BUILD.gn
|
||||
@@ -363,6 +363,7 @@ source_set("browser") {
|
||||
@@ -986,18 +986,18 @@ index 431c4151c4c76f99ea2ec21b9f019e6bf123df79..9f9d8feff59b03b15e289e6fbc947492
|
||||
|
||||
public_deps = [
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_view_mac.h b/content/browser/renderer_host/render_widget_host_view_mac.h
|
||||
index 60de2c2d1d9120796c5df0751a54d09b1e507147..92c8d47448681322d122807d5fadccdb3d91a603 100644
|
||||
index d4320df856533ef75f943deeac82119c746f5e20..c6e9cc8fd3b3e152493086a6f401d1c6ce318725 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_mac.h
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_mac.h
|
||||
@@ -24,6 +24,7 @@
|
||||
@@ -25,6 +25,7 @@
|
||||
#include "content/browser/renderer_host/text_input_manager.h"
|
||||
#include "content/common/content_export.h"
|
||||
#include "content/common/render_widget_host_ns_view.mojom.h"
|
||||
+#include "electron/mas.h"
|
||||
#include "mojo/public/cpp/bindings/associated_receiver.h"
|
||||
#include "mojo/public/cpp/bindings/associated_remote.h"
|
||||
#include "third_party/blink/public/mojom/webshare/webshare.mojom.h"
|
||||
@@ -54,7 +55,9 @@ class CursorManager;
|
||||
#include "third_party/blink/public/common/page/content_to_visible_time_request.h"
|
||||
@@ -55,7 +56,9 @@ class CursorManager;
|
||||
|
||||
@protocol RenderWidgetHostViewMacDelegate;
|
||||
|
||||
@@ -1020,7 +1020,7 @@ index 60de2c2d1d9120796c5df0751a54d09b1e507147..92c8d47448681322d122807d5fadccdb
|
||||
// Used to force the NSApplication's focused accessibility element to be the
|
||||
// content::BrowserAccessibilityCocoa accessibility tree when the NSView for
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_view_mac.mm b/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
index 1ed8918ae793301197c456bb20dd9e82a50d1e4e..0747a20b283151a75c524dc0fa74c7b799725e54 100644
|
||||
index 63041c4311293c53d370522646012cde803e0a99..886b3e87e9041931d3cb59ef775b5012e8e2f908 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_mac.mm
|
||||
@@ -53,6 +53,7 @@
|
||||
@@ -1031,7 +1031,7 @@ index 1ed8918ae793301197c456bb20dd9e82a50d1e4e..0747a20b283151a75c524dc0fa74c7b7
|
||||
#include "media/base/media_switches.h"
|
||||
#include "skia/ext/platform_canvas.h"
|
||||
#include "skia/ext/skia_utils_mac.h"
|
||||
@@ -293,8 +294,10 @@
|
||||
@@ -292,8 +293,10 @@
|
||||
void RenderWidgetHostViewMac::MigrateNSViewBridge(
|
||||
remote_cocoa::mojom::Application* remote_cocoa_application,
|
||||
uint64_t parent_ns_view_id) {
|
||||
@@ -1042,7 +1042,7 @@ index 1ed8918ae793301197c456bb20dd9e82a50d1e4e..0747a20b283151a75c524dc0fa74c7b7
|
||||
|
||||
// Reset `ns_view_` before resetting `remote_ns_view_` to avoid dangling
|
||||
// pointers. `ns_view_` gets reinitialized later in this method.
|
||||
@@ -1717,10 +1720,12 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
|
||||
@@ -1720,10 +1723,12 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
|
||||
|
||||
gfx::NativeViewAccessible
|
||||
RenderWidgetHostViewMac::AccessibilityGetNativeViewAccessibleForWindow() {
|
||||
@@ -1055,7 +1055,7 @@ index 1ed8918ae793301197c456bb20dd9e82a50d1e4e..0747a20b283151a75c524dc0fa74c7b7
|
||||
return gfx::NativeViewAccessible([GetInProcessNSView() window]);
|
||||
}
|
||||
|
||||
@@ -1772,9 +1777,11 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
|
||||
@@ -1775,9 +1780,11 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
|
||||
}
|
||||
|
||||
void RenderWidgetHostViewMac::SetAccessibilityWindow(NSWindow* window) {
|
||||
@@ -1067,7 +1067,7 @@ index 1ed8918ae793301197c456bb20dd9e82a50d1e4e..0747a20b283151a75c524dc0fa74c7b7
|
||||
}
|
||||
|
||||
bool RenderWidgetHostViewMac::SyncIsWidgetForMainFrame(
|
||||
@@ -2304,20 +2311,26 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
|
||||
@@ -2307,20 +2314,26 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
|
||||
void RenderWidgetHostViewMac::GetRenderWidgetAccessibilityToken(
|
||||
GetRenderWidgetAccessibilityTokenCallback callback) {
|
||||
base::ProcessId pid = getpid();
|
||||
@@ -1095,10 +1095,10 @@ index 1ed8918ae793301197c456bb20dd9e82a50d1e4e..0747a20b283151a75c524dc0fa74c7b7
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
diff --git a/content/common/BUILD.gn b/content/common/BUILD.gn
|
||||
index 691fb357cb6865cc0b47d37a509a440b52475493..3377fbe048b4e6945ca4790aa2dadde7dd9f47ea 100644
|
||||
index 6294792999d1653b73c695ebfddda0f8a45d82c9..da6be02dcff5d956e69fa356ec6dea65aa9780af 100644
|
||||
--- a/content/common/BUILD.gn
|
||||
+++ b/content/common/BUILD.gn
|
||||
@@ -280,6 +280,7 @@ source_set("common") {
|
||||
@@ -282,6 +282,7 @@ source_set("common") {
|
||||
"//ui/shell_dialogs",
|
||||
"//url",
|
||||
"//url/ipc:url_ipc",
|
||||
@@ -1189,7 +1189,7 @@ index a1068589ad844518038ee7bc15a3de9bc5cba525..1ff781c49f086ec8015c7d3c44567dbe
|
||||
|
||||
} // namespace content
|
||||
diff --git a/content/test/BUILD.gn b/content/test/BUILD.gn
|
||||
index fc808a4a52383001885031035efe3d5ab898ba7f..46766e561e1e6ff14c0ece100386fcd5ce9df49a 100644
|
||||
index ec792aa7e050550721cd221bfe8ff335e22e90ef..4521cc9e247c44248627c12b9eda0961f837d744 100644
|
||||
--- a/content/test/BUILD.gn
|
||||
+++ b/content/test/BUILD.gn
|
||||
@@ -701,6 +701,7 @@ static_library("test_support") {
|
||||
@@ -1209,7 +1209,7 @@ index fc808a4a52383001885031035efe3d5ab898ba7f..46766e561e1e6ff14c0ece100386fcd5
|
||||
}
|
||||
|
||||
mojom("content_test_mojo_bindings") {
|
||||
@@ -2076,6 +2079,7 @@ test("content_browsertests") {
|
||||
@@ -2078,6 +2081,7 @@ test("content_browsertests") {
|
||||
"//ui/shell_dialogs",
|
||||
"//ui/snapshot",
|
||||
"//ui/webui:test_support",
|
||||
@@ -1217,7 +1217,7 @@ index fc808a4a52383001885031035efe3d5ab898ba7f..46766e561e1e6ff14c0ece100386fcd5
|
||||
]
|
||||
|
||||
if (!(is_chromeos && target_cpu == "arm64" && current_cpu == "arm")) {
|
||||
@@ -3430,6 +3434,7 @@ test("content_unittests") {
|
||||
@@ -3446,6 +3450,7 @@ test("content_unittests") {
|
||||
"//ui/shell_dialogs",
|
||||
"//ui/webui:test_support",
|
||||
"//url",
|
||||
@@ -1378,7 +1378,7 @@ index 75178516b53665c82195f795c5e4498c588e51c9..10e453a18813d3078dc4f01ab040acc6
|
||||
} // namespace
|
||||
#endif
|
||||
diff --git a/net/dns/BUILD.gn b/net/dns/BUILD.gn
|
||||
index 5be47a39edb9c5f3b05a13d10732b772d30cc2d7..a455b220b1e16770888bb02daeb88bfc4fa86fbd 100644
|
||||
index fe250ad7f81a503f2db084e6b55dafc06e35e2fb..23ae43042df5cd5bf08db5d1c736be6daee96e06 100644
|
||||
--- a/net/dns/BUILD.gn
|
||||
+++ b/net/dns/BUILD.gn
|
||||
@@ -223,6 +223,8 @@ source_set("dns") {
|
||||
@@ -1789,7 +1789,7 @@ index eb81a70e4d5d5cd3e6ae9b45f8cd1c795ea76c51..9921ccb10d3455600eddd85f77f10228
|
||||
|
||||
} // namespace sandbox
|
||||
diff --git a/third_party/blink/renderer/core/BUILD.gn b/third_party/blink/renderer/core/BUILD.gn
|
||||
index 796fb4ff8bcf65c3c533ad1a777e3dbaf545d0dc..7adf61c7de52e1d5c73c0940ab46717514bc4437 100644
|
||||
index e90757c2962fccbdfeff5842b0805e51ed8eb152..17a800cbb634862e80a14fc6e864cd3db402e52f 100644
|
||||
--- a/third_party/blink/renderer/core/BUILD.gn
|
||||
+++ b/third_party/blink/renderer/core/BUILD.gn
|
||||
@@ -444,6 +444,7 @@ component("core") {
|
||||
@@ -2140,7 +2140,7 @@ index ef031ba14e4c649f6f3a5718ac521e6b424d64cb..38e528450196b4dbd5fa6a25b96baa10
|
||||
// Accessible object
|
||||
if (AXElementWrapper::IsValidElement(value)) {
|
||||
diff --git a/ui/base/BUILD.gn b/ui/base/BUILD.gn
|
||||
index 7cdab4235dca2ebdbdf77c6324df14f3094750d4..053221860b3fe6cae8e9d8505b7decacaf12e8ea 100644
|
||||
index e4b9053c9333598ec0347ec84a4d898d8eedca6a..f08d8343a6bb665be57c9e6766476c71efa47143 100644
|
||||
--- a/ui/base/BUILD.gn
|
||||
+++ b/ui/base/BUILD.gn
|
||||
@@ -355,6 +355,13 @@ component("base") {
|
||||
@@ -2359,7 +2359,7 @@ index bbe355cf69f160866188216cc274d75bd35603db..06ee100d7ea2e892dbf3c0b1adc96c50
|
||||
// enough.
|
||||
return PlatformFontMac::SystemFontType::kGeneral;
|
||||
diff --git a/ui/views/BUILD.gn b/ui/views/BUILD.gn
|
||||
index de9338902104daacef1d05858354724a6fa198cc..775d317346a77cf54c4cfb3c3723e5e990f50bb3 100644
|
||||
index 9a160c5209cb4e4640aa130b9cb2747cf6338f77..d42a2979c1957cbd51f894682f0ca98c9cf4eed0 100644
|
||||
--- a/ui/views/BUILD.gn
|
||||
+++ b/ui/views/BUILD.gn
|
||||
@@ -734,6 +734,8 @@ component("views") {
|
||||
@@ -2371,7 +2371,7 @@ index de9338902104daacef1d05858354724a6fa198cc..775d317346a77cf54c4cfb3c3723e5e9
|
||||
}
|
||||
|
||||
if (is_win) {
|
||||
@@ -1163,6 +1165,8 @@ source_set("test_support") {
|
||||
@@ -1150,6 +1152,8 @@ source_set("test_support") {
|
||||
"//ui/base/mojom:ui_base_types",
|
||||
]
|
||||
|
||||
|
||||
@@ -7,10 +7,10 @@ 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 0d70e10657f5f1cc5811e56044f13d9ae6c7f2a1..4efd5407479b9e5ee6af84a4cd6d26895d8b19f7 100644
|
||||
index 68b3acc5a4e67fee975fd982f252cbf46c28ccac..cf1001557f2f59747ceb394ab2c93b4bf379dafb 100644
|
||||
--- a/services/network/network_context.cc
|
||||
+++ b/services/network/network_context.cc
|
||||
@@ -172,6 +172,11 @@
|
||||
@@ -173,6 +173,11 @@
|
||||
#include "services/network/web_transport.h"
|
||||
#include "url/gurl.h"
|
||||
|
||||
@@ -22,7 +22,7 @@ index 0d70e10657f5f1cc5811e56044f13d9ae6c7f2a1..4efd5407479b9e5ee6af84a4cd6d2689
|
||||
#if BUILDFLAG(IS_CT_SUPPORTED)
|
||||
// gn check does not account for BUILDFLAG(). So, for iOS builds, it will
|
||||
// complain about a missing dependency on the target exposing this header. Add a
|
||||
@@ -631,6 +636,111 @@ void RecordHSTSPreconnectUpgradeReason(HSTSRedirectUpgradeReason reason) {
|
||||
@@ -632,6 +637,111 @@ void RecordHSTSPreconnectUpgradeReason(HSTSRedirectUpgradeReason reason) {
|
||||
|
||||
} // namespace
|
||||
|
||||
@@ -134,7 +134,7 @@ index 0d70e10657f5f1cc5811e56044f13d9ae6c7f2a1..4efd5407479b9e5ee6af84a4cd6d2689
|
||||
constexpr uint32_t NetworkContext::kMaxOutstandingRequestsPerProcess;
|
||||
|
||||
NetworkContext::NetworkContextHttpAuthPreferences::
|
||||
@@ -1078,6 +1188,13 @@ void NetworkContext::SetClient(
|
||||
@@ -1081,6 +1191,13 @@ void NetworkContext::SetClient(
|
||||
client_.Bind(std::move(client));
|
||||
}
|
||||
|
||||
@@ -148,7 +148,7 @@ index 0d70e10657f5f1cc5811e56044f13d9ae6c7f2a1..4efd5407479b9e5ee6af84a4cd6d2689
|
||||
void NetworkContext::CreateURLLoaderFactory(
|
||||
mojo::PendingReceiver<mojom::URLLoaderFactory> receiver,
|
||||
mojom::URLLoaderFactoryParamsPtr params) {
|
||||
@@ -2767,6 +2884,10 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
|
||||
@@ -2800,6 +2917,10 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
|
||||
cert_verifier = std::make_unique<net::CachingCertVerifier>(
|
||||
std::make_unique<net::CoalescingCertVerifier>(
|
||||
std::move(cert_verifier)));
|
||||
@@ -160,10 +160,10 @@ index 0d70e10657f5f1cc5811e56044f13d9ae6c7f2a1..4efd5407479b9e5ee6af84a4cd6d2689
|
||||
|
||||
builder.SetCertVerifier(IgnoreErrorsCertVerifier::MaybeWrapCertVerifier(
|
||||
diff --git a/services/network/network_context.h b/services/network/network_context.h
|
||||
index 80f64d8bc17c9a706dafd3e9639a6d7e62caf0d5..912e4d60647f6376dfef62d18998b556bc7efa32 100644
|
||||
index 54a5feca1fbec658039826304f27283bd9d9c15a..04e6e884dccbb680a39f2b9c8a54de162e056a30 100644
|
||||
--- a/services/network/network_context.h
|
||||
+++ b/services/network/network_context.h
|
||||
@@ -121,6 +121,7 @@ class SimpleUrlPatternMatcher;
|
||||
@@ -122,6 +122,7 @@ class SimpleUrlPatternMatcher;
|
||||
}
|
||||
|
||||
namespace network {
|
||||
@@ -171,7 +171,7 @@ index 80f64d8bc17c9a706dafd3e9639a6d7e62caf0d5..912e4d60647f6376dfef62d18998b556
|
||||
class CookieManager;
|
||||
class HostResolver;
|
||||
class MdnsResponderManager;
|
||||
@@ -257,6 +258,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
@@ -258,6 +259,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
void CreateURLLoaderFactory(
|
||||
mojo::PendingReceiver<mojom::URLLoaderFactory> receiver,
|
||||
mojom::URLLoaderFactoryParamsPtr params) override;
|
||||
@@ -180,7 +180,7 @@ index 80f64d8bc17c9a706dafd3e9639a6d7e62caf0d5..912e4d60647f6376dfef62d18998b556
|
||||
void ResetURLLoaderFactories() override;
|
||||
void GetViaObliviousHttp(
|
||||
mojom::ObliviousHttpRequestPtr request,
|
||||
@@ -982,6 +985,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
@@ -1002,6 +1005,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
std::vector<base::OnceClosure> dismount_closures_;
|
||||
#endif // BUILDFLAG(IS_DIRECTORY_TRANSFER_REQUIRED)
|
||||
|
||||
@@ -190,7 +190,7 @@ index 80f64d8bc17c9a706dafd3e9639a6d7e62caf0d5..912e4d60647f6376dfef62d18998b556
|
||||
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 47134ad9365ce50035d5a305418e36a41fc917c9..63d410dd356594a5928ed2f84b05b403bf3367f0 100644
|
||||
index 152bffb4e6565437e867b79364c594305350047f..6c43c2985123525793dd6b60c9d7d7c1db7fdf04 100644
|
||||
--- a/services/network/public/mojom/network_context.mojom
|
||||
+++ b/services/network/public/mojom/network_context.mojom
|
||||
@@ -325,6 +325,17 @@ struct SocketBrokerRemotes {
|
||||
@@ -211,7 +211,7 @@ index 47134ad9365ce50035d5a305418e36a41fc917c9..63d410dd356594a5928ed2f84b05b403
|
||||
// Parameters for constructing a network context.
|
||||
struct NetworkContextParams {
|
||||
// The user agent string.
|
||||
@@ -977,6 +988,9 @@ interface NetworkContext {
|
||||
@@ -981,6 +992,9 @@ interface NetworkContext {
|
||||
// Sets a client for this network context.
|
||||
SetClient(pending_remote<NetworkContextClient> client);
|
||||
|
||||
@@ -222,7 +222,7 @@ index 47134ad9365ce50035d5a305418e36a41fc917c9..63d410dd356594a5928ed2f84b05b403
|
||||
CreateURLLoaderFactory(
|
||||
pending_receiver<URLLoaderFactory> url_loader_factory,
|
||||
diff --git a/services/network/test/test_network_context.h b/services/network/test/test_network_context.h
|
||||
index beb1c3dba14fcc504886f100b1568768231a4f2d..bc26f449109b3be84490fbb3569e36aa4aca8c4b 100644
|
||||
index 8b419ec4a949551557eba8c84589a18147b78c5d..b472be0acdc0cd4971e6e0a9e623bc1c84d07a02 100644
|
||||
--- a/services/network/test/test_network_context.h
|
||||
+++ b/services/network/test/test_network_context.h
|
||||
@@ -63,6 +63,8 @@ class TestNetworkContext : public mojom::NetworkContext {
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user