android-components / mozilla.components.concept.engine / DefaultSettings

DefaultSettings

data class DefaultSettings : Settings (source)

Settings implementation used to set defaults for Engine and EngineSession.

Constructors

Name Summary
<init> DefaultSettings(javascriptEnabled: Boolean = true, domStorageEnabled: Boolean = true, webFontsEnabled: Boolean = true, automaticFontSizeAdjustment: Boolean = true, automaticLanguageAdjustment: Boolean = true, mediaPlaybackRequiresUserGesture: Boolean = true, trackingProtectionPolicy: TrackingProtectionPolicy? = null, requestInterceptor: RequestInterceptor? = null, historyTrackingDelegate: HistoryTrackingDelegate? = null, userAgentString: String? = null, javaScriptCanOpenWindowsAutomatically: Boolean = false, displayZoomControls: Boolean = true, loadWithOverviewMode: Boolean = false, useWideViewPort: Boolean? = null, allowFileAccess: Boolean = true, allowFileAccessFromFileURLs: Boolean = false, allowUniversalAccessFromFileURLs: Boolean = false, allowContentAccess: Boolean = true, verticalScrollBarEnabled: Boolean = true, horizontalScrollBarEnabled: Boolean = true, remoteDebuggingEnabled: Boolean = false, supportMultipleWindows: Boolean = false, preferredColorScheme: PreferredColorScheme = PreferredColorScheme.System, testingModeEnabled: Boolean = false, suspendMediaWhenInactive: Boolean = false, fontInflationEnabled: Boolean? = null, fontSizeFactor: Float? = null, forceUserScalableContent: Boolean = false, loginAutofillEnabled: Boolean = false)
Settings implementation used to set defaults for Engine and EngineSession.

Properties

Name Summary
allowContentAccess var allowContentAccess: Boolean
Setting to control whether or not the engine is allowed to load content from a content provider installed in the system.
allowFileAccess var allowFileAccess: Boolean
Setting to control whether or not file access is allowed.
allowFileAccessFromFileURLs var allowFileAccessFromFileURLs: Boolean
Setting to control whether or not JavaScript running in the context of a file scheme URL should be allowed to access content from other file scheme URLs.
allowUniversalAccessFromFileURLs var allowUniversalAccessFromFileURLs: Boolean
Setting to control whether or not JavaScript running in the context of a file scheme URL should be allowed to access content from any origin.
automaticFontSizeAdjustment var automaticFontSizeAdjustment: Boolean
Setting to control whether the fonts adjust size with the system accessibility settings.
automaticLanguageAdjustment var automaticLanguageAdjustment: Boolean
Setting to control whether the Accept-Language headers are altered with system locale settings.
displayZoomControls var displayZoomControls: Boolean
Setting to control whether or not zoom controls should be displayed.
domStorageEnabled var domStorageEnabled: Boolean
Setting to control whether or not DOM Storage is enabled.
fontInflationEnabled var fontInflationEnabled: Boolean?
Setting to control whether font inflation is enabled.
fontSizeFactor var fontSizeFactor: Float?
Setting to control the font size factor. All font sizes will be multiplied by this factor.
forceUserScalableContent var forceUserScalableContent: Boolean
Setting to force the ability to scale the content
historyTrackingDelegate var historyTrackingDelegate: HistoryTrackingDelegate?
Setting to provide a history delegate to the engine.
horizontalScrollBarEnabled var horizontalScrollBarEnabled: Boolean
Setting to control whether or not horizontal scrolling is enabled.
javaScriptCanOpenWindowsAutomatically var javaScriptCanOpenWindowsAutomatically: Boolean
Setting to control whether or not window.open can be called from JavaScript.
javascriptEnabled var javascriptEnabled: Boolean
Setting to control whether or not JavaScript is enabled.
loadWithOverviewMode var loadWithOverviewMode: Boolean
Setting to control whether or not the engine zooms out the content to fit on screen by width.
loginAutofillEnabled var loginAutofillEnabled: Boolean
Setting to control login autofill.
mediaPlaybackRequiresUserGesture var mediaPlaybackRequiresUserGesture: Boolean
Setting to control whether or not a user gesture is required to play media.
preferredColorScheme var preferredColorScheme: PreferredColorScheme
Setting to alert the content that the user prefers a particular theme. This affects the @mediaprefers-color-scheme query.
remoteDebuggingEnabled var remoteDebuggingEnabled: Boolean
Setting to control whether or not remote debugging is enabled.
requestInterceptor var requestInterceptor: RequestInterceptor?
Setting to intercept and override requests.
supportMultipleWindows var supportMultipleWindows: Boolean
Setting to control whether or not multiple windows are supported.
suspendMediaWhenInactive var suspendMediaWhenInactive: Boolean
Setting to control whether media should be suspended when the session is inactive.
testingModeEnabled var testingModeEnabled: Boolean
Setting to control whether or not testing mode is enabled.
trackingProtectionPolicy var trackingProtectionPolicy: TrackingProtectionPolicy?
Setting to control tracking protection.
useWideViewPort var useWideViewPort: Boolean?
Setting to control whether to support the viewport HTML meta tag or if a wide viewport should be used. If not null, this value overrides useWideViePort webSettings in EngineSession.toggleDesktopMode.
userAgentString var userAgentString: String?
Setting to control the user agent string.
verticalScrollBarEnabled var verticalScrollBarEnabled: Boolean
Setting to control whether or not vertical scrolling is enabled.
webFontsEnabled var webFontsEnabled: Boolean
Setting to control whether or not Web fonts are enabled.

Inherited Properties

Name Summary
safeBrowsingPolicy open var safeBrowsingPolicy: Array<SafeBrowsingPolicy>
Setting to control tracking protection.

Extension Functions

Name Summary
loadResourceAsString fun Any.loadResourceAsString(path: String): String
Loads a file from the resources folder and returns its content as a string object.