commit
95ffe14461
@ -1,62 +0,0 @@
|
||||
diff -up chromium-104.0.5112.101/chrome/browser/about_flags.cc.accel-mjpeg chromium-104.0.5112.101/chrome/browser/about_flags.cc
|
||||
--- chromium-104.0.5112.101/chrome/browser/about_flags.cc.accel-mjpeg 2022-08-16 23:29:08.000000000 +0000
|
||||
+++ chromium-104.0.5112.101/chrome/browser/about_flags.cc 2022-08-18 14:21:36.762266571 +0000
|
||||
@@ -4485,12 +4485,12 @@ const FeatureEntry kFeatureEntries[] = {
|
||||
flag_descriptions::kWebXrForceRuntimeDescription, kOsDesktop,
|
||||
MULTI_VALUE_TYPE(kWebXrForceRuntimeChoices)},
|
||||
#endif // ENABLE_VR
|
||||
-#if BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
+#if BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_LINUX)
|
||||
{"disable-accelerated-mjpeg-decode",
|
||||
flag_descriptions::kAcceleratedMjpegDecodeName,
|
||||
- flag_descriptions::kAcceleratedMjpegDecodeDescription, kOsCrOS,
|
||||
+ flag_descriptions::kAcceleratedMjpegDecodeDescription, kOsCrOS | kOsLinux,
|
||||
SINGLE_DISABLE_VALUE_TYPE(switches::kDisableAcceleratedMjpegDecode)},
|
||||
-#endif // BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
+#endif // BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_LINUX)
|
||||
{"system-keyboard-lock", flag_descriptions::kSystemKeyboardLockName,
|
||||
flag_descriptions::kSystemKeyboardLockDescription, kOsDesktop,
|
||||
FEATURE_VALUE_TYPE(features::kSystemKeyboardLock)},
|
||||
diff -up chromium-104.0.5112.101/chrome/browser/flag_descriptions.cc.accel-mjpeg chromium-104.0.5112.101/chrome/browser/flag_descriptions.cc
|
||||
--- chromium-104.0.5112.101/chrome/browser/flag_descriptions.cc.accel-mjpeg 2022-08-16 23:29:09.000000000 +0000
|
||||
+++ chromium-104.0.5112.101/chrome/browser/flag_descriptions.cc 2022-08-18 14:25:23.609572649 +0000
|
||||
@@ -4170,7 +4170,7 @@ const char kUseAngleGL[] = "OpenGL";
|
||||
|
||||
// ChromeOS -------------------------------------------------------------------
|
||||
|
||||
-#if BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
+#if BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_LINUX)
|
||||
|
||||
const char kAcceleratedMjpegDecodeName[] =
|
||||
"Hardware-accelerated mjpeg decode for captured frame";
|
||||
@@ -4178,6 +4178,10 @@ const char kAcceleratedMjpegDecodeDescri
|
||||
"Enable hardware-accelerated mjpeg decode for captured frame where "
|
||||
"available.";
|
||||
|
||||
+#endif
|
||||
+
|
||||
+#if BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
+
|
||||
const char kAdaptiveChargingForTestingName[] =
|
||||
"Show adaptive charging notifications for testing";
|
||||
const char kAdaptiveChargingForTestingDescription[] =
|
||||
diff -up chromium-104.0.5112.101/chrome/browser/flag_descriptions.h.accel-mjpeg chromium-104.0.5112.101/chrome/browser/flag_descriptions.h
|
||||
--- chromium-104.0.5112.101/chrome/browser/flag_descriptions.h.accel-mjpeg 2022-08-18 14:21:36.765266469 +0000
|
||||
+++ chromium-104.0.5112.101/chrome/browser/flag_descriptions.h 2022-08-18 14:26:10.469983301 +0000
|
||||
@@ -2390,11 +2390,15 @@ extern const char kUseAngleGL[];
|
||||
|
||||
// ChromeOS -------------------------------------------------------------------
|
||||
|
||||
-#if BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
+#if BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_LINUX)
|
||||
|
||||
extern const char kAcceleratedMjpegDecodeName[];
|
||||
extern const char kAcceleratedMjpegDecodeDescription[];
|
||||
|
||||
+#endif // BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_LINUX)
|
||||
+
|
||||
+#if BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
+
|
||||
extern const char kAdaptiveChargingName[];
|
||||
extern const char kAdaptiveChargingDescription[];
|
||||
|
@ -1,19 +0,0 @@
|
||||
diff -up chromium-109.0.5414.74/chrome/browser/media/router/media_router_feature.cc.disable-GlobalMediaControlsCastStartStop chromium-109.0.5414.74/chrome/browser/media/router/media_router_feature.cc
|
||||
--- chromium-109.0.5414.74/chrome/browser/media/router/media_router_feature.cc.disable-GlobalMediaControlsCastStartStop 2023-01-11 15:27:50.587737070 +0100
|
||||
+++ chromium-109.0.5414.74/chrome/browser/media/router/media_router_feature.cc 2023-01-11 15:30:35.136829951 +0100
|
||||
@@ -48,15 +48,9 @@ BASE_FEATURE(kMediaRemotingWithoutFullsc
|
||||
"MediaRemotingWithoutFullscreen",
|
||||
base::FEATURE_DISABLED_BY_DEFAULT);
|
||||
|
||||
-#if BUILDFLAG(IS_CHROMEOS)
|
||||
BASE_FEATURE(kGlobalMediaControlsCastStartStop,
|
||||
"GlobalMediaControlsCastStartStop",
|
||||
base::FEATURE_DISABLED_BY_DEFAULT);
|
||||
-#else
|
||||
-BASE_FEATURE(kGlobalMediaControlsCastStartStop,
|
||||
- "GlobalMediaControlsCastStartStop",
|
||||
- base::FEATURE_ENABLED_BY_DEFAULT);
|
||||
-#endif // BUILDFLAG(IS_CHROMEOS)
|
||||
|
||||
#endif // BUILDFLAG(IS_ANDROID)
|
||||
|
@ -1,79 +0,0 @@
|
||||
diff -up chromium-112.0.5615.20/chrome/common/safe_browsing/BUILD.gn.nounrar chromium-112.0.5615.20/chrome/common/safe_browsing/BUILD.gn
|
||||
--- chromium-112.0.5615.20/chrome/common/safe_browsing/BUILD.gn.nounrar 2023-03-08 23:00:09.000000000 +0100
|
||||
+++ chromium-112.0.5615.20/chrome/common/safe_browsing/BUILD.gn 2023-03-10 16:02:12.970759171 +0100
|
||||
@@ -58,25 +58,6 @@ if (safe_browsing_mode == 1) {
|
||||
public_deps = [ "//components/safe_browsing/core/common/proto:csd_proto" ]
|
||||
}
|
||||
|
||||
- source_set("rar_analyzer") {
|
||||
- sources = [
|
||||
- "rar_analyzer.cc",
|
||||
- "rar_analyzer.h",
|
||||
- ]
|
||||
-
|
||||
- deps = [
|
||||
- ":archive_analyzer_results",
|
||||
- ":download_type_util",
|
||||
- "//base",
|
||||
- "//base:i18n",
|
||||
- "//components/safe_browsing/content/common:file_type_policies",
|
||||
- "//components/safe_browsing/core/common",
|
||||
- "//third_party/unrar:unrar",
|
||||
- ]
|
||||
-
|
||||
- public_deps = [ "//components/safe_browsing/core/common/proto:csd_proto" ]
|
||||
- }
|
||||
-
|
||||
if (is_linux || is_win) {
|
||||
source_set("document_analyzer") {
|
||||
sources = [
|
||||
@@ -172,7 +153,6 @@ source_set("safe_browsing") {
|
||||
":archive_analyzer_results",
|
||||
":binary_feature_extractor",
|
||||
":download_type_util",
|
||||
- ":rar_analyzer",
|
||||
"//components/safe_browsing/core/common",
|
||||
"//third_party/lzma_sdk/google:seven_zip_reader",
|
||||
]
|
||||
diff -up chromium-112.0.5615.20/chrome/common/safe_browsing/DEPS.nounrar chromium-112.0.5615.20/chrome/common/safe_browsing/DEPS
|
||||
--- chromium-112.0.5615.20/chrome/common/safe_browsing/DEPS.nounrar 2023-03-08 23:00:09.000000000 +0100
|
||||
+++ chromium-112.0.5615.20/chrome/common/safe_browsing/DEPS 2023-03-10 13:20:06.558188423 +0100
|
||||
@@ -3,7 +3,6 @@ include_rules = [
|
||||
"+components/safe_browsing/core/common",
|
||||
"+third_party/maldoca",
|
||||
"+third_party/protobuf",
|
||||
- "+third_party/unrar",
|
||||
"+third_party/zlib",
|
||||
"+third_party/lzma_sdk/google",
|
||||
]
|
||||
diff -up chromium-112.0.5615.20/chrome/services/file_util/BUILD.gn.nounrar chromium-112.0.5615.20/chrome/services/file_util/BUILD.gn
|
||||
--- chromium-112.0.5615.20/chrome/services/file_util/BUILD.gn.nounrar 2023-03-08 23:00:09.000000000 +0100
|
||||
+++ chromium-112.0.5615.20/chrome/services/file_util/BUILD.gn 2023-03-10 13:20:06.558188423 +0100
|
||||
@@ -60,7 +60,6 @@ source_set("file_util") {
|
||||
deps += [
|
||||
"//chrome/common/safe_browsing",
|
||||
"//chrome/common/safe_browsing:archive_analyzer_results",
|
||||
- "//chrome/common/safe_browsing:rar_analyzer",
|
||||
]
|
||||
|
||||
if (is_linux || is_win) {
|
||||
diff -up chromium-112.0.5615.20/chrome/services/file_util/safe_archive_analyzer.cc.nounrar chromium-112.0.5615.20/chrome/services/file_util/safe_archive_analyzer.cc
|
||||
--- chromium-112.0.5615.20/chrome/services/file_util/safe_archive_analyzer.cc.nounrar 2023-03-08 23:00:09.000000000 +0100
|
||||
+++ chromium-112.0.5615.20/chrome/services/file_util/safe_archive_analyzer.cc 2023-03-10 13:20:06.558188423 +0100
|
||||
@@ -45,12 +45,16 @@ void SafeArchiveAnalyzer::AnalyzeDmgFile
|
||||
void SafeArchiveAnalyzer::AnalyzeRarFile(base::File rar_file,
|
||||
base::File temporary_file,
|
||||
AnalyzeRarFileCallback callback) {
|
||||
+#if 0
|
||||
DCHECK(rar_file.IsValid());
|
||||
|
||||
safe_browsing::ArchiveAnalyzerResults results;
|
||||
safe_browsing::rar_analyzer::AnalyzeRarFile(
|
||||
std::move(rar_file), std::move(temporary_file), &results);
|
||||
std::move(callback).Run(results);
|
||||
+#else
|
||||
+ NOTREACHED();
|
||||
+#endif
|
||||
}
|
||||
|
||||
void SafeArchiveAnalyzer::AnalyzeSevenZipFile(
|
@ -0,0 +1,454 @@
|
||||
diff --git a/chrome/browser/ui/BUILD.gn b/chrome/browser/ui/BUILD.gn
|
||||
index 3470da1..ff39851b 100644
|
||||
--- a/chrome/browser/ui/BUILD.gn
|
||||
+++ b/chrome/browser/ui/BUILD.gn
|
||||
@@ -5628,8 +5628,12 @@
|
||||
sources += [
|
||||
"views/chrome_browser_main_extra_parts_views_linux.cc",
|
||||
"views/chrome_browser_main_extra_parts_views_linux.h",
|
||||
+ "views/dark_mode_manager_linux.cc",
|
||||
+ "views/dark_mode_manager_linux.h",
|
||||
]
|
||||
deps += [
|
||||
+ "//components/dbus/thread_linux",
|
||||
+ "//dbus",
|
||||
"//ui/base/cursor",
|
||||
"//ui/ozone",
|
||||
]
|
||||
diff --git a/chrome/browser/ui/DEPS b/chrome/browser/ui/DEPS
|
||||
index fc3fab23..b56a704e 100644
|
||||
--- a/chrome/browser/ui/DEPS
|
||||
+++ b/chrome/browser/ui/DEPS
|
||||
@@ -42,6 +42,9 @@
|
||||
"browser_navigator_browsertest\.cc": [
|
||||
"+ash/shell.h",
|
||||
],
|
||||
+ "dark_mode_manager_linux\.cc": [
|
||||
+ "+dbus",
|
||||
+ ],
|
||||
"fullscreen_controller_interactive_browsertest\.cc": [
|
||||
"+ash/shell.h",
|
||||
],
|
||||
diff --git a/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.cc b/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.cc
|
||||
index dbc9cc4e..d7fad5b 100644
|
||||
--- a/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.cc
|
||||
+++ b/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.cc
|
||||
@@ -7,6 +7,7 @@
|
||||
#include "base/metrics/histogram_macros.h"
|
||||
#include "chrome/browser/themes/theme_service_aura_linux.h"
|
||||
#include "chrome/browser/ui/browser_list.h"
|
||||
+#include "chrome/browser/ui/views/dark_mode_manager_linux.h"
|
||||
#include "chrome/browser/ui/views/theme_profile_key.h"
|
||||
#include "ui/base/buildflags.h"
|
||||
#include "ui/base/cursor/cursor_factory.h"
|
||||
@@ -56,6 +57,8 @@
|
||||
UMA_HISTOGRAM_ENUMERATION("Linux.SystemTheme.Default",
|
||||
linux_ui_theme->GetNativeTheme()->system_theme());
|
||||
}
|
||||
+
|
||||
+ dark_mode_manager_ = std::make_unique<ui::DarkModeManagerLinux>();
|
||||
}
|
||||
|
||||
void ChromeBrowserMainExtraPartsViewsLinux::PreCreateThreads() {
|
||||
diff --git a/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.h b/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.h
|
||||
index 392d14c..6deb520 100644
|
||||
--- a/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.h
|
||||
+++ b/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.h
|
||||
@@ -13,6 +13,7 @@
|
||||
|
||||
namespace ui {
|
||||
class LinuxUiGetter;
|
||||
+class DarkModeManagerLinux;
|
||||
}
|
||||
|
||||
// Extra parts, which are used by both Ozone/X11/Wayland and inherited by the
|
||||
@@ -41,6 +42,8 @@
|
||||
absl::optional<display::ScopedDisplayObserver> display_observer_;
|
||||
|
||||
std::unique_ptr<ui::LinuxUiGetter> linux_ui_getter_;
|
||||
+
|
||||
+ std::unique_ptr<ui::DarkModeManagerLinux> dark_mode_manager_;
|
||||
};
|
||||
|
||||
#endif // CHROME_BROWSER_UI_VIEWS_CHROME_BROWSER_MAIN_EXTRA_PARTS_VIEWS_LINUX_H_
|
||||
diff --git a/chrome/browser/ui/views/dark_mode_manager_linux.cc b/chrome/browser/ui/views/dark_mode_manager_linux.cc
|
||||
new file mode 100644
|
||||
index 0000000..bb638f7
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/ui/views/dark_mode_manager_linux.cc
|
||||
@@ -0,0 +1,160 @@
|
||||
+// Copyright 2023 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
+
|
||||
+#include "chrome/browser/ui/views/dark_mode_manager_linux.h"
|
||||
+
|
||||
+#include "base/functional/bind.h"
|
||||
+#include "base/logging.h"
|
||||
+#include "components/dbus/thread_linux/dbus_thread_linux.h"
|
||||
+#include "dbus/bus.h"
|
||||
+#include "dbus/message.h"
|
||||
+#include "dbus/object_proxy.h"
|
||||
+#include "ui/linux/linux_ui.h"
|
||||
+#include "ui/linux/linux_ui_factory.h"
|
||||
+#include "ui/native_theme/native_theme.h"
|
||||
+
|
||||
+namespace {
|
||||
+
|
||||
+constexpr char kFreedesktopSettingsService[] = "org.freedesktop.portal.Desktop";
|
||||
+constexpr char kFreedesktopSettingsObjectPath[] =
|
||||
+ "/org/freedesktop/portal/desktop";
|
||||
+constexpr char kFreedesktopSettingsInterface[] =
|
||||
+ "org.freedesktop.portal.Settings";
|
||||
+constexpr char kSettingChangedSignal[] = "SettingChanged";
|
||||
+constexpr char kReadMethod[] = "Read";
|
||||
+constexpr char kSettingsNamespace[] = "org.freedesktop.appearance";
|
||||
+constexpr char kColorSchemeKey[] = "color-scheme";
|
||||
+constexpr int kFreedesktopColorSchemeDark = 1;
|
||||
+
|
||||
+scoped_refptr<dbus::Bus> CreateBus() {
|
||||
+ dbus::Bus::Options options;
|
||||
+ options.bus_type = dbus::Bus::SESSION;
|
||||
+ options.connection_type = dbus::Bus::PRIVATE;
|
||||
+ options.dbus_task_runner = dbus_thread_linux::GetTaskRunner();
|
||||
+ return base::MakeRefCounted<dbus::Bus>(options);
|
||||
+}
|
||||
+
|
||||
+} // namespace
|
||||
+
|
||||
+namespace ui {
|
||||
+
|
||||
+DarkModeManagerLinux::DarkModeManagerLinux()
|
||||
+ : bus_(CreateBus()),
|
||||
+ settings_proxy_(bus_->GetObjectProxy(
|
||||
+ kFreedesktopSettingsService,
|
||||
+ dbus::ObjectPath(kFreedesktopSettingsObjectPath))) {
|
||||
+ // Subscribe to changes in the color scheme preference.
|
||||
+ settings_proxy_->ConnectToSignal(
|
||||
+ kFreedesktopSettingsInterface, kSettingChangedSignal,
|
||||
+ base::BindRepeating(&DarkModeManagerLinux::OnPortalSettingChanged,
|
||||
+ weak_ptr_factory_.GetWeakPtr()),
|
||||
+ base::BindOnce(&DarkModeManagerLinux::OnSignalConnected,
|
||||
+ weak_ptr_factory_.GetWeakPtr()));
|
||||
+
|
||||
+ // Read initial color scheme preference.
|
||||
+ dbus::MethodCall method_call(kFreedesktopSettingsInterface, kReadMethod);
|
||||
+ dbus::MessageWriter writer(&method_call);
|
||||
+ writer.AppendString(kSettingsNamespace);
|
||||
+ writer.AppendString(kColorSchemeKey);
|
||||
+ settings_proxy_->CallMethod(
|
||||
+ &method_call, dbus::ObjectProxy::TIMEOUT_USE_DEFAULT,
|
||||
+ base::BindOnce(&DarkModeManagerLinux::OnReadColorSchemeResponse,
|
||||
+ weak_ptr_factory_.GetWeakPtr()));
|
||||
+
|
||||
+ // Read the toolkit preference while asynchronously fetching the
|
||||
+ // portal preference.
|
||||
+ if (auto* linux_ui_theme = ui::GetDefaultLinuxUiTheme()) {
|
||||
+ auto* native_theme = linux_ui_theme->GetNativeTheme();
|
||||
+ native_theme_observer_.Observe(native_theme);
|
||||
+ SetColorScheme(native_theme->ShouldUseDarkColors());
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+DarkModeManagerLinux::~DarkModeManagerLinux() {
|
||||
+ settings_proxy_ = nullptr;
|
||||
+ dbus::Bus* const bus_ptr = bus_.get();
|
||||
+ bus_ptr->GetDBusTaskRunner()->PostTask(
|
||||
+ FROM_HERE, base::BindOnce(&dbus::Bus::ShutdownAndBlock, std::move(bus_)));
|
||||
+}
|
||||
+
|
||||
+void DarkModeManagerLinux::OnNativeThemeUpdated(
|
||||
+ ui::NativeTheme* observed_theme) {
|
||||
+ SetColorScheme(observed_theme->ShouldUseDarkColors());
|
||||
+}
|
||||
+
|
||||
+void DarkModeManagerLinux::OnSignalConnected(const std::string& interface_name,
|
||||
+ const std::string& signal_name,
|
||||
+ bool connected) {
|
||||
+ // Nothing to do. Continue using the toolkit setting if !connected.
|
||||
+}
|
||||
+
|
||||
+void DarkModeManagerLinux::OnPortalSettingChanged(dbus::Signal* signal) {
|
||||
+ dbus::MessageReader reader(signal);
|
||||
+
|
||||
+ std::string namespace_changed;
|
||||
+ std::string key_changed;
|
||||
+ dbus::MessageReader variant_reader(nullptr);
|
||||
+ if (!reader.PopString(&namespace_changed) ||
|
||||
+ !reader.PopString(&key_changed) || !reader.PopVariant(&variant_reader)) {
|
||||
+ LOG(ERROR) << "Received malformed Setting Changed signal from "
|
||||
+ "org.freedesktop.portal.Settings";
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ if (namespace_changed != kSettingsNamespace ||
|
||||
+ key_changed != kColorSchemeKey) {
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ uint32_t new_color_scheme;
|
||||
+ if (!variant_reader.PopUint32(&new_color_scheme)) {
|
||||
+ LOG(ERROR)
|
||||
+ << "Failed to read color-scheme value from SettingChanged signal";
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ SetColorScheme(new_color_scheme == kFreedesktopColorSchemeDark);
|
||||
+}
|
||||
+
|
||||
+void DarkModeManagerLinux::OnReadColorSchemeResponse(dbus::Response* response) {
|
||||
+ if (!response) {
|
||||
+ // Continue using the toolkit setting.
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ dbus::MessageReader reader(response);
|
||||
+ dbus::MessageReader variant_reader(nullptr);
|
||||
+ if (!reader.PopVariant(&variant_reader)) {
|
||||
+ LOG(ERROR) << "Failed to read variant from Read method response";
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ uint32_t new_color_scheme;
|
||||
+ if (!variant_reader.PopVariantOfUint32(&new_color_scheme)) {
|
||||
+ LOG(ERROR) << "Failed to read color-scheme value from Read "
|
||||
+ "method response";
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ // Ignore future updates from the toolkit theme.
|
||||
+ native_theme_observer_.Reset();
|
||||
+
|
||||
+ SetColorScheme(new_color_scheme == kFreedesktopColorSchemeDark);
|
||||
+}
|
||||
+
|
||||
+void DarkModeManagerLinux::SetColorScheme(bool prefer_dark_theme) {
|
||||
+ if (prefer_dark_theme_ == prefer_dark_theme) {
|
||||
+ return;
|
||||
+ }
|
||||
+ prefer_dark_theme_ = prefer_dark_theme;
|
||||
+
|
||||
+ NativeTheme* web_theme = NativeTheme::GetInstanceForWeb();
|
||||
+ web_theme->set_use_dark_colors(prefer_dark_theme_);
|
||||
+ web_theme->set_preferred_color_scheme(
|
||||
+ prefer_dark_theme_ ? NativeTheme::PreferredColorScheme::kDark
|
||||
+ : NativeTheme::PreferredColorScheme::kLight);
|
||||
+ web_theme->NotifyOnNativeThemeUpdated();
|
||||
+}
|
||||
+
|
||||
+} // namespace ui
|
||||
diff --git a/chrome/browser/ui/views/dark_mode_manager_linux.h b/chrome/browser/ui/views/dark_mode_manager_linux.h
|
||||
new file mode 100644
|
||||
index 0000000..34b07ff
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/ui/views/dark_mode_manager_linux.h
|
||||
@@ -0,0 +1,62 @@
|
||||
+// Copyright 2023 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
+
|
||||
+#ifndef CHROME_BROWSER_UI_VIEWS_DARK_MODE_MANAGER_LINUX_H_
|
||||
+#define CHROME_BROWSER_UI_VIEWS_DARK_MODE_MANAGER_LINUX_H_
|
||||
+
|
||||
+#include <string>
|
||||
+
|
||||
+#include "base/memory/scoped_refptr.h"
|
||||
+#include "base/memory/weak_ptr.h"
|
||||
+#include "base/scoped_observation.h"
|
||||
+#include "ui/native_theme/native_theme_observer.h"
|
||||
+
|
||||
+namespace dbus {
|
||||
+class Bus;
|
||||
+class ObjectProxy;
|
||||
+class Response;
|
||||
+class Signal;
|
||||
+} // namespace dbus
|
||||
+
|
||||
+namespace ui {
|
||||
+
|
||||
+// Observes the system color scheme preference using
|
||||
+// org.freedesktop.portal.Settings. Falls back to the toolkit preference if
|
||||
+// org.freedesktop.portal.Settings is unavailable. Propagates the dark mode
|
||||
+// preference to the web theme.
|
||||
+class DarkModeManagerLinux : public NativeThemeObserver {
|
||||
+ public:
|
||||
+ DarkModeManagerLinux();
|
||||
+ DarkModeManagerLinux(const DarkModeManagerLinux&) = delete;
|
||||
+ DarkModeManagerLinux& operator=(const DarkModeManagerLinux&) = delete;
|
||||
+ ~DarkModeManagerLinux() override;
|
||||
+
|
||||
+ private:
|
||||
+ // ui::NativeThemeObserver:
|
||||
+ void OnNativeThemeUpdated(ui::NativeTheme* observed_theme) override;
|
||||
+
|
||||
+ // D-Bus async handlers
|
||||
+ void OnSignalConnected(const std::string& interface_name,
|
||||
+ const std::string& signal_name,
|
||||
+ bool connected);
|
||||
+ void OnPortalSettingChanged(dbus::Signal* signal);
|
||||
+ void OnReadColorSchemeResponse(dbus::Response* response);
|
||||
+
|
||||
+ // Sets `prefer_dark_theme_` and propagates to the web theme.
|
||||
+ void SetColorScheme(bool prefer_dark_theme);
|
||||
+
|
||||
+ scoped_refptr<dbus::Bus> bus_;
|
||||
+ raw_ptr<dbus::ObjectProxy> settings_proxy_;
|
||||
+
|
||||
+ bool prefer_dark_theme_ = false;
|
||||
+
|
||||
+ base::ScopedObservation<NativeTheme, NativeThemeObserver>
|
||||
+ native_theme_observer_{this};
|
||||
+
|
||||
+ base::WeakPtrFactory<DarkModeManagerLinux> weak_ptr_factory_{this};
|
||||
+};
|
||||
+
|
||||
+} // namespace ui
|
||||
+
|
||||
+#endif // CHROME_BROWSER_UI_VIEWS_DARK_MODE_MANAGER_LINUX_H_
|
||||
diff --git a/chrome/common/chrome_features.cc b/chrome/common/chrome_features.cc
|
||||
index 91b1e98..7adddbd 100644
|
||||
--- a/chrome/common/chrome_features.cc
|
||||
+++ b/chrome/common/chrome_features.cc
|
||||
@@ -1448,17 +1448,17 @@
|
||||
BASE_FEATURE(kWebShare, "WebShare", base::FEATURE_DISABLED_BY_DEFAULT);
|
||||
#endif
|
||||
|
||||
-// Whether to enable "dark mode" enhancements in Mac Mojave or Windows 10 for
|
||||
-// UIs implemented with web technologies.
|
||||
+// Whether to enable "dark mode" enhancements in Mac Mojave, Windows 10, or
|
||||
+// Linux for UIs implemented with web technologies.
|
||||
BASE_FEATURE(kWebUIDarkMode,
|
||||
"WebUIDarkMode",
|
||||
#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || \
|
||||
- BUILDFLAG(IS_CHROMEOS)
|
||||
+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX)
|
||||
base::FEATURE_ENABLED_BY_DEFAULT
|
||||
#else
|
||||
base::FEATURE_DISABLED_BY_DEFAULT
|
||||
#endif // BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) ||
|
||||
- // BUILDFLAG(IS_CHROMEOS)
|
||||
+ // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX)
|
||||
);
|
||||
|
||||
#if BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
diff --git a/ui/qt/qt_ui.cc b/ui/qt/qt_ui.cc
|
||||
index b188ad0..6c0d2cd 100644
|
||||
--- a/ui/qt/qt_ui.cc
|
||||
+++ b/ui/qt/qt_ui.cc
|
||||
@@ -98,6 +98,13 @@
|
||||
QtNativeTheme& operator=(const QtNativeTheme&) = delete;
|
||||
~QtNativeTheme() override = default;
|
||||
|
||||
+ void ThemeChanged(bool prefer_dark_theme) {
|
||||
+ set_use_dark_colors(IsForcedDarkMode() || prefer_dark_theme);
|
||||
+ set_preferred_color_scheme(CalculatePreferredColorScheme());
|
||||
+
|
||||
+ NotifyOnNativeThemeUpdated();
|
||||
+ }
|
||||
+
|
||||
// ui::NativeTheme:
|
||||
DISABLE_CFI_VCALL
|
||||
void PaintFrameTopArea(cc::PaintCanvas* canvas,
|
||||
@@ -387,7 +394,7 @@
|
||||
}
|
||||
|
||||
void QtUi::ThemeChanged() {
|
||||
- native_theme_->NotifyOnNativeThemeUpdated();
|
||||
+ native_theme_->ThemeChanged(PreferDarkTheme());
|
||||
}
|
||||
|
||||
DISABLE_CFI_VCALL
|
||||
diff --git a/chrome/browser/ui/BUILD.gn b/chrome/browser/ui/BUILD.gn
|
||||
index decfb02b6817e..108e2af907e25 100644
|
||||
--- a/chrome/browser/ui/BUILD.gn
|
||||
+++ b/chrome/browser/ui/BUILD.gn
|
||||
@@ -5632,20 +5632,24 @@ static_library("ui") {
|
||||
]
|
||||
}
|
||||
|
||||
- if (use_aura) {
|
||||
+ if (use_aura && (is_linux || is_chromeos_lacros)) {
|
||||
# These files can do Gtk+-based theming for builds with gtk enabled.
|
||||
- if (is_linux || is_chromeos_lacros) {
|
||||
+ sources += [
|
||||
+ "views/chrome_browser_main_extra_parts_views_linux.cc",
|
||||
+ "views/chrome_browser_main_extra_parts_views_linux.h",
|
||||
+ ]
|
||||
+ deps += [
|
||||
+ "//ui/base/cursor",
|
||||
+ "//ui/ozone",
|
||||
+ ]
|
||||
+ if (use_dbus) {
|
||||
sources += [
|
||||
- "views/chrome_browser_main_extra_parts_views_linux.cc",
|
||||
- "views/chrome_browser_main_extra_parts_views_linux.h",
|
||||
"views/dark_mode_manager_linux.cc",
|
||||
"views/dark_mode_manager_linux.h",
|
||||
]
|
||||
deps += [
|
||||
"//components/dbus/thread_linux",
|
||||
"//dbus",
|
||||
- "//ui/base/cursor",
|
||||
- "//ui/ozone",
|
||||
]
|
||||
}
|
||||
}
|
||||
diff --git a/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.cc b/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.cc
|
||||
index d7fad5b5b9007..23d0611fdb2b5 100644
|
||||
--- a/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.cc
|
||||
+++ b/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.cc
|
||||
@@ -7,7 +7,6 @@
|
||||
#include "base/metrics/histogram_macros.h"
|
||||
#include "chrome/browser/themes/theme_service_aura_linux.h"
|
||||
#include "chrome/browser/ui/browser_list.h"
|
||||
-#include "chrome/browser/ui/views/dark_mode_manager_linux.h"
|
||||
#include "chrome/browser/ui/views/theme_profile_key.h"
|
||||
#include "ui/base/buildflags.h"
|
||||
#include "ui/base/cursor/cursor_factory.h"
|
||||
@@ -19,6 +18,10 @@
|
||||
#include "ui/native_theme/native_theme.h"
|
||||
#include "ui/ozone/public/ozone_platform.h"
|
||||
|
||||
+#if defined(USE_DBUS)
|
||||
+#include "chrome/browser/ui/views/dark_mode_manager_linux.h"
|
||||
+#endif
|
||||
+
|
||||
namespace {
|
||||
|
||||
class LinuxUiGetterImpl : public ui::LinuxUiGetter {
|
||||
@@ -57,8 +60,9 @@ void ChromeBrowserMainExtraPartsViewsLinux::ToolkitInitialized() {
|
||||
UMA_HISTOGRAM_ENUMERATION("Linux.SystemTheme.Default",
|
||||
linux_ui_theme->GetNativeTheme()->system_theme());
|
||||
}
|
||||
-
|
||||
+#if defined(USE_DBUS)
|
||||
dark_mode_manager_ = std::make_unique<ui::DarkModeManagerLinux>();
|
||||
+#endif
|
||||
}
|
||||
|
||||
void ChromeBrowserMainExtraPartsViewsLinux::PreCreateThreads() {
|
||||
diff --git a/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.h b/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.h
|
||||
index 6deb5205d198a..bc9167bda1fc3 100644
|
||||
--- a/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.h
|
||||
+++ b/chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.h
|
||||
@@ -13,7 +13,9 @@
|
||||
|
||||
namespace ui {
|
||||
class LinuxUiGetter;
|
||||
+#if defined(USE_DBUS)
|
||||
class DarkModeManagerLinux;
|
||||
+#endif
|
||||
}
|
||||
|
||||
// Extra parts, which are used by both Ozone/X11/Wayland and inherited by the
|
||||
@@ -42,8 +44,9 @@ class ChromeBrowserMainExtraPartsViewsLinux
|
||||
absl::optional<display::ScopedDisplayObserver> display_observer_;
|
||||
|
||||
std::unique_ptr<ui::LinuxUiGetter> linux_ui_getter_;
|
||||
-
|
||||
+#if defined(USE_DBUS)
|
||||
std::unique_ptr<ui::DarkModeManagerLinux> dark_mode_manager_;
|
||||
+#endif
|
||||
};
|
||||
|
||||
#endif // CHROME_BROWSER_UI_VIEWS_CHROME_BROWSER_MAIN_EXTRA_PARTS_VIEWS_LINUX_H_
|
@ -0,0 +1,12 @@
|
||||
diff -up chromium-113.0.5672.24/chrome/browser/media/router/media_router_feature.cc.disable-GlobalMediaControlsCastStartStop chromium-113.0.5672.24/chrome/browser/media/router/media_router_feature.cc
|
||||
--- chromium-113.0.5672.24/chrome/browser/media/router/media_router_feature.cc.disable-GlobalMediaControlsCastStartStop 2023-04-07 13:54:52.562292026 +0200
|
||||
+++ chromium-113.0.5672.24/chrome/browser/media/router/media_router_feature.cc 2023-04-07 13:57:41.470414086 +0200
|
||||
@@ -68,7 +68,7 @@ BASE_FEATURE(kGlobalMediaControlsCastSta
|
||||
#else
|
||||
BASE_FEATURE(kGlobalMediaControlsCastStartStop,
|
||||
"GlobalMediaControlsCastStartStop",
|
||||
- base::FEATURE_ENABLED_BY_DEFAULT);
|
||||
+ base::FEATURE_DISABLED_BY_DEFAULT);
|
||||
#endif // BUILDFLAG(IS_CHROMEOS)
|
||||
#endif // BUILDFLAG(IS_ANDROID)
|
||||
|
@ -0,0 +1,115 @@
|
||||
diff -up chromium-113.0.5672.24/chrome/common/safe_browsing/BUILD.gn.nounrar chromium-113.0.5672.24/chrome/common/safe_browsing/BUILD.gn
|
||||
--- chromium-113.0.5672.24/chrome/common/safe_browsing/BUILD.gn.nounrar 2023-04-07 13:11:59.495927476 +0200
|
||||
+++ chromium-113.0.5672.24/chrome/common/safe_browsing/BUILD.gn 2023-04-07 13:47:57.004758029 +0200
|
||||
@@ -143,8 +143,6 @@ source_set("safe_browsing") {
|
||||
"protobuf_message_log_macros.h",
|
||||
"protobuf_message_read_macros.h",
|
||||
"protobuf_message_write_macros.h",
|
||||
- "rar_analyzer.cc",
|
||||
- "rar_analyzer.h",
|
||||
"seven_zip_analyzer.cc",
|
||||
"seven_zip_analyzer.h",
|
||||
"zip_analyzer.cc",
|
||||
@@ -160,7 +158,6 @@ source_set("safe_browsing") {
|
||||
"//components/safe_browsing/content/common:file_type_policies",
|
||||
"//components/safe_browsing/core/common",
|
||||
"//third_party/lzma_sdk/google:seven_zip_reader",
|
||||
- "//third_party/unrar:unrar",
|
||||
]
|
||||
|
||||
if (is_linux) {
|
||||
diff -up chromium-113.0.5672.24/chrome/common/safe_browsing/DEPS.nounrar chromium-113.0.5672.24/chrome/common/safe_browsing/DEPS
|
||||
--- chromium-113.0.5672.24/chrome/common/safe_browsing/DEPS.nounrar 2023-04-04 20:41:26.000000000 +0200
|
||||
+++ chromium-113.0.5672.24/chrome/common/safe_browsing/DEPS 2023-04-07 13:11:59.495927476 +0200
|
||||
@@ -3,7 +3,6 @@ include_rules = [
|
||||
"+components/safe_browsing/core/common",
|
||||
"+third_party/maldoca",
|
||||
"+third_party/protobuf",
|
||||
- "+third_party/unrar",
|
||||
"+third_party/zlib",
|
||||
"+third_party/lzma_sdk/google",
|
||||
]
|
||||
diff -up chromium-113.0.5672.24/chrome/services/file_util/BUILD.gn.nounrar chromium-113.0.5672.24/chrome/services/file_util/BUILD.gn
|
||||
diff -up chromium-113.0.5672.24/chrome/services/file_util/safe_archive_analyzer.cc.nounrar chromium-113.0.5672.24/chrome/services/file_util/safe_archive_analyzer.cc
|
||||
--- chromium-113.0.5672.24/chrome/services/file_util/safe_archive_analyzer.cc.nounrar 2023-04-07 13:11:59.495927476 +0200
|
||||
+++ chromium-113.0.5672.24/chrome/services/file_util/safe_archive_analyzer.cc 2023-04-07 13:52:52.998109006 +0200
|
||||
@@ -61,6 +61,7 @@ void SafeArchiveAnalyzer::AnalyzeRarFile
|
||||
base::File rar_file,
|
||||
mojo::PendingRemote<chrome::mojom::TemporaryFileGetter> temp_file_getter,
|
||||
AnalyzeRarFileCallback callback) {
|
||||
+#if 0
|
||||
DCHECK(rar_file.IsValid());
|
||||
temp_file_getter_.Bind(std::move(temp_file_getter));
|
||||
callback_ = std::move(callback);
|
||||
@@ -76,6 +77,9 @@ void SafeArchiveAnalyzer::AnalyzeRarFile
|
||||
rar_analyzer_.Init(std::move(rar_file), base::FilePath(),
|
||||
std::move(analysis_finished_callback),
|
||||
std::move(temp_file_getter_callback), &results_);
|
||||
+#else
|
||||
+ NOTREACHED();
|
||||
+#endif
|
||||
}
|
||||
|
||||
void SafeArchiveAnalyzer::AnalyzeSevenZipFile(
|
||||
diff -up chromium-113.0.5672.53/chrome/common/safe_browsing/zip_analyzer.cc.me chromium-113.0.5672.53/chrome/common/safe_browsing/zip_analyzer.cc
|
||||
--- chromium-113.0.5672.53/chrome/common/safe_browsing/zip_analyzer.cc.me 2023-04-23 18:10:06.103858362 +0200
|
||||
+++ chromium-113.0.5672.53/chrome/common/safe_browsing/zip_analyzer.cc 2023-04-23 18:12:05.428092347 +0200
|
||||
@@ -18,7 +18,7 @@
|
||||
#include "base/time/time.h"
|
||||
#include "build/build_config.h"
|
||||
#include "chrome/common/safe_browsing/archive_analyzer_results.h"
|
||||
-#include "chrome/common/safe_browsing/rar_analyzer.h"
|
||||
+//#include "chrome/common/safe_browsing/rar_analyzer.h"
|
||||
#include "components/safe_browsing/content/common/file_type_policies.h"
|
||||
#include "components/safe_browsing/core/common/features.h"
|
||||
#include "components/safe_browsing/core/common/proto/csd.pb.h"
|
||||
@@ -132,14 +132,14 @@ bool ZipAnalyzer::AnalyzeNestedArchive(
|
||||
std::move(nested_analysis_finished_callback),
|
||||
get_temp_file_callback_, results_);
|
||||
return true;
|
||||
- } else if (file_type == DownloadFileType::RAR) {
|
||||
+ } /* else if (file_type == DownloadFileType::RAR) {
|
||||
nested_rar_analyzer_ = std::make_unique<safe_browsing::RarAnalyzer>();
|
||||
nested_rar_analyzer_->Init(temp_file_.Duplicate(),
|
||||
root_zip_path_.Append(path),
|
||||
std::move(nested_analysis_finished_callback),
|
||||
get_temp_file_callback_, results_);
|
||||
return true;
|
||||
- }
|
||||
+ }*/
|
||||
return false;
|
||||
}
|
||||
|
||||
diff -up chromium-113.0.5672.53/chrome/common/safe_browsing/zip_analyzer.h.me chromium-113.0.5672.53/chrome/common/safe_browsing/zip_analyzer.h
|
||||
--- chromium-113.0.5672.53/chrome/common/safe_browsing/zip_analyzer.h.me 2023-04-23 18:12:11.316203496 +0200
|
||||
+++ chromium-113.0.5672.53/chrome/common/safe_browsing/zip_analyzer.h 2023-04-23 18:12:26.827498082 +0200
|
||||
@@ -78,7 +78,7 @@ class ZipAnalyzer {
|
||||
// DFS.
|
||||
// TODO(crbug.com/1426164) Create a common class to hold all analyzers.
|
||||
std::unique_ptr<safe_browsing::ZipAnalyzer> nested_zip_analyzer_;
|
||||
- std::unique_ptr<safe_browsing::RarAnalyzer> nested_rar_analyzer_;
|
||||
+// std::unique_ptr<safe_browsing::RarAnalyzer> nested_rar_analyzer_;
|
||||
|
||||
base::WeakPtrFactory<ZipAnalyzer> weak_factory_{this};
|
||||
};
|
||||
diff -up chromium-113.0.5672.53/chrome/services/file_util/safe_archive_analyzer.h.me chromium-113.0.5672.53/chrome/services/file_util/safe_archive_analyzer.h
|
||||
--- chromium-113.0.5672.53/chrome/services/file_util/safe_archive_analyzer.h.me 2023-04-23 18:06:26.476791520 +0200
|
||||
+++ chromium-113.0.5672.53/chrome/services/file_util/safe_archive_analyzer.h 2023-04-23 18:08:58.594606171 +0200
|
||||
@@ -6,7 +6,7 @@
|
||||
#define CHROME_SERVICES_FILE_UTIL_SAFE_ARCHIVE_ANALYZER_H_
|
||||
|
||||
#include "chrome/common/safe_browsing/archive_analyzer_results.h"
|
||||
-#include "chrome/common/safe_browsing/rar_analyzer.h"
|
||||
+//#include "chrome/common/safe_browsing/rar_analyzer.h"
|
||||
#include "chrome/services/file_util/public/mojom/safe_archive_analyzer.mojom.h"
|
||||
#include "mojo/public/cpp/bindings/remote.h"
|
||||
|
||||
@@ -59,7 +59,7 @@ class SafeArchiveAnalyzer : public chrom
|
||||
void Timeout();
|
||||
|
||||
safe_browsing::ZipAnalyzer zip_analyzer_;
|
||||
- safe_browsing::RarAnalyzer rar_analyzer_;
|
||||
+// safe_browsing::RarAnalyzer rar_analyzer_;
|
||||
|
||||
// A timer to ensure no archive takes too long to unpack.
|
||||
base::OneShotTimer timeout_timer_;
|
@ -1,6 +1,6 @@
|
||||
diff -up chromium-99.0.4844.51/components/os_crypt/features.gni.disblegnomekeyring chromium-99.0.4844.51/components/os_crypt/features.gni
|
||||
--- chromium-99.0.4844.51/components/os_crypt/features.gni.disblegnomekeyring 2022-03-05 14:24:15.073877597 -0500
|
||||
+++ chromium-99.0.4844.51/components/os_crypt/features.gni 2022-03-05 14:25:04.174183483 -0500
|
||||
diff -up chromium-113.0.5672.24/components/os_crypt/sync/features.gni.disblegnomekeyring chromium-113.0.5672.24/components/os_crypt/sync/features.gni
|
||||
--- chromium-113.0.5672.24/components/os_crypt/sync/features.gni.disblegnomekeyring 2023-04-07 14:23:11.083985460 +0200
|
||||
+++ chromium-113.0.5672.24/components/os_crypt/sync/features.gni 2023-04-07 14:23:44.276599353 +0200
|
||||
@@ -8,7 +8,7 @@ import("//build/config/ui.gni")
|
||||
declare_args() {
|
||||
# Whether to use libgnome-keyring (deprecated by libsecret).
|
@ -0,0 +1,38 @@
|
||||
diff -up chromium-113.0.5672.63/chrome/browser/download/bubble/download_bubble_update_service.cc.me chromium-113.0.5672.63/chrome/browser/download/bubble/download_bubble_update_service.cc
|
||||
--- chromium-113.0.5672.63/chrome/browser/download/bubble/download_bubble_update_service.cc.me 2023-05-03 17:46:37.194000834 +0200
|
||||
+++ chromium-113.0.5672.63/chrome/browser/download/bubble/download_bubble_update_service.cc 2023-05-03 17:48:05.170317575 +0200
|
||||
@@ -87,7 +87,7 @@ ItemSortKey GetSortKey(const Item& item)
|
||||
// Helper to get an iterator to the last element in the cache. The cache
|
||||
// must not be empty.
|
||||
template <typename Item>
|
||||
-SortedItems<Item>::iterator GetLastIter(SortedItems<Item>& cache) {
|
||||
+typename SortedItems<Item>::iterator GetLastIter(SortedItems<Item>& cache) {
|
||||
CHECK(!cache.empty());
|
||||
auto it = cache.end();
|
||||
return std::prev(it);
|
||||
@@ -789,9 +789,9 @@ bool DownloadBubbleUpdateService::Remove
|
||||
}
|
||||
|
||||
template <typename Id, typename Item>
|
||||
-SortedItems<Item>::iterator
|
||||
+typename SortedItems<Item>::iterator
|
||||
DownloadBubbleUpdateService::RemoveItemFromCacheByIter(
|
||||
- SortedItems<Item>::iterator iter,
|
||||
+ typename SortedItems<Item>::iterator iter,
|
||||
SortedItems<Item>& cache,
|
||||
IterMap<Id, Item>& iter_map) {
|
||||
CHECK(iter != cache.end());
|
||||
diff -up chromium-113.0.5672.63/chrome/browser/download/bubble/download_bubble_update_service.h.me chromium-113.0.5672.63/chrome/browser/download/bubble/download_bubble_update_service.h
|
||||
--- chromium-113.0.5672.63/chrome/browser/download/bubble/download_bubble_update_service.h.me 2023-05-03 17:48:14.079551820 +0200
|
||||
+++ chromium-113.0.5672.63/chrome/browser/download/bubble/download_bubble_update_service.h 2023-05-03 17:49:24.702387180 +0200
|
||||
@@ -208,8 +208,8 @@ class DownloadBubbleUpdateService
|
||||
|
||||
// Removes item if we already have the iterator to it. Returns next iterator.
|
||||
template <typename Id, typename Item>
|
||||
- SortedItems<Item>::iterator RemoveItemFromCacheByIter(
|
||||
- SortedItems<Item>::iterator iter,
|
||||
+ typename SortedItems<Item>::iterator RemoveItemFromCacheByIter(
|
||||
+ typename SortedItems<Item>::iterator iter,
|
||||
SortedItems<Item>& cache,
|
||||
IterMap<Id, Item>& iter_map);
|
||||
|
@ -0,0 +1,30 @@
|
||||
diff -up chromium-113.0.5672.63/third_party/blink/renderer/core/layout/ng/grid/ng_grid_layout_algorithm.cc.me chromium-113.0.5672.63/third_party/blink/renderer/core/layout/ng/grid/ng_grid_layout_algorithm.cc
|
||||
--- chromium-113.0.5672.63/third_party/blink/renderer/core/layout/ng/grid/ng_grid_layout_algorithm.cc.me 2023-05-03 16:30:34.244612573 +0200
|
||||
+++ chromium-113.0.5672.63/third_party/blink/renderer/core/layout/ng/grid/ng_grid_layout_algorithm.cc 2023-05-03 16:37:36.732278590 +0200
|
||||
@@ -516,8 +516,11 @@ wtf_size_t NGGridLayoutAlgorithm::BuildG
|
||||
row_auto_repetitions);
|
||||
|
||||
bool has_nested_subgrid = false;
|
||||
- auto& [grid_items, layout_data, subtree_size] =
|
||||
- sizing_tree->CreateSizingData();
|
||||
+
|
||||
+ auto& workaround_clang_bug = sizing_tree->CreateSizingData();
|
||||
+ auto& grid_items = workaround_clang_bug.grid_items;
|
||||
+ auto& layout_data = workaround_clang_bug.layout_data;
|
||||
+ auto& subtree_size = workaround_clang_bug.subtree_size;
|
||||
|
||||
if (!must_ignore_children) {
|
||||
// Construct grid items that are not subgridded.
|
||||
@@ -1540,8 +1543,10 @@ void NGGridLayoutAlgorithm::InitializeTr
|
||||
NGGridSizingTree* sizing_tree) const {
|
||||
DCHECK(sizing_tree && current_grid_index < sizing_tree->Size());
|
||||
|
||||
- auto& [grid_items, layout_data, subtree_size] =
|
||||
- sizing_tree->At(current_grid_index);
|
||||
+ auto& workaround_clang_bug = sizing_tree->At(current_grid_index);
|
||||
+ auto& grid_items = workaround_clang_bug.grid_items;
|
||||
+ auto& layout_data = workaround_clang_bug.layout_data;
|
||||
+ auto& subtree_size = workaround_clang_bug.subtree_size
|
||||
|
||||
auto InitAndCacheTrackSizes = [&](GridTrackSizingDirection track_direction) {
|
||||
InitializeTrackCollection(opt_subgrid_data, track_direction, &layout_data);
|
@ -1,10 +0,0 @@
|
||||
diff -upr chromium-71.0.3578.80.orig/third_party/widevine/cdm/widevine_cdm_version.h chromium-71.0.3578.80/third_party/widevine/cdm/widevine_cdm_version.h
|
||||
--- chromium-71.0.3578.80.orig/third_party/widevine/cdm/widevine_cdm_version.h 2018-12-21 20:18:01.000000000 +0000
|
||||
+++ chromium-71.0.3578.80/third_party/widevine/cdm/widevine_cdm_version.h 2018-12-21 21:37:45.635374949 +0000
|
||||
@@ -12,4 +12,6 @@
|
||||
// - WIDEVINE_CDM_VERSION_STRING (with the version of the CDM that's available
|
||||
// as a string, e.g., "1.0.123.456").
|
||||
|
||||
+#define WIDEVINE_CDM_VERSION_STRING "unknown"
|
||||
+
|
||||
#endif // WIDEVINE_CDM_VERSION_H_
|
@ -1,36 +0,0 @@
|
||||
diff -up chromium-86.0.4240.75/media/gpu/vaapi/vaapi_video_decode_accelerator.cc.vaapi-intel-fix chromium-86.0.4240.75/media/gpu/vaapi/vaapi_video_decode_accelerator.cc
|
||||
--- chromium-86.0.4240.75/media/gpu/vaapi/vaapi_video_decode_accelerator.cc.vaapi-intel-fix 2020-10-07 12:38:47.000000000 -0400
|
||||
+++ chromium-86.0.4240.75/media/gpu/vaapi/vaapi_video_decode_accelerator.cc 2020-10-14 16:20:46.938556042 -0400
|
||||
@@ -58,6 +58,7 @@ unsigned int GetVaFormatForVideoCodecPro
|
||||
return VA_RT_FORMAT_YUV420;
|
||||
}
|
||||
|
||||
+#if defined(OS_ANDROID) || defined(OS_CHROMEOS)
|
||||
// Returns true if the CPU is an Intel Gemini Lake or later (including Kaby
|
||||
// Lake) Cpu platform id's are referenced from the following file in kernel
|
||||
// source arch/x86/include/asm/intel-family.h
|
||||
@@ -70,6 +71,7 @@ bool IsGeminiLakeOrLater() {
|
||||
cpuid.model() >= kGeminiLakeModelId;
|
||||
return is_geminilake_or_later;
|
||||
}
|
||||
+#endif
|
||||
|
||||
} // namespace
|
||||
|
||||
@@ -1214,6 +1216,8 @@ VaapiVideoDecodeAccelerator::DecideBuffe
|
||||
if (output_mode_ == VideoDecodeAccelerator::Config::OutputMode::IMPORT)
|
||||
return BufferAllocationMode::kNormal;
|
||||
|
||||
+#if defined(OS_ANDROID) || defined(OS_CHROMEOS)
|
||||
+ // Move this to chromeOs only as it is causing problem in some intel linux drivers
|
||||
// On Gemini Lake, Kaby Lake and later we can pass to libva the client's
|
||||
// PictureBuffers to decode onto, which skips the use of the Vpp unit and its
|
||||
// associated format reconciliation copy, avoiding all internal buffer
|
||||
@@ -1229,6 +1233,7 @@ VaapiVideoDecodeAccelerator::DecideBuffe
|
||||
num_extra_pics_ = 3;
|
||||
return BufferAllocationMode::kNone;
|
||||
}
|
||||
+#endif
|
||||
|
||||
// For H.264 on older devices, another +1 is experimentally needed for
|
||||
// high-to-high resolution changes.
|
@ -1,24 +0,0 @@
|
||||
diff -up chromium-92.0.4515.107/third_party/catapult/common/py_vulcanize/py_vulcanize/generate.py.py2 chromium-92.0.4515.107/third_party/catapult/common/py_vulcanize/py_vulcanize/generate.py
|
||||
--- chromium-92.0.4515.107/third_party/catapult/common/py_vulcanize/py_vulcanize/generate.py.py2 2021-07-19 14:47:19.000000000 -0400
|
||||
+++ chromium-92.0.4515.107/third_party/catapult/common/py_vulcanize/py_vulcanize/generate.py 2021-07-26 17:02:23.160750472 -0400
|
||||
@@ -83,7 +83,7 @@ def _MinifyJS(input_js):
|
||||
|
||||
with tempfile.NamedTemporaryFile() as _:
|
||||
args = [
|
||||
- 'python',
|
||||
+ 'python2',
|
||||
rjsmin_path
|
||||
]
|
||||
p = subprocess.Popen(args,
|
||||
diff -up chromium-92.0.4515.107/tools/gn/bootstrap/bootstrap.py.py2 chromium-92.0.4515.107/tools/gn/bootstrap/bootstrap.py
|
||||
--- chromium-92.0.4515.107/tools/gn/bootstrap/bootstrap.py.py2 2021-07-19 14:45:43.000000000 -0400
|
||||
+++ chromium-92.0.4515.107/tools/gn/bootstrap/bootstrap.py 2021-07-26 17:02:23.160750472 -0400
|
||||
@@ -130,7 +130,7 @@ def main(argv):
|
||||
if not options.debug:
|
||||
gn_gen_args += ' is_debug=false'
|
||||
subprocess.check_call([
|
||||
- gn_path, 'gen', out_dir,
|
||||
+ gn_path, 'gen', out_dir, ' --script-executable=/usr/bin/python2',
|
||||
'--args=%s' % gn_gen_args, "--root=" + SRC_ROOT
|
||||
])
|
||||
|
@ -1,14 +0,0 @@
|
||||
diff -up chromium-99.0.4844.51/chrome/browser/component_updater/registration.cc.widevine-no-download chromium-99.0.4844.51/chrome/browser/component_updater/registration.cc
|
||||
--- chromium-99.0.4844.51/chrome/browser/component_updater/registration.cc.widevine-no-download 2022-03-04 14:57:16.459599123 +0000
|
||||
+++ chromium-99.0.4844.51/chrome/browser/component_updater/registration.cc 2022-03-04 14:58:39.560763939 +0000
|
||||
@@ -105,10 +105,6 @@ void RegisterComponentsForUpdate() {
|
||||
RegisterMediaFoundationWidevineCdmComponent(cus);
|
||||
#endif
|
||||
|
||||
-#if BUILDFLAG(ENABLE_WIDEVINE_CDM_COMPONENT)
|
||||
- RegisterWidevineCdmComponent(cus);
|
||||
-#endif // BUILDFLAG(ENABLE_WIDEVINE_CDM_COMPONENT)
|
||||
-
|
||||
#if BUILDFLAG(ENABLE_NACL) && !BUILDFLAG(IS_ANDROID)
|
||||
#if BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
// PNaCl on Chrome OS is on rootfs and there is no need to download it. But
|
@ -1,8 +1,4 @@
|
||||
# system wide chromium flags
|
||||
CHROMIUM_FLAGS=""
|
||||
CHROMIUM_FLAGS+=" --disable-features=AudioServiceSandbox,UseChromeOSDirectVideoDecoder,AllowQt"
|
||||
CHROMIUM_FLAGS+=" --enable-features=VaapiVideoDecoder,VaapiVideoEncoder"
|
||||
|
||||
if [ "$XDG_SESSION_TYPE" == "wayland" ] || [[ $WAYLAND_DISPLAY ]] ; then
|
||||
CHROMIUM_FLAGS+=" --use-gl=egl"
|
||||
fi
|
||||
CHROMIUM_FLAGS+=" --disable-features=AudioServiceSandbox,Vulkan,AllowQt"
|
||||
CHROMIUM_FLAGS+=" --enable-features=VaapiVideoDecoder,VaapiVideoEncoder,VaapiVideoDecodeLinuxGL"
|
||||
|
@ -1,3 +1,3 @@
|
||||
SHA512 (node-v19.8.1-linux-arm64.tar.xz) = 86ff19085669e92ce7afe2fd7d4df0c5441df2d88c00f29d5463b805f3cf5625626db8aebf98349c9a495b772da1ce6d68263730018207ea98815058a1c81397
|
||||
SHA512 (node-v19.8.1-linux-x64.tar.xz) = 925c0037c6b7074d0b0245bced20d0a0d9b1300f53b808106f16b5018d763f5f5b00bc321b33fa1033d736b1e1076608da9b7fcae66aed53d27b100b1186e2c6
|
||||
SHA512 (chromium-112.0.5615.165-clean.tar.xz) = 68f8f4f0e8add04e608c1d285351b38de0199ac5635b29dcce653b30435e68431f92ea7b381d6fe6cb4ffd5b1910e66ed6f82aab62a8fab952cb969a40f7456a
|
||||
SHA512 (chromium-113.0.5672.63-clean.tar.xz) = f172496e8569864db26872a4762564f094c3ca726f340d69c9dfaca6c260b0a4bbb37ad711f6ab6b9efd9ee58510b1a2a130f829183ae6a3bd711e7d1478954b
|
||||
|
Loading…
Reference in new issue