Skip to content
This repository was archived by the owner on Jul 9, 2025. It is now read-only.

Commit db4a017

Browse files
committed
Bug 1669731 - P2. Rename REPLACED_UNSAFE_CONTENT to REPLACED_TRACKING_CONTENT r=geckoview-reviewers,agi
unsafe content is for phishing sites, we should use tracking content instead. Differential Revision: https://phabricator.services.mozilla.com/D93270
1 parent d56e33d commit db4a017

3 files changed

Lines changed: 13 additions & 4 deletions

File tree

mobile/android/geckoview/api.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -458,7 +458,8 @@ package org.mozilla.geckoview {
458458
field public static final int LOADED_LEVEL_1_TRACKING_CONTENT = 8192;
459459
field public static final int LOADED_LEVEL_2_TRACKING_CONTENT = 1048576;
460460
field public static final int LOADED_SOCIALTRACKING_CONTENT = 131072;
461-
field public static final int REPLACED_UNSAFE_CONTENT = 16;
461+
field public static final int REPLACED_TRACKING_CONTENT = 16;
462+
field @Deprecated public static final int REPLACED_UNSAFE_CONTENT = 16;
462463
}
463464

464465
@Deprecated @AnyThread public class ContentBlockingController.ExceptionList {

mobile/android/geckoview/src/main/java/org/mozilla/geckoview/ContentBlockingController.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -413,9 +413,17 @@ public static class Event {
413413
/**
414414
* Indicates that content that would have been blocked has instead been
415415
* replaced with a shim.
416+
* @deprecated use {@link #REPLACED_TRACKING_CONTENT} instead.
416417
*/
418+
@Deprecated
417419
public static final int REPLACED_UNSAFE_CONTENT = 0x00000010;
418420

421+
/**
422+
* Indicates that content that would have been blocked has instead been
423+
* replaced with a shim.
424+
*/
425+
public static final int REPLACED_TRACKING_CONTENT = 0x00000010;
426+
419427
protected Event() {}
420428
}
421429

mobile/android/geckoview/src/main/java/org/mozilla/geckoview/doc-files/CHANGELOG.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,15 +59,15 @@ exclude: true
5959
([bug 1650108]({{bugzilla}}1650108))
6060
- ⚠️ Use AndroidX instead of the Android support library. For the public API this only changes
6161
the thread and nullable annotation types.
62-
- Added [`REPLACED_UNSAFE_CONTENT`][82.6] to content blocking API to indicate when unsafe content is shimmed.
62+
- Added [`REPLACED_TRACKING_CONTENT`][82.6] to content blocking API to indicate when unsafe content is shimmed.
6363
([bug 1663756]({{bugzilla}}1663756))
6464

6565
[82.1]: {{javadoc_uri}}/GeckoSession.ContentDelegate.html#onExternalResponse-org.mozilla.geckoview.GeckoSession-org.mozilla.geckoview.GeckoSession.WebResponseInfo-
6666
[82.2]: {{javadoc_uri}}/GeckoSession.ContentDelegate.html#onExternalResponse-org.mozilla.geckoview.GeckoSession-org.mozilla.geckoview.GeckoResult-
6767
[82.3]: {{javadoc_uri}}/Image.html
6868
[82.4]: {{javadoc_uri}}/GeckoSession.PromptDelegate.RepostConfirmPrompt.html
6969
[82.5]: {{javadoc_uri}}/GeckoSession.html#restoreState-org.mozilla.geckoview.GeckoSession.SessionState-
70-
[82.6]: {{javadoc_uri}}/ContentBlockingController.Event.html#REPLACED_UNSAFE_CONTENT
70+
[82.6]: {{javadoc_uri}}/ContentBlockingController.Event.html#REPLACED_TRACKING_CONTENT
7171

7272
## v81
7373
- Added `cookiePurging` to [`ContentBlocking.Settings.Builder`][81.1] and `getCookiePurging` and `setCookiePurging`
@@ -826,4 +826,4 @@ to allow adding gecko profiler markers.
826826
[65.24]: {{javadoc_uri}}/CrashReporter.html#sendCrashReport-android.content.Context-android.os.Bundle-java.lang.String-
827827
[65.25]: {{javadoc_uri}}/GeckoResult.html
828828

829-
[api-version]: b55b29412d4d11b9a62dfd71f60568d1286b1e7b
829+
[api-version]: a2b63f41870a698bfe884cc415427dfb8c6fb471

0 commit comments

Comments
 (0)