Compare commits

...

2 Commits

Author SHA1 Message Date
Marshall Greenblatt
ed4257c807 Fix duplicate open from DevTools when handling OnOpenURLFromTab (fixes #3735) 2024-07-11 14:33:55 -04:00
Marshall Greenblatt
b7a172fefc tools: Build using autoninja
Applies automatic `-j (#cores)` configuration
2024-07-11 10:17:21 -04:00
3 changed files with 22 additions and 4 deletions

View File

@ -226,6 +226,10 @@ patches = [
#
# Linux: Fix duplicate symbol error for window_frame_util.cc
# https://issuetracker.google.com/issues/343037853#comment3
#
# Avoid duplicate window from DevTools when CEF handles the open via
# OnOpenURLFromTab.
# https://github.com/chromiumembedded/cef/issues/3735
'name': 'chrome_browser_browser',
},
{

View File

@ -13,7 +13,7 @@ index 2480282a19d12..dbd1fbf8a15b5 100644
return false;
}
diff --git chrome/browser/devtools/devtools_window.cc chrome/browser/devtools/devtools_window.cc
index 02ff1e580d3a7..7f51115896049 100644
index 02ff1e580d3a7..e2e232c424029 100644
--- chrome/browser/devtools/devtools_window.cc
+++ chrome/browser/devtools/devtools_window.cc
@@ -37,6 +37,7 @@
@ -38,7 +38,21 @@ index 02ff1e580d3a7..7f51115896049 100644
}
// Create WebContents with devtools.
@@ -1919,12 +1927,28 @@ void DevToolsWindow::CreateDevToolsBrowser() {
@@ -1754,9 +1762,13 @@ void DevToolsWindow::OpenInNewTab(const GURL& url) {
if (!inspected_web_contents ||
!inspected_web_contents->OpenURL(params,
/*navigation_handle_callback=*/{})) {
+#if !BUILDFLAG(ENABLE_CEF)
+ // Remove default behavior when CEF handles the open via OnOpenURLFromTab.
+ // See CEF issue #3735.
chrome::ScopedTabbedBrowserDisplayer displayer(profile_);
chrome::AddSelectedTabWithURL(displayer.browser(), fixed_url,
ui::PAGE_TRANSITION_LINK);
+#endif
}
}
@@ -1919,12 +1931,28 @@ void DevToolsWindow::CreateDevToolsBrowser() {
Browser::CreationStatus::kOk) {
return;
}

View File

@ -1335,8 +1335,8 @@ if not options.nobuild and (chromium_checkout_changed or \
tool = os.path.join(cef_src_dir, 'tools', 'gclient_hook.py')
run('%s %s' % (python_exe, tool), cef_src_dir, depot_tools_dir)
# Build using Ninja.
command = 'ninja '
# Build using autoninja for automatic `-j (#cores)` configuration.
command = 'autoninja '
if options.verbosebuild:
command += '-v '
if options.buildfailurelimit != 1: