IResourceRequestIsWindowOpen Property Awesomium.NET 1.7.6Awesomium.NET
Gets if this is the first request sent by a new view that is the result of JavaScript window.open.

Namespace: Awesomium.Core
Assembly: Awesomium.Core (in Awesomium.Core.dll) Version: 1.7.6.0
Syntax

bool IsWindowOpen { get; }

Property Value

Type: Boolean
Remarks

The initial request (OnRequest(ResourceRequest)) of new views that are the result of JavaScript window.open, is always issued before the ShowCreatedWebView event is fired.

By default, Requests that are the result of JavaScript window.open or are POST requests (such as the submission of HTML forms with method POST and target _blank), are not canceled. The user is expected to wrap the new view (see: NewViewInstance) when ShowCreatedWebView occurs, without reloading the target URL since navigation to the target URL is already queued on the new view.

In order to avoid double requests issued to a target URL, any other requests (most possibly links with target _blank or the submission of HTML forms with target _blank and method GET where data is passed through the URL therefore there's no danger of loosing data), are canceled by default before ShowCreatedWebView, and the user must then load the target URL manually.

POST or window.open requests cannot be canceled in advance, as we do not know if the user chooses to wrap the new view (which is the expected behavior). This however can cause implications in certain scenarios (such as in a popup blocker scenario), where users may want to cancel such requests too.

IsWindowOpen allows you to implement an IResourceInterceptor and cancel such requests yourself prior to ShowCreatedWebView, if you do not intend to wrap the new view at ShowCreatedWebView.

See Also

Reference