GitLab is used only for code review, issue tracking and project management. Canonical locations for source code are still https://gitweb.torproject.org/ https://git.torproject.org/ and git-rw.torproject.org.

Unverified Commit 6f338e43 authored by Matthew Finkel's avatar Matthew Finkel
Browse files

Merge branch 'bug_40006_02' into android-components-57.0.6-10.0-2

parents b8ebf04f 25f1f7c1
......@@ -615,6 +615,14 @@ class GeckoEngine(
override var forceUserScalableContent: Boolean
get() = runtime.settings.forceUserScalableEnabled
set(value) { runtime.settings.forceUserScalableEnabled = value }
override var torSecurityLevel: Int
get() = runtime.settings.torSecurityLevel
set(value) {
value.let {
runtime.settings.torSecurityLevel = it
}
}
}.apply {
defaultSettings?.let {
this.javascriptEnabled = it.javascriptEnabled
......@@ -631,6 +639,7 @@ class GeckoEngine(
this.fontSizeFactor = it.fontSizeFactor
this.forceUserScalableContent = it.forceUserScalableContent
this.loginAutofillEnabled = it.loginAutofillEnabled
this.torSecurityLevel = it.torSecurityLevel
}
}
......
......@@ -615,6 +615,14 @@ class GeckoEngine(
override var forceUserScalableContent: Boolean
get() = runtime.settings.forceUserScalableEnabled
set(value) { runtime.settings.forceUserScalableEnabled = value }
override var torSecurityLevel: Int
get() = runtime.settings.torSecurityLevel
set(value) {
value.let {
runtime.settings.torSecurityLevel = it
}
}
}.apply {
defaultSettings?.let {
this.javascriptEnabled = it.javascriptEnabled
......@@ -631,6 +639,7 @@ class GeckoEngine(
this.fontSizeFactor = it.fontSizeFactor
this.forceUserScalableContent = it.forceUserScalableContent
this.loginAutofillEnabled = it.loginAutofillEnabled
this.torSecurityLevel = it.torSecurityLevel
}
}
......
......@@ -174,6 +174,11 @@ abstract class Settings {
* Setting to force the ability to scale the content
*/
open var forceUserScalableContent: Boolean by UnsupportedSetting()
/**
* Setting to control the current security level
*/
open var torSecurityLevel: Int by UnsupportedSetting()
}
/**
......@@ -208,7 +213,8 @@ data class DefaultSettings(
override var fontInflationEnabled: Boolean? = null,
override var fontSizeFactor: Float? = null,
override var forceUserScalableContent: Boolean = false,
override var loginAutofillEnabled: Boolean = false
override var loginAutofillEnabled: Boolean = false,
override var torSecurityLevel: Int = 0
) : Settings()
class UnsupportedSetting<T> {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment