Struct webkit2gtk::builders::WebContextBuilder
source · [−]pub struct WebContextBuilder { /* private fields */ }
Expand description
A builder-pattern type to construct WebContext
objects.
Implementations
sourceimpl WebContextBuilder
impl WebContextBuilder
sourcepub fn new() -> Self
pub fn new() -> Self
Create a new WebContextBuilder
.
sourcepub fn build(self) -> WebContext
pub fn build(self) -> WebContext
Build the WebContext
.
sourcepub fn local_storage_directory(self, local_storage_directory: &str) -> Self
👎Deprecated: Since 2.10Available on crate feature v2_8
only.
pub fn local_storage_directory(self, local_storage_directory: &str) -> Self
v2_8
only.The directory where local storage data will be saved.
Use property::WebsiteDataManager::local-storage-directory
instead.
Available on crate feature v2_28
only.
v2_28
only.Whether swap Web processes on cross-site navigations is enabled.
When enabled, pages from each security origin will be handled by their own separate Web processes, which are started (and terminated) on demand as the user navigates across different domains. This is an important security measure which helps prevent websites stealing data from other visited pages.
sourcepub fn time_zone_override(self, time_zone_override: &str) -> Self
Available on crate feature v2_38
only.
pub fn time_zone_override(self, time_zone_override: &str) -> Self
v2_38
only.The timezone override for this web context. Setting this property provides a better alternative to configure the timezone information for all webviews managed by the WebContext. The other, less optimal, approach is to globally set the TZ environment variable in the process before creating the context. However this approach might not be very convenient and can have side-effects in your application.
The expected values for this property are defined in the IANA timezone database. See this wikipedia page for instance, https://en.wikipedia.org/wiki/List_of_tz_database_time_zones.
sourcepub fn website_data_manager(
self,
website_data_manager: &impl IsA<WebsiteDataManager>
) -> Self
Available on crate feature v2_10
only.
pub fn website_data_manager(
self,
website_data_manager: &impl IsA<WebsiteDataManager>
) -> Self
v2_10
only.The WebsiteDataManager
associated with this context.
Trait Implementations
sourceimpl Clone for WebContextBuilder
impl Clone for WebContextBuilder
sourcefn clone(&self) -> WebContextBuilder
fn clone(&self) -> WebContextBuilder
1.0.0 · sourceconst fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
source
. Read more