Skip to content

Commit 9eb9ecd

Browse files
Allan Sandfeld Jensenpatricia-gallardo
Allan Sandfeld Jensen
authored andcommitted
Adaptations for Chromium 87
Change-Id: Ic4ffd98e02f986dbaf986405360e727c813e696e Reviewed-by: Peter Varga <[email protected]>
1 parent 3f0a4e4 commit 9eb9ecd

File tree

64 files changed

+640
-649
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

64 files changed

+640
-649
lines changed

configure.pri

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -201,6 +201,19 @@ defineTest(qtConfTest_detectNodeJS) {
201201
return(false)
202202
}
203203
}
204+
nodejs = $$system_quote($$system_path($$nodejs))
205+
!qtRunLoggedCommand("$$nodejs --version", version) {
206+
qtLog("'$$nodejs' didn't run.")
207+
return(false)
208+
}
209+
# at least version 10
210+
version10 = false
211+
contains(version, "v([1-9][0-9])\..*"): version10 = true
212+
213+
$${1}.version10 = $$version10
214+
export($${1}.version10)
215+
$${1}.cache += version10
216+
export($${1}.cache)
204217
return(true)
205218
}
206219

src/buildtools/config/common.pri

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,24 +14,25 @@ gn_args += \
1414
enable_nacl=false \
1515
enable_remoting=false \
1616
enable_reporting=false \
17-
enable_resource_whitelist_generation=false \
17+
enable_resource_allowlist_generation=false \
1818
enable_swiftshader=false \
19+
enable_swiftshader_vulkan=false \
1920
angle_enable_swiftshader=false \
20-
enable_web_auth=true \
2121
enable_web_speech=false \
2222
enable_widevine=true \
2323
forbid_non_component_debug_builds=false \
2424
has_native_accessibility=false \
2525
safe_browsing_mode=0 \
26+
skia_use_dawn=false \
2627
toolkit_views=false \
2728
treat_warnings_as_errors=false \
2829
use_allocator_shim=false \
2930
use_allocator=\"none\" \
30-
use_custom_libcxx=false
31+
use_custom_libcxx=false \
32+
chrome_pgo_phase=0
3133

3234
# No closure compile supported at this time
3335
gn_args += \
34-
closure_compile=false \
3536
optimize_webui=false
3637

3738
# We always embed v8 startup data currently

src/buildtools/config/support.pri

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ defineReplace(qtwebengine_checkWebEngineCoreError) {
2121
!qtwebengine_checkForGperf(QtWebEngine):return(false)
2222
!qtwebengine_checkForBison(QtWebEngine):return(false)
2323
!qtwebengine_checkForFlex(QtWebEngine):return(false)
24-
!qtwebengine_checkForPython2(QtWebengine):return(false)
24+
!qtwebengine_checkForPython2(QtWebEngine):return(false)
2525
!qtwebengine_checkForSanitizer(QtWebEngine):return(false)
2626
linux:!qtwebengine_checkForPkgCfg(QtWebEngine):return(false)
2727
linux:!qtwebengine_checkForHostPkgCfg(QtWebEngine):return(false)
@@ -151,6 +151,15 @@ defineTest(qtwebengine_checkForPython2) {
151151
return(true)
152152
}
153153

154+
defineTest(qtwebengine_checkForNodejs) {
155+
module = $$1
156+
!qtConfig(webengine-nodejs) {
157+
qtwebengine_skipBuild("Nodejs is required to build $${module}.")
158+
return(false)
159+
}
160+
return(true)
161+
}
162+
154163
defineTest(qtwebengine_checkForSanitizer) {
155164
module = $$1
156165
sanitizer:!qtConfig(webengine-sanitizer) {

src/buildtools/config/windows.pri

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ gn_args += \
44
use_sysroot=false \
55
enable_session_service=false \
66
ninja_use_custom_environment_files=false \
7-
is_multi_dll_chrome=false \
87
win_linker_timing=true \
98
com_init_check_hook_disabled=true \
109
heterogeneous_executables=true \

src/buildtools/configure.json

Lines changed: 34 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,12 @@
6868
{ "type": "pkgConfig", "args": "x11" }
6969
]
7070
},
71+
"webengine-xproto-gl": {
72+
"label": "xproto (glproto)",
73+
"sources": [
74+
{ "type": "pkgConfig", "args": "glproto" }
75+
]
76+
},
7177
"webengine-glib": {
7278
"label": "glib-2.0 >= 2.32.0",
7379
"sources": [
@@ -155,9 +161,9 @@
155161
]
156162
},
157163
"webengine-icu": {
158-
"label": "icu >= 64",
164+
"label": "icu >= 65",
159165
"sources": [
160-
{ "type": "pkgConfig", "args": "icu-uc >= 64 icu-i18n >= 64" }
166+
{ "type": "pkgConfig", "args": "icu-uc >= 65 icu-i18n >= 65" }
161167
]
162168
},
163169
"webengine-webp": {
@@ -238,10 +244,11 @@
238244
"vpx_codec_cx_pkt pkt;",
239245
"pkt.data.frame.width[0] = 0u;",
240246
"pkt.data.frame.height[0] = 0u;",
241-
"auto a = CONSTRAINED_FROM_ABOVE_DROP;"
247+
"auto a = CONSTRAINED_FROM_ABOVE_DROP;",
248+
"auto b = VPX_IMG_FMT_NV12;"
242249
]
243250
},
244-
"headers": [ "vpx/vpx_encoder.h", "vpx/vp8cx.h" ],
251+
"headers": [ "vpx/vpx_encoder.h", "vpx/vp8cx.h", "vpx/vpx_image.h" ],
245252
"sources": [
246253
{ "type": "pkgConfig", "args": "vpx" },
247254
"-lvpx"
@@ -357,6 +364,11 @@
357364
"label": "linker supports -z noexecstack",
358365
"type": "linkerSupportsFlag",
359366
"flag": "-z,noexecstack"
367+
},
368+
"webengine-nodejs": {
369+
"label": "node.js",
370+
"type": "detectNodeJS",
371+
"log": "version10"
360372
}
361373
},
362374
"features": {
@@ -373,6 +385,7 @@
373385
&& features.webengine-bison
374386
&& features.webengine-flex
375387
&& features.webengine-python2
388+
&& features.webengine-nodejs
376389
&& (!config.sanitizer || features.webengine-sanitizer)
377390
&& (!config.linux || features.pkg-config)
378391
&& (!config.linux || features.webengine-host-pkg-config)
@@ -443,6 +456,16 @@
443456
"condition": "tests.webengine-flex",
444457
"output": [ "privateFeature" ]
445458
},
459+
"webengine-nodejs": {
460+
"label": "node.js",
461+
"condition": "tests.webengine-nodejs",
462+
"output": [ "privateFeature" ]
463+
},
464+
"webengine-nodejs10": {
465+
"label": "node.js",
466+
"condition": "tests.webengine-nodejs && tests.webengine-nodejs.version10",
467+
"output": [ "privateFeature" ]
468+
},
446469
"webengine-system-ninja": {
447470
"label": "Use System Ninja",
448471
"condition": "tests.webengine-ninja",
@@ -509,6 +532,11 @@
509532
"condition": "config.unix && libs.webengine-x11",
510533
"output": [ "privateFeature" ]
511534
},
535+
"webengine-system-xproto-gl" : {
536+
"label": "xproto (glproto)",
537+
"condition": "config.unix && libs.webengine-xproto-gl",
538+
"output": [ "privateFeature" ]
539+
},
512540
"webengine-host-pkg-config": {
513541
"label": "host-pkg-config",
514542
"condition": "config.unix && tests.webengine-host-pkg-config",
@@ -525,6 +553,7 @@
525553
&& features.webengine-system-xcomposite
526554
&& features.webengine-system-xcursor
527555
&& features.webengine-system-xi
556+
&& features.webengine-system-xproto-gl
528557
&& features.webengine-system-xtst",
529558
"output": [ "privateFeature" ]
530559
},
@@ -781,6 +810,7 @@
781810
"webengine-system-xcomposite",
782811
"webengine-system-xcursor",
783812
"webengine-system-xi",
813+
"webengine-system-xproto-gl",
784814
"webengine-system-xtst"
785815
]
786816
},

src/core/accessibility_tree_formatter_qt.cpp

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,11 @@ class AccessibilityTreeFormatterQt : public AccessibilityTreeFormatterBase {
5959
explicit AccessibilityTreeFormatterQt();
6060
~AccessibilityTreeFormatterQt() override;
6161

62-
std::unique_ptr<base::DictionaryValue> BuildAccessibilityTreeForProcess(base::ProcessId) override { return nullptr; }
62+
std::unique_ptr<base::DictionaryValue> BuildAccessibilityTreeForSelector(const content::AccessibilityTreeFormatter::TreeSelector &)
63+
{ return nullptr; }
6364
std::unique_ptr<base::DictionaryValue> BuildAccessibilityTreeForWindow(gfx::AcceleratedWidget) override { return nullptr; }
64-
std::unique_ptr<base::DictionaryValue> BuildAccessibilityTreeForPattern(const base::StringPiece &) override { return nullptr; }
6565
std::unique_ptr<base::DictionaryValue> BuildAccessibilityTree(content::BrowserAccessibility *) override;
66+
6667
private:
6768
base::FilePath::StringType GetExpectedFileSuffix() override;
6869
const std::string GetAllowEmptyString() override;
@@ -72,7 +73,7 @@ class AccessibilityTreeFormatterQt : public AccessibilityTreeFormatterBase {
7273
const std::string GetRunUntilEventString() override;
7374
void RecursiveBuildAccessibilityTree(const content::BrowserAccessibility &node, base::DictionaryValue *dict) const;
7475
void AddProperties(const BrowserAccessibility &node, base::DictionaryValue *dict) const;
75-
base::string16 ProcessTreeForOutput(const base::DictionaryValue &node, base::DictionaryValue * = nullptr) override;
76+
std::string ProcessTreeForOutput(const base::DictionaryValue &node, base::DictionaryValue * = nullptr) override;
7677
};
7778

7879
AccessibilityTreeFormatterQt::AccessibilityTreeFormatterQt()
@@ -172,13 +173,13 @@ void AccessibilityTreeFormatterQt::AddProperties(const BrowserAccessibility &nod
172173
dict->SetString("description", acc_node->text(QAccessible::Description).toStdString());
173174
}
174175

175-
base::string16 AccessibilityTreeFormatterQt::ProcessTreeForOutput(const base::DictionaryValue &node, base::DictionaryValue *)
176+
std::string AccessibilityTreeFormatterQt::ProcessTreeForOutput(const base::DictionaryValue &node, base::DictionaryValue *)
176177
{
177-
base::string16 error_value;
178+
std::string error_value;
178179
if (node.GetString("error", &error_value))
179180
return error_value;
180181

181-
base::string16 line;
182+
std::string line;
182183
std::string role_value;
183184
node.GetString("role", &role_value);
184185
if (!role_value.empty())
@@ -206,7 +207,7 @@ base::string16 AccessibilityTreeFormatterQt::ProcessTreeForOutput(const base::Di
206207
node.GetInteger("id", &id_value);
207208
WriteAttribute(false, base::StringPrintf("id=%d", id_value), &line);
208209

209-
return line + base::ASCIIToUTF16("\n");
210+
return line + "\n";
210211
}
211212

212213
base::FilePath::StringType AccessibilityTreeFormatterQt::GetExpectedFileSuffix()

src/core/browser_accessibility_qt.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -435,8 +435,6 @@ QAccessible::Role BrowserAccessibilityQt::role() const
435435
return QAccessible::CheckBox;
436436
case ax::mojom::Role::kMenuItemRadio:
437437
return QAccessible::RadioButton;
438-
case ax::mojom::Role::kMenuButton:
439-
return QAccessible::MenuItem;
440438
case ax::mojom::Role::kMenuListOption:
441439
return QAccessible::MenuItem;
442440
case ax::mojom::Role::kMenuListPopup:

src/core/browser_main_parts_qt.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@
7878
#include <QOpenGLContext>
7979
#endif
8080

81-
#if defined(OS_MACOSX)
81+
#if defined(OS_MAC)
8282
#include "base/message_loop/message_pump_mac.h"
8383
#include "ui/base/idle/idle.h"
8484
#endif
@@ -225,7 +225,7 @@ std::unique_ptr<base::MessagePump> messagePumpFactory()
225225
madePrimaryPump = true;
226226
return std::make_unique<MessagePumpForUIQt>();
227227
}
228-
#if defined(OS_MACOSX)
228+
#if defined(OS_MAC)
229229
return base::MessagePumpMac::Create();
230230
#else
231231
return std::make_unique<base::MessagePumpForUI>();
@@ -268,7 +268,7 @@ int BrowserMainPartsQt::PreCreateThreads()
268268
{
269269
base::ThreadRestrictions::SetIOAllowed(true);
270270

271-
#if defined(OS_MACOSX)
271+
#if defined(OS_MAC)
272272
ui::InitIdleMonitor();
273273
#endif
274274

0 commit comments

Comments
 (0)