CreationParams class

Configuration to use when creating a new WebViewPlatformController.

The autoMediaPlaybackPolicy parameter must not be null.

Constructors

CreationParams({String? initialUrl, String? htmlData, WebSettings? webSettings, Set<String> javascriptChannelNames = const <String>{}, String? userAgent, AutoMediaPlaybackPolicy autoMediaPlaybackPolicy = AutoMediaPlaybackPolicy.require_user_action_for_all_media_types, bool isOnlyChromeUserAgent = false})
Constructs an instance to use when creating a new WebViewPlatformController.

Properties

autoMediaPlaybackPolicy → AutoMediaPlaybackPolicy
Which restrictions apply on automatic media playback.
final
hashCode → int
The hash code for this object.
no setterinherited
htmlData → String?
html data
final
initialUrl → String?
The initialUrl to load in the webview.
final
isOnlyChromeUserAgent → bool
是否仅允许chrome浏览器访问user agent true: userAgent仅包含Mozilla/5.0 AppleWebKit/535.19 Chrome/56.0.0 Mobile Safari/535.19 false: 根据设备浏览器适配
final
javascriptChannelNames → Set<String>
The initial set of JavaScript channels that are configured for this webview.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
userAgent → String?
The value used for the HTTP User-Agent: request header.
final
webSettings → WebSettings?
The initial WebSettings for the new webview.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
inherited