Files
cromite/build/patches/Disable-PrivacyGuide.patch
T
2024-02-21 11:13:53 +01:00

51 lines
2.3 KiB
Diff

From: csagan5 <32685696+csagan5@users.noreply.github.com>
Date: Sun, 31 Jul 2022 22:13:11 +0200
Subject: Disable PrivacyGuide
License: GPL-3.0-only - https://spdx.org/licenses/GPL-3.0-only.html
---
chrome/android/java/res/xml/privacy_preferences.xml | 1 +
chrome/browser/ui/webui/settings/settings_ui.cc | 2 +-
.../common/chrome_features_cc/Disable-PrivacyGuide.inc | 9 +++++++++
3 files changed, 11 insertions(+), 1 deletion(-)
create mode 100644 cromite_flags/chrome/common/chrome_features_cc/Disable-PrivacyGuide.inc
diff --git a/chrome/android/java/res/xml/privacy_preferences.xml b/chrome/android/java/res/xml/privacy_preferences.xml
--- a/chrome/android/java/res/xml/privacy_preferences.xml
+++ b/chrome/android/java/res/xml/privacy_preferences.xml
@@ -21,6 +21,7 @@ found in the LICENSE file.
android:fragment="org.chromium.chrome.browser.browsing_data.ClearBrowsingDataTabsFragment" />
<Preference
android:key="privacy_guide"
+ app:isPreferenceVisible="false"
android:title="@string/privacy_guide_pref_title"
android:summary="@string/privacy_guide_pref_summary"
android:fragment="org.chromium.chrome.browser.privacy_guide.PrivacyGuideFragment" />
diff --git a/chrome/browser/ui/webui/settings/settings_ui.cc b/chrome/browser/ui/webui/settings/settings_ui.cc
--- a/chrome/browser/ui/webui/settings/settings_ui.cc
+++ b/chrome/browser/ui/webui/settings/settings_ui.cc
@@ -357,7 +357,7 @@ SettingsUI::SettingsUI(content::WebUI* web_ui)
#endif // !BUILDFLAG(IS_CHROMEOS_LACROS)
bool show_privacy_guide =
- !chrome::ShouldDisplayManagedUi(profile) && !profile->IsChild();
+ false;
html_source->AddBoolean("showPrivacyGuide", show_privacy_guide);
html_source->AddBoolean("enablePrivacyGuide3", base::FeatureList::IsEnabled(
diff --git a/cromite_flags/chrome/common/chrome_features_cc/Disable-PrivacyGuide.inc b/cromite_flags/chrome/common/chrome_features_cc/Disable-PrivacyGuide.inc
new file mode 100644
--- /dev/null
+++ b/cromite_flags/chrome/common/chrome_features_cc/Disable-PrivacyGuide.inc
@@ -0,0 +1,9 @@
+SET_CROMITE_FEATURE_DISABLED(kPrivacyGuide3);
+SET_CROMITE_FEATURE_DISABLED(kPrivacyGuidePreload);
+
+#if BUILDFLAG(IS_ANDROID)
+
+SET_CROMITE_FEATURE_DISABLED(kPrivacyGuideAndroid3);
+SET_CROMITE_FEATURE_DISABLED(kPrivacyGuidePreloadAndroid);
+
+#endif
--