зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1462470 - Part 1 - Notify frontend of loaded tracking content in annotation-only mode. r=Ehsan
In order to notify the user that there is tracking content on the page which could have been blocked by Tracking Protection, we need to mark the document as having tracking content even when TP is off. Part 2 will update the desktop frontend to handle this correctly and show a different message when TP is on vs. off. Fennec should not be affected by this change since it already prevents loaded state from showing if TP is disabled: https://searchfox.org/mozilla-central/rev/dc6d85680539cb7e5fe2843d38a30a0581bfefe1/mobile/android/chrome/content/browser.js#5669 https://searchfox.org/mozilla-central/rev/dc6d85680539cb7e5fe2843d38a30a0581bfefe1/mobile/android/modules/geckoview/GeckoViewProgress.jsm#112 MozReview-Commit-ID: LNF0zABNsx1 --HG-- extra : rebase_source : c06a7ed9a32b9674a9c5a35834d39cf90f60b592
This commit is contained in:
Родитель
447885b8f7
Коммит
2339934fea
|
@ -1024,6 +1024,12 @@ TrackingURICallback::OnTrackerFound(nsresult aErrorCode)
|
|||
} else {
|
||||
MOZ_ASSERT(mChannelClassifier->ShouldEnableTrackingAnnotation());
|
||||
|
||||
// Even with TP disabled, we still want to show the user that there
|
||||
// are unblocked trackers on the site, so notify the UI that we loaded
|
||||
// tracking content. UI code can treat this notification differently
|
||||
// depending on whether TP is enabled or disabled.
|
||||
mChannelClassifier->NotifyTrackingProtectionDisabled(channel);
|
||||
|
||||
SetIsTrackingResourceHelper(channel);
|
||||
if (CachedPrefs::GetInstance()->IsLowerNetworkPriority()) {
|
||||
LowerPriorityHelper(channel);
|
||||
|
|
Загрузка…
Ссылка в новой задаче