mirror of
https://github.com/electron/electron.git
synced 2026-02-19 03:14:51 -05:00
Compare commits
62 Commits
robo/explo
...
v7.0.0-bet
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9e7cce3d2b | ||
|
|
c7a3142bab | ||
|
|
b6f5e26eab | ||
|
|
3330647834 | ||
|
|
bb8c7dfc7e | ||
|
|
4dea193854 | ||
|
|
080c2c9218 | ||
|
|
182f63d3a3 | ||
|
|
d3e0c461f6 | ||
|
|
b09a1c7607 | ||
|
|
7cc1efd2e6 | ||
|
|
324096aa37 | ||
|
|
d780a16d78 | ||
|
|
005ef96ac0 | ||
|
|
4f74be084a | ||
|
|
b7c2188d09 | ||
|
|
192326c7c5 | ||
|
|
1af064a144 | ||
|
|
6061fcce40 | ||
|
|
e68a9486da | ||
|
|
dd8bcb67ba | ||
|
|
27661d8e7b | ||
|
|
94ddcc4742 | ||
|
|
2515087322 | ||
|
|
36a5ba0d4d | ||
|
|
241b2a98af | ||
|
|
9b2e3d1d0b | ||
|
|
67cb05b435 | ||
|
|
3f5222b047 | ||
|
|
28e7e6492d | ||
|
|
23f7f63405 | ||
|
|
99eaa0d1bb | ||
|
|
543dbaf412 | ||
|
|
5901293628 | ||
|
|
30543cec74 | ||
|
|
66aeeac8df | ||
|
|
b03bc4de83 | ||
|
|
601c3f97ea | ||
|
|
d01a8eaa39 | ||
|
|
54e1c11b2b | ||
|
|
c1ad66b104 | ||
|
|
a905259646 | ||
|
|
356045ff57 | ||
|
|
a9f69bf732 | ||
|
|
3e181b8efc | ||
|
|
171c76e3cb | ||
|
|
0299f69fd1 | ||
|
|
0bdb7b164c | ||
|
|
ea9cfc127c | ||
|
|
0afb1a8188 | ||
|
|
f154dbda40 | ||
|
|
c3013d2e9f | ||
|
|
3272564eac | ||
|
|
a0f4632461 | ||
|
|
8ddf837d49 | ||
|
|
9822953d31 | ||
|
|
c6061cce41 | ||
|
|
a9602682c5 | ||
|
|
b7e5213afc | ||
|
|
9b70d9aa68 | ||
|
|
d9bfac32e3 | ||
|
|
9e815afc02 |
@@ -91,13 +91,19 @@ env-linux-medium: &env-linux-medium
|
||||
NUMBER_OF_NINJA_PROCESSES: 3
|
||||
|
||||
env-linux-2xlarge: &env-linux-2xlarge
|
||||
NUMBER_OF_NINJA_PROCESSES: 18
|
||||
NUMBER_OF_NINJA_PROCESSES: 34
|
||||
|
||||
env-linux-2xlarge-release: &env-linux-2xlarge-release
|
||||
NUMBER_OF_NINJA_PROCESSES: 16
|
||||
|
||||
env-machine-mac: &env-machine-mac
|
||||
NUMBER_OF_NINJA_PROCESSES: 6
|
||||
|
||||
env-mac-large: &env-mac-large
|
||||
NUMBER_OF_NINJA_PROCESSES: 10
|
||||
NUMBER_OF_NINJA_PROCESSES: 18
|
||||
|
||||
env-mac-large-release: &env-mac-large-release
|
||||
NUMBER_OF_NINJA_PROCESSES: 8
|
||||
|
||||
env-disable-crash-reporter-tests: &env-disable-crash-reporter-tests
|
||||
DISABLE_CRASH_REPORTER_TESTS: true
|
||||
@@ -1040,7 +1046,7 @@ jobs:
|
||||
linux-x64-publish:
|
||||
<<: *machine-linux-2xlarge
|
||||
environment:
|
||||
<<: *env-linux-2xlarge
|
||||
<<: *env-linux-2xlarge-release
|
||||
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_boto=True --custom-var=checkout_requests=True'
|
||||
<<: *env-release-build
|
||||
<<: *steps-electron-build-for-publish
|
||||
@@ -1089,7 +1095,7 @@ jobs:
|
||||
linux-ia32-publish:
|
||||
<<: *machine-linux-2xlarge
|
||||
environment:
|
||||
<<: *env-linux-2xlarge
|
||||
<<: *env-linux-2xlarge-release
|
||||
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_boto=True --custom-var=checkout_requests=True'
|
||||
<<: *env-ia32
|
||||
<<: *env-release-build
|
||||
@@ -1140,7 +1146,7 @@ jobs:
|
||||
linux-arm-publish:
|
||||
<<: *machine-linux-2xlarge
|
||||
environment:
|
||||
<<: *env-linux-2xlarge
|
||||
<<: *env-linux-2xlarge-release
|
||||
<<: *env-arm
|
||||
<<: *env-release-build
|
||||
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_arm=True --custom-var=checkout_boto=True --custom-var=checkout_requests=True'
|
||||
@@ -1207,7 +1213,7 @@ jobs:
|
||||
linux-arm64-publish:
|
||||
<<: *machine-linux-2xlarge
|
||||
environment:
|
||||
<<: *env-linux-2xlarge
|
||||
<<: *env-linux-2xlarge-release
|
||||
<<: *env-arm64
|
||||
<<: *env-release-build
|
||||
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_arm64=True --custom-var=checkout_boto=True --custom-var=checkout_requests=True'
|
||||
@@ -1257,7 +1263,7 @@ jobs:
|
||||
osx-publish:
|
||||
<<: *machine-mac-large
|
||||
environment:
|
||||
<<: *env-mac-large
|
||||
<<: *env-mac-large-release
|
||||
<<: *env-release-build
|
||||
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_boto=True --custom-var=checkout_requests=True'
|
||||
<<: *steps-electron-build-for-publish
|
||||
@@ -1310,7 +1316,7 @@ jobs:
|
||||
mas-publish:
|
||||
<<: *machine-mac-large
|
||||
environment:
|
||||
<<: *env-mac-large
|
||||
<<: *env-mac-large-release
|
||||
<<: *env-mas
|
||||
<<: *env-release-build
|
||||
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_boto=True --custom-var=checkout_requests=True'
|
||||
|
||||
1
.github/CODEOWNERS
vendored
1
.github/CODEOWNERS
vendored
@@ -11,6 +11,7 @@
|
||||
|
||||
# Upgrades WG
|
||||
/patches/ @electron/wg-upgrades
|
||||
DEPS @electron/wg-upgrades
|
||||
|
||||
# Docs & Tooling WG
|
||||
/default_app/ @electron/wg-docs-tools
|
||||
|
||||
17
BUILD.gn
17
BUILD.gn
@@ -300,14 +300,6 @@ source_set("manifests") {
|
||||
"//printing/buildflags",
|
||||
"//services/service_manager/public/cpp",
|
||||
]
|
||||
|
||||
if (enable_basic_printing) {
|
||||
deps += [ "//components/services/pdf_compositor/public/cpp:manifest" ]
|
||||
}
|
||||
|
||||
if (enable_print_preview) {
|
||||
deps += [ "//chrome/services/printing/public/cpp:manifest" ]
|
||||
}
|
||||
}
|
||||
|
||||
npm_action("electron_version_args") {
|
||||
@@ -354,8 +346,11 @@ source_set("electron_lib") {
|
||||
"//base:base_static",
|
||||
"//base/allocator:buildflags",
|
||||
"//chrome/app/resources:platform_locale_settings",
|
||||
"//chrome/services/printing/public/mojom",
|
||||
"//components/certificate_transparency",
|
||||
"//components/net_log",
|
||||
"//components/network_hints/common",
|
||||
"//components/network_hints/renderer",
|
||||
"//components/network_session_configurator/common",
|
||||
"//components/prefs",
|
||||
"//components/spellcheck/renderer",
|
||||
@@ -371,7 +366,7 @@ source_set("electron_lib") {
|
||||
"//device/bluetooth/public/cpp",
|
||||
"//gin",
|
||||
"//media/capture/mojom:video_capture",
|
||||
"//media/mojo/interfaces",
|
||||
"//media/mojo/mojom",
|
||||
"//net:extras",
|
||||
"//net:net_resources",
|
||||
"//net:net_with_v8",
|
||||
@@ -384,7 +379,7 @@ source_set("electron_lib") {
|
||||
"//services/device/public/mojom",
|
||||
"//services/proxy_resolver:lib",
|
||||
"//services/video_capture/public/mojom:constants",
|
||||
"//services/viz/privileged/interfaces/compositing",
|
||||
"//services/viz/privileged/mojom/compositing",
|
||||
"//skia",
|
||||
"//third_party/blink/public:blink",
|
||||
"//third_party/boringssl",
|
||||
@@ -579,7 +574,7 @@ source_set("electron_lib") {
|
||||
]
|
||||
deps += [
|
||||
"//components/viz/service",
|
||||
"//services/viz/public/interfaces",
|
||||
"//services/viz/public/mojom",
|
||||
"//ui/compositor",
|
||||
]
|
||||
}
|
||||
|
||||
9
DEPS
9
DEPS
@@ -5,14 +5,15 @@ gclient_gn_args = [
|
||||
'checkout_android_native_support',
|
||||
'checkout_libaom',
|
||||
'checkout_nacl',
|
||||
'checkout_oculus_sdk'
|
||||
'checkout_oculus_sdk',
|
||||
'checkout_openxr'
|
||||
]
|
||||
|
||||
vars = {
|
||||
'chromium_version':
|
||||
'9eecb7a9f652bbf84f6437b49c70922b65b38bf3',
|
||||
'78.0.3896.6',
|
||||
'node_version':
|
||||
'v12.6.0',
|
||||
'v12.8.1',
|
||||
'nan_version':
|
||||
'2ee313aaca52e2b478965ac50eb5082520380d1b',
|
||||
|
||||
@@ -60,6 +61,8 @@ vars = {
|
||||
True,
|
||||
'checkout_oculus_sdk':
|
||||
False,
|
||||
'checkout_openxr':
|
||||
False,
|
||||
'build_with_chromium':
|
||||
True,
|
||||
'checkout_android':
|
||||
|
||||
@@ -1 +1 @@
|
||||
7.0.0-nightly.20190731
|
||||
7.0.0-beta.4
|
||||
11
appveyor.yml
11
appveyor.yml
@@ -60,7 +60,7 @@ build_script:
|
||||
- ps: $env:SCCACHE_PATH="$pwd\src\electron\external_binaries\sccache.exe"
|
||||
- ps: >-
|
||||
if ($env:GN_CONFIG -eq 'release') {
|
||||
$env:GCLIENT_EXTRA_ARGS="--custom-var=checkout_boto=True --custom-var=checkout_requests=True"
|
||||
$env:GCLIENT_EXTRA_ARGS="$env:GCLIENT_EXTRA_ARGS --custom-var=checkout_boto=True --custom-var=checkout_requests=True"
|
||||
} else {
|
||||
$env:NINJA_STATUS="[%r processes, %f/%t @ %o/s : %es] "
|
||||
}
|
||||
@@ -89,6 +89,10 @@ build_script:
|
||||
- appveyor PushArtifact out/Default/dist.zip
|
||||
- appveyor PushArtifact out/Default/chromedriver.zip
|
||||
- appveyor PushArtifact out/ffmpeg/ffmpeg.zip
|
||||
- 7z a node_headers.zip out\Default\gen\node_headers
|
||||
- appveyor PushArtifact node_headers.zip
|
||||
- appveyor PushArtifact out/Default/mksnapshot.zip
|
||||
- appveyor PushArtifact out/Default/electron.lib
|
||||
- ps: >-
|
||||
if ($env:GN_CONFIG -eq 'release') {
|
||||
# Needed for msdia140.dll on 64-bit windows
|
||||
@@ -105,7 +109,7 @@ test_script:
|
||||
# Workaround for https://github.com/appveyor/ci/issues/2420
|
||||
- set "PATH=%PATH%;C:\Program Files\Git\mingw64\libexec\git-core"
|
||||
- ps: >-
|
||||
if ((-Not (Test-Path Env:\ELECTRON_RELEASE)) -And ($env:GN_CONFIG -in "testing", "release")) {
|
||||
if ((-Not (Test-Path Env:\TEST_WOA)) -And (-Not (Test-Path Env:\ELECTRON_RELEASE)) -And ($env:GN_CONFIG -in "testing", "release")) {
|
||||
$env:RUN_TESTS="true"
|
||||
}
|
||||
- ps: >-
|
||||
@@ -133,4 +137,7 @@ deploy_script:
|
||||
Write-Output "Uploading Electron release distribution to github releases"
|
||||
& python script\release\uploaders\upload.py
|
||||
}
|
||||
} elseif (Test-Path Env:\TEST_WOA) {
|
||||
# node script/release/ci-release-build.js --job=electron-woa-testing --ci=VSTS --armTest --appveyorJobId=$env:APPVEYOR_JOB_ID $env:APPVEYOR_REPO_BRANCH
|
||||
echo "Eventually run tests on WOA hardware at this step"
|
||||
}
|
||||
|
||||
84
azure-pipelines-woa.yml
Normal file
84
azure-pipelines-woa.yml
Normal file
@@ -0,0 +1,84 @@
|
||||
steps:
|
||||
- task: CopyFiles@2
|
||||
displayName: 'Copy Files to: src\electron'
|
||||
inputs:
|
||||
TargetFolder: src\electron
|
||||
|
||||
- script: |
|
||||
cd src\electron
|
||||
npm install --verbose
|
||||
displayName: 'NPM install'
|
||||
|
||||
- powershell: |
|
||||
$localArtifactPath = "$pwd\dist.zip"
|
||||
$serverArtifactPath = "$env:APPVEYOR_URL/buildjobs/$env:APPVEYOR_JOB_ID/artifacts/dist.zip"
|
||||
Invoke-RestMethod -Method Get -Uri $serverArtifactPath -OutFile $localArtifactPath -Headers @{ "Authorization" = "Bearer $env:APPVEYOR_TOKEN" }
|
||||
& "${env:ProgramFiles(x86)}\7-Zip\7z.exe" x -osrc\out\Default -y $localArtifactPath
|
||||
displayName: 'Download and extract dist.zip for test'
|
||||
env:
|
||||
APPVEYOR_TOKEN: $(APPVEYOR_TOKEN)
|
||||
|
||||
- powershell: |
|
||||
$localArtifactPath = "$pwd\ffmpeg.zip"
|
||||
$serverArtifactPath = "$env:APPVEYOR_URL/buildjobs/$env:APPVEYOR_JOB_ID/artifacts/ffmpeg.zip"
|
||||
Invoke-RestMethod -Method Get -Uri $serverArtifactPath -OutFile $localArtifactPath -Headers @{ "Authorization" = "Bearer $env:APPVEYOR_TOKEN" }
|
||||
& "${env:ProgramFiles(x86)}\7-Zip\7z.exe" x -osrc\out\ffmpeg $localArtifactPath
|
||||
displayName: 'Download and extract ffmpeg.zip for test'
|
||||
env:
|
||||
APPVEYOR_TOKEN: $(APPVEYOR_TOKEN)
|
||||
|
||||
- powershell: |
|
||||
$localArtifactPath = "$pwd\src\out\Default\mksnapshot.zip"
|
||||
$serverArtifactPath = "$env:APPVEYOR_URL/buildjobs/$env:APPVEYOR_JOB_ID/artifacts/mksnapshot.zip"
|
||||
Invoke-RestMethod -Method Get -Uri $serverArtifactPath -OutFile $localArtifactPath -Headers @{ "Authorization" = "Bearer $env:APPVEYOR_TOKEN" }
|
||||
cd src\out\Default
|
||||
& "${env:ProgramFiles(x86)}\7-Zip\7z.exe" x -y mksnapshot.zip
|
||||
displayName: 'Download and unzip mksnapshot.zip for test'
|
||||
env:
|
||||
APPVEYOR_TOKEN: $(APPVEYOR_TOKEN)
|
||||
|
||||
- powershell: |
|
||||
$localArtifactPath = "$pwd\src\node_headers.zip"
|
||||
$serverArtifactPath = "$env:APPVEYOR_URL/buildjobs/$env:APPVEYOR_JOB_ID/artifacts/node_headers.zip"
|
||||
Invoke-RestMethod -Method Get -Uri $serverArtifactPath -OutFile $localArtifactPath -Headers @{ "Authorization" = "Bearer $env:APPVEYOR_TOKEN" }
|
||||
cd src
|
||||
& "${env:ProgramFiles(x86)}\7-Zip\7z.exe" x -y node_headers.zip
|
||||
displayName: 'Download node headers for test'
|
||||
env:
|
||||
APPVEYOR_TOKEN: $(APPVEYOR_TOKEN)
|
||||
|
||||
- powershell: |
|
||||
$localArtifactPath = "$pwd\src\out\Default\electron.lib"
|
||||
$serverArtifactPath = "$env:APPVEYOR_URL/buildjobs/$env:APPVEYOR_JOB_ID/artifacts/electron.lib"
|
||||
Invoke-RestMethod -Method Get -Uri $serverArtifactPath -OutFile $localArtifactPath -Headers @{ "Authorization" = "Bearer $env:APPVEYOR_TOKEN" }
|
||||
displayName: 'Download electron.lib for test'
|
||||
env:
|
||||
APPVEYOR_TOKEN: $(APPVEYOR_TOKEN)
|
||||
|
||||
- powershell: |
|
||||
New-Item src\out\Default\gen\node_headers\Release -Type directory
|
||||
Copy-Item -path src\out\Default\electron.lib -destination src\out\Default\gen\node_headers\Release\node.lib
|
||||
displayName: 'Setup node headers'
|
||||
|
||||
- script: |
|
||||
cd src
|
||||
set npm_config_nodedir=%cd%\out\Default\gen\node_headers
|
||||
set npm_config_arch=arm64
|
||||
cd electron
|
||||
node script/yarn test -- --ci --enable-logging --verbose
|
||||
displayName: 'Run Electron tests'
|
||||
env:
|
||||
ELECTRON_OUT_DIR: Default
|
||||
IGNORE_YARN_INSTALL_ERROR: 1
|
||||
|
||||
- script: |
|
||||
cd src
|
||||
echo "Verifying non proprietary ffmpeg"
|
||||
python electron\script\verify-ffmpeg.py --build-dir out\Default --source-root %cd% --ffmpeg-path out\ffmpeg
|
||||
displayName: 'Verify ffmpeg'
|
||||
|
||||
- script: |
|
||||
cd src
|
||||
echo "Verifying mksnapshot"
|
||||
python electron\script\verify-mksnapshot.py --build-dir out\Default --source-root %cd%
|
||||
displayName: 'Verify mksnapshot'
|
||||
@@ -18,6 +18,7 @@ buildflag_header("buildflags") {
|
||||
"ENABLE_TTS=$enable_tts",
|
||||
"ENABLE_COLOR_CHOOSER=$enable_color_chooser",
|
||||
"ENABLE_ELECTRON_EXTENSIONS=$enable_electron_extensions",
|
||||
"ENABLE_PICTURE_IN_PICTURE=$enable_picture_in_picture",
|
||||
"OVERRIDE_LOCATION_PROVIDER=$enable_fake_location_provider",
|
||||
]
|
||||
}
|
||||
|
||||
@@ -18,6 +18,8 @@ declare_args() {
|
||||
|
||||
enable_color_chooser = true
|
||||
|
||||
enable_picture_in_picture = true
|
||||
|
||||
# Provide a fake location provider for mocking
|
||||
# the geolocation responses. Disable it if you
|
||||
# need to test with chromium's location provider.
|
||||
|
||||
@@ -37,6 +37,14 @@ static_library("chrome") {
|
||||
"//chrome/browser/net/proxy_config_monitor.h",
|
||||
"//chrome/browser/net/proxy_service_factory.cc",
|
||||
"//chrome/browser/net/proxy_service_factory.h",
|
||||
"//chrome/browser/predictors/preconnect_manager.cc",
|
||||
"//chrome/browser/predictors/preconnect_manager.h",
|
||||
"//chrome/browser/predictors/proxy_lookup_client_impl.cc",
|
||||
"//chrome/browser/predictors/proxy_lookup_client_impl.h",
|
||||
"//chrome/browser/predictors/resolve_host_client_impl.cc",
|
||||
"//chrome/browser/predictors/resolve_host_client_impl.h",
|
||||
"//chrome/browser/printing/printing_service.cc",
|
||||
"//chrome/browser/printing/printing_service.h",
|
||||
"//chrome/browser/ssl/security_state_tab_helper.cc",
|
||||
"//chrome/browser/ssl/security_state_tab_helper.h",
|
||||
"//chrome/browser/ui/autofill/popup_view_common.cc",
|
||||
@@ -55,6 +63,7 @@ static_library("chrome") {
|
||||
"//content/public/browser",
|
||||
]
|
||||
deps = [
|
||||
"//chrome/browser:resource_prefetch_predictor_proto",
|
||||
"//components/feature_engagement:buildflags",
|
||||
]
|
||||
|
||||
@@ -160,16 +169,18 @@ static_library("chrome") {
|
||||
"//chrome/browser/printing/printing_message_filter.cc",
|
||||
"//chrome/browser/printing/printing_message_filter.h",
|
||||
]
|
||||
|
||||
public_deps += [
|
||||
"//chrome/services/printing:lib",
|
||||
"//components/printing/browser",
|
||||
"//components/printing/renderer",
|
||||
"//components/services/pdf_compositor/public/cpp:factory",
|
||||
"//components/services/pdf_compositor",
|
||||
"//components/services/pdf_compositor/public/cpp",
|
||||
"//components/services/pdf_compositor/public/mojom",
|
||||
]
|
||||
|
||||
deps += [
|
||||
"//components/printing/common",
|
||||
"//components/services/pdf_compositor",
|
||||
"//printing",
|
||||
]
|
||||
|
||||
@@ -182,4 +193,30 @@ static_library("chrome") {
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
if (enable_picture_in_picture) {
|
||||
sources += [
|
||||
"//chrome/browser/picture_in_picture/picture_in_picture_window_manager.cc",
|
||||
"//chrome/browser/picture_in_picture/picture_in_picture_window_manager.h",
|
||||
"//chrome/browser/ui/views/overlay/back_to_tab_image_button.cc",
|
||||
"//chrome/browser/ui/views/overlay/back_to_tab_image_button.h",
|
||||
"//chrome/browser/ui/views/overlay/close_image_button.cc",
|
||||
"//chrome/browser/ui/views/overlay/close_image_button.h",
|
||||
"//chrome/browser/ui/views/overlay/overlay_window_views.cc",
|
||||
"//chrome/browser/ui/views/overlay/overlay_window_views.h",
|
||||
"//chrome/browser/ui/views/overlay/playback_image_button.cc",
|
||||
"//chrome/browser/ui/views/overlay/playback_image_button.h",
|
||||
"//chrome/browser/ui/views/overlay/resize_handle_button.cc",
|
||||
"//chrome/browser/ui/views/overlay/resize_handle_button.h",
|
||||
"//chrome/browser/ui/views/overlay/skip_ad_label_button.cc",
|
||||
"//chrome/browser/ui/views/overlay/skip_ad_label_button.h",
|
||||
"//chrome/browser/ui/views/overlay/track_image_button.cc",
|
||||
"//chrome/browser/ui/views/overlay/track_image_button.h",
|
||||
]
|
||||
|
||||
deps += [
|
||||
"//chrome/app/vector_icons",
|
||||
"//components/vector_icons:vector_icons",
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@ In most cases, you should do everything in the `ready` event handler.
|
||||
|
||||
Returns:
|
||||
|
||||
* `launchInfo` Object _macOS_
|
||||
* `launchInfo` unknown _macOS_
|
||||
|
||||
Emitted when Electron has finished initializing. On macOS, `launchInfo` holds
|
||||
the `userInfo` of the `NSUserNotification` that was used to open the application,
|
||||
@@ -146,7 +146,7 @@ Returns:
|
||||
* `event` Event
|
||||
* `type` String - A string identifying the activity. Maps to
|
||||
[`NSUserActivity.activityType`][activity-type].
|
||||
* `userInfo` Object - Contains app-specific state stored by the activity on
|
||||
* `userInfo` unknown - Contains app-specific state stored by the activity on
|
||||
another device.
|
||||
|
||||
Emitted during [Handoff][handoff] when an activity from a different device wants
|
||||
@@ -189,7 +189,7 @@ Returns:
|
||||
* `event` Event
|
||||
* `type` String - A string identifying the activity. Maps to
|
||||
[`NSUserActivity.activityType`][activity-type].
|
||||
* `userInfo` Object - Contains app-specific state stored by the activity.
|
||||
* `userInfo` unknown - Contains app-specific state stored by the activity.
|
||||
|
||||
Emitted during [Handoff][handoff] after an activity from this device was successfully
|
||||
resumed on another one.
|
||||
@@ -201,7 +201,7 @@ Returns:
|
||||
* `event` Event
|
||||
* `type` String - A string identifying the activity. Maps to
|
||||
[`NSUserActivity.activityType`][activity-type].
|
||||
* `userInfo` Object - Contains app-specific state stored by the activity.
|
||||
* `userInfo` unknown - Contains app-specific state stored by the activity.
|
||||
|
||||
Emitted when [Handoff][handoff] is about to be resumed on another device. If you need to update the state to be transferred, you should call `event.preventDefault()` immediately, construct a new `userInfo` dictionary and call `app.updateCurrentActiviy()` in a timely manner. Otherwise, the operation will fail and `continue-activity-error` will be called.
|
||||
|
||||
@@ -582,7 +582,7 @@ them.
|
||||
|
||||
Sets or creates a directory your app's logs which can then be manipulated with `app.getPath()` or `app.setPath(pathName, newPath)`.
|
||||
|
||||
Calling `app.setAppLogsPath()` without a `path` parameter will result in this directory being set to `/Library/Logs/YourAppName` on _macOS_, and inside the `userData` directory on _Linux_ and _Windows_.
|
||||
Calling `app.setAppLogsPath()` without a `path` parameter will result in this directory being set to `~/Library/Logs/YourAppName` on _macOS_, and inside the `userData` directory on _Linux_ and _Windows_.
|
||||
|
||||
### `app.getAppPath()`
|
||||
|
||||
@@ -614,6 +614,8 @@ Returns `String` - The current application directory.
|
||||
Returns `String` - A path to a special directory or file associated with `name`. On
|
||||
failure, an `Error` is thrown.
|
||||
|
||||
If `app.getPath('logs')` is called without called `app.setAppLogsPath()` being called first, a default log directory will be created equivalent to calling `app.setAppLogsPath()` without a `path` parameter.
|
||||
|
||||
### `app.getFileIcon(path[, options])`
|
||||
|
||||
* `path` String
|
||||
@@ -949,7 +951,7 @@ allow multiple instances of the application to once again run side by side.
|
||||
|
||||
* `type` String - Uniquely identifies the activity. Maps to
|
||||
[`NSUserActivity.activityType`][activity-type].
|
||||
* `userInfo` Object - App-specific state to store for use by another device.
|
||||
* `userInfo` any - App-specific state to store for use by another device.
|
||||
* `webpageURL` String (optional) - The webpage to load in a browser if no suitable app is
|
||||
installed on the resuming device. The scheme must be `http` or `https`.
|
||||
|
||||
@@ -972,7 +974,7 @@ Marks the current [Handoff][handoff] user activity as inactive without invalidat
|
||||
|
||||
* `type` String - Uniquely identifies the activity. Maps to
|
||||
[`NSUserActivity.activityType`][activity-type].
|
||||
* `userInfo` Object - App-specific state to store for use by another device.
|
||||
* `userInfo` any - App-specific state to store for use by another device.
|
||||
|
||||
Updates the current activity if its type matches `type`, merging the entries from
|
||||
`userInfo` into its current `userInfo` dictionary.
|
||||
|
||||
@@ -103,7 +103,7 @@ The `autoUpdater` object has the following methods:
|
||||
|
||||
* `options` Object
|
||||
* `url` String
|
||||
* `headers` Object (optional) _macOS_ - HTTP request headers.
|
||||
* `headers` Record<String, String> (optional) _macOS_ - HTTP request headers.
|
||||
* `serverType` String (optional) _macOS_ - Either `json` or `default`, see the [Squirrel.Mac][squirrel-mac]
|
||||
README for more information.
|
||||
|
||||
|
||||
@@ -691,7 +691,7 @@ is emitted.
|
||||
|
||||
#### `BrowserWindow.getExtensions()`
|
||||
|
||||
Returns `Object` - The keys are the extension names and each value is
|
||||
Returns `Record<String, ExtensionInfo>` - The keys are the extension names and each value is
|
||||
an Object containing `name` and `version` properties.
|
||||
|
||||
**Note:** This API cannot be called before the `ready` event of the `app` module
|
||||
@@ -724,7 +724,7 @@ is emitted.
|
||||
|
||||
#### `BrowserWindow.getDevToolsExtensions()`
|
||||
|
||||
Returns `Object` - The keys are the extension names and each value is
|
||||
Returns `Record<string, ExtensionInfo>` - The keys are the extension names and each value is
|
||||
an Object containing `name` and `version` properties.
|
||||
|
||||
To check if a DevTools extension is installed you can run the following:
|
||||
@@ -1381,7 +1381,7 @@ win.loadURL('http://localhost:8000/post', {
|
||||
|
||||
* `filePath` String
|
||||
* `options` Object (optional)
|
||||
* `query` Object (optional) - Passed to `url.format()`.
|
||||
* `query` Record<String, String> (optional) - Passed to `url.format()`.
|
||||
* `search` String (optional) - Passed to `url.format()`.
|
||||
* `hash` String (optional) - Passed to `url.format()`.
|
||||
|
||||
@@ -1437,29 +1437,27 @@ screen readers
|
||||
Sets a 16 x 16 pixel overlay onto the current taskbar icon, usually used to
|
||||
convey some sort of application status or to passively notify the user.
|
||||
|
||||
#### `win.setHasShadow(hasShadow)` _macOS_
|
||||
#### `win.setHasShadow(hasShadow)`
|
||||
|
||||
* `hasShadow` Boolean
|
||||
|
||||
Sets whether the window should have a shadow. On Windows and Linux does
|
||||
nothing.
|
||||
Sets whether the window should have a shadow.
|
||||
|
||||
#### `win.hasShadow()` _macOS_
|
||||
#### `win.hasShadow()`
|
||||
|
||||
Returns `Boolean` - Whether the window has a shadow.
|
||||
|
||||
On Windows and Linux always returns
|
||||
`true`.
|
||||
|
||||
#### `win.setOpacity(opacity)` _Windows_ _macOS_
|
||||
|
||||
* `opacity` Number - between 0.0 (fully transparent) and 1.0 (fully opaque)
|
||||
|
||||
Sets the opacity of the window. On Linux does nothing.
|
||||
Sets the opacity of the window. On Linux, does nothing. Out of bound number
|
||||
values are clamped to the [0, 1] range.
|
||||
|
||||
#### `win.getOpacity()` _Windows_ _macOS_
|
||||
#### `win.getOpacity()`
|
||||
|
||||
Returns `Number` - between 0.0 (fully transparent) and 1.0 (fully opaque)
|
||||
Returns `Number` - between 0.0 (fully transparent) and 1.0 (fully opaque). On
|
||||
Linux, always returns 1.
|
||||
|
||||
#### `win.setShape(rects)` _Windows_ _Linux_ _Experimental_
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ following properties:
|
||||
method.
|
||||
* `url` String (optional) - The request URL. Must be provided in the absolute
|
||||
form with the protocol scheme specified as http or https.
|
||||
* `session` Object (optional) - The [`Session`](session.md) instance with
|
||||
* `session` Session (optional) - The [`Session`](session.md) instance with
|
||||
which the request is associated.
|
||||
* `partition` String (optional) - The name of the [`partition`](session.md)
|
||||
with which the request is associated. Defaults to the empty string. The
|
||||
@@ -134,7 +134,7 @@ Returns:
|
||||
* `statusCode` Integer
|
||||
* `method` String
|
||||
* `redirectUrl` String
|
||||
* `responseHeaders` Object
|
||||
* `responseHeaders` Record<String, String[]>
|
||||
|
||||
Emitted when there is redirection and the mode is `manual`. Calling
|
||||
[`request.followRedirect`](#requestfollowredirect) will continue with the redirection.
|
||||
@@ -158,7 +158,7 @@ internally buffered inside Electron process memory.
|
||||
#### `request.setHeader(name, value)`
|
||||
|
||||
* `name` String - An extra HTTP header name.
|
||||
* `value` Object - An extra HTTP header value.
|
||||
* `value` String - An extra HTTP header value.
|
||||
|
||||
Adds an extra HTTP header. The header name will be issued as-is without
|
||||
lowercasing. It can be called only before first write. Calling this method after
|
||||
@@ -169,7 +169,7 @@ the first write will throw an error. If the passed value is not a `String`, its
|
||||
|
||||
* `name` String - Specify an extra header name.
|
||||
|
||||
Returns `Object` - The value of a previously set extra header name.
|
||||
Returns `String` - The value of a previously set extra header name.
|
||||
|
||||
#### `request.removeHeader(name)`
|
||||
|
||||
|
||||
@@ -74,6 +74,9 @@ will be returned in the promise.
|
||||
|
||||
Returns `Promise<Object>` - Resolves with an object containing the `value` and `percentage` of trace buffer maximum usage
|
||||
|
||||
* `value` Number
|
||||
* `percentage` Number
|
||||
|
||||
Get the maximum usage across processes of trace buffer as a percentage of the
|
||||
full state.
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@ The `crashReporter` module has the following methods:
|
||||
* `productName` String (optional) - Defaults to `app.name`.
|
||||
* `uploadToServer` Boolean (optional) - Whether crash reports should be sent to the server. Default is `true`.
|
||||
* `ignoreSystemCrashHandler` Boolean (optional) - Default is `false`.
|
||||
* `extra` Object (optional) - An object you can define that will be sent along with the
|
||||
* `extra` Record<String, String> (optional) - An object you can define that will be sent along with the
|
||||
report. Only string properties are sent correctly. Nested objects are not
|
||||
supported. When using Windows, the property names and values must be fewer than 64 characters.
|
||||
* `crashesDirectory` String (optional) - Directory to store the crash reports temporarily (only used when the crash reporter is started via `process.crashReporter.start`).
|
||||
|
||||
@@ -50,7 +50,7 @@ Returns:
|
||||
|
||||
* `event` Event
|
||||
* `method` String - Method name.
|
||||
* `params` Object - Event parameters defined by the 'parameters'
|
||||
* `params` unknown - Event parameters defined by the 'parameters'
|
||||
attribute in the remote debugging protocol.
|
||||
|
||||
Emitted whenever the debugging target issues an instrumentation event.
|
||||
@@ -78,7 +78,7 @@ Detaches the debugger from the `webContents`.
|
||||
|
||||
* `method` String - Method name, should be one of the methods defined by the
|
||||
[remote debugging protocol][rdp].
|
||||
* `commandParams` Object (optional) - JSON object with request parameters.
|
||||
* `commandParams` any (optional) - JSON object with request parameters.
|
||||
|
||||
Returns `Promise<any>` - A promise that resolves with the response defined by
|
||||
the 'returns' attribute of the command description in the remote debugging protocol
|
||||
|
||||
@@ -52,6 +52,8 @@ The `dialog` module has the following methods:
|
||||
boxes.
|
||||
* `securityScopedBookmarks` Boolean (optional) _macOS_ _mas_ - Create [security scoped bookmarks](https://developer.apple.com/library/content/documentation/Security/Conceptual/AppSandboxDesignGuide/AppSandboxInDepth/AppSandboxInDepth.html#//apple_ref/doc/uid/TP40011183-CH3-SW16) when packaged for the Mac App Store.
|
||||
|
||||
Returns `String[] | undefined`, the file paths chosen by the user; if the dialog is cancelled it returns `undefined`.
|
||||
|
||||
The `browserWindow` argument allows the dialog to attach itself to a parent window, making it modal.
|
||||
|
||||
The `filters` specifies an array of file types that can be displayed or
|
||||
@@ -227,7 +229,7 @@ expanding and collapsing the dialog.
|
||||
include a checkbox with the given label.
|
||||
* `checkboxChecked` Boolean (optional) - Initial checked state of the
|
||||
checkbox. `false` by default.
|
||||
* `icon` [NativeImage](native-image.md) (optional)
|
||||
* `icon` ([NativeImage](native-image.md) | String) (optional)
|
||||
* `cancelId` Integer (optional) - The index of the button to be used to cancel the dialog, via
|
||||
the `Esc` key. By default this is assigned to the first button with "cancel" or "no" as the
|
||||
label. If no such labeled buttons exist and this option is not set, `0` will be used as the
|
||||
|
||||
@@ -18,6 +18,8 @@ app.dock.bounce()
|
||||
* `type` String (optional) - Can be `critical` or `informational`. The default is
|
||||
`informational`
|
||||
|
||||
Returns `Integer` - an ID representing the request.
|
||||
|
||||
When `critical` is passed, the dock icon will bounce until either the
|
||||
application becomes active or the request is canceled.
|
||||
|
||||
@@ -25,7 +27,7 @@ When `informational` is passed, the dock icon will bounce for one second.
|
||||
However, the request remains active until either the application becomes active
|
||||
or the request is canceled.
|
||||
|
||||
Returns `Integer` an ID representing the request.
|
||||
**Nota Bene:** This method can only be used while the app is not focused; when the app is focused it will return -1.
|
||||
|
||||
#### `dock.cancelBounce(id)` _macOS_
|
||||
|
||||
|
||||
@@ -51,7 +51,7 @@ A `String` representing the HTTP status message.
|
||||
|
||||
#### `response.headers`
|
||||
|
||||
An `Object` representing the response HTTP headers. The `headers` object is
|
||||
An `Record<string, string[]>` representing the response HTTP headers. The `headers` object is
|
||||
formatted as follows:
|
||||
|
||||
* All header names are lowercased.
|
||||
|
||||
@@ -90,7 +90,7 @@ Removes listeners of the specified `channel`.
|
||||
### `ipcMain.handle(channel, listener)`
|
||||
|
||||
* `channel` String
|
||||
* `listener` Function<Promise> | Function<any>
|
||||
* `listener` Function<Promise<void> | any>
|
||||
* `event` IpcMainInvokeEvent
|
||||
* `...args` any[]
|
||||
|
||||
@@ -122,7 +122,7 @@ WebContents is the source of the invoke request.
|
||||
### `ipcMain.handleOnce(channel, listener)`
|
||||
|
||||
* `channel` String
|
||||
* `listener` Function<Promise> | Function<any>
|
||||
* `listener` Function<Promise<void> | any>
|
||||
* `event` IpcMainInvokeEvent
|
||||
* `...args` any[]
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ See [`Menu`](menu.md) for examples.
|
||||
* `menuItem` MenuItem
|
||||
* `browserWindow` [BrowserWindow](browser-window.md)
|
||||
* `event` [KeyboardEvent](structures/keyboard-event.md)
|
||||
* `role` String (optional) - Can be `undo`, `redo`, `cut`, `copy`, `paste`, `pasteandmatchstyle`, `delete`, `selectall`, `reload`, `forcereload`, `toggledevtools`, `resetzoom`, `zoomin`, `zoomout`, `togglefullscreen`, `window`, `minimize`, `close`, `help`, `about`, `services`, `hide`, `hideothers`, `unhide`, `quit`, `startspeaking`, `stopspeaking`, `close`, `minimize`, `zoom`, `front`, `appMenu`, `fileMenu`, `editMenu`, `viewMenu` or `windowMenu` - Define the action of the menu item, when specified the
|
||||
* `role` String (optional) - Can be `undo`, `redo`, `cut`, `copy`, `paste`, `pasteAndMatchStyle`, `delete`, `selectAll`, `reload`, `forceReload`, `toggleDevTools`, `resetZoom`, `zoomIn`, `zoomOut`, `togglefullscreen`, `window`, `minimize`, `close`, `help`, `about`, `services`, `hide`, `hideOthers`, `unhide`, `quit`, `startSpeaking`, `stopSpeaking`, `close`, `minimize`, `zoom`, `front`, `appMenu`, `fileMenu`, `editMenu`, `viewMenu`, `recentDocuments`, `toggleTabBar`, `selectNextTab`, `selectPreviousTab`, `mergeAllWindows`, `clearRecentDocuments`, `moveTabToNewWindow` or `windowMenu` - Define the action of the menu item, when specified the
|
||||
`click` property will be ignored. See [roles](#roles).
|
||||
* `type` String (optional) - Can be `normal`, `separator`, `submenu`, `checkbox` or
|
||||
`radio`.
|
||||
@@ -82,7 +82,7 @@ The `role` property can have following values:
|
||||
* `reload` - Reload the current window.
|
||||
* `forceReload` - Reload the current window ignoring the cache.
|
||||
* `toggleDevTools` - Toggle developer tools in the current window.
|
||||
* `toggleFullScreen` - Toggle full screen mode on the current window.
|
||||
* `togglefullscreen` - Toggle full screen mode on the current window.
|
||||
* `resetZoom` - Reset the focused page's zoom level to the original size.
|
||||
* `zoomIn` - Zoom in the focused page by 10%.
|
||||
* `zoomOut` - Zoom out the focused page by 10%.
|
||||
@@ -152,7 +152,7 @@ A `String` indicating the type of the item. Can be `normal`, `separator`, `subme
|
||||
|
||||
#### `menuItem.role`
|
||||
|
||||
A `String` (optional) indicating the item's role, if set. Can be `undo`, `redo`, `cut`, `copy`, `paste`, `pasteandmatchstyle`, `delete`, `selectall`, `reload`, `forcereload`, `toggledevtools`, `resetzoom`, `zoomin`, `zoomout`, `togglefullscreen`, `window`, `minimize`, `close`, `help`, `about`, `services`, `hide`, `hideothers`, `unhide`, `quit`, `startspeaking`, `stopspeaking`, `close`, `minimize`, `zoom`, `front`, `appMenu`, `fileMenu`, `editMenu`, `viewMenu` or `windowMenu`
|
||||
A `String` (optional) indicating the item's role, if set. Can be `undo`, `redo`, `cut`, `copy`, `paste`, `pasteAndMatchStyle`, `delete`, `selectAll`, `reload`, `forceReload`, `toggleDevTools`, `resetZoom`, `zoomIn`, `zoomOut`, `togglefullscreen`, `window`, `minimize`, `close`, `help`, `about`, `services`, `hide`, `hideOthers`, `unhide`, `quit`, `startSpeaking`, `stopSpeaking`, `close`, `minimize`, `zoom`, `front`, `appMenu`, `fileMenu`, `editMenu`, `viewMenu`, `recentDocuments`, `toggleTabBar`, `selectNextTab`, `selectPreviousTab`, `mergeAllWindows`, `clearRecentDocuments`, `moveTabToNewWindow` or `windowMenu`
|
||||
|
||||
#### `menuItem.accelerator`
|
||||
|
||||
|
||||
35
docs/api/native-theme.md
Normal file
35
docs/api/native-theme.md
Normal file
@@ -0,0 +1,35 @@
|
||||
# nativeTheme
|
||||
|
||||
> Read and respond to changes in Chromium's native color theme.
|
||||
|
||||
Process: [Main](../glossary.md#main-process), [Renderer](../glossary.md#renderer-process)
|
||||
|
||||
## Events
|
||||
|
||||
The `nativeTheme` module emits the following events:
|
||||
|
||||
### Event: 'updated'
|
||||
|
||||
Emitted when something in the underlying NativeTheme has changed. This normally
|
||||
means that either the value of `shouldUseDarkColors`,
|
||||
`shouldUseHighContrastColors` or `shouldUseInvertedColorScheme` has changed.
|
||||
You will have to check them to determine which one has changed.
|
||||
|
||||
## Properties
|
||||
|
||||
The `nativeTheme` module has the following properties:
|
||||
|
||||
### `nativeTheme.shouldUseDarkColors` _Readonly_
|
||||
|
||||
A `Boolean` for if the OS / Chromium currently has a dark mode enabled or is
|
||||
being instructed to show a dark-style UI.
|
||||
|
||||
### `nativeTheme.shouldUseHighContrastColors` _macOS_ _Windows_ _Readonly_
|
||||
|
||||
A `Boolean` for if the OS / Chromium currently has high-contrast mode enabled
|
||||
or is being instructed to show a high-constrast UI.
|
||||
|
||||
### `nativeTheme.shouldUseInvertedColorScheme` _macOS_ _Windows_ _Readonly_
|
||||
|
||||
A `Boolean` for if the OS / Chromium currently has an inverted color scheme
|
||||
or is being instructed to use an inverted color scheme.
|
||||
@@ -54,7 +54,7 @@ The `net` module has the following methods:
|
||||
|
||||
### `net.request(options)`
|
||||
|
||||
* `options` (Object | String) - The `ClientRequest` constructor options.
|
||||
* `options` (ClientRequestConstructorOptions | String) - The `ClientRequest` constructor options.
|
||||
|
||||
Returns [`ClientRequest`](./client-request.md)
|
||||
|
||||
|
||||
@@ -228,7 +228,7 @@ should be called with either a `String` or an object that has the `data`,
|
||||
* `redirectRequest` Object
|
||||
* `url` String
|
||||
* `method` String (optional)
|
||||
* `session` Object (optional)
|
||||
* `session` Session | null (optional)
|
||||
* `uploadData` [ProtocolResponseUploadData](structures/protocol-response-upload-data.md) (optional)
|
||||
* `completion` Function (optional)
|
||||
* `error` Error
|
||||
@@ -388,7 +388,7 @@ which sends a `Buffer` as a response.
|
||||
* `redirectRequest` Object
|
||||
* `url` String
|
||||
* `method` String (optional)
|
||||
* `session` Object | null (optional)
|
||||
* `session` Session | null (optional)
|
||||
* `uploadData` Object (optional)
|
||||
* `contentType` String - MIME type of the content.
|
||||
* `data` String - Content to be sent.
|
||||
|
||||
@@ -14,7 +14,7 @@ property, so writing `let { screen } = require('electron')` will not work.
|
||||
|
||||
An example of creating a window that fills the whole screen:
|
||||
|
||||
```javascript
|
||||
```javascript fiddle='docs/fiddles/screen/fit-screen'
|
||||
const { app, BrowserWindow, screen } = require('electron')
|
||||
|
||||
let win
|
||||
|
||||
@@ -91,6 +91,20 @@ session.defaultSession.on('will-download', (event, item, webContents) => {
|
||||
})
|
||||
```
|
||||
|
||||
#### Event: 'preconnect' _Experimental_
|
||||
|
||||
Returns:
|
||||
|
||||
* `event` Event
|
||||
* `preconnectUrl` String - The URL being requested for preconnection by the
|
||||
renderer.
|
||||
* `allowCredentials` Boolean - True if the renderer is requesting that the
|
||||
connection include credentials (see the
|
||||
[spec](https://w3c.github.io/resource-hints/#preconnect) for more details.)
|
||||
|
||||
Emitted when a render process requests preconnection to a URL, generally due to
|
||||
a [resource hint](https://w3c.github.io/resource-hints/).
|
||||
|
||||
### Instance Methods
|
||||
|
||||
The following methods are available on instances of `Session`:
|
||||
@@ -238,6 +252,14 @@ window.webContents.session.enableNetworkEmulation({
|
||||
window.webContents.session.enableNetworkEmulation({ offline: true })
|
||||
```
|
||||
|
||||
#### `ses.preconnect(options)` _Experimental_
|
||||
|
||||
* `options` Object
|
||||
* `url` String - URL for preconnect. Only the origin is relevant for opening the socket.
|
||||
* `numSockets` Number (optional) - number of sockets to preconnect. Must be between 1 and 6. Defaults to 1.
|
||||
|
||||
Preconnects the given number of sockets to an origin.
|
||||
|
||||
#### `ses.disableNetworkEmulation()`
|
||||
|
||||
Disables any network emulation already active for the `session`. Resets to
|
||||
|
||||
4
docs/api/structures/extension-info.md
Normal file
4
docs/api/structures/extension-info.md
Normal file
@@ -0,0 +1,4 @@
|
||||
# ExtensionInfo Object
|
||||
|
||||
* `name` String
|
||||
* `version` String
|
||||
@@ -19,7 +19,7 @@
|
||||
include in the trace. If not specified, trace all processes.
|
||||
* `histogram_names` String[] (optional) - a list of [histogram][] names to report
|
||||
with the trace.
|
||||
* `memory_dump_config` Object (optional) - if the
|
||||
* `memory_dump_config` Record<String, any> (optional) - if the
|
||||
`disabled-by-default-memory-infra` category is enabled, this contains
|
||||
optional additional configuration for data collection. See the [Chromium
|
||||
memory-infra docs][memory-infra docs] for more information.
|
||||
|
||||
@@ -27,28 +27,34 @@ Returns:
|
||||
|
||||
* `event` Event
|
||||
|
||||
### Event: 'inverted-color-scheme-changed' _Windows_
|
||||
### Event: 'inverted-color-scheme-changed' _Windows_ _Deprecated_
|
||||
|
||||
Returns:
|
||||
|
||||
* `event` Event
|
||||
* `invertedColorScheme` Boolean - `true` if an inverted color scheme (a high contrast color scheme with light text and dark backgrounds) is being used, `false` otherwise.
|
||||
|
||||
### Event: 'high-contrast-color-scheme-changed' _Windows_
|
||||
**Deprecated:** Should use the new [`updated`](native-theme.md#event-updated) event on the `nativeTheme` module.
|
||||
|
||||
### Event: 'high-contrast-color-scheme-changed' _Windows_ _Deprecated_
|
||||
|
||||
Returns:
|
||||
|
||||
* `event` Event
|
||||
* `highContrastColorScheme` Boolean - `true` if a high contrast theme is being used, `false` otherwise.
|
||||
|
||||
**Deprecated:** Should use the new [`updated`](native-theme.md#event-updated) event on the `nativeTheme` module.
|
||||
|
||||
## Methods
|
||||
|
||||
### `systemPreferences.isDarkMode()` _macOS_ _Windows_
|
||||
### `systemPreferences.isDarkMode()` _macOS_ _Windows_ _Deprecated_
|
||||
|
||||
Returns `Boolean` - Whether the system is in Dark Mode.
|
||||
|
||||
**Note:** On macOS 10.15 Catalina in order for this API to return the correct value when in the "automatic" dark mode setting you must either have `NSRequiresAquaSystemAppearance=false` in your `Info.plist` or be on Electron `>=7.0.0`. See the [dark mode guide](../tutorial/mojave-dark-mode-guide.md) for more information.
|
||||
|
||||
**Deprecated:** Should use the new [`nativeTheme.shouldUseDarkColors`](native-theme.md#nativethemeshouldusedarkcolors-readonly) API.
|
||||
|
||||
### `systemPreferences.isSwipeTrackingFromScrollEventsEnabled()` _macOS_
|
||||
|
||||
Returns `Boolean` - Whether the Swipe between pages setting is on.
|
||||
@@ -56,7 +62,7 @@ Returns `Boolean` - Whether the Swipe between pages setting is on.
|
||||
### `systemPreferences.postNotification(event, userInfo[, deliverImmediately])` _macOS_
|
||||
|
||||
* `event` String
|
||||
* `userInfo` Object
|
||||
* `userInfo` Record<String, any>
|
||||
* `deliverImmediately` Boolean (optional) - `true` to post notifications immediately even when the subscribing app is inactive.
|
||||
|
||||
Posts `event` as native notifications of macOS. The `userInfo` is an Object
|
||||
@@ -65,7 +71,7 @@ that contains the user information dictionary sent along with the notification.
|
||||
### `systemPreferences.postLocalNotification(event, userInfo)` _macOS_
|
||||
|
||||
* `event` String
|
||||
* `userInfo` Object
|
||||
* `userInfo` Record<String, any>
|
||||
|
||||
Posts `event` as native notifications of macOS. The `userInfo` is an Object
|
||||
that contains the user information dictionary sent along with the notification.
|
||||
@@ -73,7 +79,7 @@ that contains the user information dictionary sent along with the notification.
|
||||
### `systemPreferences.postWorkspaceNotification(event, userInfo)` _macOS_
|
||||
|
||||
* `event` String
|
||||
* `userInfo` Object
|
||||
* `userInfo` Record<String, any>
|
||||
|
||||
Posts `event` as native notifications of macOS. The `userInfo` is an Object
|
||||
that contains the user information dictionary sent along with the notification.
|
||||
@@ -83,7 +89,7 @@ that contains the user information dictionary sent along with the notification.
|
||||
* `event` String
|
||||
* `callback` Function
|
||||
* `event` String
|
||||
* `userInfo` Object
|
||||
* `userInfo` Record<String, unknown>
|
||||
* `object` String
|
||||
|
||||
Returns `Number` - The ID of this subscription
|
||||
@@ -110,7 +116,7 @@ example values of `event` are:
|
||||
* `event` String
|
||||
* `callback` Function
|
||||
* `event` String
|
||||
* `userInfo` Object
|
||||
* `userInfo` Record<String, unknown>
|
||||
* `object` String
|
||||
|
||||
Returns `Number` - The ID of this subscription
|
||||
@@ -123,7 +129,7 @@ This is necessary for events such as `NSUserDefaultsDidChangeNotification`.
|
||||
* `event` String
|
||||
* `callback` Function
|
||||
* `event` String
|
||||
* `userInfo` Object
|
||||
* `userInfo` Record<String, unknown>
|
||||
* `object` String
|
||||
|
||||
Same as `subscribeNotification`, but uses `NSWorkspace.sharedWorkspace.notificationCenter`.
|
||||
@@ -149,7 +155,7 @@ Same as `unsubscribeNotification`, but removes the subscriber from `NSWorkspace.
|
||||
|
||||
### `systemPreferences.registerDefaults(defaults)` _macOS_
|
||||
|
||||
* `defaults` Object - a dictionary of (`key: value`) user defaults
|
||||
* `defaults` Record<String, String | Boolean | Number> - a dictionary of (`key: value`) user defaults
|
||||
|
||||
Add the specified defaults to your application's `NSUserDefaults`.
|
||||
|
||||
@@ -342,14 +348,18 @@ Returns `String` - The standard system color formatted as `#RRGGBBAA`.
|
||||
|
||||
Returns one of several standard system colors that automatically adapt to vibrancy and changes in accessibility settings like 'Increase contrast' and 'Reduce transparency'. See [Apple Documentation](https://developer.apple.com/design/human-interface-guidelines/macos/visual-design/color#system-colors) for more details.
|
||||
|
||||
### `systemPreferences.isInvertedColorScheme()` _Windows_
|
||||
### `systemPreferences.isInvertedColorScheme()` _Windows_ _Deprecated_
|
||||
|
||||
Returns `Boolean` - `true` if an inverted color scheme (a high contrast color scheme with light text and dark backgrounds) is active, `false` otherwise.
|
||||
|
||||
### `systemPreferences.isHighContrastColorScheme()` _macOS_ _Windows_
|
||||
**Deprecated:** Should use the new [`nativeTheme.shouldUseInvertedColorScheme`](native-theme.md#nativethemeshoulduseinvertedcolorscheme-macos-windows-readonly) API.
|
||||
|
||||
### `systemPreferences.isHighContrastColorScheme()` _macOS_ _Windows_ _Deprecated_
|
||||
|
||||
Returns `Boolean` - `true` if a high contrast theme is active, `false` otherwise.
|
||||
|
||||
**Depreacted:** Should use the new [`nativeTheme.shouldUseHighContrastColors`](native-theme.md#nativethemeshouldusehighcontrastcolors-macos-windows-readonly) API.
|
||||
|
||||
### `systemPreferences.getEffectiveAppearance()` _macOS_
|
||||
|
||||
Returns `String` - Can be `dark`, `light` or `unknown`.
|
||||
@@ -365,7 +375,9 @@ using `electron-packager` or `electron-forge` just set the `enableDarwinDarkMode
|
||||
packager option to `true`. See the [Electron Packager API](https://github.com/electron/electron-packager/blob/master/docs/api.md#darwindarkmodesupport)
|
||||
for more details.
|
||||
|
||||
### `systemPreferences.getAppLevelAppearance()` _macOS_
|
||||
**[Deprecated](modernization/property-updates.md)**
|
||||
|
||||
### `systemPreferences.getAppLevelAppearance()` _macOS_ _Deprecated_
|
||||
|
||||
Returns `String` | `null` - Can be `dark`, `light` or `unknown`.
|
||||
|
||||
@@ -375,7 +387,7 @@ You can use the `setAppLevelAppearance` API to set this value.
|
||||
|
||||
**[Deprecated](modernization/property-updates.md)**
|
||||
|
||||
### `systemPreferences.setAppLevelAppearance(appearance)` _macOS_
|
||||
### `systemPreferences.setAppLevelAppearance(appearance)` _macOS_ _Deprecated_
|
||||
|
||||
* `appearance` String | null - Can be `dark` or `light`
|
||||
|
||||
@@ -450,10 +462,25 @@ Returns an object with system animation settings.
|
||||
|
||||
### `systemPreferences.appLevelAppearance` _macOS_
|
||||
|
||||
A `String` property that determines the macOS appearance setting for
|
||||
A `String` property that can be `dark`, `light` or `unknown`. It determines the macOS appearance setting for
|
||||
your application. This maps to values in: [NSApplication.appearance](https://developer.apple.com/documentation/appkit/nsapplication/2967170-appearance?language=objc). Setting this will override the
|
||||
system default as well as the value of `getEffectiveAppearance`.
|
||||
|
||||
Possible values that can be set are `dark` and `light`, and possible return values are `dark`, `light`, and `unknown`.
|
||||
|
||||
This property is only available on macOS 10.14 Mojave or newer.
|
||||
|
||||
### `systemPreferences.effectiveAppearance` _macOS_ _Readonly_
|
||||
|
||||
A `String` property that can be `dark`, `light` or `unknown`.
|
||||
|
||||
Returns the macOS appearance setting that is currently applied to your application,
|
||||
maps to [NSApplication.effectiveAppearance](https://developer.apple.com/documentation/appkit/nsapplication/2967171-effectiveappearance?language=objc)
|
||||
|
||||
Please note that until Electron is built targeting the 10.14 SDK, your application's
|
||||
`effectiveAppearance` will default to 'light' and won't inherit the OS preference. In
|
||||
the interim in order for your application to inherit the OS preference you must set the
|
||||
`NSRequiresAquaSystemAppearance` key in your apps `Info.plist` to `false`. If you are
|
||||
using `electron-packager` or `electron-forge` just set the `enableDarwinDarkMode`
|
||||
packager option to `true`. See the [Electron Packager API](https://github.com/electron/electron-packager/blob/master/docs/api.md#darwindarkmodesupport)
|
||||
for more details.
|
||||
|
||||
@@ -143,7 +143,7 @@ Returns:
|
||||
* `frameName` String
|
||||
* `disposition` String - Can be `default`, `foreground-tab`, `background-tab`,
|
||||
`new-window`, `save-to-disk` and `other`.
|
||||
* `options` Object - The options which will be used for creating the new
|
||||
* `options` BrowserWindowConstructorOptions - The options which will be used for creating the new
|
||||
[`BrowserWindow`](browser-window.md).
|
||||
* `additionalFeatures` String[] - The non-standard features (features not handled
|
||||
by Chromium or Electron) given to `window.open()`.
|
||||
@@ -481,7 +481,7 @@ Returns:
|
||||
* `requestId` Integer
|
||||
* `activeMatchOrdinal` Integer - Position of the active match.
|
||||
* `matches` Integer - Number of Matches.
|
||||
* `selectionArea` Object - Coordinates of first match region.
|
||||
* `selectionArea` Rectangle - Coordinates of first match region.
|
||||
* `finalUpdate` Boolean
|
||||
|
||||
Emitted when a result is available for
|
||||
@@ -669,10 +669,10 @@ Emitted when the devtools window instructs the webContents to reload
|
||||
Returns:
|
||||
|
||||
* `event` Event
|
||||
* `webPreferences` Object - The web preferences that will be used by the guest
|
||||
* `webPreferences` WebPreferences - The web preferences that will be used by the guest
|
||||
page. This object can be modified to adjust the preferences for the guest
|
||||
page.
|
||||
* `params` Object - The other `<webview>` parameters such as the `src` URL.
|
||||
* `params` Record<string, string> - The other `<webview>` parameters such as the `src` URL.
|
||||
This object can be modified to adjust the parameters of the guest page.
|
||||
|
||||
Emitted when a `<webview>`'s web contents is being attached to this web
|
||||
@@ -842,7 +842,7 @@ webContents.loadURL('https://github.com', options)
|
||||
|
||||
* `filePath` String
|
||||
* `options` Object (optional)
|
||||
* `query` Object (optional) - Passed to `url.format()`.
|
||||
* `query` Record<String, String> (optional) - Passed to `url.format()`.
|
||||
* `search` String (optional) - Passed to `url.format()`.
|
||||
* `hash` String (optional) - Passed to `url.format()`.
|
||||
|
||||
@@ -1269,11 +1269,7 @@ Returns [`PrinterInfo[]`](structures/printer-info.md).
|
||||
* `failureReason` String - Called back if the print fails; can be `cancelled` or `failed`.
|
||||
|
||||
Prints window's web page. When `silent` is set to `true`, Electron will pick
|
||||
the system's default printer if `deviceName` is empty and the default settings
|
||||
for printing.
|
||||
|
||||
Calling `window.print()` in web page is equivalent to calling
|
||||
`webContents.print({ silent: false, printBackground: false, deviceName: '' })`.
|
||||
the system's default printer if `deviceName` is empty and the default settings for printing.
|
||||
|
||||
Use `page-break-before: always;` CSS style to force to print to a new page.
|
||||
|
||||
@@ -1563,13 +1559,6 @@ Disable device emulation enabled by `webContents.enableDeviceEmulation`.
|
||||
#### `contents.sendInputEvent(inputEvent)`
|
||||
|
||||
* `inputEvent` [MouseInputEvent](structures/mouse-input-event.md) | [MouseWheelInputEvent](structures/mouse-wheel-input-event.md) | [KeyboardInputEvent](structures/keyboard-input-event.md)
|
||||
* `type` String (**required**) - The type of the event, can be `mouseDown`,
|
||||
`mouseUp`, `mouseEnter`, `mouseLeave`, `contextMenu`, `mouseWheel`,
|
||||
`mouseMove`, `keyDown`, `keyUp` or `char`.
|
||||
* `modifiers` String[] - An array of modifiers of the event, can
|
||||
include `shift`, `control`, `alt`, `meta`, `isKeypad`, `isAutoRepeat`,
|
||||
`leftButtonDown`, `middleButtonDown`, `rightButtonDown`, `capsLock`,
|
||||
`numLock`, `left`, `right`.
|
||||
|
||||
Sends an input `event` to the page.
|
||||
**Note:** The [`BrowserWindow`](browser-window.md) containing the contents needs to be focused for
|
||||
|
||||
@@ -593,7 +593,7 @@ examples.
|
||||
|
||||
### `<webview>.sendInputEvent(event)`
|
||||
|
||||
* `event` Object
|
||||
* `event` [MouseInputEvent](structures/mouse-input-event.md) | [MouseWheelInputEvent](structures/mouse-wheel-input-event.md) | [KeyboardInputEvent](structures/keyboard-input-event.md)
|
||||
|
||||
Returns `Promise<void>`
|
||||
|
||||
@@ -767,7 +767,7 @@ Returns:
|
||||
* `requestId` Integer
|
||||
* `activeMatchOrdinal` Integer - Position of the active match.
|
||||
* `matches` Integer - Number of Matches.
|
||||
* `selectionArea` Object - Coordinates of first match region.
|
||||
* `selectionArea` Rectangle - Coordinates of first match region.
|
||||
* `finalUpdate` Boolean
|
||||
|
||||
Fired when a result is available for
|
||||
@@ -791,7 +791,7 @@ Returns:
|
||||
* `frameName` String
|
||||
* `disposition` String - Can be `default`, `foreground-tab`, `background-tab`,
|
||||
`new-window`, `save-to-disk` and `other`.
|
||||
* `options` Object - The options which should be used for creating the new
|
||||
* `options` BrowserWindowConstructorOptions - The options which should be used for creating the new
|
||||
[`BrowserWindow`](browser-window.md).
|
||||
|
||||
Fired when the guest page attempts to open a new browser window.
|
||||
@@ -872,7 +872,7 @@ webview.addEventListener('close', () => {
|
||||
Returns:
|
||||
|
||||
* `channel` String
|
||||
* `args` Array
|
||||
* `args` any[]
|
||||
|
||||
Fired when the guest page has sent an asynchronous message to embedder page.
|
||||
|
||||
|
||||
20
docs/fiddles/screen/fit-screen/main.js
Normal file
20
docs/fiddles/screen/fit-screen/main.js
Normal file
@@ -0,0 +1,20 @@
|
||||
// Retrieve information about screen size, displays, cursor position, etc.
|
||||
//
|
||||
// For more info, see:
|
||||
// https://electronjs.org/docs/api/screen
|
||||
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
let mainWindow = null
|
||||
|
||||
app.on('ready', () => {
|
||||
// We cannot require the screen module until the app is ready.
|
||||
const { screen } = require('electron')
|
||||
|
||||
// Create a window that fills the screen's available work area.
|
||||
const primaryDisplay = screen.getPrimaryDisplay()
|
||||
const { width, height } = primaryDisplay.workAreaSize
|
||||
|
||||
mainWindow = new BrowserWindow({ width, height })
|
||||
mainWindow.loadURL('https://electronjs.org')
|
||||
})
|
||||
@@ -27,18 +27,8 @@ see [SECURITY.md](https://github.com/electron/electron/tree/master/SECURITY.md)
|
||||
|
||||
## Chromium Security Issues and Upgrades
|
||||
|
||||
While Electron strives to support new versions of Chromium as soon as possible,
|
||||
developers should be aware that upgrading is a serious undertaking - involving
|
||||
hand-editing dozens or even hundreds of files. Given the resources and
|
||||
contributions available today, Electron will often not be on the very latest
|
||||
version of Chromium, lagging behind by several weeks or a few months.
|
||||
|
||||
We feel that our current system of updating the Chromium component strikes an
|
||||
appropriate balance between the resources we have available and the needs of
|
||||
the majority of applications built on top of the framework. We definitely are
|
||||
interested in hearing more about specific use cases from the people that build
|
||||
things on top of Electron. Pull requests and contributions supporting this
|
||||
effort are always very welcome.
|
||||
Electron keeps up to date with alternating Chromium releases. For more information,
|
||||
see the [Electron Release Cadence blog post](https://electronjs.org/blog/12-week-cadence).
|
||||
|
||||
## Security Is Everyone's Responsibility
|
||||
|
||||
|
||||
@@ -18,4 +18,55 @@
|
||||
<message name="IDS_DESKTOP_MEDIA_PICKER_MULTIPLE_SCREEN_NAME" desc="Name for screens in the desktop media picker UI when there are multiple monitors.">
|
||||
{SCREEN_INDEX, plural, =1{Screen #} other{Screen #}}
|
||||
</message>
|
||||
|
||||
<!-- Picture-in-Picture -->
|
||||
<if expr="is_macosx">
|
||||
<message name="IDS_PICTURE_IN_PICTURE_TITLE_TEXT" desc="Title of the Picture-in-Picture window. This appears in the system tray and window header.">
|
||||
Picture in Picture
|
||||
</message>
|
||||
</if>
|
||||
<if expr="not is_macosx">
|
||||
<message name="IDS_PICTURE_IN_PICTURE_TITLE_TEXT" desc="Title of the Picture-in-Picture window. This appears in the system tray and window header.">
|
||||
Picture in picture
|
||||
</message>
|
||||
</if>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_PAUSE_CONTROL_TEXT" desc="Text label of the pause control button. The button appears when the user hovers over the Picture-in-Picture window and the video is currently playing.">
|
||||
Pause
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_PLAY_CONTROL_TEXT" desc="Text label of the play control button. The button appears when the user hovers over the Picture-in-Picture window and the video is currently paused.">
|
||||
Play
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_REPLAY_CONTROL_TEXT" desc="Text label of the replay control button. The button appears when the user hovers over the Picture-in-Picture window and the video is ended.">
|
||||
Play from the beginning
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_BACK_TO_TAB_CONTROL_TEXT" desc="Text label of the back to tab control button. The button appears when the user hovers over the Picture-in-Picture window.">
|
||||
Back to video player
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_MUTE_CONTROL_TEXT" desc="Text label of the mute control button. The button appears when the user hovers over the Picture-in-Picture window and the video is currently unmuted.">
|
||||
Mute
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_UNMUTE_CONTROL_TEXT" desc="Text label of the mute control button. The button appears when the user hovers over the Picture-in-Picture window and the video is currently muted.">
|
||||
Unmute
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_SKIP_AD_CONTROL_TEXT" desc="Text label of the skip ad control button. The button appears when the user hovers over the Picture-in-Picture window.">
|
||||
Skip Ad
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_CLOSE_CONTROL_TEXT" desc="Text label of the close control button. The button appears when the user hovers over the Picture-in-Picture window.">
|
||||
Close
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_RESIZE_HANDLE_TEXT" desc="Text label of the resize handle. The button appears when the user hovers over the Picture-in-Picture window.">
|
||||
Resize
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_PLAY_PAUSE_CONTROL_ACCESSIBLE_TEXT" desc="Accessible text label used for the controls button in the Picture-in-Picture window. The button toggles between play and pause controls.">
|
||||
Toggle video to play or pause
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_MUTE_CONTROL_ACCESSIBLE_TEXT" desc="Accessible text label used for the controls button in the Picture-in-Picture window. The button toggles mute state.">
|
||||
Toggle mute
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_NEXT_TRACK_CONTROL_ACCESSIBLE_TEXT" desc="Accessible text label used for the controls button in the Picture-in-Picture window. The button invokes next track action.">
|
||||
Next track
|
||||
</message>
|
||||
<message name="IDS_PICTURE_IN_PICTURE_PREVIOUS_TRACK_CONTROL_ACCESSIBLE_TEXT" desc="Accessible text label used for the controls button in the Picture-in-Picture window. The button invokes previous track action.">
|
||||
Previous track
|
||||
</message>
|
||||
</grit-part>
|
||||
|
||||
@@ -34,6 +34,7 @@ auto_filenames = {
|
||||
"docs/api/menu.md",
|
||||
"docs/api/modernization",
|
||||
"docs/api/native-image.md",
|
||||
"docs/api/native-theme.md",
|
||||
"docs/api/net-log.md",
|
||||
"docs/api/net.md",
|
||||
"docs/api/notification.md",
|
||||
@@ -76,6 +77,7 @@ auto_filenames = {
|
||||
"docs/api/structures/desktop-capturer-source.md",
|
||||
"docs/api/structures/display.md",
|
||||
"docs/api/structures/event.md",
|
||||
"docs/api/structures/extension-info.md",
|
||||
"docs/api/structures/file-filter.md",
|
||||
"docs/api/structures/file-path-with-headers.md",
|
||||
"docs/api/structures/gpu-feature-status.md",
|
||||
@@ -130,6 +132,7 @@ auto_filenames = {
|
||||
"lib/common/api/deprecate.ts",
|
||||
"lib/common/api/module-list.js",
|
||||
"lib/common/api/native-image.js",
|
||||
"lib/common/api/native-theme.ts",
|
||||
"lib/common/api/shell.js",
|
||||
"lib/common/buffer-utils.ts",
|
||||
"lib/common/clipboard-utils.ts",
|
||||
@@ -228,7 +231,7 @@ auto_filenames = {
|
||||
"lib/browser/api/protocol.ts",
|
||||
"lib/browser/api/screen.ts",
|
||||
"lib/browser/api/session.js",
|
||||
"lib/browser/api/system-preferences.js",
|
||||
"lib/browser/api/system-preferences.ts",
|
||||
"lib/browser/api/top-level-window.js",
|
||||
"lib/browser/api/touch-bar.js",
|
||||
"lib/browser/api/tray.js",
|
||||
@@ -261,6 +264,7 @@ auto_filenames = {
|
||||
"lib/common/api/exports/electron.js",
|
||||
"lib/common/api/module-list.js",
|
||||
"lib/common/api/native-image.js",
|
||||
"lib/common/api/native-theme.ts",
|
||||
"lib/common/api/shell.js",
|
||||
"lib/common/buffer-utils.ts",
|
||||
"lib/common/clipboard-utils.ts",
|
||||
@@ -286,6 +290,7 @@ auto_filenames = {
|
||||
"lib/common/api/exports/electron.js",
|
||||
"lib/common/api/module-list.js",
|
||||
"lib/common/api/native-image.js",
|
||||
"lib/common/api/native-theme.ts",
|
||||
"lib/common/api/shell.js",
|
||||
"lib/common/buffer-utils.ts",
|
||||
"lib/common/clipboard-utils.ts",
|
||||
@@ -336,6 +341,7 @@ auto_filenames = {
|
||||
"lib/common/api/exports/electron.js",
|
||||
"lib/common/api/module-list.js",
|
||||
"lib/common/api/native-image.js",
|
||||
"lib/common/api/native-theme.ts",
|
||||
"lib/common/api/shell.js",
|
||||
"lib/common/buffer-utils.ts",
|
||||
"lib/common/clipboard-utils.ts",
|
||||
|
||||
@@ -75,8 +75,6 @@ filenames = {
|
||||
"shell/browser/api/atom_api_power_monitor.h",
|
||||
"shell/browser/api/atom_api_power_save_blocker.cc",
|
||||
"shell/browser/api/atom_api_power_save_blocker.h",
|
||||
"shell/browser/api/atom_api_protocol.cc",
|
||||
"shell/browser/api/atom_api_protocol.h",
|
||||
"shell/browser/api/atom_api_protocol_ns.cc",
|
||||
"shell/browser/api/atom_api_protocol_ns.h",
|
||||
"shell/browser/api/atom_api_screen.cc",
|
||||
@@ -91,8 +89,6 @@ filenames = {
|
||||
"shell/browser/api/atom_api_top_level_window.h",
|
||||
"shell/browser/api/atom_api_tray.cc",
|
||||
"shell/browser/api/atom_api_tray.h",
|
||||
"shell/browser/api/atom_api_url_request.cc",
|
||||
"shell/browser/api/atom_api_url_request.h",
|
||||
"shell/browser/api/atom_api_url_request_ns.cc",
|
||||
"shell/browser/api/atom_api_url_request_ns.h",
|
||||
"shell/browser/api/atom_api_view.cc",
|
||||
@@ -103,8 +99,6 @@ filenames = {
|
||||
"shell/browser/api/atom_api_web_contents_mac.mm",
|
||||
"shell/browser/api/atom_api_web_contents_view.cc",
|
||||
"shell/browser/api/atom_api_web_contents_view.h",
|
||||
"shell/browser/api/atom_api_web_request.cc",
|
||||
"shell/browser/api/atom_api_web_request.h",
|
||||
"shell/browser/api/atom_api_web_request_ns.cc",
|
||||
"shell/browser/api/atom_api_web_request_ns.h",
|
||||
"shell/browser/api/atom_api_web_view_manager.cc",
|
||||
@@ -116,8 +110,6 @@ filenames = {
|
||||
"shell/browser/api/event.h",
|
||||
"shell/browser/api/event_emitter.cc",
|
||||
"shell/browser/api/event_emitter.h",
|
||||
"shell/browser/api/stream_subscriber.cc",
|
||||
"shell/browser/api/stream_subscriber.h",
|
||||
"shell/browser/api/trackable_object.cc",
|
||||
"shell/browser/api/trackable_object.h",
|
||||
"shell/browser/api/frame_subscriber.cc",
|
||||
@@ -176,8 +168,6 @@ filenames = {
|
||||
"shell/browser/common_web_contents_delegate.h",
|
||||
"shell/browser/cookie_change_notifier.cc",
|
||||
"shell/browser/cookie_change_notifier.h",
|
||||
"shell/browser/io_thread.cc",
|
||||
"shell/browser/io_thread.h",
|
||||
"shell/browser/javascript_environment.cc",
|
||||
"shell/browser/javascript_environment.h",
|
||||
"shell/browser/lib/bluetooth_chooser.cc",
|
||||
@@ -185,8 +175,6 @@ filenames = {
|
||||
"shell/browser/lib/power_observer.h",
|
||||
"shell/browser/lib/power_observer_linux.h",
|
||||
"shell/browser/lib/power_observer_linux.cc",
|
||||
"shell/browser/loader/layered_resource_handler.cc",
|
||||
"shell/browser/loader/layered_resource_handler.h",
|
||||
"shell/browser/login_handler.cc",
|
||||
"shell/browser/login_handler.h",
|
||||
"shell/browser/mac/atom_application.h",
|
||||
@@ -223,58 +211,26 @@ filenames = {
|
||||
"shell/browser/media/media_device_id_salt.h",
|
||||
"shell/browser/media/media_stream_devices_controller.cc",
|
||||
"shell/browser/media/media_stream_devices_controller.h",
|
||||
"shell/browser/net/about_protocol_handler.cc",
|
||||
"shell/browser/net/about_protocol_handler.h",
|
||||
"shell/browser/net/asar/asar_protocol_handler.cc",
|
||||
"shell/browser/net/asar/asar_protocol_handler.h",
|
||||
"shell/browser/net/asar/asar_url_loader.cc",
|
||||
"shell/browser/net/asar/asar_url_loader.h",
|
||||
"shell/browser/net/asar/url_request_asar_job.cc",
|
||||
"shell/browser/net/asar/url_request_asar_job.h",
|
||||
"shell/browser/net/atom_cert_verifier.cc",
|
||||
"shell/browser/net/atom_cert_verifier.h",
|
||||
"shell/browser/net/atom_network_delegate.cc",
|
||||
"shell/browser/net/atom_network_delegate.h",
|
||||
"shell/browser/net/atom_url_loader_factory.cc",
|
||||
"shell/browser/net/atom_url_loader_factory.h",
|
||||
"shell/browser/net/atom_url_request.cc",
|
||||
"shell/browser/net/atom_url_request.h",
|
||||
"shell/browser/net/atom_url_request_job_factory.cc",
|
||||
"shell/browser/net/atom_url_request_job_factory.h",
|
||||
"shell/browser/net/http_protocol_handler.cc",
|
||||
"shell/browser/net/http_protocol_handler.h",
|
||||
"shell/browser/net/cert_verifier_client.cc",
|
||||
"shell/browser/net/cert_verifier_client.h",
|
||||
"shell/browser/net/proxying_url_loader_factory.cc",
|
||||
"shell/browser/net/proxying_url_loader_factory.h",
|
||||
"shell/browser/net/js_asker.cc",
|
||||
"shell/browser/net/js_asker.h",
|
||||
"shell/browser/net/network_context_service_factory.cc",
|
||||
"shell/browser/net/network_context_service_factory.h",
|
||||
"shell/browser/net/network_context_service.cc",
|
||||
"shell/browser/net/network_context_service.h",
|
||||
"shell/browser/net/node_stream_loader.cc",
|
||||
"shell/browser/net/node_stream_loader.h",
|
||||
"shell/browser/net/require_ct_delegate.cc",
|
||||
"shell/browser/net/require_ct_delegate.h",
|
||||
"shell/browser/net/resolve_proxy_helper.cc",
|
||||
"shell/browser/net/resolve_proxy_helper.h",
|
||||
"shell/browser/net/system_network_context_manager.cc",
|
||||
"shell/browser/net/system_network_context_manager.h",
|
||||
"shell/browser/net/url_pipe_loader.cc",
|
||||
"shell/browser/net/url_pipe_loader.h",
|
||||
"shell/browser/net/url_request_about_job.cc",
|
||||
"shell/browser/net/url_request_about_job.h",
|
||||
"shell/browser/net/url_request_async_asar_job.cc",
|
||||
"shell/browser/net/url_request_async_asar_job.h",
|
||||
"shell/browser/net/url_request_string_job.cc",
|
||||
"shell/browser/net/url_request_string_job.h",
|
||||
"shell/browser/net/url_request_buffer_job.cc",
|
||||
"shell/browser/net/url_request_buffer_job.h",
|
||||
"shell/browser/net/url_request_context_getter.cc",
|
||||
"shell/browser/net/url_request_context_getter.h",
|
||||
"shell/browser/net/url_request_fetch_job.cc",
|
||||
"shell/browser/net/url_request_fetch_job.h",
|
||||
"shell/browser/net/url_request_stream_job.cc",
|
||||
"shell/browser/net/url_request_stream_job.h",
|
||||
"shell/browser/notifications/linux/libnotify_notification.cc",
|
||||
"shell/browser/notifications/linux/libnotify_notification.h",
|
||||
"shell/browser/notifications/linux/notification_presenter_linux.cc",
|
||||
@@ -316,6 +272,8 @@ filenames = {
|
||||
"shell/browser/relauncher_win.cc",
|
||||
"shell/browser/relauncher.cc",
|
||||
"shell/browser/relauncher.h",
|
||||
"shell/browser/renderer_host/electron_render_message_filter.cc",
|
||||
"shell/browser/renderer_host/electron_render_message_filter.h",
|
||||
"shell/browser/session_preferences.cc",
|
||||
"shell/browser/session_preferences.h",
|
||||
"shell/browser/special_storage_policy.cc",
|
||||
@@ -364,6 +322,8 @@ filenames = {
|
||||
"shell/browser/ui/file_dialog_gtk.cc",
|
||||
"shell/browser/ui/file_dialog_mac.mm",
|
||||
"shell/browser/ui/file_dialog_win.cc",
|
||||
"shell/browser/ui/util_gtk.cc",
|
||||
"shell/browser/ui/util_gtk.h",
|
||||
"shell/browser/ui/inspectable_web_contents.cc",
|
||||
"shell/browser/ui/inspectable_web_contents.h",
|
||||
"shell/browser/ui/inspectable_web_contents_delegate.h",
|
||||
@@ -463,6 +423,8 @@ filenames = {
|
||||
"shell/common/api/atom_api_native_image.cc",
|
||||
"shell/common/api/atom_api_native_image.h",
|
||||
"shell/common/api/atom_api_native_image_mac.mm",
|
||||
"shell/common/api/atom_api_native_theme.cc",
|
||||
"shell/common/api/atom_api_native_theme.h",
|
||||
"shell/common/api/atom_api_shell.cc",
|
||||
"shell/common/api/atom_api_v8_util.cc",
|
||||
"shell/common/api/electron_bindings.cc",
|
||||
@@ -508,6 +470,11 @@ filenames = {
|
||||
"shell/common/crash_reporter/linux/crash_dump_handler.h",
|
||||
"shell/common/crash_reporter/win/crash_service_main.cc",
|
||||
"shell/common/crash_reporter/win/crash_service_main.h",
|
||||
"shell/common/gin_converters/callback_converter_gin_adapter.h",
|
||||
"shell/common/gin_converters/gurl_converter_gin_adapter.h",
|
||||
"shell/common/gin_converters/net_converter_gin_adapter.h",
|
||||
"shell/common/gin_converters/std_converter.h",
|
||||
"shell/common/gin_converters/value_converter_gin_adapter.h",
|
||||
"shell/common/gin_util.h",
|
||||
"shell/common/heap_snapshot.cc",
|
||||
"shell/common/heap_snapshot.h",
|
||||
|
||||
@@ -178,7 +178,7 @@ const roles = {
|
||||
{ role: 'services' },
|
||||
{ type: 'separator' },
|
||||
{ role: 'hide' },
|
||||
{ role: 'hideothers' },
|
||||
{ role: 'hideOthers' },
|
||||
{ role: 'unhide' },
|
||||
{ type: 'separator' },
|
||||
{ role: 'quit' }
|
||||
@@ -209,8 +209,8 @@ const roles = {
|
||||
{
|
||||
label: 'Speech',
|
||||
submenu: [
|
||||
{ role: 'startspeaking' },
|
||||
{ role: 'stopspeaking' }
|
||||
{ role: 'startSpeaking' },
|
||||
{ role: 'stopSpeaking' }
|
||||
]
|
||||
}
|
||||
] : [
|
||||
@@ -225,12 +225,12 @@ const roles = {
|
||||
label: 'View',
|
||||
submenu: [
|
||||
{ role: 'reload' },
|
||||
{ role: 'forcereload' },
|
||||
{ role: 'toggledevtools' },
|
||||
{ role: 'forceReload' },
|
||||
{ role: 'toggleDevTools' },
|
||||
{ type: 'separator' },
|
||||
{ role: 'resetzoom' },
|
||||
{ role: 'zoomin' },
|
||||
{ role: 'zoomout' },
|
||||
{ role: 'resetZoom' },
|
||||
{ role: 'zoomIn' },
|
||||
{ role: 'zoomOut' },
|
||||
{ type: 'separator' },
|
||||
{ role: 'togglefullscreen' }
|
||||
]
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
'use strict'
|
||||
|
||||
const { EventEmitter } = require('events')
|
||||
const { deprecate } = require('electron')
|
||||
const { systemPreferences, SystemPreferences } = process.electronBinding('system_preferences')
|
||||
|
||||
// SystemPreferences is an EventEmitter.
|
||||
Object.setPrototypeOf(SystemPreferences.prototype, EventEmitter.prototype)
|
||||
EventEmitter.call(systemPreferences)
|
||||
|
||||
if ('appLevelAppearance' in systemPreferences) {
|
||||
deprecate.fnToProperty(SystemPreferences.prototype, 'appLevelAppearance', '_getAppLevelAppearance', '_setAppLevelAppearance')
|
||||
}
|
||||
|
||||
module.exports = systemPreferences
|
||||
42
lib/browser/api/system-preferences.ts
Normal file
42
lib/browser/api/system-preferences.ts
Normal file
@@ -0,0 +1,42 @@
|
||||
import { EventEmitter } from 'events'
|
||||
import { deprecate } from 'electron'
|
||||
const { systemPreferences, SystemPreferences } = process.electronBinding('system_preferences')
|
||||
|
||||
// SystemPreferences is an EventEmitter.
|
||||
Object.setPrototypeOf(SystemPreferences.prototype, EventEmitter.prototype)
|
||||
EventEmitter.call(systemPreferences)
|
||||
|
||||
if ('appLevelAppearance' in systemPreferences) {
|
||||
deprecate.fnToProperty(
|
||||
SystemPreferences.prototype,
|
||||
'appLevelAppearance',
|
||||
'_getAppLevelAppearance',
|
||||
'_setAppLevelAppearance'
|
||||
)
|
||||
}
|
||||
|
||||
if ('effectiveAppearance' in systemPreferences) {
|
||||
deprecate.fnToProperty(
|
||||
SystemPreferences.prototype,
|
||||
'effectiveAppearance',
|
||||
'_getEffectiveAppearance'
|
||||
)
|
||||
}
|
||||
|
||||
SystemPreferences.prototype.isDarkMode = deprecate.moveAPI(
|
||||
SystemPreferences.prototype.isDarkMode,
|
||||
'systemPreferences.isDarkMode()',
|
||||
'nativeTheme.shouldUseDarkColors'
|
||||
)
|
||||
SystemPreferences.prototype.isInvertedColorScheme = deprecate.moveAPI(
|
||||
SystemPreferences.prototype.isInvertedColorScheme,
|
||||
'systemPreferences.isInvertedColorScheme()',
|
||||
'nativeTheme.shouldUseInvertedColorScheme'
|
||||
)
|
||||
SystemPreferences.prototype.isHighContrastColorScheme = deprecate.moveAPI(
|
||||
SystemPreferences.prototype.isHighContrastColorScheme,
|
||||
'systemPreferences.isHighContrastColorScheme()',
|
||||
'nativeTheme.shouldUseHighContrastColors'
|
||||
)
|
||||
|
||||
module.exports = systemPreferences
|
||||
@@ -427,11 +427,7 @@ const chromeExtensionHandler = function (request, callback) {
|
||||
}
|
||||
|
||||
app.on('session-created', function (ses) {
|
||||
ses.protocol.registerBufferProtocol('chrome-extension', chromeExtensionHandler, function (error) {
|
||||
if (error) {
|
||||
console.error(`Unable to register chrome-extension protocol: ${error}`)
|
||||
}
|
||||
})
|
||||
ses.protocol.registerBufferProtocol('chrome-extension', chromeExtensionHandler)
|
||||
})
|
||||
|
||||
// The persistent path of "DevTools Extensions" preference file.
|
||||
|
||||
@@ -40,9 +40,9 @@ const getEditMenuItems = function (): Electron.MenuItemConstructorOptions[] {
|
||||
{ role: 'cut' },
|
||||
{ role: 'copy' },
|
||||
{ role: 'paste' },
|
||||
{ role: 'pasteandmatchstyle' },
|
||||
{ role: 'pasteAndMatchStyle' },
|
||||
{ role: 'delete' },
|
||||
{ role: 'selectall' }
|
||||
{ role: 'selectAll' }
|
||||
]
|
||||
}
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ const mergeOptions = function (child, parent, visited) {
|
||||
if (key in child && key !== 'webPreferences') continue
|
||||
|
||||
const value = parent[key]
|
||||
if (typeof value === 'object') {
|
||||
if (typeof value === 'object' && !Array.isArray(value)) {
|
||||
child[key] = mergeOptions(child[key] || {}, value, visited)
|
||||
} else {
|
||||
child[key] = value
|
||||
|
||||
@@ -51,7 +51,15 @@ const deprecate: ElectronInternal.DeprecationUtil = {
|
||||
const warn = warnOnce(`${fn.name} function`, `${newName} function`)
|
||||
return function (this: any) {
|
||||
warn()
|
||||
fn.apply(this, arguments)
|
||||
return fn.apply(this, arguments)
|
||||
}
|
||||
},
|
||||
|
||||
moveAPI: (fn: Function, oldUsage: string, newUsage: string) => {
|
||||
const warn = warnOnce(oldUsage, newUsage)
|
||||
return function (this: any) {
|
||||
warn()
|
||||
return fn.apply(this, arguments)
|
||||
}
|
||||
},
|
||||
|
||||
@@ -69,7 +77,7 @@ const deprecate: ElectronInternal.DeprecationUtil = {
|
||||
},
|
||||
|
||||
// deprecate a getter/setter function pair in favor of a property
|
||||
fnToProperty: (prototype: any, prop: string, getter: string, setter: string) => {
|
||||
fnToProperty: (prototype: any, prop: string, getter: string, setter?: string) => {
|
||||
const withWarnOnce = function (obj: any, key: any, oldName: string, newName: string) {
|
||||
const warn = warnOnce(oldName, newName)
|
||||
const method = obj[key]
|
||||
@@ -80,7 +88,9 @@ const deprecate: ElectronInternal.DeprecationUtil = {
|
||||
}
|
||||
|
||||
prototype[getter.substr(1)] = withWarnOnce(prototype, getter, `${getter.substr(1)} function`, `${prop} property`)
|
||||
prototype[setter.substr(1)] = withWarnOnce(prototype, setter, `${setter.substr(1)} function`, `${prop} property`)
|
||||
if (setter) {
|
||||
prototype[setter.substr(1)] = withWarnOnce(prototype, setter, `${setter.substr(1)} function`, `${prop} property`)
|
||||
}
|
||||
},
|
||||
|
||||
// remove a property with no replacement
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
module.exports = [
|
||||
{ name: 'clipboard', loader: () => require('./clipboard') },
|
||||
{ name: 'nativeImage', loader: () => require('./native-image') },
|
||||
{ name: 'nativeTheme', loader: () => require('./native-theme') },
|
||||
{ name: 'shell', loader: () => require('./shell') },
|
||||
// The internal modules, invisible unless you know their names.
|
||||
{ name: 'deprecate', loader: () => require('./deprecate'), private: true }
|
||||
|
||||
8
lib/common/api/native-theme.ts
Normal file
8
lib/common/api/native-theme.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
import { EventEmitter } from 'events'
|
||||
|
||||
const { NativeTheme, nativeTheme } = process.electronBinding('native_theme')
|
||||
|
||||
Object.setPrototypeOf(NativeTheme.prototype, EventEmitter.prototype)
|
||||
EventEmitter.call(nativeTheme as any)
|
||||
|
||||
module.exports = nativeTheme
|
||||
@@ -48,7 +48,6 @@ v8Util.setHiddenValue(global, 'ipcNative', {
|
||||
onMessage (internal: boolean, channel: string, args: any[], senderId: number) {
|
||||
const sender = internal ? ipcInternalEmitter : ipcEmitter
|
||||
sender.emit(channel, { sender, senderId }, ...args)
|
||||
process.activateUvLoop()
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#include <vector>
|
||||
|
||||
#include "base/macros.h"
|
||||
#include "base/optional.h"
|
||||
#include "native_mate/converter.h"
|
||||
|
||||
namespace mate {
|
||||
@@ -34,6 +35,17 @@ class Arguments {
|
||||
return ConvertFromV8(isolate_, info_->Data(), out);
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
bool GetNext(base::Optional<T>* out) {
|
||||
if (next_ >= info_->Length())
|
||||
return true;
|
||||
v8::Local<v8::Value> val = (*info_)[next_];
|
||||
bool success = ConvertFromV8(isolate_, val, out);
|
||||
if (success)
|
||||
next_++;
|
||||
return success;
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
bool GetNext(T* out) {
|
||||
if (next_ >= info_->Length()) {
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{
|
||||
"name": "electron",
|
||||
"version": "7.0.0-nightly.20190731",
|
||||
"version": "7.0.0-beta.4",
|
||||
"repository": "https://github.com/electron/electron",
|
||||
"description": "Build cross platform desktop apps with JavaScript, HTML, and CSS",
|
||||
"devDependencies": {
|
||||
"@electron/docs-parser": "^0.4.1",
|
||||
"@electron/typescript-definitions": "^8.5.0",
|
||||
"@electron/docs-parser": "^0.4.2",
|
||||
"@electron/typescript-definitions": "^8.6.1",
|
||||
"@octokit/rest": "^16.3.2",
|
||||
"@primer/octicons": "^9.1.1",
|
||||
"@types/chai": "^4.1.7",
|
||||
|
||||
@@ -35,15 +35,12 @@ mas-cfisobjc.patch
|
||||
mas-cgdisplayusesforcetogray.patch
|
||||
mas-audiodeviceduck.patch
|
||||
mas-lssetapplicationlaunchservicesserverconnectionstatus.patch
|
||||
allow_webview_file_url.patch
|
||||
ignore_rc_check.patch
|
||||
enable_widevine.patch
|
||||
chrome_key_systems.patch
|
||||
allow_nested_error_trackers.patch
|
||||
blink_initialization_order.patch
|
||||
ssl_security_state_tab_helper.patch
|
||||
exclude-a-few-test-files-from-build.patch
|
||||
expose-net-observer-api.patch
|
||||
desktop_media_list.patch
|
||||
proxy_config_monitor.patch
|
||||
gritsettings_resource_ids.patch
|
||||
@@ -60,7 +57,6 @@ autofill_size_calculation.patch
|
||||
fix_disable_usage_of_abort_report_np_in_mas_builds.patch
|
||||
fix_disable_usage_of_pthread_fchdir_np_and_pthread_chdir_np_in_mas.patch
|
||||
fix_disable_usage_of_setapplicationisdaemon_and.patch
|
||||
disable_network_services_by_default.patch
|
||||
unsandboxed_ppapi_processes_skip_zygote.patch
|
||||
patch_the_ensure_gn_version_py_script_to_work_on_mac_ci.patch
|
||||
build_add_electron_tracing_category.patch
|
||||
@@ -69,11 +65,16 @@ feat_offscreen_rendering_with_viz_compositor.patch
|
||||
worker_context_will_destroy.patch
|
||||
fix_breakpad_symbol_generation_on_linux_arm.patch
|
||||
frame_host_manager.patch
|
||||
cross_site_document_resource_handler.patch
|
||||
crashpad_pid_check.patch
|
||||
chore_add_debounce_on_the_updatewebcontentsvisibility_method_to.patch
|
||||
preconnect_feature.patch
|
||||
network_service_allow_remote_certificate_verification_logic.patch
|
||||
put_back_deleted_colors_for_autofill.patch
|
||||
build_win_disable_zc_twophase.patch
|
||||
disable_color_correct_rendering.patch
|
||||
add_contentgpuclient_precreatemessageloop_callback.patch
|
||||
fix_disabling_compositor_recycling.patch
|
||||
picture-in-picture.patch
|
||||
allow_new_privileges_in_unsandboxed_child_processes.patch
|
||||
ssl_security_state_tab_helper.patch
|
||||
revert_cleanup_remove_menu_subtitles_sublabels.patch
|
||||
expose_setuseragent_on_networkcontext.patch
|
||||
|
||||
@@ -1,18 +1,19 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Milan Burda <milan.burda@gmail.com>
|
||||
Date: Thu, 11 Apr 2019 14:49:20 +0200
|
||||
Subject: Add ContentGpuClient::PreCreateMessageLoop() callback
|
||||
Subject: add_contentgpuclient_precreatemessageloop_callback.patch
|
||||
|
||||
This adds a ContentGpuClient::PreCreateMessageLoop() callback.
|
||||
Invoke in GpuMain after SetErrorMode, before starting the message loop.
|
||||
Allows Electron to restore WER when ELECTRON_DEFAULT_ERROR_MODE is set.
|
||||
|
||||
This should be upstreamed
|
||||
This should be upstreamed.
|
||||
|
||||
diff --git a/content/gpu/gpu_main.cc b/content/gpu/gpu_main.cc
|
||||
index 69cb584e3b99a6989dbb2906bfa5bdf1c5cd3df5..7d1d9f871f7a0676b040651cf5a7122ee6cf2732 100644
|
||||
index 4373f508964cb1e9fd51c952122ac2f41fb35ae9..065a7a57b77f1e3bf5e03fac900f1936d48ad4ff 100644
|
||||
--- a/content/gpu/gpu_main.cc
|
||||
+++ b/content/gpu/gpu_main.cc
|
||||
@@ -235,6 +235,10 @@ int GpuMain(const MainFunctionParams& parameters) {
|
||||
@@ -236,6 +236,10 @@ int GpuMain(const MainFunctionParams& parameters) {
|
||||
|
||||
logging::SetLogMessageHandler(GpuProcessLogMessageHandler);
|
||||
|
||||
@@ -23,7 +24,7 @@ index 69cb584e3b99a6989dbb2906bfa5bdf1c5cd3df5..7d1d9f871f7a0676b040651cf5a7122e
|
||||
// We are experiencing what appear to be memory-stomp issues in the GPU
|
||||
// process. These issues seem to be impacting the task executor and listeners
|
||||
// registered to it. Create the task executor on the heap to guard against
|
||||
@@ -348,7 +352,6 @@ int GpuMain(const MainFunctionParams& parameters) {
|
||||
@@ -349,7 +353,6 @@ int GpuMain(const MainFunctionParams& parameters) {
|
||||
GpuProcess gpu_process(io_thread_priority);
|
||||
#endif
|
||||
|
||||
@@ -32,10 +33,10 @@ index 69cb584e3b99a6989dbb2906bfa5bdf1c5cd3df5..7d1d9f871f7a0676b040651cf5a7122e
|
||||
client->PostIOThreadCreated(gpu_process.io_task_runner());
|
||||
|
||||
diff --git a/content/public/gpu/content_gpu_client.h b/content/public/gpu/content_gpu_client.h
|
||||
index 20e31e1bd96395cb4350aa6ae84cc16c4ca2116b..d89af81ef9426c197a62027b514011afd10ea3ce 100644
|
||||
index 830d5e89af7bd3ddb409ac7bf9d8eb3109830d41..7d544536ec846c294deb6626f51d5de7846fc5c2 100644
|
||||
--- a/content/public/gpu/content_gpu_client.h
|
||||
+++ b/content/public/gpu/content_gpu_client.h
|
||||
@@ -35,6 +35,10 @@ class CONTENT_EXPORT ContentGpuClient {
|
||||
@@ -39,6 +39,10 @@ class CONTENT_EXPORT ContentGpuClient {
|
||||
public:
|
||||
virtual ~ContentGpuClient() {}
|
||||
|
||||
|
||||
@@ -39,10 +39,10 @@ index 2aef366ac8194aa261cbca6abc051f7da8a988d3..3c7d66c81032636abcca4f1538ce9b7f
|
||||
|
||||
GIN_EXPORT static ArrayBufferAllocator* SharedInstance();
|
||||
diff --git a/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc b/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
|
||||
index fc77a1d2c717cbf6a4066082c4e941d73e707847..cde4f969cb799b9ede05f29148fba32d32309cc2 100644
|
||||
index b747d8afba334747787485582d89cd5599b7b8ae..581c2ffce679dd131e8b8af86f3d3a9a89485e78 100644
|
||||
--- a/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
|
||||
+++ b/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
|
||||
@@ -643,6 +643,10 @@ class ArrayBufferAllocator : public v8::ArrayBuffer::Allocator {
|
||||
@@ -641,6 +641,10 @@ class ArrayBufferAllocator : public v8::ArrayBuffer::Allocator {
|
||||
size, WTF::ArrayBufferContents::kDontInitialize);
|
||||
}
|
||||
|
||||
@@ -54,7 +54,7 @@ index fc77a1d2c717cbf6a4066082c4e941d73e707847..cde4f969cb799b9ede05f29148fba32d
|
||||
WTF::ArrayBufferContents::FreeMemory(data);
|
||||
}
|
||||
diff --git a/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_contents.cc b/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_contents.cc
|
||||
index 0031242152ce5190b0dfc77b53af2d984e5fad82..a6370ec793ce6c38eb7dab189583ea11cca51c1f 100644
|
||||
index ac76d127b96b80c8260a7e2cda0b669cd98787ad..dcab64586700a8740262aede8dba2755f652d8e8 100644
|
||||
--- a/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_contents.cc
|
||||
+++ b/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_contents.cc
|
||||
@@ -130,6 +130,11 @@ void* ArrayBufferContents::AllocateMemoryOrNull(size_t size,
|
||||
@@ -70,10 +70,10 @@ index 0031242152ce5190b0dfc77b53af2d984e5fad82..a6370ec793ce6c38eb7dab189583ea11
|
||||
Partitions::ArrayBufferPartition()->Free(data);
|
||||
}
|
||||
diff --git a/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_contents.h b/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_contents.h
|
||||
index 601046eca671613693d3fc083cf48a0d530c8fd3..a94b7ea29bbd6d5e6cc6fb3a850be7e1ef00c5ad 100644
|
||||
index 3f44cd2fdf648057be8defcf041574b4c91e0363..55c0e7c66649ae9d9cbef6179daac7ad771b755c 100644
|
||||
--- a/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_contents.h
|
||||
+++ b/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_contents.h
|
||||
@@ -135,6 +135,7 @@ class WTF_EXPORT ArrayBufferContents {
|
||||
@@ -140,6 +140,7 @@ class WTF_EXPORT ArrayBufferContents {
|
||||
void CopyTo(ArrayBufferContents& other);
|
||||
|
||||
static void* AllocateMemoryOrNull(size_t, InitializationPolicy);
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Jeremy Apthorp <nornagon@nornagon.net>
|
||||
Date: Mon, 26 Aug 2019 12:02:51 -0700
|
||||
Subject: allow new privileges in unsandboxed child processes
|
||||
|
||||
This allows unsandboxed renderers to launch setuid processes on Linux.
|
||||
|
||||
diff --git a/content/browser/child_process_launcher_helper_linux.cc b/content/browser/child_process_launcher_helper_linux.cc
|
||||
index 720b92a1a3a7ab5512f839005b272e4989d2ac65..b1759109627cd00053489dcdd397e942fa9d289f 100644
|
||||
--- a/content/browser/child_process_launcher_helper_linux.cc
|
||||
+++ b/content/browser/child_process_launcher_helper_linux.cc
|
||||
@@ -54,6 +54,18 @@ bool ChildProcessLauncherHelper::BeforeLaunchOnLauncherThread(
|
||||
const int sandbox_fd = SandboxHostLinux::GetInstance()->GetChildSocket();
|
||||
options->fds_to_remap.push_back(
|
||||
std::make_pair(sandbox_fd, service_manager::GetSandboxFD()));
|
||||
+
|
||||
+ // (For Electron), if we're launching without zygote, that means we're
|
||||
+ // launching an unsandboxed process (since all sandboxed processes are
|
||||
+ // forked from the zygote). Relax the allow_new_privs option to permit
|
||||
+ // launching suid processes from unsandboxed renderers.
|
||||
+ service_manager::ZygoteHandle zygote_handle =
|
||||
+ base::CommandLine::ForCurrentProcess()->HasSwitch(switches::kNoZygote)
|
||||
+ ? nullptr
|
||||
+ : delegate_->GetZygote();
|
||||
+ if (!zygote_handle) {
|
||||
+ options->allow_new_privs = true;
|
||||
+ }
|
||||
}
|
||||
|
||||
options->environment = delegate_->GetEnvironment();
|
||||
@@ -1,20 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Cheng Zhao <zcbenz@gmail.com>
|
||||
Date: Thu, 20 Sep 2018 17:49:42 -0700
|
||||
Subject: allow_webview_file_url.patch
|
||||
|
||||
Allow webview to load non-web URLs.
|
||||
|
||||
diff --git a/content/browser/loader/resource_dispatcher_host_impl.cc b/content/browser/loader/resource_dispatcher_host_impl.cc
|
||||
index 76bcf34f58ef62dc42927a94d1e4410c1a0bde2e..008d89fe6b46facb7b3f8ca908c76c36d19c396b 100644
|
||||
--- a/content/browser/loader/resource_dispatcher_host_impl.cc
|
||||
+++ b/content/browser/loader/resource_dispatcher_host_impl.cc
|
||||
@@ -1426,6 +1426,8 @@ void ResourceDispatcherHostImpl::BeginNavigationRequest(
|
||||
!policy->IsWebSafeScheme(info.common_params.url.scheme()) &&
|
||||
!is_external_protocol;
|
||||
|
||||
+ non_web_url_in_guest = false;
|
||||
+
|
||||
if (is_shutdown_ || non_web_url_in_guest) {
|
||||
url_loader_client->OnComplete(
|
||||
network::URLLoaderCompletionStatus(net::ERR_ABORTED));
|
||||
@@ -1,12 +1,13 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Heilig Benedek <benecene@gmail.com>
|
||||
Date: Wed, 30 Jan 2019 17:04:33 +0100
|
||||
Subject: don't call into chrome internals for autofill popup size calculations
|
||||
Subject: autofill_size_calculation.patch
|
||||
|
||||
The default GetWindowBounds calls into chrome internal functions to
|
||||
find out the size of the window - this can be overridden but even
|
||||
then some methods call into the original. Let's just return an empty
|
||||
gfx::Rect and do the actual job in the subclass.
|
||||
We don't want to call into chrome internals for autofill popup size
|
||||
calculations. The default GetWindowBounds calls into chrome internal
|
||||
functions to find out the size of the window - this can be overridden
|
||||
but even then some methods call into the original. Let's just return
|
||||
an empty gfx::Rect and do the actual job in the subclass.
|
||||
|
||||
diff --git a/chrome/browser/ui/autofill/popup_view_common.cc b/chrome/browser/ui/autofill/popup_view_common.cc
|
||||
index 25e2cfce4999bdf6a94d61aae4558470d18f89ed..c9880bcd639eb59ae52c38dbdabbd86ebac3b530 100644
|
||||
|
||||
@@ -5,7 +5,7 @@ Subject: blink-worker-enable-csp-in-file-scheme.patch
|
||||
|
||||
|
||||
diff --git a/third_party/blink/renderer/core/workers/worker_classic_script_loader.cc b/third_party/blink/renderer/core/workers/worker_classic_script_loader.cc
|
||||
index 873bf34f0f6fff5ee955f84a5019ddf9c6aefc9c..8fca091c4a430f7109aa59400e1ffbea533938d9 100644
|
||||
index b1b9f451951bb7b11eefe6453a71a6b44be838a5..0f62ba09ef99538a5b0b306f601d10c44a7a7abf 100644
|
||||
--- a/third_party/blink/renderer/core/workers/worker_classic_script_loader.cc
|
||||
+++ b/third_party/blink/renderer/core/workers/worker_classic_script_loader.cc
|
||||
@@ -308,7 +308,6 @@ void WorkerClassicScriptLoader::ProcessContentSecurityPolicy(
|
||||
|
||||
@@ -10,10 +10,10 @@ to fix electron/electron#13787. The backport landed in Chromium 67 but the
|
||||
DidCreateScriptContext re-ordering needs to be upstreamed or kept indefinitely
|
||||
|
||||
diff --git a/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc b/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc
|
||||
index 50c06fddeff3647dc99f8ab9f1538723f91ec2a9..fa4b6c3c8081af03055ddeadc53606fcc9030d5c 100644
|
||||
index c0ec993ca6d96c5f95eb7b918ca9c37d9defff43..2522add8f9b1e3ada14fcc5c09d161b0820f4418 100644
|
||||
--- a/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc
|
||||
+++ b/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc
|
||||
@@ -203,11 +203,10 @@ void LocalWindowProxy::Initialize() {
|
||||
@@ -205,11 +205,10 @@ void LocalWindowProxy::Initialize() {
|
||||
GetFrame()->IsMainFrame());
|
||||
MainThreadDebugger::Instance()->ContextCreated(script_state_, GetFrame(),
|
||||
origin);
|
||||
|
||||
@@ -14,10 +14,10 @@ when there is code doing that.
|
||||
This patch reverts the change to fix the crash in Electron.
|
||||
|
||||
diff --git a/third_party/blink/renderer/core/frame/local_frame.cc b/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
index 60b3fe655dc8c309e3099d15283f8223e9ae2a50..c66465dd1c059e8de6055e44260dd51810c4f202 100644
|
||||
index 1673685187012698768445d38dcda90e084f8cde..00edb7945956ff7ce62da73499fd85d3ebac4d95 100644
|
||||
--- a/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/local_frame.cc
|
||||
@@ -332,10 +332,6 @@ void LocalFrame::DetachImpl(FrameDetachType type) {
|
||||
@@ -335,10 +335,6 @@ void LocalFrame::DetachImpl(FrameDetachType type) {
|
||||
}
|
||||
CHECK(!view_ || !view_->IsAttached());
|
||||
|
||||
@@ -28,7 +28,7 @@ index 60b3fe655dc8c309e3099d15283f8223e9ae2a50..c66465dd1c059e8de6055e44260dd518
|
||||
if (!Client())
|
||||
return;
|
||||
|
||||
@@ -353,6 +349,10 @@ void LocalFrame::DetachImpl(FrameDetachType type) {
|
||||
@@ -356,6 +352,10 @@ void LocalFrame::DetachImpl(FrameDetachType type) {
|
||||
// Notify ScriptController that the frame is closing, since its cleanup ends
|
||||
// up calling back to LocalFrameClient via WindowProxy.
|
||||
GetScriptController().ClearForClose();
|
||||
|
||||
@@ -5,10 +5,10 @@ Subject: blink_world_context.patch
|
||||
|
||||
|
||||
diff --git a/third_party/blink/public/web/web_local_frame.h b/third_party/blink/public/web/web_local_frame.h
|
||||
index ea92c2747104615ac876b8322bd5e7acf039924d..1a5b6c4945de6e26a163fe653fef65838431d7b0 100644
|
||||
index a781a44399a31f048419311d2317229c912752c2..131c0dcb125b00215e3ad469c11c4b47d7cb126b 100644
|
||||
--- a/third_party/blink/public/web/web_local_frame.h
|
||||
+++ b/third_party/blink/public/web/web_local_frame.h
|
||||
@@ -357,6 +357,9 @@ class WebLocalFrame : public WebFrame {
|
||||
@@ -356,6 +356,9 @@ class WebLocalFrame : public WebFrame {
|
||||
// be calling this API.
|
||||
virtual v8::Local<v8::Context> MainWorldScriptContext() const = 0;
|
||||
|
||||
@@ -19,10 +19,10 @@ index ea92c2747104615ac876b8322bd5e7acf039924d..1a5b6c4945de6e26a163fe653fef6583
|
||||
// that the script evaluated to with callback. Script execution can be
|
||||
// suspend.
|
||||
diff --git a/third_party/blink/renderer/core/frame/web_local_frame_impl.cc b/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
|
||||
index 3215cba24c414f235c3149ffd45e30dfc7979060..752e04d1510d54ae525e4c7d1b5a149cba2b087a 100644
|
||||
index cb07cda4464d3d5a2ad59bf9fb03921e4bdedae2..6278cf7ee5d404de40114dbe87350eb8acc08289 100644
|
||||
--- a/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
|
||||
+++ b/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
|
||||
@@ -868,6 +868,13 @@ v8::Local<v8::Object> WebLocalFrameImpl::GlobalProxy() const {
|
||||
@@ -874,6 +874,13 @@ v8::Local<v8::Object> WebLocalFrameImpl::GlobalProxy() const {
|
||||
return MainWorldScriptContext()->Global();
|
||||
}
|
||||
|
||||
@@ -37,10 +37,10 @@ index 3215cba24c414f235c3149ffd45e30dfc7979060..752e04d1510d54ae525e4c7d1b5a149c
|
||||
return BindingSecurity::ShouldAllowAccessToFrame(
|
||||
CurrentDOMWindow(V8PerIsolateData::MainThreadIsolate()),
|
||||
diff --git a/third_party/blink/renderer/core/frame/web_local_frame_impl.h b/third_party/blink/renderer/core/frame/web_local_frame_impl.h
|
||||
index c9a5d1d253d7ff16dc88667b07b883842a388c11..ee7079631e3a713f8b001c5d104fc2b1bbe99e8c 100644
|
||||
index 9fbb94efc829928a1b1e284d529dd5562619dc20..0a0904ab66d55753252ccf484c03c07c8dac002b 100644
|
||||
--- a/third_party/blink/renderer/core/frame/web_local_frame_impl.h
|
||||
+++ b/third_party/blink/renderer/core/frame/web_local_frame_impl.h
|
||||
@@ -149,6 +149,8 @@ class CORE_EXPORT WebLocalFrameImpl final
|
||||
@@ -150,6 +150,8 @@ class CORE_EXPORT WebLocalFrameImpl final
|
||||
int argc,
|
||||
v8::Local<v8::Value> argv[]) override;
|
||||
v8::Local<v8::Context> MainWorldScriptContext() const override;
|
||||
|
||||
@@ -26,7 +26,7 @@ index de89d291e5cbc0981cf06170ed35502a1239136d..656f6c38d55d9f9af569bc772254ca13
|
||||
viz::mojom::CompositorFrameSinkClient* renderer_compositor_frame_sink);
|
||||
void OnDidNotProduceFrame(const viz::BeginFrameAck& ack);
|
||||
diff --git a/content/browser/renderer_host/browser_compositor_view_mac.mm b/content/browser/renderer_host/browser_compositor_view_mac.mm
|
||||
index 4b3f3c7e97e73ad6d0166ad114f4168d9ed00e11..59e58d693c971742951434f6582140d9179235f2 100644
|
||||
index 8ddd790decc43af9820c97121a3b359e7cbb49ee..18019d5794f688ca07b35a665cc9800bb1d3047a 100644
|
||||
--- a/content/browser/renderer_host/browser_compositor_view_mac.mm
|
||||
+++ b/content/browser/renderer_host/browser_compositor_view_mac.mm
|
||||
@@ -80,6 +80,12 @@
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Samuel Attard <sattard@slack-corp.com>
|
||||
Date: Tue, 23 Apr 2019 09:51:43 -0700
|
||||
Subject: build: add electron tracing category
|
||||
Subject: build_add_electron_tracing_category.patch
|
||||
|
||||
All TRACE events in Chromium use a static assert to ensure that the
|
||||
categories in use are known / declared. This patch is required for us
|
||||
to introduce a new Electron category.
|
||||
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 7c0723ffd4934300fed249e2d3c98532e9382885..b0e5e3f30c2235e4bbe0bd3dc324e99d7f505e79 100644
|
||||
index b50d4123e44ddee34af0b07bfe5d067c4ccc5809..3e2c639a067fb76848783f35ec112a380da2353e 100644
|
||||
--- a/base/trace_event/builtin_categories.h
|
||||
+++ b/base/trace_event/builtin_categories.h
|
||||
@@ -61,6 +61,7 @@
|
||||
|
||||
@@ -5,7 +5,7 @@ Subject: build_gn.patch
|
||||
|
||||
|
||||
diff --git a/build/config/BUILDCONFIG.gn b/build/config/BUILDCONFIG.gn
|
||||
index 23695f67293383fe086ce56a7ab6fe08ed28cce7..1d01c7a33634fc749f7498377e96dc0467e698f5 100644
|
||||
index 59ab7810e71916e8f0f2d69f06e3c2c3ebc99030..b144e800c94956429ca85fc0aefe6539a6246e4b 100644
|
||||
--- a/build/config/BUILDCONFIG.gn
|
||||
+++ b/build/config/BUILDCONFIG.gn
|
||||
@@ -123,6 +123,9 @@ if (current_os == "") {
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: deepak1556 <hop2deep@gmail.com>
|
||||
Date: Tue, 16 Jul 2019 14:38:52 -0700
|
||||
Subject: build: Temporarily disable /Zc:twoPhase when libcxx is not used on
|
||||
windows.
|
||||
Subject: build_win_disable_zc_twophase.patch
|
||||
|
||||
This is to workaround the bug in crbug.com/969698#c10
|
||||
Temporarily disable /Zc:twoPhase when libcxx is not used on
|
||||
Windows. This is to workaround the bug in crbug.com/969698#c10
|
||||
until fixes have landed in upstream.
|
||||
|
||||
diff --git a/build/config/win/BUILD.gn b/build/config/win/BUILD.gn
|
||||
index a6c0aeaf98f7a860c131dc52161f52f308432a91..7b490d07d0f8383db5cea2703d7451db0108d252 100644
|
||||
index edb193a5f3ac04b1ea017d3744a5ac1383fc055b..459368d9885f26f80c6bbef452a3be0706cb7c13 100644
|
||||
--- a/build/config/win/BUILD.gn
|
||||
+++ b/build/config/win/BUILD.gn
|
||||
@@ -2,6 +2,7 @@
|
||||
@@ -19,7 +19,7 @@ index a6c0aeaf98f7a860c131dc52161f52f308432a91..7b490d07d0f8383db5cea2703d7451db
|
||||
import("//build/config/chrome_build.gni")
|
||||
import("//build/config/clang/clang.gni")
|
||||
import("//build/config/compiler/compiler.gni")
|
||||
@@ -67,9 +68,13 @@ config("compiler") {
|
||||
@@ -61,9 +62,13 @@ config("compiler") {
|
||||
"/FS", # Preserve previous PDB behavior.
|
||||
"/bigobj", # Some of our files are bigger than the regular limits.
|
||||
"/utf-8", # Assume UTF-8 by default to avoid code page dependencies.
|
||||
|
||||
@@ -5,10 +5,10 @@ Subject: can_create_window.patch
|
||||
|
||||
|
||||
diff --git a/content/browser/frame_host/render_frame_host_impl.cc b/content/browser/frame_host/render_frame_host_impl.cc
|
||||
index a9d30fa2e6b9b2f5fd96be4ecf90dafa9e7ea57a..b352615567a2719828626d9ad4b79ea8c494975f 100644
|
||||
index f55a98595f30f718d238e0a873c9ec82610b8a41..d1369e7dbf71414905531a0b49eb9459772951e8 100644
|
||||
--- a/content/browser/frame_host/render_frame_host_impl.cc
|
||||
+++ b/content/browser/frame_host/render_frame_host_impl.cc
|
||||
@@ -3831,6 +3831,7 @@ void RenderFrameHostImpl::CreateNewWindow(
|
||||
@@ -3947,6 +3947,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,
|
||||
@@ -17,10 +17,10 @@ index a9d30fa2e6b9b2f5fd96be4ecf90dafa9e7ea57a..b352615567a2719828626d9ad4b79ea8
|
||||
&no_javascript_access);
|
||||
|
||||
diff --git a/content/common/frame.mojom b/content/common/frame.mojom
|
||||
index a2fe2dbd0d1c91a0bf5047b5c93f30758a0db277..d9f44fecaae883d861eea94c6cc16727967f0baa 100644
|
||||
index e227f780d720a80a13699f475757142571094cd1..6984f69e6f9a0d3058b0054df8a3aa9d46f14dbd 100644
|
||||
--- a/content/common/frame.mojom
|
||||
+++ b/content/common/frame.mojom
|
||||
@@ -305,6 +305,10 @@ struct CreateNewWindowParams {
|
||||
@@ -299,6 +299,10 @@ struct CreateNewWindowParams {
|
||||
|
||||
// The window features to use for the new window.
|
||||
blink.mojom.WindowFeatures features;
|
||||
@@ -32,10 +32,10 @@ index a2fe2dbd0d1c91a0bf5047b5c93f30758a0db277..d9f44fecaae883d861eea94c6cc16727
|
||||
|
||||
// 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 21da9c9c43a94411787d7cab8513b88302383e97..44a574d3c621695d7d1304c7b8db08db8cf753d1 100644
|
||||
index 3e5ebb5c71ba2b6a3cc0f914e10c64dce06d6088..d51d21fbd09cfa2c017f85ab96c1156a6a4f74f9 100644
|
||||
--- a/content/public/browser/content_browser_client.cc
|
||||
+++ b/content/public/browser/content_browser_client.cc
|
||||
@@ -494,6 +494,8 @@ bool ContentBrowserClient::CanCreateWindow(
|
||||
@@ -489,6 +489,8 @@ bool ContentBrowserClient::CanCreateWindow(
|
||||
const std::string& frame_name,
|
||||
WindowOpenDisposition disposition,
|
||||
const blink::mojom::WindowFeatures& features,
|
||||
@@ -45,10 +45,10 @@ index 21da9c9c43a94411787d7cab8513b88302383e97..44a574d3c621695d7d1304c7b8db08db
|
||||
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 b0709c05aec437c36498587e7a3bd79bf311c525..7d83d9e0d0c57511955921d85f15a27a88c3ac37 100644
|
||||
index 0c80d202fe984fc8b799571a288ad7005c75afeb..6767853c179179c546bbaa6fd07ade7db9c40a82 100644
|
||||
--- a/content/public/browser/content_browser_client.h
|
||||
+++ b/content/public/browser/content_browser_client.h
|
||||
@@ -175,6 +175,7 @@ class RenderFrameHost;
|
||||
@@ -178,6 +178,7 @@ class RenderFrameHost;
|
||||
class RenderProcessHost;
|
||||
class RenderViewHost;
|
||||
class ResourceContext;
|
||||
@@ -56,7 +56,7 @@ index b0709c05aec437c36498587e7a3bd79bf311c525..7d83d9e0d0c57511955921d85f15a27a
|
||||
class SerialDelegate;
|
||||
class SiteInstance;
|
||||
class SpeechRecognitionManagerDelegate;
|
||||
@@ -778,6 +779,8 @@ class CONTENT_EXPORT ContentBrowserClient {
|
||||
@@ -771,6 +772,8 @@ class CONTENT_EXPORT ContentBrowserClient {
|
||||
const std::string& frame_name,
|
||||
WindowOpenDisposition disposition,
|
||||
const blink::mojom::WindowFeatures& features,
|
||||
@@ -66,18 +66,18 @@ index b0709c05aec437c36498587e7a3bd79bf311c525..7d83d9e0d0c57511955921d85f15a27a
|
||||
bool opener_suppressed,
|
||||
bool* no_javascript_access);
|
||||
diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc
|
||||
index d0ca81590d2b5688022ca6045869dcae0ecd778e..7752c1e49dbee49c64a552ec249cabdb4d073109 100644
|
||||
index cc63d162b378f328e1799d69c6762363f3227457..2e8eea0451b16125a75b2b3dc14be807e4413070 100644
|
||||
--- a/content/renderer/render_view_impl.cc
|
||||
+++ b/content/renderer/render_view_impl.cc
|
||||
@@ -75,6 +75,7 @@
|
||||
@@ -73,6 +73,7 @@
|
||||
#include "content/renderer/ime_event_guard.h"
|
||||
#include "content/renderer/internal_document_state_data.h"
|
||||
#include "content/renderer/loader/request_extra_data.h"
|
||||
+#include "content/renderer/loader/web_url_request_util.h"
|
||||
#include "content/renderer/media/audio/audio_device_factory.h"
|
||||
#include "content/renderer/media/stream/media_stream_device_observer.h"
|
||||
#include "content/renderer/media/video_capture/video_capture_impl_manager.h"
|
||||
@@ -1366,6 +1367,8 @@ WebView* RenderViewImpl::CreateView(
|
||||
#include "content/renderer/media/webrtc/peer_connection_dependency_factory.h"
|
||||
#include "content/renderer/media/webrtc/rtc_peer_connection_handler.h"
|
||||
@@ -1322,6 +1323,8 @@ WebView* RenderViewImpl::CreateView(
|
||||
}
|
||||
params->features = ConvertWebWindowFeaturesToMojoWindowFeatures(features);
|
||||
|
||||
@@ -87,10 +87,10 @@ index d0ca81590d2b5688022ca6045869dcae0ecd778e..7752c1e49dbee49c64a552ec249cabdb
|
||||
// moved on send.
|
||||
bool is_background_tab =
|
||||
diff --git a/content/shell/browser/web_test/web_test_content_browser_client.cc b/content/shell/browser/web_test/web_test_content_browser_client.cc
|
||||
index dacecdd4d0195e999f11fd2e1dfaabe95a639263..c5b88ee2561561c0b8a8032d32255645ce30c450 100644
|
||||
index e0e6f185c567ccf96c9a4d1b62bc6b060d0d3c0c..55685e60c431d3f39edeb415cafd7070de57c746 100644
|
||||
--- a/content/shell/browser/web_test/web_test_content_browser_client.cc
|
||||
+++ b/content/shell/browser/web_test/web_test_content_browser_client.cc
|
||||
@@ -308,6 +308,8 @@ bool WebTestContentBrowserClient::CanCreateWindow(
|
||||
@@ -312,6 +312,8 @@ bool WebTestContentBrowserClient::CanCreateWindow(
|
||||
const std::string& frame_name,
|
||||
WindowOpenDisposition disposition,
|
||||
const blink::mojom::WindowFeatures& features,
|
||||
@@ -100,10 +100,10 @@ index dacecdd4d0195e999f11fd2e1dfaabe95a639263..c5b88ee2561561c0b8a8032d32255645
|
||||
bool opener_suppressed,
|
||||
bool* no_javascript_access) {
|
||||
diff --git a/content/shell/browser/web_test/web_test_content_browser_client.h b/content/shell/browser/web_test/web_test_content_browser_client.h
|
||||
index 4f00217da5a4f6f3d7410b82352fcb94e7f4a8fd..33e30d6a816e87dade0a26710a8f71fc6f630f34 100644
|
||||
index 1a714946de9f0dceaec008e93928d2c414ef01da..34423135e85b3ed7a54c9f22f6674f9c4026a67c 100644
|
||||
--- a/content/shell/browser/web_test/web_test_content_browser_client.h
|
||||
+++ b/content/shell/browser/web_test/web_test_content_browser_client.h
|
||||
@@ -69,6 +69,8 @@ class WebTestContentBrowserClient : public ShellContentBrowserClient {
|
||||
@@ -67,6 +67,8 @@ class WebTestContentBrowserClient : public ShellContentBrowserClient {
|
||||
const std::string& frame_name,
|
||||
WindowOpenDisposition disposition,
|
||||
const blink::mojom::WindowFeatures& features,
|
||||
|
||||
@@ -1,65 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Samuel Attard <sattard@slack-corp.com>
|
||||
Date: Wed, 5 Jun 2019 15:11:00 -0700
|
||||
Subject: chore: add debounce on the updateWebContentsVisibility method to
|
||||
ensure quick changes in occlusion do not result in flickering
|
||||
|
||||
diff --git a/content/app_shim_remote_cocoa/web_contents_view_cocoa.h b/content/app_shim_remote_cocoa/web_contents_view_cocoa.h
|
||||
index 230e259f6017310e556d11dec43973b74015f191..ebd19fc31efef50677da417dfd69f0c8cce6c682 100644
|
||||
--- a/content/app_shim_remote_cocoa/web_contents_view_cocoa.h
|
||||
+++ b/content/app_shim_remote_cocoa/web_contents_view_cocoa.h
|
||||
@@ -58,6 +58,8 @@ CONTENT_EXPORT
|
||||
offset:(NSPoint)offset;
|
||||
- (void)clearViewsHostableView;
|
||||
- (void)updateWebContentsVisibility;
|
||||
+- (remote_cocoa::mojom::Visibility)currentVisibility;
|
||||
+- (void)notifyWebContentsVisibilityChanged;
|
||||
- (void)viewDidBecomeFirstResponder:(NSNotification*)notification;
|
||||
@end
|
||||
|
||||
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 615fe671d415747cb84f673327629d3dc771039e..6c31ba5b9149161784f5813598ddcf30e2d8af2a 100644
|
||||
--- a/content/app_shim_remote_cocoa/web_contents_view_cocoa.mm
|
||||
+++ b/content/app_shim_remote_cocoa/web_contents_view_cocoa.mm
|
||||
@@ -257,9 +257,14 @@ - (void)viewDidBecomeFirstResponder:(NSNotification*)notification {
|
||||
host_->OnBecameFirstResponder(direction);
|
||||
}
|
||||
|
||||
-- (void)updateWebContentsVisibility {
|
||||
+- (void)notifyWebContentsVisibilityChanged {
|
||||
if (!host_)
|
||||
return;
|
||||
+
|
||||
+ host_->OnWindowVisibilityChanged([self currentVisibility]);
|
||||
+}
|
||||
+
|
||||
+- (Visibility)currentVisibility {
|
||||
Visibility visibility = Visibility::kVisible;
|
||||
if ([self isHiddenOrHasHiddenAncestor] || ![self window])
|
||||
visibility = Visibility::kHidden;
|
||||
@@ -267,7 +272,24 @@ - (void)updateWebContentsVisibility {
|
||||
visibility = Visibility::kVisible;
|
||||
else
|
||||
visibility = Visibility::kOccluded;
|
||||
- host_->OnWindowVisibilityChanged(visibility);
|
||||
+ return visibility;
|
||||
+}
|
||||
+
|
||||
+- (void)updateWebContentsVisibility {
|
||||
+ if (!host_)
|
||||
+ return;
|
||||
+ // Cancel any pending notifications visibility changes, this ensures that the latest incoming change is the only
|
||||
+ // change that will take affect
|
||||
+ [NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(notifyWebContentsVisibilityChanged) object:nil];
|
||||
+
|
||||
+ Visibility visibility = [self currentVisibility];
|
||||
+
|
||||
+ // If it's visible, notify immediately to render ASAP
|
||||
+ if (visibility == Visibility::kVisible)
|
||||
+ host_->OnWindowVisibilityChanged(visibility);
|
||||
+ else
|
||||
+ // If it's occluded queue it for 3 seconds to be sure that it isn't a double kOccluded -> kVisible
|
||||
+ [self performSelector:@selector(notifyWebContentsVisibilityChanged) withObject:nil afterDelay:3.0];
|
||||
}
|
||||
|
||||
- (void)resizeSubviewsWithOldSize:(NSSize)oldBoundsSize {
|
||||
@@ -1,9 +1,9 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Jeremy Apthorp <jeremya@chromium.org>
|
||||
Date: Wed, 10 Oct 2018 15:07:34 -0700
|
||||
Subject: define Command::IsMediaKey on mac
|
||||
Subject: command-ismediakey.patch
|
||||
|
||||
the definition is copied from //chrome/common/extensions/command.cc,
|
||||
define Command::IsMediaKey on mac; copied from //chrome/common/extensions/command.cc,
|
||||
which also defines a bunch of other stuff that depends on extensions.
|
||||
since we only need IsMediaKey, and we don't want the extensions stuff
|
||||
(and aren't compiling command.cc), it's safe to duplicate the
|
||||
|
||||
@@ -8,10 +8,10 @@ run before shutdown. This is required to cleanup WebContents asynchronously
|
||||
in atom::CommonWebContentsDelegate::ResetManageWebContents.
|
||||
|
||||
diff --git a/content/browser/browser_main_loop.cc b/content/browser/browser_main_loop.cc
|
||||
index 5b9d42a924bdd121a3eab7145d3f62679e44b09e..78d3ce1ab15ffd1fba2a4a4c1d6447c7627ddb50 100644
|
||||
index d97e75b486252348deb30a14f95f668728fab15b..0700cb7ef1eefdb661e46652e239f3aef86d29ea 100644
|
||||
--- a/content/browser/browser_main_loop.cc
|
||||
+++ b/content/browser/browser_main_loop.cc
|
||||
@@ -1508,7 +1508,7 @@ void BrowserMainLoop::MainMessageLoopRun() {
|
||||
@@ -1483,7 +1483,7 @@ void BrowserMainLoop::MainMessageLoopRun() {
|
||||
NOTREACHED();
|
||||
#else
|
||||
base::RunLoop run_loop;
|
||||
|
||||
@@ -1,52 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: deepak1556 <hop2deep@gmail.com>
|
||||
Date: Mon, 3 Jun 2019 14:07:40 -0700
|
||||
Subject: cross_site_document_resource_handler.patch
|
||||
|
||||
Add a content layer hook to disable CORB for a renderer process,
|
||||
this patch can be removed once we switch to network service,
|
||||
where the embedders have a chance to design their URLLoaders.
|
||||
|
||||
diff --git a/content/browser/loader/cross_site_document_resource_handler.cc b/content/browser/loader/cross_site_document_resource_handler.cc
|
||||
index b74bbef56038e29ca35403affd284a7a8868c201..d6887e576ac197f80a7e5261bd251cd761d1d814 100644
|
||||
--- a/content/browser/loader/cross_site_document_resource_handler.cc
|
||||
+++ b/content/browser/loader/cross_site_document_resource_handler.cc
|
||||
@@ -582,6 +582,9 @@ bool CrossSiteDocumentResourceHandler::ShouldBlockBasedOnHeaders(
|
||||
request()->initiator()->scheme() == url::kFileScheme)
|
||||
return false;
|
||||
|
||||
+ if (GetContentClient()->browser()->ShouldBypassCORB(info->GetChildID()))
|
||||
+ return false;
|
||||
+
|
||||
return true;
|
||||
}
|
||||
|
||||
diff --git a/content/public/browser/content_browser_client.cc b/content/public/browser/content_browser_client.cc
|
||||
index 39d3c28ca33fa1eeab14b67ec31a6ae09f25c354..1fc64dd493536f1aefafd6a683c19289920000b7 100644
|
||||
--- a/content/public/browser/content_browser_client.cc
|
||||
+++ b/content/public/browser/content_browser_client.cc
|
||||
@@ -71,6 +71,10 @@ std::unique_ptr<BrowserMainParts> ContentBrowserClient::CreateBrowserMainParts(
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
+bool ContentBrowserClient::ShouldBypassCORB(int render_process_id) const {
|
||||
+ return false;
|
||||
+}
|
||||
+
|
||||
void ContentBrowserClient::PostAfterStartupTask(
|
||||
const base::Location& from_here,
|
||||
const scoped_refptr<base::TaskRunner>& task_runner,
|
||||
diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h
|
||||
index 3d518759a3bc190970a2d45ec178c97096fa250d..b2c12759d2cd94d7971f20bc289c7fa70f1fe863 100644
|
||||
--- a/content/public/browser/content_browser_client.h
|
||||
+++ b/content/public/browser/content_browser_client.h
|
||||
@@ -249,6 +249,9 @@ class CONTENT_EXPORT ContentBrowserClient {
|
||||
virtual std::unique_ptr<BrowserMainParts> CreateBrowserMainParts(
|
||||
const MainFunctionParams& parameters);
|
||||
|
||||
+ // Electron: Allows bypassing CORB checks for a renderer process.
|
||||
+ virtual bool ShouldBypassCORB(int render_process_id) const;
|
||||
+
|
||||
// Allows the embedder to change the default behavior of
|
||||
// BrowserThread::PostAfterStartupTask to better match whatever
|
||||
// definition of "startup" the embedder has in mind. This may be
|
||||
@@ -17,10 +17,10 @@ only one or two specific checks fail. Then it's better to simply comment out the
|
||||
failing checks and allow the rest of the target to have them enabled.
|
||||
|
||||
diff --git a/content/browser/frame_host/navigation_controller_impl.cc b/content/browser/frame_host/navigation_controller_impl.cc
|
||||
index 6a3cca0f846c944f23afe91ca149a0aa28bc18aa..20b3f2ef31d2f036fb0a08d5d7678bb9e67532e6 100644
|
||||
index cb86fa407c6f084070841ef65db9b31f264706d3..5d5ddcb77ba102489182c44e9580d750450f899f 100644
|
||||
--- a/content/browser/frame_host/navigation_controller_impl.cc
|
||||
+++ b/content/browser/frame_host/navigation_controller_impl.cc
|
||||
@@ -1211,8 +1211,10 @@ NavigationType NavigationControllerImpl::ClassifyNavigation(
|
||||
@@ -1210,8 +1210,10 @@ NavigationType NavigationControllerImpl::ClassifyNavigation(
|
||||
return NAVIGATION_TYPE_NEW_SUBFRAME;
|
||||
}
|
||||
|
||||
@@ -33,7 +33,7 @@ index 6a3cca0f846c944f23afe91ca149a0aa28bc18aa..20b3f2ef31d2f036fb0a08d5d7678bb9
|
||||
|
||||
if (rfh->GetParent()) {
|
||||
// All manual subframes would be did_create_new_entry and handled above, so
|
||||
@@ -1464,7 +1466,10 @@ void NavigationControllerImpl::RendererDidNavigateToNewPage(
|
||||
@@ -1463,7 +1465,10 @@ void NavigationControllerImpl::RendererDidNavigateToNewPage(
|
||||
new_entry->GetFavicon() = GetLastCommittedEntry()->GetFavicon();
|
||||
}
|
||||
|
||||
@@ -46,10 +46,10 @@ index 6a3cca0f846c944f23afe91ca149a0aa28bc18aa..20b3f2ef31d2f036fb0a08d5d7678bb9
|
||||
// navigation. Now we know that the renderer has updated its state accordingly
|
||||
// and it is safe to also clear the browser side history.
|
||||
diff --git a/ui/base/clipboard/clipboard_win.cc b/ui/base/clipboard/clipboard_win.cc
|
||||
index 82bdc4eccf06b7c636dd48cfffebe2606c2cff38..c4385984ebc23bc0a89e7e6ae7d42715a707177d 100644
|
||||
index 34c13c28117fe5fced5ca3190c5f948168cd010f..554ddabee8952e578a61a9b9c3f358b2475abd69 100644
|
||||
--- a/ui/base/clipboard/clipboard_win.cc
|
||||
+++ b/ui/base/clipboard/clipboard_win.cc
|
||||
@@ -729,9 +729,9 @@ void ClipboardWin::WriteBitmapFromHandle(HBITMAP source_hbitmap,
|
||||
@@ -730,9 +730,9 @@ void ClipboardWin::WriteBitmapFromHandle(HBITMAP source_hbitmap,
|
||||
}
|
||||
|
||||
void ClipboardWin::WriteToClipboard(unsigned int format, HANDLE handle) {
|
||||
|
||||
@@ -36,7 +36,7 @@ index 8e02a8a95eb07516162eacdf5b361231d3a02975..3497b85428a52c6019cfb5d30229071f
|
||||
virtual content::DesktopMediaID::Type GetMediaListType() const = 0;
|
||||
};
|
||||
diff --git a/chrome/browser/media/webrtc/desktop_media_list_base.cc b/chrome/browser/media/webrtc/desktop_media_list_base.cc
|
||||
index 983a8303b11527cdab449d03485653b8c27102de..1362161da462be4eb70f9e698eb274c1890ac0ab 100644
|
||||
index 7346429314858b4ce7e5caaea7c3328ca22b1b02..fd98c0eb68f04f9f3bdbe8c77cfeb523d685ba87 100644
|
||||
--- a/chrome/browser/media/webrtc/desktop_media_list_base.cc
|
||||
+++ b/chrome/browser/media/webrtc/desktop_media_list_base.cc
|
||||
@@ -21,6 +21,11 @@ DesktopMediaListBase::DesktopMediaListBase(base::TimeDelta update_period)
|
||||
@@ -94,9 +94,9 @@ index 983a8303b11527cdab449d03485653b8c27102de..1362161da462be4eb70f9e698eb274c1
|
||||
void DesktopMediaListBase::ScheduleNextRefresh() {
|
||||
+ if (!observer_->ShouldScheduleNextRefresh(this))
|
||||
+ return;
|
||||
base::PostDelayedTaskWithTraits(FROM_HERE, {BrowserThread::UI},
|
||||
base::BindOnce(&DesktopMediaListBase::Refresh,
|
||||
weak_factory_.GetWeakPtr()),
|
||||
base::PostDelayedTask(FROM_HERE, {BrowserThread::UI},
|
||||
base::BindOnce(&DesktopMediaListBase::Refresh,
|
||||
weak_factory_.GetWeakPtr()),
|
||||
diff --git a/chrome/browser/media/webrtc/desktop_media_list_base.h b/chrome/browser/media/webrtc/desktop_media_list_base.h
|
||||
index 29ef83096f7a7c69c67e9ad1bee2c45723e58f3f..ec228a826b298eb590f15c843e3346460ae13321 100644
|
||||
--- a/chrome/browser/media/webrtc/desktop_media_list_base.h
|
||||
@@ -133,12 +133,12 @@ index 47401abc984e6fe26c7f4c5399aa565c687060b0..ca6a527ffac877c27aac94337ec5a7b5
|
||||
protected:
|
||||
virtual ~DesktopMediaListObserver() {}
|
||||
diff --git a/chrome/browser/media/webrtc/native_desktop_media_list.cc b/chrome/browser/media/webrtc/native_desktop_media_list.cc
|
||||
index 872152cededb29ca3c04b2deb3fe6491be001af9..4ca62f03abf11bf9d0a48c85a79e098fb6758a30 100644
|
||||
index b2005c70acbc1c05c59bb2059b190ab78fb63a68..1a7188e2df76672d66da3206d4448df35a065754 100644
|
||||
--- a/chrome/browser/media/webrtc/native_desktop_media_list.cc
|
||||
+++ b/chrome/browser/media/webrtc/native_desktop_media_list.cc
|
||||
@@ -7,14 +7,15 @@
|
||||
#include "base/bind.h"
|
||||
@@ -8,14 +8,15 @@
|
||||
#include "base/hash/hash.h"
|
||||
#include "base/message_loop/message_pump_type.h"
|
||||
#include "base/single_thread_task_runner.h"
|
||||
+#include "base/strings/string_number_conversions.h"
|
||||
#include "base/strings/utf_string_conversions.h"
|
||||
|
||||
@@ -15,7 +15,7 @@ the redraw locking mechanism, which fixes these issues. The electron issue
|
||||
can be found at https://github.com/electron/electron/issues/1821
|
||||
|
||||
diff --git a/ui/views/win/hwnd_message_handler.cc b/ui/views/win/hwnd_message_handler.cc
|
||||
index 9b683f301913f85b6849439dd230cc4cf32eca1d..44dbae9b1ed1486a0119666eae8a531b7d9c50d3 100644
|
||||
index 8cde33ad0e4e81534f3e808aa37f7135fb994719..743c7d2ae18cc17e509ffa253dc25c64762d8902 100644
|
||||
--- a/ui/views/win/hwnd_message_handler.cc
|
||||
+++ b/ui/views/win/hwnd_message_handler.cc
|
||||
@@ -331,6 +331,10 @@ constexpr int kSynthesizedMouseMessagesTimeDifference = 500;
|
||||
@@ -37,7 +37,7 @@ index 9b683f301913f85b6849439dd230cc4cf32eca1d..44dbae9b1ed1486a0119666eae8a531b
|
||||
(!(GetWindowLong(hwnd_, GWL_STYLE) & WS_CAPTION) ||
|
||||
!ui::win::IsAeroGlassEnabled())) {
|
||||
if (should_lock_)
|
||||
@@ -989,6 +994,10 @@ bool HWNDMessageHandler::HasChildRenderingWindow() {
|
||||
@@ -992,6 +997,10 @@ bool HWNDMessageHandler::HasChildRenderingWindow() {
|
||||
hwnd());
|
||||
}
|
||||
|
||||
@@ -49,12 +49,12 @@ index 9b683f301913f85b6849439dd230cc4cf32eca1d..44dbae9b1ed1486a0119666eae8a531b
|
||||
// HWNDMessageHandler, gfx::WindowImpl overrides:
|
||||
|
||||
diff --git a/ui/views/win/hwnd_message_handler.h b/ui/views/win/hwnd_message_handler.h
|
||||
index 9f0a1a8698838cd797f22cbc4fb100b024758927..2733d8d0220ef92458ca295484525006ddb9d5e8 100644
|
||||
index d85486af34da6bcc11c0bc0ccd6349b161b1dac3..c59cd6f26a4ed39cff294316a9771f063712a8c0 100644
|
||||
--- a/ui/views/win/hwnd_message_handler.h
|
||||
+++ b/ui/views/win/hwnd_message_handler.h
|
||||
@@ -193,6 +193,8 @@ class VIEWS_EXPORT HWNDMessageHandler : public gfx::WindowImpl,
|
||||
@@ -194,6 +194,8 @@ class VIEWS_EXPORT HWNDMessageHandler : public gfx::WindowImpl,
|
||||
using TouchIDs = std::set<DWORD>;
|
||||
enum class DwmFrameState { OFF, ON };
|
||||
enum class DwmFrameState { kOff, kOn };
|
||||
|
||||
+ bool HasNativeFrame();
|
||||
+
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Birunthan Mohanathas <birunthan@mohanathas.com>
|
||||
Date: Fri, 30 Nov 2018 12:44:12 +0200
|
||||
Subject: Add --disable-color-correct-rendering switch
|
||||
Subject: disable_color_correct_rendering.patch
|
||||
|
||||
In Electron 2.0, `--disable-features=ColorCorrectRendering` could be
|
||||
This adds a --disable-color-correct-rendering switch. In Electron 2.0,
|
||||
`--disable-features=ColorCorrectRendering` could be
|
||||
used to make the app use the display color space (e.g. P3 on Macs)
|
||||
instead of color correcting to sRGB. Because color correct rendering is
|
||||
always enabled on Chromium 62 and later and because
|
||||
@@ -19,7 +20,7 @@ to deal with color spaces. That is being tracked at
|
||||
https://crbug.com/634542 and https://crbug.com/711107.
|
||||
|
||||
diff --git a/cc/trees/layer_tree_settings.h b/cc/trees/layer_tree_settings.h
|
||||
index d62c52b53268b4ffab702a0dac3652edc472ccb9..f1ed520f123802469d94c98c418b9f5c5d2032e0 100644
|
||||
index 8fdcc4194291910c42c103b77cf4e8267b81f566..1ad01316f2e5aca2bdd3c2ce752bd5a478a920ee 100644
|
||||
--- a/cc/trees/layer_tree_settings.h
|
||||
+++ b/cc/trees/layer_tree_settings.h
|
||||
@@ -95,6 +95,8 @@ class CC_EXPORT LayerTreeSettings {
|
||||
@@ -32,7 +33,7 @@ index d62c52b53268b4ffab702a0dac3652edc472ccb9..f1ed520f123802469d94c98c418b9f5c
|
||||
// Image Decode Service and raster tiles without images until the decode is
|
||||
// ready.
|
||||
diff --git a/components/viz/common/display/renderer_settings.h b/components/viz/common/display/renderer_settings.h
|
||||
index e33255364c18298192cf26a783204235f2daedb5..eec7c487ce0bf2d36a48402773c35556c7fddb67 100644
|
||||
index 389f2ed29bd85c35b38df92346a8d6c76ce22fd6..02cf492fa4068d10c4b8b2addee8102b35aac3e0 100644
|
||||
--- a/components/viz/common/display/renderer_settings.h
|
||||
+++ b/components/viz/common/display/renderer_settings.h
|
||||
@@ -23,6 +23,7 @@ class VIZ_COMMON_EXPORT RendererSettings {
|
||||
@@ -44,12 +45,12 @@ index e33255364c18298192cf26a783204235f2daedb5..eec7c487ce0bf2d36a48402773c35556
|
||||
bool force_antialiasing = false;
|
||||
bool force_blending_with_shaders = false;
|
||||
diff --git a/components/viz/host/renderer_settings_creation.cc b/components/viz/host/renderer_settings_creation.cc
|
||||
index cf3b10af046e7ac0607b1935369e963d969c0b82..6a6c3520fe11511ee3855944091deeb882240d0f 100644
|
||||
index f17aa1fa451f1b99d7f083e07edd49b11f7639e4..09f7c5d6a92d89c199b296771a8ff60c89a07083 100644
|
||||
--- a/components/viz/host/renderer_settings_creation.cc
|
||||
+++ b/components/viz/host/renderer_settings_creation.cc
|
||||
@@ -12,6 +12,7 @@
|
||||
#include "components/viz/common/display/renderer_settings.h"
|
||||
@@ -13,6 +13,7 @@
|
||||
#include "components/viz/common/features.h"
|
||||
#include "components/viz/common/switches.h"
|
||||
#include "ui/base/ui_base_switches.h"
|
||||
+#include "ui/gfx/switches.h"
|
||||
|
||||
@@ -65,7 +66,7 @@ index cf3b10af046e7ac0607b1935369e963d969c0b82..6a6c3520fe11511ee3855944091deeb8
|
||||
!command_line->HasSwitch(switches::kUIDisablePartialSwap);
|
||||
#if defined(OS_MACOSX)
|
||||
diff --git a/components/viz/service/display/gl_renderer.cc b/components/viz/service/display/gl_renderer.cc
|
||||
index 2fb123aa60201bfa912d0ec1e797a734f351b608..bf2bad3fce525df6e565e0387ffbefb59dd15052 100644
|
||||
index 8c67161c4a4b970fb9393a9a73a239b5aecb95cf..99ea5a9832aca67030e92e4761209872190388eb 100644
|
||||
--- a/components/viz/service/display/gl_renderer.cc
|
||||
+++ b/components/viz/service/display/gl_renderer.cc
|
||||
@@ -81,6 +81,9 @@
|
||||
@@ -90,7 +91,7 @@ index 2fb123aa60201bfa912d0ec1e797a734f351b608..bf2bad3fce525df6e565e0387ffbefb5
|
||||
|
||||
// Use the full quad_rect for debug quads to not move the edges based on
|
||||
// partial swaps.
|
||||
@@ -1406,7 +1410,8 @@ void GLRenderer::ChooseRPDQProgram(DrawRenderPassDrawQuadParams* params,
|
||||
@@ -1455,7 +1459,8 @@ void GLRenderer::ChooseRPDQProgram(DrawRenderPassDrawQuadParams* params,
|
||||
params->use_color_matrix, tint_gl_composited_content_,
|
||||
params->apply_shader_based_rounded_corner &&
|
||||
ShouldApplyRoundedCorner(params->quad)),
|
||||
@@ -100,7 +101,7 @@ index 2fb123aa60201bfa912d0ec1e797a734f351b608..bf2bad3fce525df6e565e0387ffbefb5
|
||||
}
|
||||
|
||||
void GLRenderer::UpdateRPDQUniforms(DrawRenderPassDrawQuadParams* params) {
|
||||
@@ -1877,8 +1882,8 @@ void GLRenderer::DrawSolidColorQuad(const SolidColorDrawQuad* quad,
|
||||
@@ -1926,8 +1931,8 @@ void GLRenderer::DrawSolidColorQuad(const SolidColorDrawQuad* quad,
|
||||
SetUseProgram(ProgramKey::SolidColor(use_aa ? USE_AA : NO_AA,
|
||||
tint_gl_composited_content_,
|
||||
ShouldApplyRoundedCorner(quad)),
|
||||
@@ -111,7 +112,7 @@ index 2fb123aa60201bfa912d0ec1e797a734f351b608..bf2bad3fce525df6e565e0387ffbefb5
|
||||
SetShaderColor(color, opacity);
|
||||
if (current_program_->rounded_corner_rect_location() != -1) {
|
||||
SetShaderRoundedCorner(
|
||||
@@ -2033,8 +2038,8 @@ void GLRenderer::DrawContentQuadAA(const ContentDrawQuadBase* quad,
|
||||
@@ -2082,8 +2087,8 @@ void GLRenderer::DrawContentQuadAA(const ContentDrawQuadBase* quad,
|
||||
: NON_PREMULTIPLIED_ALPHA,
|
||||
false, false, tint_gl_composited_content_,
|
||||
ShouldApplyRoundedCorner(quad)),
|
||||
@@ -122,7 +123,7 @@ index 2fb123aa60201bfa912d0ec1e797a734f351b608..bf2bad3fce525df6e565e0387ffbefb5
|
||||
|
||||
if (current_program_->tint_color_matrix_location() != -1) {
|
||||
auto matrix = cc::DebugColors::TintCompositedContentColorTransformMatrix();
|
||||
@@ -2130,8 +2135,8 @@ void GLRenderer::DrawContentQuadNoAA(const ContentDrawQuadBase* quad,
|
||||
@@ -2179,8 +2184,8 @@ void GLRenderer::DrawContentQuadNoAA(const ContentDrawQuadBase* quad,
|
||||
!quad->ShouldDrawWithBlending(), has_tex_clamp_rect,
|
||||
tint_gl_composited_content_,
|
||||
ShouldApplyRoundedCorner(quad)),
|
||||
@@ -133,16 +134,16 @@ index 2fb123aa60201bfa912d0ec1e797a734f351b608..bf2bad3fce525df6e565e0387ffbefb5
|
||||
|
||||
if (current_program_->tint_color_matrix_location() != -1) {
|
||||
auto matrix = cc::DebugColors::TintCompositedContentColorTransformMatrix();
|
||||
@@ -2234,7 +2239,7 @@ void GLRenderer::DrawYUVVideoQuad(const YUVVideoDrawQuad* quad,
|
||||
@@ -2283,7 +2288,7 @@ void GLRenderer::DrawYUVVideoQuad(const YUVVideoDrawQuad* quad,
|
||||
DCHECK_NE(src_color_space, src_color_space.GetAsFullRangeRGB());
|
||||
|
||||
gfx::ColorSpace dst_color_space =
|
||||
- current_frame()->current_render_pass->color_space;
|
||||
+ PATCH_CS(current_frame()->current_render_pass->color_space);
|
||||
|
||||
#if defined(OS_WIN)
|
||||
// Force sRGB output on Windows for overlay candidate video quads to match
|
||||
@@ -2393,8 +2398,8 @@ void GLRenderer::DrawStreamVideoQuad(const StreamVideoDrawQuad* quad,
|
||||
// DirectComposition behavior in case these switch between overlays and
|
||||
// compositing. See https://crbug.com/811118 for details.
|
||||
@@ -2439,8 +2444,8 @@ void GLRenderer::DrawStreamVideoQuad(const StreamVideoDrawQuad* quad,
|
||||
|
||||
SetUseProgram(ProgramKey::VideoStream(tex_coord_precision,
|
||||
ShouldApplyRoundedCorner(quad)),
|
||||
@@ -153,7 +154,7 @@ index 2fb123aa60201bfa912d0ec1e797a734f351b608..bf2bad3fce525df6e565e0387ffbefb5
|
||||
|
||||
DCHECK_EQ(GL_TEXTURE0, GetActiveTextureUnit(gl_));
|
||||
gl_->BindTexture(GL_TEXTURE_EXTERNAL_OES, lock.texture_id());
|
||||
@@ -2451,8 +2456,8 @@ void GLRenderer::FlushTextureQuadCache(BoundGeometry flush_binding) {
|
||||
@@ -2497,8 +2502,8 @@ void GLRenderer::FlushTextureQuadCache(BoundGeometry flush_binding) {
|
||||
draw_cache_.nearest_neighbor ? GL_NEAREST : GL_LINEAR);
|
||||
|
||||
// Bind the program to the GL state.
|
||||
@@ -164,7 +165,7 @@ index 2fb123aa60201bfa912d0ec1e797a734f351b608..bf2bad3fce525df6e565e0387ffbefb5
|
||||
|
||||
if (current_program_->rounded_corner_rect_location() != -1) {
|
||||
SetShaderRoundedCorner(
|
||||
@@ -3153,7 +3158,9 @@ void GLRenderer::PrepareGeometry(BoundGeometry binding) {
|
||||
@@ -3195,7 +3200,9 @@ void GLRenderer::PrepareGeometry(BoundGeometry binding) {
|
||||
void GLRenderer::SetUseProgram(const ProgramKey& program_key_no_color,
|
||||
const gfx::ColorSpace& src_color_space,
|
||||
const gfx::ColorSpace& dst_color_space) {
|
||||
@@ -175,7 +176,7 @@ index 2fb123aa60201bfa912d0ec1e797a734f351b608..bf2bad3fce525df6e565e0387ffbefb5
|
||||
|
||||
gfx::ColorSpace adjusted_color_space = src_color_space;
|
||||
float sdr_white_level = current_frame()->sdr_white_level;
|
||||
@@ -3540,7 +3547,7 @@ void GLRenderer::CopyRenderPassDrawQuadToOverlayResource(
|
||||
@@ -3574,7 +3581,7 @@ void GLRenderer::CopyRenderPassDrawQuadToOverlayResource(
|
||||
|
||||
*overlay_texture = FindOrCreateOverlayTexture(
|
||||
params.quad->render_pass_id, iosurface_width, iosurface_height,
|
||||
@@ -184,7 +185,7 @@ index 2fb123aa60201bfa912d0ec1e797a734f351b608..bf2bad3fce525df6e565e0387ffbefb5
|
||||
*new_bounds = gfx::RectF(updated_dst_rect.origin(),
|
||||
gfx::SizeF((*overlay_texture)->texture.size()));
|
||||
|
||||
@@ -3759,8 +3766,8 @@ void GLRenderer::FlushOverdrawFeedback(const gfx::Rect& output_rect) {
|
||||
@@ -3792,8 +3799,8 @@ void GLRenderer::FlushOverdrawFeedback(const gfx::Rect& output_rect) {
|
||||
|
||||
PrepareGeometry(SHARED_BINDING);
|
||||
|
||||
@@ -195,17 +196,17 @@ index 2fb123aa60201bfa912d0ec1e797a734f351b608..bf2bad3fce525df6e565e0387ffbefb5
|
||||
|
||||
gfx::Transform render_matrix;
|
||||
render_matrix.Translate(0.5 * output_rect.width() + output_rect.x(),
|
||||
@@ -3920,3 +3927,5 @@ gfx::Size GLRenderer::GetRenderPassBackingPixelSize(
|
||||
@@ -3953,3 +3960,5 @@ gfx::Size GLRenderer::GetRenderPassBackingPixelSize(
|
||||
}
|
||||
|
||||
} // namespace viz
|
||||
+
|
||||
+#undef PATCH_CS
|
||||
diff --git a/content/browser/gpu/gpu_process_host.cc b/content/browser/gpu/gpu_process_host.cc
|
||||
index a22390afced20c3a898aa5e84c403f90b1eb0fe2..d15b9978f6e9a2e0b51d1cf4c57a7fc5472b2b0c 100644
|
||||
index 350e8aa2ed6cb7b5725b23795a25edc710b3c6be..4c6e78f9dba1e607bee61842a884201ad085cfbe 100644
|
||||
--- a/content/browser/gpu/gpu_process_host.cc
|
||||
+++ b/content/browser/gpu/gpu_process_host.cc
|
||||
@@ -192,6 +192,7 @@ GpuTerminationStatus ConvertToGpuTerminationStatus(
|
||||
@@ -193,6 +193,7 @@ GpuTerminationStatus ConvertToGpuTerminationStatus(
|
||||
|
||||
// Command-line switches to propagate to the GPU process.
|
||||
static const char* const kSwitchNames[] = {
|
||||
@@ -214,10 +215,10 @@ index a22390afced20c3a898aa5e84c403f90b1eb0fe2..d15b9978f6e9a2e0b51d1cf4c57a7fc5
|
||||
service_manager::switches::kGpuSandboxAllowSysVShm,
|
||||
service_manager::switches::kGpuSandboxFailuresFatal,
|
||||
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
index 6f0671a753879d7b327681979090508e610cc129..f1beaf3433d67014cff527a686fd3239862eb537 100644
|
||||
index 299acbb8973f8b603575b006cfd1d296869f7c2a..32e4c105256e5d1a8930766433f8c1b28d88166d 100644
|
||||
--- a/content/browser/renderer_host/render_process_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
@@ -219,6 +219,7 @@
|
||||
@@ -218,6 +218,7 @@
|
||||
#include "ui/base/ui_base_switches.h"
|
||||
#include "ui/base/ui_base_switches_util.h"
|
||||
#include "ui/display/display_switches.h"
|
||||
@@ -225,7 +226,7 @@ index 6f0671a753879d7b327681979090508e610cc129..f1beaf3433d67014cff527a686fd3239
|
||||
#include "ui/gl/gl_switches.h"
|
||||
#include "ui/native_theme/native_theme_features.h"
|
||||
#include "url/url_constants.h"
|
||||
@@ -2933,6 +2934,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer(
|
||||
@@ -2903,6 +2904,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer(
|
||||
// Propagate the following switches to the renderer command line (along
|
||||
// with any associated values) if present in the browser command line.
|
||||
static const char* const kSwitchNames[] = {
|
||||
@@ -234,10 +235,10 @@ index 6f0671a753879d7b327681979090508e610cc129..f1beaf3433d67014cff527a686fd3239
|
||||
network::switches::kExplicitlyAllowedPorts,
|
||||
service_manager::switches::kDisableInProcessStackTraces,
|
||||
diff --git a/content/renderer/render_widget.cc b/content/renderer/render_widget.cc
|
||||
index 734c561001cc625c60851590d69bc7485928538a..1f56e138ae967e8f7c39a4629f6cb7dc590cf42c 100644
|
||||
index f15823dd27ae8f91257afd8ae81a9c3915c50059..c8d239ff9a5a66f02248ef6b9e202e7c347c356c 100644
|
||||
--- a/content/renderer/render_widget.cc
|
||||
+++ b/content/renderer/render_widget.cc
|
||||
@@ -2854,6 +2854,9 @@ cc::LayerTreeSettings RenderWidget::GenerateLayerTreeSettings(
|
||||
@@ -2861,6 +2861,9 @@ cc::LayerTreeSettings RenderWidget::GenerateLayerTreeSettings(
|
||||
settings.main_frame_before_activation_enabled =
|
||||
cmd.HasSwitch(cc::switches::kEnableMainFrameBeforeActivation);
|
||||
|
||||
@@ -248,7 +249,7 @@ index 734c561001cc625c60851590d69bc7485928538a..1f56e138ae967e8f7c39a4629f6cb7dc
|
||||
// is what the renderer uses if its not threaded.
|
||||
settings.enable_checker_imaging =
|
||||
diff --git a/ui/gfx/mac/io_surface.cc b/ui/gfx/mac/io_surface.cc
|
||||
index 3d936357343e9829768891a45b6459d6a1bbb4f1..55062c91722b900bbbc775c0c88cfc6e57ddc04b 100644
|
||||
index 41f7fcbdd63af315f4b4e768bfef3b5004807a0b..398a4fdea3cc0ab4f5132deeb9365189f9c928c3 100644
|
||||
--- a/ui/gfx/mac/io_surface.cc
|
||||
+++ b/ui/gfx/mac/io_surface.cc
|
||||
@@ -16,6 +16,7 @@
|
||||
@@ -259,7 +260,7 @@ index 3d936357343e9829768891a45b6459d6a1bbb4f1..55062c91722b900bbbc775c0c88cfc6e
|
||||
|
||||
namespace gfx {
|
||||
|
||||
@@ -191,6 +192,11 @@ IOSurfaceRef CreateIOSurface(const gfx::Size& size,
|
||||
@@ -186,6 +187,11 @@ IOSurfaceRef CreateIOSurface(const gfx::Size& size,
|
||||
|
||||
// Ensure that all IOSurfaces start as sRGB.
|
||||
CGColorSpaceRef color_space = base::mac::GetSRGBColorSpace();
|
||||
@@ -271,7 +272,7 @@ index 3d936357343e9829768891a45b6459d6a1bbb4f1..55062c91722b900bbbc775c0c88cfc6e
|
||||
base::ScopedCFTypeRef<CFDataRef> color_space_icc(
|
||||
CGColorSpaceCopyICCProfile(color_space));
|
||||
IOSurfaceSetValue(surface, CFSTR("IOSurfaceColorSpace"), color_space_icc);
|
||||
@@ -202,6 +208,14 @@ IOSurfaceRef CreateIOSurface(const gfx::Size& size,
|
||||
@@ -197,6 +203,14 @@ IOSurfaceRef CreateIOSurface(const gfx::Size& size,
|
||||
|
||||
void IOSurfaceSetColorSpace(IOSurfaceRef io_surface,
|
||||
const ColorSpace& color_space) {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Nitish Sakhawalkar <nitsakh@icloud.com>
|
||||
Date: Mon, 13 May 2019 15:48:36 -0700
|
||||
Subject: Disable custom libcxx on windows
|
||||
Subject: disable_custom_libcxx_on_windows.patch
|
||||
|
||||
|
||||
diff --git a/build/config/c++/c++.gni b/build/config/c++/c++.gni
|
||||
|
||||
@@ -5,10 +5,10 @@ Subject: disable_hidden.patch
|
||||
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
index 8278ff4f07e5a18941521c92c819d099636b96b4..8606461c0422460e5d2d6adab0fea4ad8060ece5 100644
|
||||
index 3925586d55cb79a26b231781a821c510dfe17bd4..1ccff96eccde8dbff2b972d53c05486fb160c5db 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
@@ -670,6 +670,9 @@ void RenderWidgetHostImpl::WasHidden() {
|
||||
@@ -675,6 +675,9 @@ void RenderWidgetHostImpl::WasHidden() {
|
||||
if (is_hidden_)
|
||||
return;
|
||||
|
||||
@@ -19,10 +19,10 @@ index 8278ff4f07e5a18941521c92c819d099636b96b4..8606461c0422460e5d2d6adab0fea4ad
|
||||
|
||||
TRACE_EVENT0("renderer_host", "RenderWidgetHostImpl::WasHidden");
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.h b/content/browser/renderer_host/render_widget_host_impl.h
|
||||
index 350770092301beffa86a658a5c42276b238d0800..9296c0ad7f83cd4a5dce041de2fb97a537e44858 100644
|
||||
index ef6276238004ff6e12de90d03be1f720c1ac266c..b8d981a45edb22a60cc439e881a4bc81854b35cd 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.h
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.h
|
||||
@@ -156,6 +156,9 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
||||
@@ -183,6 +183,9 @@ class CONTENT_EXPORT RenderWidgetHostImpl
|
||||
// RenderWidgetHostImpl.
|
||||
static RenderWidgetHostImpl* From(RenderWidgetHost* rwh);
|
||||
|
||||
|
||||
@@ -1,26 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Cheng Zhao <zcbenz@gmail.com>
|
||||
Date: Tue, 9 Apr 2019 14:57:02 -0700
|
||||
Subject: disable_network_services_by_default.patch
|
||||
|
||||
Disable NetworkService by default.
|
||||
|
||||
This allows us to enable NetworkService with command line flags, which makes it
|
||||
easier to work on NetworkService migration.
|
||||
|
||||
We should remove this patch after all Electron's code has been migrated to the
|
||||
NetworkService.
|
||||
|
||||
diff --git a/services/network/public/cpp/features.cc b/services/network/public/cpp/features.cc
|
||||
index d10016967b1ac607166e593fbddf39a8fc533fe0..2f8d69091a3eeb46e52d48c015d76df9fe41e350 100644
|
||||
--- a/services/network/public/cpp/features.cc
|
||||
+++ b/services/network/public/cpp/features.cc
|
||||
@@ -23,7 +23,7 @@ const base::Feature kNetworkService {
|
||||
#else
|
||||
"NetworkServiceNotSupported",
|
||||
#endif
|
||||
- base::FEATURE_ENABLED_BY_DEFAULT
|
||||
+ base::FEATURE_DISABLED_BY_DEFAULT
|
||||
};
|
||||
|
||||
// Out of Blink CORS
|
||||
@@ -6,10 +6,10 @@ Subject: disable_user_gesture_requirement_for_beforeunload_dialogs.patch
|
||||
See https://github.com/electron/electron/issues/10754
|
||||
|
||||
diff --git a/third_party/blink/renderer/core/dom/document.cc b/third_party/blink/renderer/core/dom/document.cc
|
||||
index ac89475a90cdf889c073c6d7749732285455db8c..ed658f7a115087cdec0778ace5ad80b8643d5e92 100644
|
||||
index 6a99225ce1f53582c1ce578f9ae7f5eb40544b95..05f9d5da2b819b0f15fe021dccaeff9480aaa827 100644
|
||||
--- a/third_party/blink/renderer/core/dom/document.cc
|
||||
+++ b/third_party/blink/renderer/core/dom/document.cc
|
||||
@@ -4067,7 +4067,9 @@ bool Document::DispatchBeforeUnloadEvent(ChromeClient* chrome_client,
|
||||
@@ -4139,7 +4139,9 @@ bool Document::DispatchBeforeUnloadEvent(ChromeClient* chrome_client,
|
||||
"frame that never had a user gesture since its load. "
|
||||
"https://www.chromestatus.com/feature/5082396709879808";
|
||||
Intervention::GenerateReport(frame_, "BeforeUnloadNoGesture", message);
|
||||
|
||||
@@ -31,27 +31,10 @@ With that in mind, an acceptable alternative to disabling the limit at compile-t
|
||||
for a given `BrowserWindow` via a `webPreferences` option,
|
||||
similar to [`nodeIntegration`](https://electronjs.org/docs/tutorial/security#2-disable-nodejs-integration-for-remote-content).
|
||||
|
||||
diff --git a/content/common/dom_storage/dom_storage_map.cc b/content/common/dom_storage/dom_storage_map.cc
|
||||
index fd088fb170bead6452ded14016f21f0c29659e03..b90b6cf9132d16bc3b2076c3fa313916e2b5ea7d 100644
|
||||
--- a/content/common/dom_storage/dom_storage_map.cc
|
||||
+++ b/content/common/dom_storage/dom_storage_map.cc
|
||||
@@ -185,10 +185,12 @@ bool DOMStorageMap::SetItemInternal(MapType* map_type,
|
||||
size_t new_item_size = size_in_storage(key, value);
|
||||
size_t new_storage_used = storage_used_ - old_item_size + new_item_size;
|
||||
|
||||
+#if 0
|
||||
// Only check quota if the size is increasing, this allows
|
||||
// shrinking changes to pre-existing files that are over budget.
|
||||
if (new_item_size > old_item_size && new_storage_used > quota_)
|
||||
return false;
|
||||
+#endif
|
||||
|
||||
(*map_type)[key] = value;
|
||||
ResetKeyIterator();
|
||||
diff --git a/content/common/dom_storage/dom_storage_types.h b/content/common/dom_storage/dom_storage_types.h
|
||||
index e87afe5b8ee07f7038a7cc9c40832b6cd27884da..61c9a0dfff60f79c7b36ff5c7d741c06dca03ada 100644
|
||||
--- a/content/common/dom_storage/dom_storage_types.h
|
||||
+++ b/content/common/dom_storage/dom_storage_types.h
|
||||
diff --git a/content/browser/dom_storage/dom_storage_types.h b/content/browser/dom_storage/dom_storage_types.h
|
||||
index 6c0b831ebaaa2c1749bbc7436ce1025656588310..b67767751cadc6072c133297c7a6cdcc6bfd0c98 100644
|
||||
--- a/content/browser/dom_storage/dom_storage_types.h
|
||||
+++ b/content/browser/dom_storage/dom_storage_types.h
|
||||
@@ -21,6 +21,7 @@ typedef std::map<base::string16, base::NullableString16> DOMStorageValuesMap;
|
||||
|
||||
// The quota for each storage area.
|
||||
@@ -61,7 +44,7 @@ index e87afe5b8ee07f7038a7cc9c40832b6cd27884da..61c9a0dfff60f79c7b36ff5c7d741c06
|
||||
|
||||
// In the browser process we allow some overage to
|
||||
diff --git a/third_party/blink/renderer/modules/storage/cached_storage_area.cc b/third_party/blink/renderer/modules/storage/cached_storage_area.cc
|
||||
index 4b976b74490234cd9ad5ac7a0a63708b6edbbae3..183ed46369dc0f0026c53521d19209011d2d0eea 100644
|
||||
index d91fdc2a7d52307126bc04d44167edadb8c743a8..630acfca527aaec44742d45e47ce29d7754e3385 100644
|
||||
--- a/third_party/blink/renderer/modules/storage/cached_storage_area.cc
|
||||
+++ b/third_party/blink/renderer/modules/storage/cached_storage_area.cc
|
||||
@@ -107,11 +107,13 @@ bool CachedStorageArea::SetItem(const String& key,
|
||||
|
||||
@@ -8,7 +8,7 @@ this but it is not a blocker for releasing Electron. This patch removes
|
||||
the hard fail on dylib resolve failure from dump_syms
|
||||
|
||||
diff --git a/components/crash/content/tools/generate_breakpad_symbols.py b/components/crash/content/tools/generate_breakpad_symbols.py
|
||||
index 937548cc0303d67402f42a6910cfc57bf0e53d64..dce68b1bd1ef58a5dfddb2bbdb56930ed943ad1d 100755
|
||||
index cdd374c33a3edc12db9c9496a4ca765d2ba0ab5d..db04d39f8d263dc2b3b67b7f84470f557b519cfa 100755
|
||||
--- a/components/crash/content/tools/generate_breakpad_symbols.py
|
||||
+++ b/components/crash/content/tools/generate_breakpad_symbols.py
|
||||
@@ -175,7 +175,7 @@ def GetSharedLibraryDependenciesMac(binary, exe_path):
|
||||
|
||||
@@ -7,10 +7,10 @@ Compilation of those files fails with the Chromium 68.
|
||||
Remove the patch during the Chromium 69 upgrade.
|
||||
|
||||
diff --git a/third_party/blink/renderer/platform/BUILD.gn b/third_party/blink/renderer/platform/BUILD.gn
|
||||
index 0764cc88a8c4753a1c682e4164ec1988f7b824dd..cb1314d44fe2150a049e1e6072f036ffd26a5bfb 100644
|
||||
index a4d738446b0cc23397adc4cf9518ff96f378e35a..4d643c011d17c63db33a39d0b4e5aa4c2ee435fa 100644
|
||||
--- a/third_party/blink/renderer/platform/BUILD.gn
|
||||
+++ b/third_party/blink/renderer/platform/BUILD.gn
|
||||
@@ -1706,7 +1706,7 @@ jumbo_source_set("blink_platform_unittests_sources") {
|
||||
@@ -1746,7 +1746,7 @@ jumbo_source_set("blink_platform_unittests_sources") {
|
||||
"graphics/paint/drawing_display_item_test.cc",
|
||||
"graphics/paint/drawing_recorder_test.cc",
|
||||
"graphics/paint/float_clip_rect_test.cc",
|
||||
|
||||
@@ -1,29 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Jeremy Apthorp <jeremya@chromium.org>
|
||||
Date: Thu, 18 Oct 2018 17:06:56 -0700
|
||||
Subject: expose-net-observer-api.patch
|
||||
|
||||
Expose URLRequestContextGetter::{Add,Remove}Observer.
|
||||
This patch should be removed once we switch to using the net service (cc @robo)
|
||||
|
||||
diff --git a/net/url_request/url_request_context_getter.h b/net/url_request/url_request_context_getter.h
|
||||
index def76d3902f30ae1384ae5f629fa116b3975fa86..e5ee0bfa93f497f18bdb3ad7cd51a6726dc87f3e 100644
|
||||
--- a/net/url_request/url_request_context_getter.h
|
||||
+++ b/net/url_request/url_request_context_getter.h
|
||||
@@ -79,11 +79,16 @@ class NET_EXPORT URLRequestContextGetter
|
||||
friend class web::NetworkContextOwner;
|
||||
#endif // defined(OS_IOS)
|
||||
|
||||
+ // NOTE(nornagon/robo): electron currently depends on this deprecated API
|
||||
+ // from net/, but will be removing it soon when we switch to using the
|
||||
+ // network service.
|
||||
+ public:
|
||||
// Adds / removes an observer to watch for shutdown of |this|'s context. Must
|
||||
// only be called on network thread. May not be called once
|
||||
// GetURLRequestContext() starts returning nullptr.
|
||||
void AddObserver(URLRequestContextGetterObserver* observer);
|
||||
void RemoveObserver(URLRequestContextGetterObserver* observer);
|
||||
+ private:
|
||||
|
||||
// OnDestruct is used to ensure deletion on the thread on which the request
|
||||
// IO happens.
|
||||
90
patches/chromium/expose_setuseragent_on_networkcontext.patch
Normal file
90
patches/chromium/expose_setuseragent_on_networkcontext.patch
Normal file
@@ -0,0 +1,90 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Jeremy Apthorp <nornagon@nornagon.net>
|
||||
Date: Wed, 28 Aug 2019 12:21:25 -0700
|
||||
Subject: expose SetUserAgent on NetworkContext
|
||||
|
||||
Applying
|
||||
https://chromium-review.googlesource.com/c/chromium/src/+/1585083 before
|
||||
it's merged. There may end up being a better way of doing this, or the
|
||||
patch may be merged upstream, at which point this patch should be
|
||||
removed.
|
||||
|
||||
diff --git a/net/url_request/static_http_user_agent_settings.h b/net/url_request/static_http_user_agent_settings.h
|
||||
index 0ccfe130f00ec3b6c75cd8ee04d5a2777e1fd00c..653829457d58bf92057cc36aa8a289703d8b0577 100644
|
||||
--- a/net/url_request/static_http_user_agent_settings.h
|
||||
+++ b/net/url_request/static_http_user_agent_settings.h
|
||||
@@ -26,13 +26,17 @@ class NET_EXPORT StaticHttpUserAgentSettings : public HttpUserAgentSettings {
|
||||
accept_language_ = new_accept_language;
|
||||
}
|
||||
|
||||
+ void set_user_agent(const std::string& new_user_agent) {
|
||||
+ user_agent_ = new_user_agent;
|
||||
+ }
|
||||
+
|
||||
// HttpUserAgentSettings implementation
|
||||
std::string GetAcceptLanguage() const override;
|
||||
std::string GetUserAgent() const override;
|
||||
|
||||
private:
|
||||
std::string accept_language_;
|
||||
- const std::string user_agent_;
|
||||
+ std::string user_agent_;
|
||||
|
||||
DISALLOW_COPY_AND_ASSIGN(StaticHttpUserAgentSettings);
|
||||
};
|
||||
diff --git a/services/network/network_context.cc b/services/network/network_context.cc
|
||||
index 13fcd399516c7c26cf89a15dda083faea97ea969..7feed6ef9374d37430584f58272790e0e801f148 100644
|
||||
--- a/services/network/network_context.cc
|
||||
+++ b/services/network/network_context.cc
|
||||
@@ -1095,6 +1095,13 @@ void NetworkContext::SetNetworkConditions(
|
||||
std::move(network_conditions));
|
||||
}
|
||||
|
||||
+void NetworkContext::SetUserAgent(const std::string& new_user_agent) {
|
||||
+ // This may only be called on NetworkContexts created with a constructor that
|
||||
+ // calls ApplyContextParamsToBuilder.
|
||||
+ DCHECK(user_agent_settings_);
|
||||
+ user_agent_settings_->set_user_agent(new_user_agent);
|
||||
+}
|
||||
+
|
||||
void NetworkContext::SetAcceptLanguage(const std::string& new_accept_language) {
|
||||
// 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 f765e5e232de56f070d404e16149abd6627159cd..ce9955126f84f0cd7c7b7961c6dc6f0709359b17 100644
|
||||
--- a/services/network/network_context.h
|
||||
+++ b/services/network/network_context.h
|
||||
@@ -214,6 +214,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
void CloseIdleConnections(CloseIdleConnectionsCallback callback) override;
|
||||
void SetNetworkConditions(const base::UnguessableToken& throttling_profile_id,
|
||||
mojom::NetworkConditionsPtr conditions) override;
|
||||
+ void SetUserAgent(const std::string& new_user_agent) override;
|
||||
void SetAcceptLanguage(const std::string& new_accept_language) override;
|
||||
void SetEnableReferrers(bool enable_referrers) override;
|
||||
#if defined(OS_CHROMEOS)
|
||||
diff --git a/services/network/public/mojom/network_context.mojom b/services/network/public/mojom/network_context.mojom
|
||||
index 4e21a1276d83ce0154aa06e169e4b4394d215164..79b2088852fc9d930935e86de029d654749e7d6a 100644
|
||||
--- a/services/network/public/mojom/network_context.mojom
|
||||
+++ b/services/network/public/mojom/network_context.mojom
|
||||
@@ -859,6 +859,9 @@ interface NetworkContext {
|
||||
SetNetworkConditions(mojo_base.mojom.UnguessableToken throttling_profile_id,
|
||||
NetworkConditions? conditions);
|
||||
|
||||
+ // Updates the user agent to be used for requests.
|
||||
+ SetUserAgent(string new_user_agent);
|
||||
+
|
||||
// Updates the Accept-Language header to be used for requests.
|
||||
SetAcceptLanguage(string new_accept_language);
|
||||
|
||||
diff --git a/services/network/test/test_network_context.h b/services/network/test/test_network_context.h
|
||||
index 0608e512432bc3426714d78bddd87bf537ddebae..7bed7ebc5e52660fff7cb6b93a618e0a16376ab8 100644
|
||||
--- a/services/network/test/test_network_context.h
|
||||
+++ b/services/network/test/test_network_context.h
|
||||
@@ -94,6 +94,7 @@ class TestNetworkContext : public mojom::NetworkContext {
|
||||
void CloseIdleConnections(CloseIdleConnectionsCallback callback) override {}
|
||||
void SetNetworkConditions(const base::UnguessableToken& throttling_profile_id,
|
||||
mojom::NetworkConditionsPtr conditions) override {}
|
||||
+ void SetUserAgent(const std::string& new_user_agent) override {}
|
||||
void SetAcceptLanguage(const std::string& new_accept_language) override {}
|
||||
void SetEnableReferrers(bool enable_referrers) override {}
|
||||
#if defined(OS_CHROMEOS)
|
||||
@@ -1,7 +1,7 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Heilig Benedek <benecene@gmail.com>
|
||||
Date: Wed, 20 Mar 2019 20:30:44 +0100
|
||||
Subject: feat: offscreen rendering with viz compositor
|
||||
Subject: feat_offscreen_rendering_with_viz_compositor.patch
|
||||
|
||||
|
||||
diff --git a/components/viz/host/host_display_client.cc b/components/viz/host/host_display_client.cc
|
||||
@@ -45,7 +45,7 @@ index f5e18df4e06e24d3bdd51308abde48e217444848..41017d9d53b1c0d563ea0901f5cae407
|
||||
#if defined(USE_X11)
|
||||
void HostDisplayClient::DidCompleteSwapWithNewSize(const gfx::Size& size) {
|
||||
diff --git a/components/viz/host/host_display_client.h b/components/viz/host/host_display_client.h
|
||||
index 5e5c5da4a3cfc927df3fb120fcab647e927271c1..8c6ec95f309660fb83012a13c7b9bb64b782e7d9 100644
|
||||
index b8177277ebca471fc147f2d5b53521cbadd8fa2d..72a807e138f80b4ab37cb1d368bc968e299d903f 100644
|
||||
--- a/components/viz/host/host_display_client.h
|
||||
+++ b/components/viz/host/host_display_client.h
|
||||
@@ -30,17 +30,17 @@ class VIZ_HOST_EXPORT HostDisplayClient : public mojom::DisplayClient {
|
||||
@@ -85,7 +85,7 @@ index 65c26e2f7ae813e50f6740f73a4d145467da4366..39c04c4d6b644a4ad7b13b4e932b085f
|
||||
|
||||
if (!canvas_) {
|
||||
diff --git a/components/viz/host/layered_window_updater_impl.h b/components/viz/host/layered_window_updater_impl.h
|
||||
index d9a9730a78b9aec833c64282ca868dbba5594d82..d98426e9f78931bd43061ec994559d594c96151c 100644
|
||||
index ced30727ab67e557265c3a61f7c213763da973ce..f422786fe6cd9cab47494fe6028f3c3be8bc763e 100644
|
||||
--- a/components/viz/host/layered_window_updater_impl.h
|
||||
+++ b/components/viz/host/layered_window_updater_impl.h
|
||||
@@ -33,7 +33,7 @@ class VIZ_HOST_EXPORT LayeredWindowUpdaterImpl
|
||||
@@ -98,10 +98,10 @@ index d9a9730a78b9aec833c64282ca868dbba5594d82..d98426e9f78931bd43061ec994559d59
|
||||
private:
|
||||
const HWND hwnd_;
|
||||
diff --git a/components/viz/service/BUILD.gn b/components/viz/service/BUILD.gn
|
||||
index a43cee43701fc3c139c726d14b128de3ae71c2c2..32ce9f5634ddefd5cd0feaa551f04697b53da68d 100644
|
||||
index a3fc1b3bdc9c22f4ac4b1ae8ddd992f419d04d55..0da7bf23e0f5309887c9038a14c33d2d80095d0b 100644
|
||||
--- a/components/viz/service/BUILD.gn
|
||||
+++ b/components/viz/service/BUILD.gn
|
||||
@@ -113,6 +113,8 @@ viz_component("service") {
|
||||
@@ -118,6 +118,8 @@ viz_component("service") {
|
||||
"display_embedder/output_surface_provider_impl.h",
|
||||
"display_embedder/server_shared_bitmap_manager.cc",
|
||||
"display_embedder/server_shared_bitmap_manager.h",
|
||||
@@ -111,7 +111,7 @@ index a43cee43701fc3c139c726d14b128de3ae71c2c2..32ce9f5634ddefd5cd0feaa551f04697
|
||||
"display_embedder/software_output_surface.h",
|
||||
"display_embedder/viz_process_context_provider.cc",
|
||||
diff --git a/components/viz/service/display_embedder/output_surface_provider_impl.cc b/components/viz/service/display_embedder/output_surface_provider_impl.cc
|
||||
index 7f61cb7c847bae88b50f2c32bbe9be6525a4c587..f059762b2c39c927b6bc6e40ad1c0641913082f2 100644
|
||||
index e3c8e9dbca69f2665e8dbbd798d45c3b7199e04c..d9fa2d536e977ac966065a9058661f887e995320 100644
|
||||
--- a/components/viz/service/display_embedder/output_surface_provider_impl.cc
|
||||
+++ b/components/viz/service/display_embedder/output_surface_provider_impl.cc
|
||||
@@ -20,6 +20,7 @@
|
||||
@@ -122,15 +122,15 @@ index 7f61cb7c847bae88b50f2c32bbe9be6525a4c587..f059762b2c39c927b6bc6e40ad1c0641
|
||||
#include "components/viz/service/display_embedder/software_output_surface.h"
|
||||
#include "components/viz/service/display_embedder/viz_process_context_provider.h"
|
||||
#include "components/viz/service/gl/gpu_service_impl.h"
|
||||
@@ -32,6 +33,7 @@
|
||||
#include "gpu/ipc/common/surface_handle.h"
|
||||
@@ -33,6 +34,7 @@
|
||||
#include "gpu/ipc/scheduler_sequence.h"
|
||||
#include "gpu/ipc/service/gpu_channel_manager_delegate.h"
|
||||
#include "gpu/ipc/service/image_transport_surface.h"
|
||||
+#include "services/viz/privileged/interfaces/compositing/layered_window_updater.mojom.h"
|
||||
+#include "services/viz/privileged/mojom/compositing/layered_window_updater.mojom.h"
|
||||
#include "ui/base/ui_base_switches.h"
|
||||
#include "ui/gl/gl_context.h"
|
||||
#include "ui/gl/init/gl_factory.h"
|
||||
@@ -219,6 +221,19 @@ OutputSurfaceProviderImpl::CreateSoftwareOutputDeviceForPlatform(
|
||||
@@ -223,6 +225,19 @@ OutputSurfaceProviderImpl::CreateSoftwareOutputDeviceForPlatform(
|
||||
if (headless_)
|
||||
return std::make_unique<SoftwareOutputDevice>();
|
||||
|
||||
@@ -185,7 +185,7 @@ index f3867356e3d641416e00e6d115ae9ae2a0be90ab..b1d192d2b20ccb63fba07093101d745e
|
||||
|
||||
diff --git a/components/viz/service/display_embedder/software_output_device_proxy.cc b/components/viz/service/display_embedder/software_output_device_proxy.cc
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..f5fc4f37c10bdc8aca8c1618985d46d10c830437
|
||||
index 0000000000000000000000000000000000000000..c17b03e00089bfd301c63910426bb16afb8cdae7
|
||||
--- /dev/null
|
||||
+++ b/components/viz/service/display_embedder/software_output_device_proxy.cc
|
||||
@@ -0,0 +1,156 @@
|
||||
@@ -200,7 +200,7 @@ index 0000000000000000000000000000000000000000..f5fc4f37c10bdc8aca8c1618985d46d1
|
||||
+#include "components/viz/common/resources/resource_sizes.h"
|
||||
+#include "components/viz/service/display_embedder/output_device_backing.h"
|
||||
+#include "mojo/public/cpp/system/platform_handle.h"
|
||||
+#include "services/viz/privileged/interfaces/compositing/layered_window_updater.mojom.h"
|
||||
+#include "services/viz/privileged/mojom/compositing/layered_window_updater.mojom.h"
|
||||
+#include "skia/ext/platform_canvas.h"
|
||||
+#include "third_party/skia/include/core/SkCanvas.h"
|
||||
+#include "ui/gfx/skia_util.h"
|
||||
@@ -347,7 +347,7 @@ index 0000000000000000000000000000000000000000..f5fc4f37c10bdc8aca8c1618985d46d1
|
||||
+} // namespace viz
|
||||
diff --git a/components/viz/service/display_embedder/software_output_device_proxy.h b/components/viz/service/display_embedder/software_output_device_proxy.h
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..ff3c0217812a8370a20aa528f117e928fd1b95f4
|
||||
index 0000000000000000000000000000000000000000..3865939d0445a23a468770f57207ba5ef23277ed
|
||||
--- /dev/null
|
||||
+++ b/components/viz/service/display_embedder/software_output_device_proxy.h
|
||||
@@ -0,0 +1,88 @@
|
||||
@@ -367,8 +367,8 @@ index 0000000000000000000000000000000000000000..ff3c0217812a8370a20aa528f117e928
|
||||
+#include "components/viz/host/host_display_client.h"
|
||||
+#include "components/viz/service/display/software_output_device.h"
|
||||
+#include "components/viz/service/viz_service_export.h"
|
||||
+#include "services/viz/privileged/interfaces/compositing/display_private.mojom.h"
|
||||
+#include "services/viz/privileged/interfaces/compositing/layered_window_updater.mojom.h"
|
||||
+#include "services/viz/privileged/mojom/compositing/display_private.mojom.h"
|
||||
+#include "services/viz/privileged/mojom/compositing/layered_window_updater.mojom.h"
|
||||
+
|
||||
+namespace viz {
|
||||
+
|
||||
@@ -440,7 +440,7 @@ index 0000000000000000000000000000000000000000..ff3c0217812a8370a20aa528f117e928
|
||||
+
|
||||
+#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 73ea1986b2140a3ffb87c5e23c7ab2174bac0a10..3ba3657ba12ec47cc3db3fec218496ffe817d35b 100644
|
||||
index 74316edc0e0bd28b1772e9d7cf34327d113462c4..9cbe5400458ce6e0b8ea9edfa3f0969fb936ee1e 100644
|
||||
--- a/components/viz/service/display_embedder/software_output_device_win.cc
|
||||
+++ b/components/viz/service/display_embedder/software_output_device_win.cc
|
||||
@@ -11,6 +11,7 @@
|
||||
@@ -449,7 +449,7 @@ index 73ea1986b2140a3ffb87c5e23c7ab2174bac0a10..3ba3657ba12ec47cc3db3fec218496ff
|
||||
#include "components/viz/service/display_embedder/output_device_backing.h"
|
||||
+#include "components/viz/service/display_embedder/software_output_device_proxy.h"
|
||||
#include "mojo/public/cpp/system/platform_handle.h"
|
||||
#include "services/viz/privileged/interfaces/compositing/layered_window_updater.mojom.h"
|
||||
#include "services/viz/privileged/mojom/compositing/layered_window_updater.mojom.h"
|
||||
#include "skia/ext/platform_canvas.h"
|
||||
@@ -265,7 +266,7 @@ void SoftwareOutputDeviceWinProxy::EndPaintDelegated(
|
||||
if (!canvas_)
|
||||
@@ -476,10 +476,10 @@ index 73ea1986b2140a3ffb87c5e23c7ab2174bac0a10..3ba3657ba12ec47cc3db3fec218496ff
|
||||
} else {
|
||||
return std::make_unique<SoftwareOutputDeviceWinDirect>(hwnd, backing);
|
||||
}
|
||||
diff --git a/services/viz/privileged/interfaces/compositing/display_private.mojom b/services/viz/privileged/interfaces/compositing/display_private.mojom
|
||||
index 8898b9162a65e043e8b95237b8874e48ea71744e..a455df870ece25fc6e5e46688a1c6b5b396b841a 100644
|
||||
--- a/services/viz/privileged/interfaces/compositing/display_private.mojom
|
||||
+++ b/services/viz/privileged/interfaces/compositing/display_private.mojom
|
||||
diff --git a/services/viz/privileged/mojom/compositing/display_private.mojom b/services/viz/privileged/mojom/compositing/display_private.mojom
|
||||
index 5c6292cfb3b8b46802c772d202d19c78e4782488..ed27af3ab0b383553b4d9492d29cec2b91bee807 100644
|
||||
--- a/services/viz/privileged/mojom/compositing/display_private.mojom
|
||||
+++ b/services/viz/privileged/mojom/compositing/display_private.mojom
|
||||
@@ -79,12 +79,14 @@ interface DisplayPrivate {
|
||||
};
|
||||
|
||||
@@ -496,10 +496,10 @@ index 8898b9162a65e043e8b95237b8874e48ea71744e..a455df870ece25fc6e5e46688a1c6b5b
|
||||
CreateLayeredWindowUpdater(LayeredWindowUpdater& layered_window_updater);
|
||||
|
||||
// Notifies that a swap has occurred and provides information about the pixel
|
||||
diff --git a/services/viz/privileged/interfaces/compositing/layered_window_updater.mojom b/services/viz/privileged/interfaces/compositing/layered_window_updater.mojom
|
||||
index 58a7e221eaabd9e21196496d220c77babe07c56d..dd141b16eace2999380ed137b4adf1f3538a8a70 100644
|
||||
--- a/services/viz/privileged/interfaces/compositing/layered_window_updater.mojom
|
||||
+++ b/services/viz/privileged/interfaces/compositing/layered_window_updater.mojom
|
||||
diff --git a/services/viz/privileged/mojom/compositing/layered_window_updater.mojom b/services/viz/privileged/mojom/compositing/layered_window_updater.mojom
|
||||
index 6b7fbb6cf13dc8ee6ade0878a9a2c1efc5d4d3f1..e2af75168cb914a7b3b4a6c9b6a285498c3f8e72 100644
|
||||
--- a/services/viz/privileged/mojom/compositing/layered_window_updater.mojom
|
||||
+++ b/services/viz/privileged/mojom/compositing/layered_window_updater.mojom
|
||||
@@ -26,5 +26,5 @@ interface LayeredWindowUpdater {
|
||||
// Draws to the HWND by copying pixels from shared memory. Callback must be
|
||||
// called after draw operation is complete to signal shared memory can be
|
||||
@@ -508,7 +508,7 @@ index 58a7e221eaabd9e21196496d220c77babe07c56d..dd141b16eace2999380ed137b4adf1f3
|
||||
+ Draw(gfx.mojom.Rect damage_rect) => ();
|
||||
};
|
||||
diff --git a/ui/compositor/compositor.h b/ui/compositor/compositor.h
|
||||
index 5158731bd8512fcd2ee859b1e5eeff3a9a32ca9a..4d3592e939c45eec86cd4c7e328de247e9374419 100644
|
||||
index 359e7d21a4a5e7acaed9bd7f42f40019e650a182..cd90aab9d3a7b5335c829d964d92e3fa62401408 100644
|
||||
--- a/ui/compositor/compositor.h
|
||||
+++ b/ui/compositor/compositor.h
|
||||
@@ -23,6 +23,7 @@
|
||||
@@ -517,7 +517,7 @@ index 5158731bd8512fcd2ee859b1e5eeff3a9a32ca9a..4d3592e939c45eec86cd4c7e328de247
|
||||
#include "components/viz/common/surfaces/frame_sink_id.h"
|
||||
+#include "components/viz/host/host_display_client.h"
|
||||
#include "components/viz/host/host_frame_sink_client.h"
|
||||
#include "services/viz/privileged/interfaces/compositing/vsync_parameter_observer.mojom-forward.h"
|
||||
#include "services/viz/privileged/mojom/compositing/vsync_parameter_observer.mojom-forward.h"
|
||||
#include "third_party/skia/include/core/SkColor.h"
|
||||
@@ -194,6 +195,15 @@ class COMPOSITOR_EXPORT ContextFactory {
|
||||
virtual bool SyncTokensRequiredForDisplayCompositor() = 0;
|
||||
@@ -555,10 +555,10 @@ index 5158731bd8512fcd2ee859b1e5eeff3a9a32ca9a..4d3592e939c45eec86cd4c7e328de247
|
||||
Layer* root_layer_ = nullptr;
|
||||
|
||||
diff --git a/ui/compositor/host/host_context_factory_private.cc b/ui/compositor/host/host_context_factory_private.cc
|
||||
index 1c84de621781d0d7cf41866fc033b78881c5e972..112a1a6c2a0f24ee9ace05d7c38247b22fb4ed4c 100644
|
||||
index 747d01865657b0bd055c7bb1515dfc84ddbe92aa..0453999f6513176bd8e835741292ecf3ad51f5b1 100644
|
||||
--- a/ui/compositor/host/host_context_factory_private.cc
|
||||
+++ b/ui/compositor/host/host_context_factory_private.cc
|
||||
@@ -99,8 +99,12 @@ void HostContextFactoryPrivate::ConfigureCompositor(
|
||||
@@ -98,8 +98,12 @@ void HostContextFactoryPrivate::ConfigureCompositor(
|
||||
mojo::MakeRequest(&root_params->compositor_frame_sink_client);
|
||||
root_params->display_private =
|
||||
mojo::MakeRequest(&compositor_data.display_private);
|
||||
@@ -594,10 +594,10 @@ index 4014e64a75da88cf66c02e8adb71171c2666cab7..25e57784e1a1ffc546b003daa4cd0059
|
||||
// The geometry of the frame.
|
||||
gfx::Size pixel_size;
|
||||
float scale_factor = 1.f;
|
||||
diff --git a/ui/gfx/mojo/ca_layer_params.mojom b/ui/gfx/mojo/ca_layer_params.mojom
|
||||
index 7bf735643541b18bafffe645d3ff37e96caa4dea..f7eaf10ffd665789f10a587142fac0c0c79b9798 100644
|
||||
--- a/ui/gfx/mojo/ca_layer_params.mojom
|
||||
+++ b/ui/gfx/mojo/ca_layer_params.mojom
|
||||
diff --git a/ui/gfx/mojom/ca_layer_params.mojom b/ui/gfx/mojom/ca_layer_params.mojom
|
||||
index a73b2e678ffe0a682d0aa5409724fb441768bec5..6c36626d204c77ef51278b9e8f6fc6ee24a7a9ab 100644
|
||||
--- a/ui/gfx/mojom/ca_layer_params.mojom
|
||||
+++ b/ui/gfx/mojom/ca_layer_params.mojom
|
||||
@@ -18,5 +18,6 @@ struct CALayerParams {
|
||||
bool is_empty;
|
||||
CALayerContent content;
|
||||
@@ -605,10 +605,10 @@ index 7bf735643541b18bafffe645d3ff37e96caa4dea..f7eaf10ffd665789f10a587142fac0c0
|
||||
+ gfx.mojom.Rect damage;
|
||||
float scale_factor;
|
||||
};
|
||||
diff --git a/ui/gfx/mojo/ca_layer_params_struct_traits.cc b/ui/gfx/mojo/ca_layer_params_struct_traits.cc
|
||||
index dd553996b5c6ff5ec0c210a020a18a6a843b8aae..26d1e0bda2640052d42ea4e691c3df73074dea08 100644
|
||||
--- a/ui/gfx/mojo/ca_layer_params_struct_traits.cc
|
||||
+++ b/ui/gfx/mojo/ca_layer_params_struct_traits.cc
|
||||
diff --git a/ui/gfx/mojom/ca_layer_params_mojom_traits.cc b/ui/gfx/mojom/ca_layer_params_mojom_traits.cc
|
||||
index 843d5c24ec33de07c12d4417eb111f91dbcd42fe..0ea594950fcd2686f1b07248dbc8ceb257d89dca 100644
|
||||
--- a/ui/gfx/mojom/ca_layer_params_mojom_traits.cc
|
||||
+++ b/ui/gfx/mojom/ca_layer_params_mojom_traits.cc
|
||||
@@ -52,6 +52,9 @@ bool StructTraits<gfx::mojom::CALayerParamsDataView, gfx::CALayerParams>::Read(
|
||||
if (!data.ReadPixelSize(&out->pixel_size))
|
||||
return false;
|
||||
@@ -619,10 +619,10 @@ index dd553996b5c6ff5ec0c210a020a18a6a843b8aae..26d1e0bda2640052d42ea4e691c3df73
|
||||
out->scale_factor = data.scale_factor();
|
||||
return true;
|
||||
}
|
||||
diff --git a/ui/gfx/mojo/ca_layer_params_struct_traits.h b/ui/gfx/mojo/ca_layer_params_struct_traits.h
|
||||
index 94127a0d5b50b052318e9e5a360755fe771f87e9..348fa26c5c95a13d1ddd0ff2545aca3a35841a77 100644
|
||||
--- a/ui/gfx/mojo/ca_layer_params_struct_traits.h
|
||||
+++ b/ui/gfx/mojo/ca_layer_params_struct_traits.h
|
||||
diff --git a/ui/gfx/mojom/ca_layer_params_mojom_traits.h b/ui/gfx/mojom/ca_layer_params_mojom_traits.h
|
||||
index 4cac766eae3161baedac4202f694129cd90c80de..0821495ad22944d8856bb750cac8912a2f8328c3 100644
|
||||
--- a/ui/gfx/mojom/ca_layer_params_mojom_traits.h
|
||||
+++ b/ui/gfx/mojom/ca_layer_params_mojom_traits.h
|
||||
@@ -20,6 +20,10 @@ struct StructTraits<gfx::mojom::CALayerParamsDataView, gfx::CALayerParams> {
|
||||
return ca_layer_params.pixel_size;
|
||||
}
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Shelley Vohr <shelley.vohr@gmail.com>
|
||||
Date: Tue, 28 May 2019 18:12:17 -0700
|
||||
Subject: fix: breakpad symbol generation on linux arm
|
||||
Subject: fix_breakpad_symbol_generation_on_linux_arm.patch
|
||||
|
||||
Fixes broken Linux ARM breakpad symbol generation by patching
|
||||
out an `ldd`-related call that was throwing.
|
||||
|
||||
diff --git a/components/crash/content/tools/generate_breakpad_symbols.py b/components/crash/content/tools/generate_breakpad_symbols.py
|
||||
index 4249d7b26f9037b60a40e073f56037f9ff036138..0ad9ff9b9bc7dd535655b37013270ad504aa6a34 100755
|
||||
index edb3fa5c125fae7858a1f36495410baf47d58484..05a1385e13d282a63975143cbc6e157984bbd992 100755
|
||||
--- a/components/crash/content/tools/generate_breakpad_symbols.py
|
||||
+++ b/components/crash/content/tools/generate_breakpad_symbols.py
|
||||
@@ -67,7 +67,8 @@ def GetSharedLibraryDependenciesLinux(binary, options):
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Samuel Attard <sattard@slack-corp.com>
|
||||
Date: Mon, 4 Mar 2019 14:43:36 -0800
|
||||
Subject: fix: disable usage of abort_report_np in MAS builds
|
||||
Subject: fix_disable_usage_of_abort_report_np_in_mas_builds.patch
|
||||
|
||||
Disable usage of abort_report_np in MAS builds.
|
||||
|
||||
diff --git a/sandbox/mac/sandbox_logging.cc b/sandbox/mac/sandbox_logging.cc
|
||||
index 4eebcea13d17093a685cc79b8a8f61fb3894c71b..d704dced154f1d5db097e566a9c681438f94475d 100644
|
||||
|
||||
@@ -1,27 +1,27 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Samuel Attard <sattard@slack-corp.com>
|
||||
Date: Mon, 4 Mar 2019 14:46:48 -0800
|
||||
Subject: fix: disable usage of pthread_fchdir_np and pthread_chdir_np in MAS
|
||||
builds
|
||||
Subject:
|
||||
fix_disable_usage_of_pthread_fchdir_np_and_pthread_chdir_np_in_MAS.patch
|
||||
|
||||
Disable usage of pthread_fchdir_np and pthread_chdir_np in MAS builds.
|
||||
|
||||
diff --git a/base/process/launch_mac.cc b/base/process/launch_mac.cc
|
||||
index c6d5cbbd5417a1b18a6cf94a681de6c671089e35..92d683619e8de505d5172a8ae09e6e67f28da96f 100644
|
||||
index 1119fb3f97b116028d78fdf42c1d336440a1681f..264178186f3f780b2b33de7649b1321b23964515 100644
|
||||
--- a/base/process/launch_mac.cc
|
||||
+++ b/base/process/launch_mac.cc
|
||||
@@ -25,10 +25,12 @@
|
||||
@@ -26,8 +26,10 @@ extern "C" {
|
||||
// descriptor. libpthread only exposes a syscall wrapper starting in
|
||||
// macOS 10.12, but the system call dates back to macOS 10.5. On older OSes,
|
||||
// the syscall is issued directly.
|
||||
+#if !defined(MAS_BUILD)
|
||||
extern "C" {
|
||||
int pthread_chdir_np(const char*) API_AVAILABLE(macosx(10.12));
|
||||
int pthread_chdir_np(const char* dir) API_AVAILABLE(macosx(10.12));
|
||||
int pthread_fchdir_np(int fd) API_AVAILABLE(macosx(10.12));
|
||||
}
|
||||
+#endif
|
||||
|
||||
namespace base {
|
||||
|
||||
@@ -95,21 +97,29 @@ class PosixSpawnFileActions {
|
||||
int responsibility_spawnattrs_setdisclaim(posix_spawnattr_t attrs, int disclaim)
|
||||
API_AVAILABLE(macosx(10.14));
|
||||
@@ -98,21 +100,29 @@ class PosixSpawnFileActions {
|
||||
};
|
||||
|
||||
int ChangeCurrentThreadDirectory(const char* path) {
|
||||
@@ -51,3 +51,17 @@ index c6d5cbbd5417a1b18a6cf94a681de6c671089e35..92d683619e8de505d5172a8ae09e6e67
|
||||
}
|
||||
|
||||
struct GetAppOutputOptions {
|
||||
@@ -228,11 +238,13 @@ Process LaunchProcess(const std::vector<std::string>& argv,
|
||||
file_actions.Inherit(STDERR_FILENO);
|
||||
}
|
||||
|
||||
+#if 0
|
||||
if (options.disclaim_responsibility) {
|
||||
if (__builtin_available(macOS 10.14, *)) {
|
||||
DPSXCHECK(responsibility_spawnattrs_setdisclaim(attr.get(), 1));
|
||||
}
|
||||
}
|
||||
+#endif
|
||||
|
||||
std::vector<char*> argv_cstr;
|
||||
argv_cstr.reserve(argv.size() + 1);
|
||||
|
||||
@@ -1,14 +1,16 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Samuel Attard <sattard@slack-corp.com>
|
||||
Date: Mon, 4 Mar 2019 14:51:45 -0800
|
||||
Subject: fix: disable usage of SetApplicationIsDaemon and
|
||||
_LSSetApplicationLaunchServicesServerConnectionStatus in MAS builds
|
||||
Subject: fix_disable_usage_of_setapplicationisdaemon_and.patch
|
||||
|
||||
Disable usage of SetApplicationIsDaemon and
|
||||
_LSSetApplicationLaunchServicesServerConnectionStatus in MAS builds
|
||||
|
||||
diff --git a/content/utility/utility_service_factory.cc b/content/utility/utility_service_factory.cc
|
||||
index e4c8405fb17e37fd843eb9a962e0c5360524a693..1d5ee0a13a837efd0befe2ec02b38fbf4dcbc572 100644
|
||||
index 9b0759ab820ddb0e2a9e609b88bbc1673607c4e3..2392fd01736550f404304df324da9d81dfb3d446 100644
|
||||
--- a/content/utility/utility_service_factory.cc
|
||||
+++ b/content/utility/utility_service_factory.cc
|
||||
@@ -198,7 +198,7 @@ void UtilityServiceFactory::RunService(
|
||||
@@ -196,7 +196,7 @@ void UtilityServiceFactory::RunService(
|
||||
std::unique_ptr<service_manager::Service>
|
||||
UtilityServiceFactory::CreateAudioService(
|
||||
mojo::PendingReceiver<service_manager::mojom::Service> receiver) {
|
||||
|
||||
20
patches/chromium/fix_disabling_compositor_recycling.patch
Normal file
20
patches/chromium/fix_disabling_compositor_recycling.patch
Normal file
@@ -0,0 +1,20 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Samuel Attard <sattard@slack-corp.com>
|
||||
Date: Thu, 22 Aug 2019 15:55:08 -0700
|
||||
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/browser_compositor_view_mac.mm b/content/browser/renderer_host/browser_compositor_view_mac.mm
|
||||
index 18019d5794f688ca07b35a665cc9800bb1d3047a..60c7e980dd322ba012c564fca68848c3188ca5dc 100644
|
||||
--- a/content/browser/renderer_host/browser_compositor_view_mac.mm
|
||||
+++ b/content/browser/renderer_host/browser_compositor_view_mac.mm
|
||||
@@ -209,7 +209,7 @@
|
||||
}
|
||||
|
||||
void BrowserCompositorMac::SetRenderWidgetHostIsHidden(bool hidden) {
|
||||
- render_widget_host_is_hidden_ = hidden;
|
||||
+ render_widget_host_is_hidden_ = false;
|
||||
UpdateState();
|
||||
}
|
||||
|
||||
@@ -42,10 +42,10 @@ index 906a1ee4ac58b0744a32153bbaafeac4322a60e4..c90f4aead36cbf3767dc5094728963c2
|
||||
// another SiteInstance for the same site.
|
||||
void RegisterSiteInstance(SiteInstanceImpl* site_instance);
|
||||
diff --git a/content/browser/frame_host/render_frame_host_manager.cc b/content/browser/frame_host/render_frame_host_manager.cc
|
||||
index 37593f39cecfe34fcbb7f0e9911175facdd87ea8..fab42c861fbc5f5344851b0bcb19e592678be8e6 100644
|
||||
index ba10b76c4cdec0137aeb39c7edbfed723ed7426f..eadf6a06d22a345776fd832827ba9b3d44738ce4 100644
|
||||
--- a/content/browser/frame_host/render_frame_host_manager.cc
|
||||
+++ b/content/browser/frame_host/render_frame_host_manager.cc
|
||||
@@ -2180,6 +2180,21 @@ bool RenderFrameHostManager::InitRenderView(
|
||||
@@ -2228,6 +2228,21 @@ bool RenderFrameHostManager::InitRenderView(
|
||||
scoped_refptr<SiteInstance>
|
||||
RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
const NavigationRequest& request) {
|
||||
@@ -67,12 +67,13 @@ index 37593f39cecfe34fcbb7f0e9911175facdd87ea8..fab42c861fbc5f5344851b0bcb19e592
|
||||
SiteInstance* current_site_instance = render_frame_host_->GetSiteInstance();
|
||||
|
||||
// All children of MHTML documents must be MHTML documents. They all live in
|
||||
@@ -2217,6 +2232,53 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
@@ -2265,6 +2280,59 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
request.common_params().url);
|
||||
no_renderer_swap_allowed |=
|
||||
request.from_begin_navigation() && !can_renderer_initiate_transfer;
|
||||
+
|
||||
+ if (!GetContentClient()->browser()->CanUseCustomSiteInstance()) {
|
||||
+ bool has_navigation_started = request.state() != NavigationRequest::NOT_STARTED;
|
||||
+ bool has_response_started =
|
||||
+ (request.state() == NavigationRequest::RESPONSE_STARTED ||
|
||||
+ request.state() == NavigationRequest::FAILED) &&
|
||||
@@ -80,11 +81,12 @@ index 37593f39cecfe34fcbb7f0e9911175facdd87ea8..fab42c861fbc5f5344851b0bcb19e592
|
||||
+ // Gives user a chance to choose a custom site instance.
|
||||
+ SiteInstance* affinity_site_instance = nullptr;
|
||||
+ scoped_refptr<SiteInstance> overriden_site_instance;
|
||||
+ bool should_register_site_instance = false;
|
||||
+ ContentBrowserClient::SiteInstanceForNavigationType siteInstanceType =
|
||||
+ GetContentClient()->browser()->ShouldOverrideSiteInstanceForNavigation(
|
||||
+ current_frame_host(), speculative_frame_host(), browser_context,
|
||||
+ request.common_params().url, has_response_started,
|
||||
+ &affinity_site_instance);
|
||||
+ request.common_params().url, has_navigation_started,
|
||||
+ has_response_started, &affinity_site_instance);
|
||||
+ switch (siteInstanceType) {
|
||||
+ case ContentBrowserClient::SiteInstanceForNavigationType::
|
||||
+ FORCE_CANDIDATE_OR_NEW:
|
||||
@@ -93,6 +95,12 @@ index 37593f39cecfe34fcbb7f0e9911175facdd87ea8..fab42c861fbc5f5344851b0bcb19e592
|
||||
+ ? candidate_site_instance
|
||||
+ : current_site_instance->CreateRelatedSiteInstance(
|
||||
+ request.common_params().url);
|
||||
+ should_register_site_instance = true;
|
||||
+ break;
|
||||
+ case ContentBrowserClient::SiteInstanceForNavigationType::FORCE_NEW:
|
||||
+ overriden_site_instance = current_site_instance->CreateRelatedSiteInstance(
|
||||
+ request.common_params().url);
|
||||
+ should_register_site_instance = true;
|
||||
+ break;
|
||||
+ case ContentBrowserClient::SiteInstanceForNavigationType::FORCE_CURRENT:
|
||||
+ overriden_site_instance = render_frame_host_->GetSiteInstance();
|
||||
@@ -109,9 +117,7 @@ index 37593f39cecfe34fcbb7f0e9911175facdd87ea8..fab42c861fbc5f5344851b0bcb19e592
|
||||
+ break;
|
||||
+ }
|
||||
+ if (overriden_site_instance) {
|
||||
+ if (siteInstanceType ==
|
||||
+ ContentBrowserClient::SiteInstanceForNavigationType::
|
||||
+ FORCE_CANDIDATE_OR_NEW) {
|
||||
+ if (should_register_site_instance) {
|
||||
+ GetContentClient()->browser()->RegisterPendingSiteInstance(
|
||||
+ render_frame_host_.get(), overriden_site_instance.get());
|
||||
+ }
|
||||
@@ -121,7 +127,7 @@ index 37593f39cecfe34fcbb7f0e9911175facdd87ea8..fab42c861fbc5f5344851b0bcb19e592
|
||||
} else {
|
||||
// Subframe navigations will use the current renderer, unless specifically
|
||||
// allowed to swap processes.
|
||||
@@ -2228,23 +2290,28 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
@@ -2276,23 +2344,28 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
if (no_renderer_swap_allowed && !should_swap_for_error_isolation)
|
||||
return scoped_refptr<SiteInstance>(current_site_instance);
|
||||
|
||||
@@ -153,10 +159,10 @@ index 37593f39cecfe34fcbb7f0e9911175facdd87ea8..fab42c861fbc5f5344851b0bcb19e592
|
||||
}
|
||||
|
||||
diff --git a/content/browser/site_instance_impl.cc b/content/browser/site_instance_impl.cc
|
||||
index a805b110c378d0584a361f3a499be57c7826a63a..00c1f807033a76390c12335e5a647a6f951372c2 100644
|
||||
index d0d4e89f4190752fa00a575bb91842a72f4c0070..7b8d9af4005c6c7b7f4ebf0090d718fd276d012b 100644
|
||||
--- a/content/browser/site_instance_impl.cc
|
||||
+++ b/content/browser/site_instance_impl.cc
|
||||
@@ -367,6 +367,10 @@ bool SiteInstanceImpl::HasRelatedSiteInstance(const GURL& url) {
|
||||
@@ -368,6 +368,10 @@ bool SiteInstanceImpl::HasRelatedSiteInstance(const GURL& url) {
|
||||
return browsing_instance_->HasSiteInstance(url);
|
||||
}
|
||||
|
||||
@@ -180,12 +186,12 @@ index 1edb9fd6b0c383f291735dd1a952fcb7b17cc87f..23967f040eb346be265faa2a92562e1f
|
||||
size_t GetRelatedActiveContentsCount() override;
|
||||
bool RequiresDedicatedProcess() override;
|
||||
diff --git a/content/public/browser/content_browser_client.cc b/content/public/browser/content_browser_client.cc
|
||||
index 44a574d3c621695d7d1304c7b8db08db8cf753d1..39d3c28ca33fa1eeab14b67ec31a6ae09f25c354 100644
|
||||
index d51d21fbd09cfa2c017f85ab96c1156a6a4f74f9..5459d566e37866f247452a7f88d884760ec5e608 100644
|
||||
--- a/content/public/browser/content_browser_client.cc
|
||||
+++ b/content/public/browser/content_browser_client.cc
|
||||
@@ -52,6 +52,20 @@ void OverrideOnBindInterface(const service_manager::BindSourceInfo& remote_info,
|
||||
handle);
|
||||
}
|
||||
@@ -44,6 +44,21 @@
|
||||
|
||||
namespace content {
|
||||
|
||||
+bool ContentBrowserClient::CanUseCustomSiteInstance() {
|
||||
+ return false;
|
||||
@@ -196,6 +202,7 @@ index 44a574d3c621695d7d1304c7b8db08db8cf753d1..39d3c28ca33fa1eeab14b67ec31a6ae0
|
||||
+ content::RenderFrameHost* speculative_rfh,
|
||||
+ content::BrowserContext* browser_context,
|
||||
+ const GURL& url,
|
||||
+ bool has_navigation_started,
|
||||
+ bool has_request_started,
|
||||
+ content::SiteInstance** affinity_site_instance) const {
|
||||
+ return SiteInstanceForNavigationType::ASK_CHROMIUM;
|
||||
@@ -205,10 +212,10 @@ index 44a574d3c621695d7d1304c7b8db08db8cf753d1..39d3c28ca33fa1eeab14b67ec31a6ae0
|
||||
const MainFunctionParams& parameters) {
|
||||
return nullptr;
|
||||
diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h
|
||||
index 7d83d9e0d0c57511955921d85f15a27a88c3ac37..3d518759a3bc190970a2d45ec178c97096fa250d 100644
|
||||
index 6767853c179179c546bbaa6fd07ade7db9c40a82..4ef8220f88c13b4c19a885245d1f0fa91d293f2a 100644
|
||||
--- a/content/public/browser/content_browser_client.h
|
||||
+++ b/content/public/browser/content_browser_client.h
|
||||
@@ -208,8 +208,41 @@ CONTENT_EXPORT void OverrideOnBindInterface(
|
||||
@@ -205,8 +205,45 @@ struct WebPreferences;
|
||||
// the observer interfaces.)
|
||||
class CONTENT_EXPORT ContentBrowserClient {
|
||||
public:
|
||||
@@ -221,6 +228,9 @@ index 7d83d9e0d0c57511955921d85f15a27a88c3ac37..3d518759a3bc190970a2d45ec178c970
|
||||
+ // Use the current site instance for the navigation.
|
||||
+ FORCE_CURRENT,
|
||||
+
|
||||
+ // Use a new, unrelated site instance.
|
||||
+ FORCE_NEW,
|
||||
+
|
||||
+ // Use the provided affinity site instance for the navigation.
|
||||
+ FORCE_AFFINITY,
|
||||
+
|
||||
@@ -239,6 +249,7 @@ index 7d83d9e0d0c57511955921d85f15a27a88c3ac37..3d518759a3bc190970a2d45ec178c970
|
||||
+ content::RenderFrameHost* speculative_rfh,
|
||||
+ content::BrowserContext* browser_context,
|
||||
+ const GURL& url,
|
||||
+ bool has_navigation_started,
|
||||
+ bool has_request_started,
|
||||
+ content::SiteInstance** affinity_site_instance) const;
|
||||
+
|
||||
|
||||
@@ -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 b/tools/gritsettings/resource_ids
|
||||
index 7ac3cf37b48153541278b3524d5c1610f6ae62e7..d284647347afca7beb1fea7415ae8f951026a03b 100644
|
||||
index a4c39b1f6b141056b35ff8b7d9283863d057d0a2..b3a6bb5c948d7ebe6d9746e9210d97344c8a5c9e 100644
|
||||
--- a/tools/gritsettings/resource_ids
|
||||
+++ b/tools/gritsettings/resource_ids
|
||||
@@ -459,6 +459,11 @@
|
||||
@@ -465,6 +465,11 @@
|
||||
"includes": [28880],
|
||||
},
|
||||
|
||||
|
||||
@@ -7,10 +7,10 @@ Dont compare RC.exe and RC.py output.
|
||||
FIXME: It has to be reverted once the script is fixed.
|
||||
|
||||
diff --git a/build/toolchain/win/tool_wrapper.py b/build/toolchain/win/tool_wrapper.py
|
||||
index 926086670dac3ccf85f4085b513740aec1ebe9e5..cbb32f1143420d47af23f1ad92ee8656543a93e0 100644
|
||||
index 3834cf2c01a9c63bfe7a6fc9e7549930a5eda01c..454b831a37c13fdd2fe4d8953d60dab661386f9a 100644
|
||||
--- a/build/toolchain/win/tool_wrapper.py
|
||||
+++ b/build/toolchain/win/tool_wrapper.py
|
||||
@@ -224,7 +224,11 @@ class WinTool(object):
|
||||
@@ -250,7 +250,11 @@ class WinTool(object):
|
||||
if rc_exe_exit_code == 0:
|
||||
import filecmp
|
||||
# Strip "/fo" prefix.
|
||||
|
||||
@@ -6,7 +6,7 @@ Subject: libgtkui_export.patch
|
||||
Export libgtkui symbols for the GN component build.
|
||||
|
||||
diff --git a/chrome/browser/ui/libgtkui/gtk_util.h b/chrome/browser/ui/libgtkui/gtk_util.h
|
||||
index adea4a859d96e219acc92c9178574f089a57944c..df615a91c00d22cabafffebe151728010fe9c1c4 100644
|
||||
index d75427b5d5a0aca237cacc9654a8298e26285a81..8608d083a3eb6fe6b22e059cd68834ec4ded0458 100644
|
||||
--- a/chrome/browser/ui/libgtkui/gtk_util.h
|
||||
+++ b/chrome/browser/ui/libgtkui/gtk_util.h
|
||||
@@ -11,6 +11,7 @@
|
||||
@@ -28,9 +28,9 @@ index adea4a859d96e219acc92c9178574f089a57944c..df615a91c00d22cabafffebe15172801
|
||||
-std::string GetDesktopName(base::Environment* env);
|
||||
+LIBGTKUI_EXPORT std::string GetDesktopName(base::Environment* env);
|
||||
|
||||
guint GetGdkKeyCodeForAccelerator(const ui::Accelerator& accelerator);
|
||||
|
||||
@@ -51,7 +52,7 @@ void TurnButtonBlue(GtkWidget* button);
|
||||
GdkModifierType GetGdkModifierForAccelerator(
|
||||
const ui::Accelerator& accelerator);
|
||||
@@ -49,7 +50,7 @@ void TurnButtonBlue(GtkWidget* button);
|
||||
|
||||
// Sets |dialog| as transient for |parent|, which will keep it on top and center
|
||||
// it above |parent|. Do nothing if |parent| is nullptr.
|
||||
@@ -39,7 +39,7 @@ index adea4a859d96e219acc92c9178574f089a57944c..df615a91c00d22cabafffebe15172801
|
||||
|
||||
// Gets the transient parent aura window for |dialog|.
|
||||
aura::Window* GetAuraTransientParent(GtkWidget* dialog);
|
||||
@@ -157,7 +158,7 @@ void ApplyCssToContext(GtkStyleContext* context, const std::string& css);
|
||||
@@ -155,7 +156,7 @@ void ApplyCssToContext(GtkStyleContext* context, const std::string& css);
|
||||
|
||||
// Get the 'color' property from the style context created by
|
||||
// GetStyleContextFromCss(|css_selector|).
|
||||
@@ -48,7 +48,7 @@ index adea4a859d96e219acc92c9178574f089a57944c..df615a91c00d22cabafffebe15172801
|
||||
|
||||
ScopedCssProvider GetCssProvider(const std::string& css);
|
||||
|
||||
@@ -170,7 +171,7 @@ void RenderBackground(const gfx::Size& size,
|
||||
@@ -168,7 +169,7 @@ void RenderBackground(const gfx::Size& size,
|
||||
// Renders a background from the style context created by
|
||||
// GetStyleContextFromCss(|css_selector|) into a 24x24 bitmap and
|
||||
// returns the average color.
|
||||
|
||||
@@ -7,12 +7,12 @@ Removes usage of the _LSSetApplicationLaunchServicesServerConnectionStatus
|
||||
private API.
|
||||
|
||||
diff --git a/content/gpu/gpu_main.cc b/content/gpu/gpu_main.cc
|
||||
index de80e1023c948a347440eeb960079f498e43fb87..69cb584e3b99a6989dbb2906bfa5bdf1c5cd3df5 100644
|
||||
index d257830f5943937a634aa85539ad654310579e2c..4373f508964cb1e9fd51c952122ac2f41fb35ae9 100644
|
||||
--- a/content/gpu/gpu_main.cc
|
||||
+++ b/content/gpu/gpu_main.cc
|
||||
@@ -285,8 +285,10 @@ int GpuMain(const MainFunctionParams& parameters) {
|
||||
@@ -286,8 +286,10 @@ int GpuMain(const MainFunctionParams& parameters) {
|
||||
std::make_unique<base::SingleThreadTaskExecutor>(
|
||||
base::MessagePump::Type::NS_RUNLOOP);
|
||||
base::MessagePumpType::NS_RUNLOOP);
|
||||
|
||||
+#ifndef MAS_BUILD
|
||||
// Tell LaunchServices to continue without a connection to the daemon.
|
||||
|
||||
@@ -73,7 +73,7 @@ index 94afefcee81b87c05bf9b1199d90d3d4b5ea84a6..2ec7f04c71824b47de1ddbf1f0e8625d
|
||||
|
||||
} // namespace blink
|
||||
diff --git a/third_party/blink/renderer/core/paint/theme_painter_mac.mm b/third_party/blink/renderer/core/paint/theme_painter_mac.mm
|
||||
index e965faf9fd8d5ec3572d769421f149907d66c67f..b2d0bbd80994fdf9607009d9e27bf4c3629fe402 100644
|
||||
index e94235acb17335fbc78c606ff26036871117bd09..7c4bd19215c67f649636ae69b9a21b5c1ba21ecc 100644
|
||||
--- a/third_party/blink/renderer/core/paint/theme_painter_mac.mm
|
||||
+++ b/third_party/blink/renderer/core/paint/theme_painter_mac.mm
|
||||
@@ -41,6 +41,7 @@
|
||||
|
||||
@@ -38,10 +38,10 @@ index 743d1364bcd13e24ecbe5ced730161d15b8c3e93..a7e81072194c00baa0aa3159a6bfe374
|
||||
// is concerned.
|
||||
@property(nonatomic, readonly) NSString* subrole;
|
||||
diff --git a/content/browser/accessibility/browser_accessibility_cocoa.mm b/content/browser/accessibility/browser_accessibility_cocoa.mm
|
||||
index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f9503948665d8d 100644
|
||||
index aef51e0f959e4e7706a87f17226dd4f17bfc7ba3..71bf5bef235ff33c2405ed13cdad1c7012e53122 100644
|
||||
--- a/content/browser/accessibility/browser_accessibility_cocoa.mm
|
||||
+++ b/content/browser/accessibility/browser_accessibility_cocoa.mm
|
||||
@@ -141,6 +141,7 @@
|
||||
@@ -219,6 +219,7 @@
|
||||
// VoiceOver uses -1 to mean "no limit" for AXResultsLimit.
|
||||
const int kAXResultsLimitNoLimit = -1;
|
||||
|
||||
@@ -49,7 +49,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
extern "C" {
|
||||
|
||||
// The following are private accessibility APIs required for cursor navigation
|
||||
@@ -342,6 +343,7 @@ void AddMisspelledTextAttributes(const AXPlatformRange& ax_range,
|
||||
@@ -420,6 +421,7 @@ void AddMisspelledTextAttributes(const AXPlatformRange& ax_range,
|
||||
AddMisspelledTextAttributes(ax_range, attributed_text);
|
||||
return attributed_text;
|
||||
}
|
||||
@@ -57,7 +57,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
|
||||
// Returns an autoreleased copy of the AXNodeData's attribute.
|
||||
NSString* NSStringForStringAttribute(BrowserAccessibility* browserAccessibility,
|
||||
@@ -609,7 +611,9 @@ + (void)initialize {
|
||||
@@ -687,7 +689,9 @@ + (void)initialize {
|
||||
{NSAccessibilityEditableAncestorAttribute, @"editableAncestor"},
|
||||
{NSAccessibilityElementBusyAttribute, @"elementBusy"},
|
||||
{NSAccessibilityEnabledAttribute, @"enabled"},
|
||||
@@ -67,7 +67,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
{NSAccessibilityExpandedAttribute, @"expanded"},
|
||||
{NSAccessibilityFocusableAncestorAttribute, @"focusableAncestor"},
|
||||
{NSAccessibilityFocusedAttribute, @"focused"},
|
||||
@@ -644,13 +648,17 @@ + (void)initialize {
|
||||
@@ -722,13 +726,17 @@ + (void)initialize {
|
||||
{NSAccessibilityRowsAttribute, @"rows"},
|
||||
// TODO(aboxhall): expose
|
||||
// NSAccessibilityServesAsTitleForUIElementsAttribute
|
||||
@@ -85,7 +85,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
{NSAccessibilitySizeAttribute, @"size"},
|
||||
{NSAccessibilitySortDirectionAttribute, @"sortDirection"},
|
||||
{NSAccessibilitySubroleAttribute, @"subrole"},
|
||||
@@ -1148,6 +1156,7 @@ - (NSNumber*)enabled {
|
||||
@@ -1226,6 +1234,7 @@ - (NSNumber*)enabled {
|
||||
ax::mojom::Restriction::kDisabled];
|
||||
}
|
||||
|
||||
@@ -93,7 +93,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
// Returns a text marker that points to the last character in the document that
|
||||
// can be selected with VoiceOver.
|
||||
- (id)endTextMarker {
|
||||
@@ -1158,6 +1167,7 @@ - (id)endTextMarker {
|
||||
@@ -1236,6 +1245,7 @@ - (id)endTextMarker {
|
||||
BrowserAccessibilityPositionInstance position = root->CreatePositionAt(0);
|
||||
return CreateTextMarker(position->CreatePositionAtEndOfAnchor());
|
||||
}
|
||||
@@ -101,7 +101,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
|
||||
- (NSNumber*)expanded {
|
||||
if (![self instanceActive])
|
||||
@@ -2029,6 +2039,7 @@ - (NSValue*)selectedTextRange {
|
||||
@@ -2107,6 +2117,7 @@ - (NSValue*)selectedTextRange {
|
||||
return [NSValue valueWithRange:NSMakeRange(selStart, selLength)];
|
||||
}
|
||||
|
||||
@@ -109,7 +109,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
- (id)selectedTextMarkerRange {
|
||||
if (![self instanceActive])
|
||||
return nil;
|
||||
@@ -2064,6 +2075,7 @@ - (id)selectedTextMarkerRange {
|
||||
@@ -2142,6 +2153,7 @@ - (id)selectedTextMarkerRange {
|
||||
CreateAXPlatformRange(*anchorObject, anchorOffset, anchorAffinity,
|
||||
*focusObject, focusOffset, focusAffinity));
|
||||
}
|
||||
@@ -117,7 +117,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
|
||||
- (NSValue*)size {
|
||||
if (![self instanceActive])
|
||||
@@ -2096,6 +2108,7 @@ - (NSString*)sortDirection {
|
||||
@@ -2174,6 +2186,7 @@ - (NSString*)sortDirection {
|
||||
return nil;
|
||||
}
|
||||
|
||||
@@ -125,7 +125,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
// Returns a text marker that points to the first character in the document that
|
||||
// can be selected with VoiceOver.
|
||||
- (id)startTextMarker {
|
||||
@@ -2106,6 +2119,7 @@ - (id)startTextMarker {
|
||||
@@ -2184,6 +2197,7 @@ - (id)startTextMarker {
|
||||
BrowserAccessibilityPositionInstance position = root->CreatePositionAt(0);
|
||||
return CreateTextMarker(position->CreatePositionAtStartOfAnchor());
|
||||
}
|
||||
@@ -133,7 +133,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
|
||||
// Returns a subrole based upon the role.
|
||||
- (NSString*)subrole {
|
||||
@@ -2409,11 +2423,13 @@ - (NSAttributedString*)attributedValueForRange:(NSRange)range {
|
||||
@@ -2475,11 +2489,13 @@ - (NSAttributedString*)attributedValueForRange:(NSRange)range {
|
||||
NSMutableAttributedString* attributedValue =
|
||||
[[[NSMutableAttributedString alloc] initWithString:value] autorelease];
|
||||
|
||||
@@ -147,23 +147,27 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
|
||||
return [attributedValue attributedSubstringFromRange:range];
|
||||
}
|
||||
@@ -2496,6 +2512,7 @@ - (id)accessibilityAttributeValue:(NSString*)attribute
|
||||
@@ -2562,9 +2578,8 @@ - (id)accessibilityAttributeValue:(NSString*)attribute
|
||||
return ToBrowserAccessibilityCocoa(cell);
|
||||
}
|
||||
|
||||
- if ([attribute
|
||||
- isEqualToString:
|
||||
- NSAccessibilityUIElementForTextMarkerParameterizedAttribute]) {
|
||||
+#ifndef MAS_BUILD
|
||||
if ([attribute isEqualToString:@"AXUIElementForTextMarker"]) {
|
||||
+ if ([attribute isEqualToString:NSAccessibilityUIElementForTextMarkerParameterizedAttribute]) {
|
||||
BrowserAccessibilityPositionInstance position =
|
||||
CreatePositionFromTextMarker(parameter);
|
||||
@@ -2673,6 +2690,7 @@ - (id)accessibilityAttributeValue:(NSString*)attribute
|
||||
NSString* text = GetTextForTextMarkerRange(parameter);
|
||||
return [NSNumber numberWithInt:[text length]];
|
||||
if (!position->IsNullPosition())
|
||||
@@ -2854,6 +2869,7 @@ - (id)accessibilityAttributeValue:(NSString*)attribute
|
||||
|
||||
return CreateTextMarker(root->CreatePositionAt(index));
|
||||
}
|
||||
+#endif
|
||||
|
||||
if ([attribute isEqualToString:
|
||||
NSAccessibilityBoundsForRangeParameterizedAttribute]) {
|
||||
@@ -2706,6 +2724,7 @@ - (id)accessibilityAttributeValue:(NSString*)attribute
|
||||
@@ -2887,6 +2903,7 @@ - (id)accessibilityAttributeValue:(NSString*)attribute
|
||||
return nil;
|
||||
}
|
||||
|
||||
@@ -171,7 +175,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
if ([attribute
|
||||
isEqualToString:
|
||||
NSAccessibilityLineTextMarkerRangeForTextMarkerParameterizedAttribute]) {
|
||||
@@ -2786,6 +2805,7 @@ AXPlatformRange range(position->CreatePreviousLineStartPosition(
|
||||
@@ -2967,6 +2984,7 @@ AXPlatformRange range(position->CreatePreviousLineStartPosition(
|
||||
|
||||
return @(child->GetIndexInParent());
|
||||
}
|
||||
@@ -180,7 +184,7 @@ index 6e97b6750cad46a8a8096c199c3a2f5386e0ae3b..3cfbb34bf6426d575c7affb9f4f95039
|
||||
return nil;
|
||||
}
|
||||
diff --git a/content/browser/accessibility/browser_accessibility_manager_mac.mm b/content/browser/accessibility/browser_accessibility_manager_mac.mm
|
||||
index cd447453b5a8877a9b1da7eab28130a795e3015b..9ef9a7aa5733b8591ed96511e9cdbc8f51875d04 100644
|
||||
index 851da832bd30e05974317601712f309b2d542ab6..dd6d4c50468ec5f3364213e43b9336f13b153a19 100644
|
||||
--- a/content/browser/accessibility/browser_accessibility_manager_mac.mm
|
||||
+++ b/content/browser/accessibility/browser_accessibility_manager_mac.mm
|
||||
@@ -493,6 +493,7 @@ void PostAnnouncementNotification(NSString* announcement) {
|
||||
@@ -232,7 +236,7 @@ index e59ac93d0e1554a2df5d8c74db2beba25d090228..6657c48664bdec4964b382f80309d1bf
|
||||
|
||||
} // namespace
|
||||
diff --git a/device/bluetooth/bluetooth_adapter_mac.mm b/device/bluetooth/bluetooth_adapter_mac.mm
|
||||
index b6bea74d9f9c2fcfba381477895e4c15741318fc..4a02e5659e85c507d480d7fb9b63ee10bad1fe85 100644
|
||||
index 8e4a469b6f0675dc7b82543d5758f0c2ec226809..2fcfb6edb5f57bd25756257b77361d25768f9abf 100644
|
||||
--- a/device/bluetooth/bluetooth_adapter_mac.mm
|
||||
+++ b/device/bluetooth/bluetooth_adapter_mac.mm
|
||||
@@ -36,6 +36,7 @@
|
||||
@@ -276,7 +280,7 @@ index b6bea74d9f9c2fcfba381477895e4c15741318fc..4a02e5659e85c507d480d7fb9b63ee10
|
||||
|
||||
void BluetoothAdapterMac::RemovePairingDelegateInternal(
|
||||
diff --git a/media/audio/BUILD.gn b/media/audio/BUILD.gn
|
||||
index d8ae83ce63aafdd0fcd1994a144465791e94ba4a..d19096f9afd606bb7bfd6c377f8a976417d3bff2 100644
|
||||
index 35fd1d7da0adfb8c8bef3d2ff3aa9ac25285421a..b7eda4e11c464e733e4ddb1cbf009ba811fc332a 100644
|
||||
--- a/media/audio/BUILD.gn
|
||||
+++ b/media/audio/BUILD.gn
|
||||
@@ -180,6 +180,12 @@ source_set("audio") {
|
||||
@@ -306,10 +310,10 @@ index 7ec6dab821b542cb0096e7f8875ba21703463087..3e26c9dd0a296b8d9c99ca1ee9d9faba
|
||||
}
|
||||
|
||||
diff --git a/net/dns/dns_config_service_posix.cc b/net/dns/dns_config_service_posix.cc
|
||||
index ee2d5721425c86124de6396b77a564d55e89a212..954812b9dda506b16483c37e9ed938716aa560d1 100644
|
||||
index 2e0f06b0c1e4b1670bfe8145b3c5abb178b47d62..2f9483283a789a69d7e85536620daa2e35ee9155 100644
|
||||
--- a/net/dns/dns_config_service_posix.cc
|
||||
+++ b/net/dns/dns_config_service_posix.cc
|
||||
@@ -244,6 +244,7 @@ class DnsConfigServicePosix::Watcher {
|
||||
@@ -246,6 +246,7 @@ class DnsConfigServicePosix::Watcher {
|
||||
|
||||
bool Watch() {
|
||||
bool success = true;
|
||||
@@ -317,7 +321,7 @@ index ee2d5721425c86124de6396b77a564d55e89a212..954812b9dda506b16483c37e9ed93871
|
||||
if (!config_watcher_.Watch(base::Bind(&Watcher::OnConfigChanged,
|
||||
base::Unretained(this)))) {
|
||||
LOG(ERROR) << "DNS config watch failed to start.";
|
||||
@@ -265,6 +266,7 @@ class DnsConfigServicePosix::Watcher {
|
||||
@@ -267,6 +268,7 @@ class DnsConfigServicePosix::Watcher {
|
||||
DNS_CONFIG_WATCH_MAX);
|
||||
}
|
||||
#endif // !defined(OS_ANDROID) && !defined(OS_IOS)
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Jeremy Apthorp <nornagon@nornagon.net>
|
||||
Date: Wed, 8 May 2019 17:25:55 -0700
|
||||
Subject: network service: allow remote certificate verification logic
|
||||
Subject: network_service_allow_remote_certificate_verification_logic.patch
|
||||
|
||||
|
||||
diff --git a/services/network/network_context.cc b/services/network/network_context.cc
|
||||
index dffa1299b1cfce8609313435769189495fd8ccb5..ddea6f6e60b6f5ec4c0fdaddf825870f6b4db419 100644
|
||||
index ace1397d74dc49d730fd635aed0206febf8711f4..13fcd399516c7c26cf89a15dda083faea97ea969 100644
|
||||
--- a/services/network/network_context.cc
|
||||
+++ b/services/network/network_context.cc
|
||||
@@ -91,6 +91,11 @@
|
||||
@@ -90,6 +90,11 @@
|
||||
#include "services/network/url_loader.h"
|
||||
#include "services/network/url_request_context_builder_mojo.h"
|
||||
|
||||
@@ -20,7 +20,7 @@ index dffa1299b1cfce8609313435769189495fd8ccb5..ddea6f6e60b6f5ec4c0fdaddf825870f
|
||||
#if BUILDFLAG(IS_CT_SUPPORTED)
|
||||
#include "components/certificate_transparency/chrome_ct_policy_enforcer.h"
|
||||
#include "components/certificate_transparency/chrome_require_ct_delegate.h"
|
||||
@@ -319,6 +324,75 @@ std::string HashesToBase64String(const net::HashValueVector& hashes) {
|
||||
@@ -318,6 +323,75 @@ std::string HashesToBase64String(const net::HashValueVector& hashes) {
|
||||
|
||||
} // namespace
|
||||
|
||||
@@ -96,7 +96,7 @@ index dffa1299b1cfce8609313435769189495fd8ccb5..ddea6f6e60b6f5ec4c0fdaddf825870f
|
||||
constexpr uint32_t NetworkContext::kMaxOutstandingRequestsPerProcess;
|
||||
constexpr bool NetworkContext::enable_resource_scheduler_;
|
||||
|
||||
@@ -676,6 +750,12 @@ void NetworkContext::SetClient(mojom::NetworkContextClientPtr client) {
|
||||
@@ -649,6 +723,12 @@ void NetworkContext::SetClient(mojom::NetworkContextClientPtr client) {
|
||||
client_ = std::move(client);
|
||||
}
|
||||
|
||||
@@ -109,7 +109,7 @@ index dffa1299b1cfce8609313435769189495fd8ccb5..ddea6f6e60b6f5ec4c0fdaddf825870f
|
||||
void NetworkContext::CreateURLLoaderFactory(
|
||||
mojom::URLLoaderFactoryRequest request,
|
||||
mojom::URLLoaderFactoryParamsPtr params) {
|
||||
@@ -2151,12 +2231,19 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext() {
|
||||
@@ -1723,12 +1803,19 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext() {
|
||||
cert_net_fetcher_, /*system_trust_store_provider=*/nullptr)));
|
||||
}
|
||||
#endif
|
||||
@@ -134,7 +134,7 @@ index dffa1299b1cfce8609313435769189495fd8ccb5..ddea6f6e60b6f5ec4c0fdaddf825870f
|
||||
std::unique_ptr<net::NetworkDelegate> network_delegate =
|
||||
std::make_unique<NetworkServiceNetworkDelegate>(this);
|
||||
diff --git a/services/network/network_context.h b/services/network/network_context.h
|
||||
index 297289317efc82b61379c7800e1039eaaf49dc6b..40ba50148d10f16afd9f386917966a6f797b1d92 100644
|
||||
index 936ed0637758cb8b0b39d04dc0bf84a80b38eeec..f765e5e232de56f070d404e16149abd6627159cd 100644
|
||||
--- a/services/network/network_context.h
|
||||
+++ b/services/network/network_context.h
|
||||
@@ -80,6 +80,7 @@ class DomainReliabilityMonitor;
|
||||
@@ -145,7 +145,7 @@ index 297289317efc82b61379c7800e1039eaaf49dc6b..40ba50148d10f16afd9f386917966a6f
|
||||
class CookieManager;
|
||||
class ExpectCTReporter;
|
||||
class HostResolver;
|
||||
@@ -182,6 +183,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
@@ -165,6 +166,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
|
||||
// mojom::NetworkContext implementation:
|
||||
void SetClient(mojom::NetworkContextClientPtr client) override;
|
||||
@@ -153,7 +153,7 @@ index 297289317efc82b61379c7800e1039eaaf49dc6b..40ba50148d10f16afd9f386917966a6f
|
||||
void CreateURLLoaderFactory(mojom::URLLoaderFactoryRequest request,
|
||||
mojom::URLLoaderFactoryParamsPtr params) override;
|
||||
void ResetURLLoaderFactories() override;
|
||||
@@ -576,6 +578,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
@@ -557,6 +559,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
|
||||
std::unique_ptr<network::NSSTempCertsCacheChromeOS> nss_temp_certs_cache_;
|
||||
#endif
|
||||
|
||||
@@ -163,11 +163,11 @@ index 297289317efc82b61379c7800e1039eaaf49dc6b..40ba50148d10f16afd9f386917966a6f
|
||||
// CertNetFetcher is not used by the current platform.
|
||||
scoped_refptr<net::CertNetFetcherImpl> cert_net_fetcher_;
|
||||
diff --git a/services/network/public/mojom/network_context.mojom b/services/network/public/mojom/network_context.mojom
|
||||
index 58b18e0c3c2beea5f22af3c0b2ad206798ad33a9..4dcb94d32a9928d70f061dbc12dc7b7e672025b8 100644
|
||||
index bd03a47acefb77d0271f58ba28866f689ac21ad3..4e21a1276d83ce0154aa06e169e4b4394d215164 100644
|
||||
--- a/services/network/public/mojom/network_context.mojom
|
||||
+++ b/services/network/public/mojom/network_context.mojom
|
||||
@@ -161,6 +161,17 @@ interface TrustedURLLoaderHeaderClient {
|
||||
OnLoaderCreated(int32 request_id, TrustedHeaderClient& header_client);
|
||||
@@ -164,6 +164,17 @@ interface TrustedURLLoaderHeaderClient {
|
||||
pending_receiver<TrustedHeaderClient> header_client);
|
||||
};
|
||||
|
||||
+interface CertVerifierClient {
|
||||
@@ -184,7 +184,7 @@ index 58b18e0c3c2beea5f22af3c0b2ad206798ad33a9..4dcb94d32a9928d70f061dbc12dc7b7e
|
||||
// Parameters for constructing a network context.
|
||||
struct NetworkContextParams {
|
||||
// Name used by memory tools to identify the context.
|
||||
@@ -576,6 +587,9 @@ interface NetworkContext {
|
||||
@@ -697,6 +708,9 @@ interface NetworkContext {
|
||||
// Sets a client for this network context.
|
||||
SetClient(NetworkContextClient client);
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ Do not check for unique origin in CacheStorage, in Electron we may have
|
||||
scripts running without an origin.
|
||||
|
||||
diff --git a/content/browser/cache_storage/legacy/legacy_cache_storage.cc b/content/browser/cache_storage/legacy/legacy_cache_storage.cc
|
||||
index a064cef489d6dbb86c1fd1da2bd2e918316326ed..9408cf6ec682bc917555a328926d0f57e49c61a1 100644
|
||||
index b1a4d62c9230fd11e74d4fa959b0d89f30a27e83..225c31ec025d73eb581dee9a05cb17cd70ee4be8 100644
|
||||
--- a/content/browser/cache_storage/legacy/legacy_cache_storage.cc
|
||||
+++ b/content/browser/cache_storage/legacy/legacy_cache_storage.cc
|
||||
@@ -104,7 +104,7 @@ class LegacyCacheStorage::CacheLoader {
|
||||
|
||||
@@ -1,12 +1,13 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Jeremy Apthorp <jeremya@chromium.org>
|
||||
Date: Fri, 5 Oct 2018 14:22:06 -0700
|
||||
Subject: pass RenderProcessHost through to PlatformNotificationService
|
||||
Subject: notification_provenance.patch
|
||||
|
||||
this is so Electron can identify which renderer a notification came from
|
||||
Pass RenderProcessHost through to PlatformNotificationService
|
||||
so Electron can identify which renderer a notification came from.
|
||||
|
||||
diff --git a/content/browser/notifications/blink_notification_service_impl.cc b/content/browser/notifications/blink_notification_service_impl.cc
|
||||
index ceb4bc6248a961bd907e35e9f758cebdbd0ae62b..c85acbb33b7b467716b717159816a00e67d46119 100644
|
||||
index a717d9f3539dc0fe86b743c6e29e4311b8b5cec3..1351217319c57be414e6c66f8a01f71fe46d2c04 100644
|
||||
--- a/content/browser/notifications/blink_notification_service_impl.cc
|
||||
+++ b/content/browser/notifications/blink_notification_service_impl.cc
|
||||
@@ -88,9 +88,11 @@ BlinkNotificationServiceImpl::BlinkNotificationServiceImpl(
|
||||
@@ -54,7 +55,7 @@ index 5253f6be778cc78571b3df0a33d364a9b1e6ef52..dc5307e6500b0bfb5da83e8d8ff8886b
|
||||
|
||||
scoped_refptr<ServiceWorkerContextWrapper> service_worker_context_;
|
||||
diff --git a/content/browser/notifications/blink_notification_service_impl_unittest.cc b/content/browser/notifications/blink_notification_service_impl_unittest.cc
|
||||
index f64eb733ede38501c34b2af89f42255189abd982..3c2dfad7ac9ba64b0b49ebef41a303edd1470cb1 100644
|
||||
index ce997528ce2973b54dbbf965220cc30bcb19a094..e84b0b62d853b044e590a0c764f1b21ad3210886 100644
|
||||
--- a/content/browser/notifications/blink_notification_service_impl_unittest.cc
|
||||
+++ b/content/browser/notifications/blink_notification_service_impl_unittest.cc
|
||||
@@ -138,7 +138,7 @@ class BlinkNotificationServiceImplTest : public ::testing::Test {
|
||||
@@ -67,7 +68,7 @@ index f64eb733ede38501c34b2af89f42255189abd982..3c2dfad7ac9ba64b0b49ebef41a303ed
|
||||
notification_service_remote_.BindNewPipeAndPassReceiver());
|
||||
|
||||
diff --git a/content/browser/notifications/platform_notification_context_impl.cc b/content/browser/notifications/platform_notification_context_impl.cc
|
||||
index 564d4fdb4d414bdb49d74dc8066dd3de86339dda..32d0ab7f8049dc13e83deac925ef9d10fc1554c1 100644
|
||||
index 93ae69a720d4d24b5fd11508a9f6ec3c17f559d5..93768924cf442ef4cb36addfe279852b9c0dd444 100644
|
||||
--- a/content/browser/notifications/platform_notification_context_impl.cc
|
||||
+++ b/content/browser/notifications/platform_notification_context_impl.cc
|
||||
@@ -207,12 +207,13 @@ void PlatformNotificationContextImpl::Shutdown() {
|
||||
@@ -87,7 +88,7 @@ index 564d4fdb4d414bdb49d74dc8066dd3de86339dda..32d0ab7f8049dc13e83deac925ef9d10
|
||||
|
||||
void PlatformNotificationContextImpl::RemoveService(
|
||||
diff --git a/content/browser/notifications/platform_notification_context_impl.h b/content/browser/notifications/platform_notification_context_impl.h
|
||||
index 83d7c93482bf68ca98ee58de537711dad5844699..edd488efa643e80659cceab476cf53e12f10a1fb 100644
|
||||
index 4bf25bf1fa69f7d3869369172d375e2e489e62a1..f80ef2cecc8b111dc54e109646573a5978d8ea9c 100644
|
||||
--- a/content/browser/notifications/platform_notification_context_impl.h
|
||||
+++ b/content/browser/notifications/platform_notification_context_impl.h
|
||||
@@ -24,6 +24,7 @@
|
||||
@@ -107,10 +108,10 @@ index 83d7c93482bf68ca98ee58de537711dad5844699..edd488efa643e80659cceab476cf53e1
|
||||
mojo::PendingReceiver<blink::mojom::NotificationService> receiver);
|
||||
|
||||
diff --git a/content/browser/renderer_interface_binders.cc b/content/browser/renderer_interface_binders.cc
|
||||
index cfdfae7e861ca6d5025f9478363e063afae326ef..b5dacb158e01091228aa97bb85db1efb24ceb6f7 100644
|
||||
index 39321f13c6b906ab9a3dab1f62d2eaa951a763a8..ac15adcd060fd2dfc7a1fc472ca617cac6319227 100644
|
||||
--- a/content/browser/renderer_interface_binders.cc
|
||||
+++ b/content/browser/renderer_interface_binders.cc
|
||||
@@ -196,7 +196,7 @@ void RendererInterfaceBinders::InitializeParameterizedBinderRegistry() {
|
||||
@@ -253,7 +253,7 @@ void RendererInterfaceBinders::InitializeParameterizedBinderRegistry() {
|
||||
RenderProcessHost* host, const url::Origin& origin) {
|
||||
static_cast<StoragePartitionImpl*>(host->GetStoragePartition())
|
||||
->GetPlatformNotificationContext()
|
||||
@@ -118,7 +119,7 @@ index cfdfae7e861ca6d5025f9478363e063afae326ef..b5dacb158e01091228aa97bb85db1efb
|
||||
+ ->CreateService(host, origin, std::move(request));
|
||||
}));
|
||||
parameterized_binder_registry_.AddInterface(
|
||||
base::BindRepeating(&BackgroundFetchServiceImpl::CreateForWorker));
|
||||
base::BindRepeating(&QuotaDispatcherHost::CreateForWorker));
|
||||
diff --git a/content/public/browser/platform_notification_service.h b/content/public/browser/platform_notification_service.h
|
||||
index ca61088079c4150fcf389504ddcf26bcf6bf69cd..d9c034c39890eef1fe3d95c6d7c0ae68eb711a89 100644
|
||||
--- a/content/public/browser/platform_notification_service.h
|
||||
@@ -141,7 +142,7 @@ index ca61088079c4150fcf389504ddcf26bcf6bf69cd..d9c034c39890eef1fe3d95c6d7c0ae68
|
||||
const GURL& origin,
|
||||
const blink::PlatformNotificationData& notification_data,
|
||||
diff --git a/content/test/mock_platform_notification_service.cc b/content/test/mock_platform_notification_service.cc
|
||||
index faa8e541d9cb530f9212420a4dfd0318069320db..0a244000e60daf8e6bd8e783b41124528a117026 100644
|
||||
index ba5982883a3821b42c47c80187af2e4d1b3f0ffb..720965aa1df6b415e12a85dd2b2e4475facab019 100644
|
||||
--- a/content/test/mock_platform_notification_service.cc
|
||||
+++ b/content/test/mock_platform_notification_service.cc
|
||||
@@ -29,6 +29,7 @@ MockPlatformNotificationService::MockPlatformNotificationService(
|
||||
|
||||
@@ -5,10 +5,10 @@ Subject: out_of_process_instance.patch
|
||||
|
||||
|
||||
diff --git a/pdf/out_of_process_instance.cc b/pdf/out_of_process_instance.cc
|
||||
index fa1ad2c48fac29d2f5ca93c83943878b3fc1a33f..1e97399067dcb8da735f70b1351ea1d08fb2e0e0 100644
|
||||
index 9c77f6422edbb42da34abb4320e0d5103cca5eea..8419b1ce6ed543b150c31d41dc8575e98c203427 100644
|
||||
--- a/pdf/out_of_process_instance.cc
|
||||
+++ b/pdf/out_of_process_instance.cc
|
||||
@@ -466,7 +466,9 @@ bool OutOfProcessInstance::Init(uint32_t argc,
|
||||
@@ -477,7 +477,9 @@ bool OutOfProcessInstance::Init(uint32_t argc,
|
||||
std::string document_url = document_url_var.AsString();
|
||||
base::StringPiece document_url_piece(document_url);
|
||||
is_print_preview_ = IsPrintPreviewUrl(document_url_piece);
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Jeremy Apthorp <nornagon@nornagon.net>
|
||||
Date: Fri, 12 Apr 2019 12:47:57 -0700
|
||||
Subject: patch the ensure_gn_version.py script to work on mac CI
|
||||
Subject: patch_the_ensure_gn_version_py_script_to_work_on_mac_ci.patch
|
||||
|
||||
This patches the ensure_gn_version_py script to work on macOS CI.
|
||||
This script is temporary until https://crbug.com/944667 is resolved. We need to
|
||||
patch it because on mac CI, we check out the source code on Linux, which
|
||||
confuses the script.
|
||||
|
||||
@@ -28,7 +28,7 @@ index 735da93c3cabb8c6139971295740ba14a30d1b69..533f53fbc42397608e3762e370cc935c
|
||||
// Non-owning pointer to the filter must outlive this class.
|
||||
explicit ChromeBrowserPepperHostFactory(content::BrowserPpapiHost* host);
|
||||
diff --git a/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc b/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc
|
||||
index 83cedb4c9e1323259afd041e571240cd971e1241..3686ae2fab5f400cf119a54aea547a72655c2b0a 100644
|
||||
index 37245c48cacbc5db164c61e4499f34ee83e0fce7..0fef12892e965e319e45f5dd1a9c5c9fc606aa9a 100644
|
||||
--- a/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc
|
||||
+++ b/chrome/browser/renderer_host/pepper/pepper_broker_message_filter.cc
|
||||
@@ -7,10 +7,12 @@
|
||||
@@ -61,7 +61,7 @@ index 83cedb4c9e1323259afd041e571240cd971e1241..3686ae2fab5f400cf119a54aea547a72
|
||||
+ return PP_OK;
|
||||
}
|
||||
diff --git a/chrome/browser/renderer_host/pepper/pepper_flash_browser_host.cc b/chrome/browser/renderer_host/pepper/pepper_flash_browser_host.cc
|
||||
index 9d28e920676edd065f735b8939854468321e99ca..6c086a792e343cf537e46f2c97c21b6257d7268e 100644
|
||||
index c6c2ac11fd5551fe03978b947d2dda4c016e59ae..2dc392a6eab17b048df730e294398a3a0fb2eb8d 100644
|
||||
--- a/chrome/browser/renderer_host/pepper/pepper_flash_browser_host.cc
|
||||
+++ b/chrome/browser/renderer_host/pepper/pepper_flash_browser_host.cc
|
||||
@@ -8,9 +8,11 @@
|
||||
@@ -179,7 +179,7 @@ index f2f40b636a41649199a38c663f03e6182df82520..41d11d1f1f9921d4b4deaaf4b2d8ab4b
|
||||
|
||||
DISALLOW_COPY_AND_ASSIGN(PepperFlashBrowserHost);
|
||||
diff --git a/chrome/browser/renderer_host/pepper/pepper_flash_drm_host.cc b/chrome/browser/renderer_host/pepper/pepper_flash_drm_host.cc
|
||||
index 0a727e8c438462a293db629da07d5aef2b25a9ee..b49303e2c19329715f72d8926cb765289224d000 100644
|
||||
index 2e51425cb66f25f240ad7f4a052bcf6eb76f2062..240fa299b1160ebb2f9b20c7361405c9b84d5d2f 100644
|
||||
--- a/chrome/browser/renderer_host/pepper/pepper_flash_drm_host.cc
|
||||
+++ b/chrome/browser/renderer_host/pepper/pepper_flash_drm_host.cc
|
||||
@@ -20,6 +20,7 @@
|
||||
@@ -258,7 +258,7 @@ index b9d2ce7f7f6837ee7b304daac82d21a3147c6faf..4d4b023d62d12b4d119acbfdee64f415
|
||||
|
||||
base::WeakPtrFactory<PepperFlashDRMHost> weak_factory_{this};
|
||||
diff --git a/chrome/browser/renderer_host/pepper/pepper_isolated_file_system_message_filter.cc b/chrome/browser/renderer_host/pepper/pepper_isolated_file_system_message_filter.cc
|
||||
index 0d083bb09ff17a691c6399d2a5746b44e3196873..2023dc0240220362a1b503da07aa9fab4cb4b434 100644
|
||||
index 00db4e2fa2ac89d89ecd31174e192dcb17f3e912..df5a53c162059270ad673fffebbd432f6df0d212 100644
|
||||
--- a/chrome/browser/renderer_host/pepper/pepper_isolated_file_system_message_filter.cc
|
||||
+++ b/chrome/browser/renderer_host/pepper/pepper_isolated_file_system_message_filter.cc
|
||||
@@ -8,17 +8,21 @@
|
||||
@@ -316,7 +316,7 @@ index 0d083bb09ff17a691c6399d2a5746b44e3196873..2023dc0240220362a1b503da07aa9fab
|
||||
}
|
||||
|
||||
PepperIsolatedFileSystemMessageFilter::
|
||||
@@ -96,6 +102,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnResourceMessageReceived(
|
||||
@@ -95,6 +101,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnResourceMessageReceived(
|
||||
return PP_ERROR_FAILED;
|
||||
}
|
||||
|
||||
@@ -324,7 +324,7 @@ index 0d083bb09ff17a691c6399d2a5746b44e3196873..2023dc0240220362a1b503da07aa9fab
|
||||
Profile* PepperIsolatedFileSystemMessageFilter::GetProfile() {
|
||||
DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
|
||||
ProfileManager* profile_manager = g_browser_process->profile_manager();
|
||||
@@ -122,6 +129,7 @@ PepperIsolatedFileSystemMessageFilter::CreateCrxFileSystem(Profile* profile) {
|
||||
@@ -121,6 +128,7 @@ PepperIsolatedFileSystemMessageFilter::CreateCrxFileSystem(Profile* profile) {
|
||||
return storage::IsolatedContext::ScopedFSHandle();
|
||||
#endif
|
||||
}
|
||||
@@ -332,7 +332,7 @@ index 0d083bb09ff17a691c6399d2a5746b44e3196873..2023dc0240220362a1b503da07aa9fab
|
||||
|
||||
int32_t PepperIsolatedFileSystemMessageFilter::OnOpenFileSystem(
|
||||
ppapi::host::HostMessageContext* context,
|
||||
@@ -130,7 +138,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnOpenFileSystem(
|
||||
@@ -129,7 +137,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnOpenFileSystem(
|
||||
case PP_ISOLATEDFILESYSTEMTYPE_PRIVATE_INVALID:
|
||||
break;
|
||||
case PP_ISOLATEDFILESYSTEMTYPE_PRIVATE_CRX:
|
||||
@@ -341,7 +341,7 @@ index 0d083bb09ff17a691c6399d2a5746b44e3196873..2023dc0240220362a1b503da07aa9fab
|
||||
case PP_ISOLATEDFILESYSTEMTYPE_PRIVATE_PLUGINPRIVATE:
|
||||
return OpenPluginPrivateFileSystem(context);
|
||||
}
|
||||
@@ -140,6 +148,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnOpenFileSystem(
|
||||
@@ -139,6 +147,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OnOpenFileSystem(
|
||||
return PP_ERROR_FAILED;
|
||||
}
|
||||
|
||||
@@ -349,7 +349,7 @@ index 0d083bb09ff17a691c6399d2a5746b44e3196873..2023dc0240220362a1b503da07aa9fab
|
||||
int32_t PepperIsolatedFileSystemMessageFilter::OpenCrxFileSystem(
|
||||
ppapi::host::HostMessageContext* context) {
|
||||
#if BUILDFLAG(ENABLE_EXTENSIONS)
|
||||
@@ -180,6 +189,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OpenCrxFileSystem(
|
||||
@@ -179,6 +188,7 @@ int32_t PepperIsolatedFileSystemMessageFilter::OpenCrxFileSystem(
|
||||
return PP_ERROR_NOTSUPPORTED;
|
||||
#endif
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user