Use Mozilla Android Components 9.0.0-SNAPSHOT. (#4750)
parent
806961094b
commit
210868f5bc
|
@ -21,7 +21,9 @@ import mozilla.components.browser.storage.sync.PlacesHistoryStorage
|
|||
import mozilla.components.concept.engine.DefaultSettings
|
||||
import mozilla.components.concept.engine.Engine
|
||||
import mozilla.components.concept.engine.EngineSession.TrackingProtectionPolicy
|
||||
import mozilla.components.concept.engine.EngineSession.TrackingProtectionPolicy.Companion.SAFE_BROWSING_ALL
|
||||
import mozilla.components.concept.engine.EngineSession.TrackingProtectionPolicy.SafeBrowsingCategory
|
||||
import mozilla.components.concept.engine.EngineSession.TrackingProtectionPolicy.Companion.select
|
||||
import mozilla.components.concept.engine.EngineSession.TrackingProtectionPolicy.TrackingCategory
|
||||
import mozilla.components.concept.engine.mediaquery.PreferredColorScheme
|
||||
import mozilla.components.concept.fetch.Client
|
||||
import mozilla.components.feature.media.MediaFeature
|
||||
|
@ -177,7 +179,10 @@ class Core(private val context: Context) {
|
|||
normalMode && privateMode -> trackingProtectionPolicy
|
||||
normalMode && !privateMode -> trackingProtectionPolicy.forRegularSessionsOnly()
|
||||
!normalMode && privateMode -> trackingProtectionPolicy.forPrivateSessionsOnly()
|
||||
else -> TrackingProtectionPolicy.select(SAFE_BROWSING_ALL)
|
||||
else -> select(
|
||||
trackingCategories = arrayOf(TrackingCategory.NONE),
|
||||
safeBrowsingCategories = arrayOf(SafeBrowsingCategory.RECOMMENDED)
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -40,21 +40,6 @@ internal fun SitePermissions.Status.toString(context: Context): String {
|
|||
}
|
||||
}
|
||||
|
||||
fun SitePermissionsRules.Action.toStatus(): SitePermissions.Status {
|
||||
return when (this) {
|
||||
SitePermissionsRules.Action.BLOCKED -> SitePermissions.Status.BLOCKED
|
||||
SitePermissionsRules.Action.ASK_TO_ALLOW -> SitePermissions.Status.NO_DECISION
|
||||
}
|
||||
}
|
||||
|
||||
fun SitePermissions.Status.toggle(): SitePermissions.Status {
|
||||
return when (this) {
|
||||
SitePermissions.Status.BLOCKED -> SitePermissions.Status.ALLOWED
|
||||
SitePermissions.Status.NO_DECISION -> SitePermissions.Status.ALLOWED
|
||||
SitePermissions.Status.ALLOWED -> SitePermissions.Status.BLOCKED
|
||||
}
|
||||
}
|
||||
|
||||
fun SitePermissions.toggle(featurePhone: PhoneFeature): SitePermissions {
|
||||
return when (featurePhone) {
|
||||
PhoneFeature.CAMERA -> {
|
||||
|
|
|
@ -18,7 +18,6 @@ import org.mozilla.fenix.mvi.UIComponentViewModelBase
|
|||
import org.mozilla.fenix.mvi.UIComponentViewModelProvider
|
||||
import org.mozilla.fenix.mvi.UIView
|
||||
import org.mozilla.fenix.settings.PhoneFeature
|
||||
import org.mozilla.fenix.settings.toStatus
|
||||
import org.mozilla.fenix.settings.toggle
|
||||
import org.mozilla.fenix.utils.Settings
|
||||
|
||||
|
|
|
@ -34,14 +34,14 @@ object Versions {
|
|||
const val androidx_work = "2.0.1"
|
||||
const val google_material = "1.1.0-alpha07"
|
||||
|
||||
const val mozilla_android_components = "8.0.0"
|
||||
const val mozilla_android_components = "9.0.0-SNAPSHOT"
|
||||
// Note that android-components also depends on application-services,
|
||||
// and in fact is our main source of appservices-related functionality.
|
||||
// The version number below tracks the application-services version
|
||||
// that we depend on directly for the fenix-megazord (and for it's
|
||||
// forUnitTest variant), and it's important that it be kept in
|
||||
// sync with the version used by android-components above.
|
||||
const val mozilla_appservices = "0.36.0"
|
||||
const val mozilla_appservices = "0.37.1"
|
||||
|
||||
const val autodispose = "1.1.0"
|
||||
const val adjust = "4.11.4"
|
||||
|
|
Loading…
Reference in New Issue