Latest PRs and disable third-party origin trials
This commit is contained in:
parent
5d25d76e4d
commit
eb335f26b1
7 changed files with 59 additions and 13 deletions
|
@ -161,4 +161,6 @@ Site-setting-for-images.patch
|
|||
Bromite-auto-updater.patch
|
||||
Experimental-user-scripts-support.patch
|
||||
Enable-native-Android-autofill.patch
|
||||
Keep-empty-tabs-between-sessions.patch
|
||||
Automated-domain-substitution.patch
|
||||
Disable-third-party-origin-trials.patch
|
||||
|
|
|
@ -143,7 +143,7 @@ diff --git a/chrome/android/java/src/org/chromium/chrome/browser/privacy/setting
|
|||
@Override
|
||||
public boolean onPreferenceChange(Preference preference, Object newValue) {
|
||||
String key = preference.getKey();
|
||||
@@ -222,6 +228,14 @@ public class PrivacySettings
|
||||
@@ -221,6 +227,14 @@ public class PrivacySettings
|
||||
} else if (PREF_INCOGNITO_TAB_HISTORY_ENABLED.equals(key)) {
|
||||
UserPrefs.get(Profile.getLastUsedRegularProfile())
|
||||
.setBoolean(Pref.INCOGNITO_TAB_HISTORY_ENABLED, (boolean) newValue);
|
||||
|
@ -158,7 +158,7 @@ diff --git a/chrome/android/java/src/org/chromium/chrome/browser/privacy/setting
|
|||
}
|
||||
|
||||
return true;
|
||||
@@ -256,6 +282,16 @@ public class PrivacySettings
|
||||
@@ -256,6 +270,16 @@ public class PrivacySettings
|
||||
canMakePaymentPref.setChecked(prefService.getBoolean(Pref.CAN_MAKE_PAYMENT_ENABLED));
|
||||
}
|
||||
|
||||
|
|
|
@ -32,7 +32,7 @@ See also: https://github.com/bromite/bromite/pull/1427
|
|||
chrome/browser/history/history_tab_helper.cc | 16 +
|
||||
chrome/browser/history/history_tab_helper.h | 10 +-
|
||||
.../history/history_tab_helper_unittest.cc | 22 ++
|
||||
.../android/offline_page_bridge.cc | 9 +
|
||||
.../android/offline_page_bridge.cc | 13 +-
|
||||
.../android/offline_page_model_factory.cc | 21 +-
|
||||
.../android/request_coordinator_factory.cc | 17 +
|
||||
.../offline_page_model_factory.h | 2 +
|
||||
|
@ -46,7 +46,7 @@ See also: https://github.com/bromite/bromite/pull/1427
|
|||
chrome/common/pref_names.cc | 5 +
|
||||
chrome/common/pref_names.h | 4 +
|
||||
chrome/test/BUILD.gn | 5 +
|
||||
36 files changed, 1044 insertions(+), 36 deletions(-)
|
||||
36 files changed, 1046 insertions(+), 38 deletions(-)
|
||||
create mode 100644 chrome/android/javatests/src/org/chromium/chrome/browser/history/Bromite_HistoryManagerTest.java
|
||||
create mode 100644 chrome/android/javatests/src/org/chromium/chrome/browser/privacy/settings/Bromite_PrivacySettingsFragmentTest_HistoryInAlwaysIncognito.java
|
||||
create mode 100644 chrome/android/junit/src/org/chromium/chrome/browser/app/appmenu/Bromite_AppMenuPropertiesDelegateUnitTest.java
|
||||
|
@ -1377,29 +1377,48 @@ diff --git a/chrome/browser/history/history_tab_helper_unittest.cc b/chrome/brow
|
|||
diff --git a/chrome/browser/offline_pages/android/offline_page_bridge.cc b/chrome/browser/offline_pages/android/offline_page_bridge.cc
|
||||
--- a/chrome/browser/offline_pages/android/offline_page_bridge.cc
|
||||
+++ b/chrome/browser/offline_pages/android/offline_page_bridge.cc
|
||||
@@ -49,6 +49,10 @@
|
||||
@@ -49,6 +49,9 @@
|
||||
#include "content/public/browser/web_contents.h"
|
||||
#include "net/base/filename_util.h"
|
||||
#include "url/android/gurl_android.h"
|
||||
+#include "chrome/browser/android/profile_key_util.h"
|
||||
+#include "components/prefs/pref_registry_simple.h"
|
||||
+#include "components/prefs/pref_service.h"
|
||||
+#include "chrome/common/pref_names.h"
|
||||
|
||||
using base::android::ConvertJavaStringToUTF8;
|
||||
using base::android::ConvertUTF16ToJavaString;
|
||||
@@ -159,6 +163,11 @@ void ValidateFileCallback(
|
||||
@@ -158,7 +161,13 @@ void ValidateFileCallback(
|
||||
int64_t offline_id,
|
||||
const GURL& url,
|
||||
const base::FilePath& file_path,
|
||||
+ SimpleFactoryKey* key,
|
||||
bool is_trusted) {
|
||||
+ // in always incognito, never trust input file (show file name in url)
|
||||
+ ProfileKey* profile_key = ::android::GetLastUsedRegularProfileKey();
|
||||
+ ProfileKey* profile_key = ProfileKey::FromSimpleFactoryKey(key);
|
||||
+ if(profile_key->GetPrefs()->GetBoolean(prefs::kIncognitoTabHistoryEnabled))
|
||||
+ is_trusted = false;
|
||||
+
|
||||
// If trusted, the launch url will be the http/https url of the offline
|
||||
// page. If the file path is content URI, directly open it. Otherwise, the
|
||||
// launch url will be the file URL pointing to the archive file of the offline
|
||||
@@ -785,7 +794,7 @@ void OfflinePageBridge::GetPageByOfflineIdDone(
|
||||
if (offline_page_model_->IsArchiveInInternalDir(offline_page->file_path)) {
|
||||
ValidateFileCallback(launch_location, j_callback_obj,
|
||||
offline_page->offline_id, offline_page->url,
|
||||
- offline_page->file_path, true /* is_trusted*/);
|
||||
+ offline_page->file_path, key_, true /* is_trusted*/);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -795,7 +804,7 @@ void OfflinePageBridge::GetPageByOfflineIdDone(
|
||||
offline_page->file_size, offline_page->digest),
|
||||
base::BindOnce(&ValidateFileCallback, launch_location, j_callback_obj,
|
||||
offline_page->offline_id, offline_page->url,
|
||||
- offline_page->file_path));
|
||||
+ offline_page->file_path, key_));
|
||||
}
|
||||
|
||||
void OfflinePageBridge::GetSizeAndComputeDigestDone(
|
||||
diff --git a/chrome/browser/offline_pages/android/offline_page_model_factory.cc b/chrome/browser/offline_pages/android/offline_page_model_factory.cc
|
||||
--- a/chrome/browser/offline_pages/android/offline_page_model_factory.cc
|
||||
+++ b/chrome/browser/offline_pages/android/offline_page_model_factory.cc
|
||||
|
|
|
@ -5571,7 +5571,7 @@ diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descripti
|
|||
|
||||
const char kDisableProcessReuse[] = "Disable subframe process reuse";
|
||||
const char kDisableProcessReuseDescription[] =
|
||||
@@ -2221,7 +2221,7 @@ const char kReduceUserAgentName[] = "Reduce User-Agent request header";
|
||||
@@ -2215,7 +2215,7 @@ const char kReduceUserAgentName[] = "Reduce User-Agent request header";
|
||||
const char kReduceUserAgentDescription[] =
|
||||
"Reduce (formerly, \"freeze\") the amount of information available in "
|
||||
"the User-Agent request header. "
|
||||
|
@ -5580,7 +5580,7 @@ diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descripti
|
|||
|
||||
const char kRestrictGamepadAccessName[] = "Restrict gamepad access";
|
||||
const char kRestrictGamepadAccessDescription[] =
|
||||
@@ -2238,7 +2238,7 @@ const char kIntensiveWakeUpThrottlingName[] =
|
||||
@@ -2232,7 +2232,7 @@ const char kIntensiveWakeUpThrottlingName[] =
|
||||
const char kIntensiveWakeUpThrottlingDescription[] =
|
||||
"When enabled, wake ups from DOM Timers are limited to 1 per minute in a "
|
||||
"page that has been hidden for 5 minutes. For additional details, see "
|
||||
|
|
25
build/patches/Disable-third-party-origin-trials.patch
Normal file
25
build/patches/Disable-third-party-origin-trials.patch
Normal file
|
@ -0,0 +1,25 @@
|
|||
From: csagan5 <32685696+csagan5@users.noreply.github.com>
|
||||
Date: Thu, 4 Nov 2021 09:19:24 +0100
|
||||
Subject: Disable third-party origin trials
|
||||
|
||||
---
|
||||
.../blink/renderer/platform/runtime_enabled_features.json5 | 4 ----
|
||||
1 file changed, 4 deletions(-)
|
||||
|
||||
diff --git a/third_party/blink/renderer/platform/runtime_enabled_features.json5 b/third_party/blink/renderer/platform/runtime_enabled_features.json5
|
||||
--- a/third_party/blink/renderer/platform/runtime_enabled_features.json5
|
||||
+++ b/third_party/blink/renderer/platform/runtime_enabled_features.json5
|
||||
@@ -2183,10 +2183,6 @@
|
||||
name: "TextFragmentTapOpensContextMenu",
|
||||
status: {"Android": "stable"},
|
||||
},
|
||||
- {
|
||||
- name: "ThirdPartyOriginTrials",
|
||||
- status: "stable",
|
||||
- },
|
||||
{
|
||||
name: "ThrottleDisplayNoneAndVisibilityHiddenCrossOriginIframes",
|
||||
status: "experimental",
|
||||
--
|
||||
2.17.1
|
||||
|
|
@ -372,7 +372,7 @@ diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/ch
|
|||
diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descriptions.cc
|
||||
--- a/chrome/browser/flag_descriptions.cc
|
||||
+++ b/chrome/browser/flag_descriptions.cc
|
||||
@@ -5364,6 +5364,11 @@ const char kUserDataSnapshotDescription[] =
|
||||
@@ -5358,6 +5358,11 @@ const char kUserDataSnapshotDescription[] =
|
||||
"update and restoring them after a version rollback.";
|
||||
#endif // !defined(OS_ANDROID) && !BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
|
||||
|
@ -387,7 +387,7 @@ diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descripti
|
|||
diff --git a/chrome/browser/flag_descriptions.h b/chrome/browser/flag_descriptions.h
|
||||
--- a/chrome/browser/flag_descriptions.h
|
||||
+++ b/chrome/browser/flag_descriptions.h
|
||||
@@ -3128,6 +3128,9 @@ extern const char kUserDataSnapshotName[];
|
||||
@@ -3125,6 +3125,9 @@ extern const char kUserDataSnapshotName[];
|
||||
extern const char kUserDataSnapshotDescription[];
|
||||
#endif // !defined(OS_ANDROID) && !BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@ Subject: Keep empty tabs between sessions
|
|||
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/tabmodel/TabPersistentStore.java b/chrome/android/java/src/org/chromium/chrome/browser/tabmodel/TabPersistentStore.java
|
||||
--- a/chrome/android/java/src/org/chromium/chrome/browser/tabmodel/TabPersistentStore.java
|
||||
+++ b/chrome/android/java/src/org/chromium/chrome/browser/tabmodel/TabPersistentStore.java
|
||||
@@ -734,15 +734,6 @@ public class TabPersistentStore {
|
||||
@@ -701,15 +701,6 @@ public class TabPersistentStore {
|
||||
.createFrozenTab(tabState, serializedCriticalPersistedTabData, tabToRestore.id,
|
||||
isIncognito, restoredIndex);
|
||||
} else {
|
||||
|
|
Loading…
Add table
Reference in a new issue