74 lines
3.2 KiB
Diff
74 lines
3.2 KiB
Diff
From 0b2e674959b1e59d890f0bb83a08351a5019239a Mon Sep 17 00:00:00 2001
|
|
From: Ho Cheung
|
|
Date: Wed, 11 Oct 2023 10:25:20 +0800
|
|
Subject: [PATCH] Remove-discovery-module-from-NTP
|
|
|
|
---
|
|
.../res/layout/new_tab_page_feed_v2_expandable_header.xml | 5 +++--
|
|
.../java/res/layout/new_tab_page_multi_feed_header.xml | 5 +++--
|
|
components/feed/core/shared_prefs/pref_names.cc | 4 ++--
|
|
3 files changed, 8 insertions(+), 6 deletions(-)
|
|
|
|
diff --git a/chrome/browser/feed/android/java/res/layout/new_tab_page_feed_v2_expandable_header.xml b/chrome/browser/feed/android/java/res/layout/new_tab_page_feed_v2_expandable_header.xml
|
|
index ee1283cb9a6a0..c89b236330bf9 100644
|
|
--- a/chrome/browser/feed/android/java/res/layout/new_tab_page_feed_v2_expandable_header.xml
|
|
+++ b/chrome/browser/feed/android/java/res/layout/new_tab_page_feed_v2_expandable_header.xml
|
|
@@ -1,6 +1,6 @@
|
|
<?xml version="1.0" encoding="utf-8"?>
|
|
<!--
|
|
-Copyright 2020 The Chromium Authors
|
|
+Copyright 2023 The Chromium Authors, Alex313031 and gz83
|
|
Use of this source code is governed by a BSD-style license that can be
|
|
found in the LICENSE file.
|
|
-->
|
|
@@ -14,7 +14,8 @@ found in the LICENSE file.
|
|
android:minHeight="@dimen/snippets_article_header_height"
|
|
android:orientation="vertical"
|
|
android:gravity="center_vertical"
|
|
- android:layoutDirection="locale" >
|
|
+ android:layoutDirection="locale"
|
|
+ android:visibility="gone" >
|
|
|
|
<RelativeLayout
|
|
tools:ignore="RelativeOverlap"
|
|
diff --git a/chrome/browser/feed/android/java/res/layout/new_tab_page_multi_feed_header.xml b/chrome/browser/feed/android/java/res/layout/new_tab_page_multi_feed_header.xml
|
|
index 483e954de0a49..15ca071b1d30f 100644
|
|
--- a/chrome/browser/feed/android/java/res/layout/new_tab_page_multi_feed_header.xml
|
|
+++ b/chrome/browser/feed/android/java/res/layout/new_tab_page_multi_feed_header.xml
|
|
@@ -1,6 +1,6 @@
|
|
<?xml version="1.0" encoding="utf-8"?>
|
|
<!--
|
|
-Copyright 2021 The Chromium Authors
|
|
+Copyright 2023 The Chromium Authors, Alex313031 and gz83
|
|
Use of this source code is governed by a BSD-style license that can be
|
|
found in the LICENSE file.
|
|
-->
|
|
@@ -11,7 +11,8 @@ found in the LICENSE file.
|
|
xmlns:tools="http://schemas.android.com/tools"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
- android:orientation="vertical" >
|
|
+ android:orientation="vertical"
|
|
+ android:visibility="gone" >
|
|
|
|
<LinearLayout
|
|
android:id="@+id/main_content"
|
|
diff --git a/components/feed/core/shared_prefs/pref_names.cc b/components/feed/core/shared_prefs/pref_names.cc
|
|
index 71586a65fcd92..e3397204d2b8b 100644
|
|
--- a/components/feed/core/shared_prefs/pref_names.cc
|
|
+++ b/components/feed/core/shared_prefs/pref_names.cc
|
|
@@ -1,4 +1,4 @@
|
|
-// Copyright 2020 The Chromium Authors
|
|
+// Copyright 2023 The Chromium Authors, Alex313031 and gz83
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
// found in the LICENSE file.
|
|
|
|
@@ -20,7 +20,7 @@ const char kArticlesListVisible[] = "ntp_snippets.list_visible";
|
|
|
|
void RegisterFeedSharedProfilePrefs(PrefRegistrySimple* registry) {
|
|
registry->RegisterBooleanPref(kEnableSnippets, true);
|
|
- registry->RegisterBooleanPref(kArticlesListVisible, true);
|
|
+ registry->RegisterBooleanPref(kArticlesListVisible, false);
|
|
}
|
|
|
|
} // namespace prefs
|