WebKit2.WebView.prototype.new_with_related_view

function new_with_related_view(): Gtk.Widget {
    // Gjs wrapper for webkit_web_view_new_with_related_view()
}
  

Creates a new WebKit2.WebView sharing the same web process with web_view. This method doesn't have any effect when WebKit2.ProcessModel.shared_secondary_process process model is used, because a single web process is shared for all the web views in the same WebKit2.WebContext. When using WebKit2.ProcessModel.multiple_secondary_processes process model, this method should always be used when creating the WebKit2.WebView in the WebKit2.WebView::create signal. You can also use this method to implement other process models based on WebKit2.ProcessModel.multiple_secondary_processes, like for example, sharing the same web process for all the views in the same security domain.

The newly created WebKit2.WebView will also have the same WebKit2.UserContentManager and WebKit2.Settings as web_view.

Since 2.4

Returns

The newly created WebKit2.WebView widget