diff --git a/README.md b/README.md index 10dab34..9db73a9 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ WebView4Delphi is an open source project created by Salvador Díaz Fau to embed WebView4Delphi only supports Windows. If you need to embed a web browser in Linux, Windows or MacOS consider using [CEF4Delphi](https://github.com/salvadordf/CEF4Delphi) instead. -WebView4Delphi uses the [Microsoft Edge WebView2 Runtime](https://docs.microsoft.com/en-us/microsoft-edge/webview2/) and [Microsoft.Web.WebView2 NuGet package version 1.0.2651.64](https://www.nuget.org/packages/Microsoft.Web.WebView2) to embed a web browser. +WebView4Delphi uses the [Microsoft Edge WebView2 Runtime](https://docs.microsoft.com/en-us/microsoft-edge/webview2/) and [Microsoft.Web.WebView2 NuGet package version 1.0.2739.15](https://www.nuget.org/packages/Microsoft.Web.WebView2) to embed a web browser. WebView4Delphi was developed and tested on Delphi 12.1, Delphi XE2, Delphi 7 and Lazarus 3.4/FPC 3.2.2. Delphi 6 support needs to be tested and it requires installing the second Delphi 6 patch. diff --git a/bin32/WebView2Loader.dll b/bin32/WebView2Loader.dll index 0c8d511..e6957b1 100644 Binary files a/bin32/WebView2Loader.dll and b/bin32/WebView2Loader.dll differ diff --git a/bin64/WebView2Loader.dll b/bin64/WebView2Loader.dll index 5eff65f..0a65a48 100644 Binary files a/bin64/WebView2Loader.dll and b/bin64/WebView2Loader.dll differ diff --git a/docs/WebView4Delphi.chm b/docs/WebView4Delphi.chm index e40fc81..1f8b7e1 100644 Binary files a/docs/WebView4Delphi.chm and b/docs/WebView4Delphi.chm differ diff --git a/docs/html/AllClasses.html b/docs/html/AllClasses.html index 3054048..ed6ca3c 100644 --- a/docs/html/AllClasses.html +++ b/docs/html/AllClasses.html @@ -733,6 +733,26 @@
Receives `NonClientRegionChanged` events.
This is the ICoreWebView2Notification that represents a [HTML Notification object](https://developer.mozilla.org/docs/Web/API/Notification).
Receives `CloseRequested` events.
Event args for the `NotificationReceived` event. \snippet ScenarioNotificationReceived.cpp NotificationReceived
Receives `NotificationReceived` events.
Represents a collection of generic objects. Used to get, remove and add objects at the specified index.
A collection of RECT.
The event args for `SaveAsUIShowing` event.
Receives `SaveAsUIShowing` events.
Event args for the ScriptDialogOpening event.
The shared buffer object that is created by [CreateSharedBuffer](https://learn.microsoft.com/en-us/microsoft-edge/webview2/reference/win32/icorewebview2environment12#createsharedbuffer). The object is presented to script as ArrayBuffer when posted to script with [PostSharedBufferToScript](/microsoft-edge/webview2/reference/win32/icorewebview2_17#postsharedbuffertoscript).
Receives the result of the `ShowSaveAsUI` method.
Event args for the SourceChanged event.
Receives SourceChanged events.
Receives `StateChanged` events.
Receives StatusBarTextChanged events.
A collection of strings.
Receives the result of the `TrySuspend` method.
Event args for the WebMessageReceived event.
Extension of WebMessageReceivedEventArgs to provide access to additional WebMessage objects.
Receives WebMessageReceived events.
An HTTP request used with the WebResourceRequested event.
Event args for the WebResourceRequested event.
Event args for the `WebResourceRequested` event.
Receives `WebResourceRequested` events.
An HTTP response used with the WebResourceRequested event.
Event args for the WebResourceResponseReceived event.
Receives WebResourceResponseReceived events.
View of the HTTP representation for a web resource response. The properties of this object are not mutable. This response view is used with the WebResourceResponseReceived event.
Receives the result of the `GetContent` method.
Receives WindowCloseRequested events.
@@ -1106,297 +1141,307 @@
Receives `ZoomFactorChanged` events.
This interface is an extension of ICoreWebView2_9 that supports BasicAuthenticationRequested event.
This interface is an extension of ICoreWebView2_10 that supports sessionId for CDP method calls and ContextMenuRequested event.
This interface is an extension of ICoreWebView2_11 that supports StatusBarTextChanged event.
This interface is an extension of ICoreWebView2_12 that supports Profile API.
This interface is an extension of ICoreWebView2_13 that adds ServerCertificate support.
This interface is an extension of ICoreWebView2_14 that supports status Favicons.
A continuation of the ICoreWebView2 interface to support printing.
This interface is an extension of ICoreWebView2_16 that supports shared buffer based on file mapping.
This interface is an extension of ICoreWebView2_17 that manages navigation requests to URI schemes registered with the OS.
This interface is an extension of ICoreWebView2_18 that manages memory usage target level.
A continuation of the ICoreWebView2 interface.
This interface is an extension of `ICoreWebView2_19` that provides the `FrameId` property.
This is the interface for getting string and exception with ExecuteScriptWithResult.
This interface is an extension of `ICoreWebView2` that allows to set filters in order to receive WebResourceRequested events for service workers, shared workers and different origin iframes.
This is the ICoreWebView_23 interface for PostWebMessageAsJsonWithAdditionalObjects.
This is the ICoreWebView2_24 interface that manages WebView2 Web Notification functionality.
This is the ICoreWebView2_25 interface.
A continuation of the ICoreWebView2_2 interface.
A continuation of the ICoreWebView2_3 interface to support FrameCreated and DownloadStarting events.
A continuation of the ICoreWebView2_4 interface to support ClientCertificateRequested event.
This interface is an extension of `ICoreWebView2_5` that manages opening the browser task manager window.
This interface is an extension of ICoreWebView2_5 that manages opening the browser task manager window.
This interface is an extension of ICoreWebView2_7 that supports media features.
This interface is an extension of ICoreWebView2_8 that default download dialog positioning and anchoring.
Event args for the AcceleratorKeyPressed event.
Receives AcceleratorKeyPressed events.
Receives the result of the AddScriptToExecuteOnDocumentCreated method.
Event args for the BasicAuthenticationRequested event. Will contain the request that led to the HTTP authorization challenge, the challenge and allows the host to provide authentication response or cancel the request.
The caller implements this interface to handle the BasicAuthenticationRequested event.
Represents a Basic HTTP authentication response that contains a user name and a password as according to RFC7617 (https://tools.ietf.org/html/rfc7617)
Provides a set of properties for managing an Extension, which includes an ID, name, and whether it is enabled or not, and the ability to Remove the Extension, and enable or disable it.
The caller implements this interface to receive the result of setting the browser Extension as enabled or disabled. If enabled, the browser Extension is running in WebView instances. If disabled, the browser Extension is not running in WebView instances.
A collection of ICoreWebView2BrowserExtension.
The caller implements this interface to receive the result of removing the browser Extension from the Profile.
Event args for the BrowserProcessExited event.
Receives BrowserProcessExited events.
Implements the interface to receive BytesReceivedChanged event. Use the ICoreWebView2DownloadOperation.BytesReceived property to get the received bytes count.
Receives CallDevToolsProtocolMethod completion results.
Receives the result of the CapturePreview method. The result is written to the stream provided in the CapturePreview method.
Provides access to the certificate metadata.
The caller implements this interface to receive the ClearBrowsingData result.
Receives the result of the ClearServerCertificateErrorActions method.
Provides access to the client certificate metadata.
A collection of ICoreWebView2ClientCertificate.
Event args for the ClientCertificateRequested event.
An event handler for the ClientCertificateRequested event.
This interface is an extension of the ICoreWebView2Controller interface to support visual hosting. An object implementing the ICoreWebView2CompositionController interface will also implement ICoreWebView2Controller. Callers are expected to use ICoreWebView2Controller for resizing, visibility, focus, and so on, and then use ICoreWebView2CompositionController to connect to a composition tree and provide input meant for the WebView.
Receives ContainsFullScreenElementChanged events.
Receives ContentLoading events.
Receives `ContentLoading` events.
Represents a context menu item of a context menu displayed by WebView.
Represents a collection of ContextMenuItem objects. Used to get, remove and add ContextMenuItem objects at the specified index.
Event args for the ContextMenuRequested event. Will contain the selection information and a collection of all of the default context menu items that the WebView would show. Allows the app to draw its own context menu or add/remove from the default context menu.
Receives ContextMenuRequested events.
Represents the information regarding the context menu target. Includes the context selected and the appropriate data used for the actions of a context menu.
The owner of the `CoreWebView2` object that provides support for resizing, showing and hiding, focusing, and other functionality related to windowing and composition. The `CoreWebView2Controller` owns the `CoreWebView2`, and if all references to the `CoreWebView2Controller` go away, the WebView is closed.
@@ -1407,42 +1452,42 @@
Provides a set of properties that are used to manage an ICoreWebView2Cookie.
A collection of ICoreWebView2Cookie.
Creates, adds or updates, gets, or or view the cookies. The changes would apply to the context of the user profile. That is, other WebViews under the same user profile could be affected.
The caller implements this interface to receive the CoreWebView2Controller created via CreateCoreWebView2CompositionController.
Receives the CoreWebView2Controller created using CreateCoreWebView2Controller.
The caller implements this interface to receive CursorChanged events. Use the Cursor property to get the new cursor.
Raised to notify the host that the end user selected a custom ContextMenuItem. CustomItemSelected event is raised on the specific ContextMenuItem that the end user selected.
@@ -1453,305 +1498,320 @@
This interface is used to complete deferrals on event args that support getting deferrals using the GetDeferral method.
Event args for the DevToolsProtocolEventReceived event.
Receives DevToolsProtocolEventReceived events from the WebView.
Receives DocumentTitleChanged events. Use the DocumentTitle property to get the modified title.
Event args for the DOMContentLoaded event.
Receives DOMContentLoaded events.
Represents a download operation. Gives access to the download's metadata and supports a user canceling, pausing, or resuming the download.
Event args for the DownloadStarting event.
Add an event handler for the DownloadStarting event.
Represents the WebView2 Environment. WebViews created from an environment run on the browser process specified with environment parameters and objects created from an environment should be used in the same environment. Using it in different environments are not guaranteed to be compatible and may fail.
Receives the WebView2Environment created using CreateCoreWebView2Environment.
Options used to create WebView2 Environment. A default implementation is provided in WebView2EnvironmentOptions.h.
Implements the interface to receive EstimatedEndTimeChanged event. Use the ICoreWebView2DownloadOperation.EstimatedEndTime property to get the new estimated end time.
Receives the result of the ExecuteScript method.
This is the result for ExecuteScriptWithResult.
This is the callback for ExecuteScriptWithResult
This interface is a handler for when the Favicon is changed. The sender is the ICoreWebView2 object the top-level document of which has changed favicon and the eventArgs is nullptr. Use the FaviconUri property and GetFavicon method to obtain the favicon data. The second argument is always null. For more information see add_FaviconChanged.
Representation of a DOM [File](https://developer.mozilla.org/docs/Web/API/File) object passed via WebMessage. You can use this object to obtain the path of a File dropped on WebView2.
ICoreWebView2Frame provides direct access to the iframes information. You can get an ICoreWebView2Frame by handling the ICoreWebView2_4.add_FrameCreated event.
Receives ContentLoading events for iframe.
Event args for the FrameCreated events.
Receives FrameCreated event.
Receives FrameDestroyed event.
Receives DOMContentLoaded events for iframe.
Provides a set of properties for a frame in the ICoreWebView2.
Collection of FrameInfos (name and source). Used to list the affected frames' info when a frame-only render process failure occurs in the ICoreWebView2.
Iterator for a collection of FrameInfos. For more info, see ICoreWebView2ProcessFailedEventArgs2 and ICoreWebView2FrameInfoCollection.
Receives FrameNameChanged event.
Receives NavigationCompleted events.
Receives NavigationCompleted events for iframe.
Receives NavigationStarting events.
Receives NavigationStarting events for iframe.
Receives PermissionRequested events for iframes.
Receives WebMessageReceived events for iframe.
Receives the result of the GetCookies method. The result is written to the cookie list provided in the GetCookies method call.
This interface is a handler for when the Favicon is changed. The sender is the ICoreWebView2 object the top-level document of which has changed favicon and the eventArgs is nullptr. Use the FaviconUri property and GetFavicon method to obtain the favicon data. The second argument is always null. For more information see add_FaviconChanged.
The caller implements this interface to handle the result of GetNonDefaultPermissionSettings.
Receives the result of the `GetProcessExtendedInfos` method. The result is written to the collection of `ProcessExtendedInfo`s provided in the `GetProcessExtendedInfos` method call.
Receives GotFocus and LostFocus events.
Receives HistoryChanged events.
Iterator for a collection of HTTP headers. For more information, navigate to ICoreWebView2HttpRequestHeaders and ICoreWebView2HttpResponseHeaders.
HTTP request headers. Used to inspect the HTTP request on WebResourceRequested event and NavigationStarting event.
HTTP response headers. Used to construct a WebResourceResponse for the WebResourceRequested event.
Implements the interface to receive IsDefaultDownloadDialogOpenChanged events.
Implements the interface to receive IsDocumentPlayingAudioChanged events. Use the IsDocumentPlayingAudio property to get the audio playing state.
Implements the interface to receive IsMutedChanged events. Use the IsMuted property to get the mute state.
Event args for LaunchingExternalUriScheme event.
Event handler for the LaunchingExternalUriScheme event.
Receives GotFocus and LostFocus events.
Event args for the MoveFocusRequested event.
Receives MoveFocusRequested events.
Event args for the NavigationCompleted event.
Receives NavigationCompleted events.
Event args for the NavigationStarting event.
Receives NavigationStarting events.
Receives NewBrowserVersionAvailable events.
Event args for the NewWindowRequested event. The event is run when content inside webview requested to a open a new window (through window.open() and so on).
Receives NewWindowRequested events.
This is the Interface for non-client region change event args.
This is the Interface of the event handler for the non-client region changed event.
Receives `NonClientRegionChanged` events. event.
Receives `CloseRequested` events.
Event args for the `NotificationReceived` event.
Receives `NotificationReceived` events.
A collection of RECT.
The event args for `SaveAsUIShowing` event.
Receives `SaveAsUIShowing` events.
Event args for the ScriptDialogOpening event.
The shared buffer object that is created by CreateSharedBuffer. The object is presented to script as ArrayBuffer when posted to script with PostSharedBufferToScript.
Receives the result of the `ShowSaveAsUI` method.
Event args for the SourceChanged event.
Receives SourceChanged events.
Implements the interface to receive StateChanged event. Use the ICoreWebView2DownloadOperation.State property to get the current state, which can be in progress, interrupted, or completed. Use the ICoreWebView2DownloadOperation.InterruptReason property to get the interrupt reason if the download is interrupted.
Receives StatusBarTextChanged events.
A collection of strings.
The caller implements this interface to receive the TrySuspend result.
Event args for the WebMessageReceived event.
Receives WebMessageReceived events.
Event args for the WebResourceRequested event.
Runs when a URL request (through network, file, and so on) is made in the webview for a Web resource matching resource context filter and URL specified in AddWebResourceRequestedFilter. The host views and modifies the request or provide a response in a similar pattern to HTTP, in which case the request immediately completed. This may not contain any request headers that are added by the network stack, such as an Authorization header.
An HTTP request used with the WebResourceRequested event.
An HTTP request used with the WebResourceRequested event.
An HTTP response used with the WebResourceRequested event.
Event args for the WebResourceResponseReceived event.
Receives WebResourceResponseReceived events.
View of the HTTP representation for a web resource response. The properties of this object are not mutable. This response view is used with the TWVBrowserBase.OnWebResourceResponseReceived event.
Receives the result of the ICoreWebView2WebResourceResponseView.GetContent method.
Receives WindowCloseRequested events.
@@ -2017,62 +2092,62 @@
Implements the interface to receive ZoomFactorChanged events. Use the ICoreWebView2Controller.ZoomFactor property to get the modified zoom factor.
Record used by GetDLLVersion to get the DLL version information
VCL and LCL version of TWVBrowserBase that puts together all browser procedures, functions, properties and events in one place. It has all you need to create, modify and destroy a web browser.
Parent class of TWVBrowser and TWVFMXBrowser that puts together all browser procedures, functions, properties and events in one place. It has all you need to create, modify and destroy a web browser.
Record with all the information to create a TCoreWebView2CustomSchemeRegistration instance to register a custom scheme.
FMX version of TWVBrowserBase that puts together all browser procedures, functions, properties and events in one place. It has all you need to create, modify and destroy a web browser.
Parent control used by FMX applications to show the web contents.
Class used to simplify the WebView2 initialization and destruction.
Class used by the TWVLoader.ProxySettigns property to configure a custom proxy server using the following command line switches: –no-proxy-server, –proxy-auto-detect, –proxy-bypass-list, –proxy-pac-url and –proxy-server.
Parent control that will be used by TWVWindowParent in VCL and LCL applications to show the web contents.
Record used by TCoreWebView2WindowFeatures.CopyToRecord to copy the windows featres
Parent control used by VCL and LCL applications to show the web contents.
The stable WebView2 Runtime that is released every 4 weeks.
Save the page as HTML and download the page-related source files (for example: CSS, JavaScript, images, etc.) in a directory with the same filename prefix.
Default kind to save non-HTML content. If this kind is selected for an HTML page, the behavior is the same as the `HTML_ONLY` kind.
Save the page as HTML. Only the top-level document is saved, excluding subresources.
Save the page as [MHTML](https://en.wikipedia.org/wiki/MHTML).
Did not perform Save As because the end user cancelled or the `Cancel` property on `ICoreWebView2SaveAsUIShowingEventArgs` was set to TRUE.
Could not perform Save As because the destination file path already exists and replacing files was not allowed by the `AllowReplace` property.
Could not perform Save As because the destination file path is an invalid path. + +
The path is invalid when it is empty, a relative path, or a directory, or when the parent path does not exist.
Could not perform Save As because the `Kind` property selection is not supported due to content MIME type or system limits. + +
See the `COREWEBVIEW2_SAVE_AS_KIND` enum for MIME type limits. + +
System limits include when the `HTML_ONLY` kind is selected for an error page at child mode, or when the `COMPLETE` kind is selected and the WebView is running in an App Container.
The ShowSaveAsUI method call completed successfully. By default, the system Save As dialog opens. If `SuppressDefaultDialog` is set to TRUE, the system dialog is skipped.
Indicates that the dialog uses the window.alert JavaScript function.
Indicates that the dialog uses the beforeunload JavaScript event.
Indicates that the dialog uses the window.confirm JavaScript function.
Indicates that the dialog uses the window.prompt JavaScript function.
Browser default ScrollBar style.
@@ -1176,31 +1227,46 @@
Indicates to ignore the warning and continue the request with the TLS certificate. This decision is cached for the RequestUri's host and the server certificate in the session.
Indicates to reject the certificate and cancel the request.
Indicates to display the default TLS interstitial error page to user for page navigations. For others TLS certificate is rejected and the request is cancelled.
Script from web page only has read access to the shared buffer.
Script from web page has read and write access to the shared buffer.
Indicates that the notification text direction adopts the browser's language setting behavior.
Indicates that the notification text is left-to-right.
Indicates that the notification text is right-to-left.
TypeLibrary major version
TypeLibrary minor version
* Reserved IDs used in some DevTools functions *
* Reserved IDs used in some JavaScript functions *
* These constants are declared in the "Windows" unit but some old Delphi versions don't have them. We have to add "WV2_" to be compatible with C++ Builder. *
The stable WebView2 Runtime that is released every 4 weeks.
Specifies Save As kind selection options for `ICoreWebView2SaveAsUIShowingEventArgs`. + +
For HTML documents, we support 3 Save As kinds: HTML_ONLY, SINGLE_FILE and COMPLETE. For non-HTML documents, you must use DEFAULT. MIME types of `text/html` and `application/xhtml+xml` are considered HTML documents.
Save the page as HTML and download the page-related source files (for example: CSS, JavaScript, images, etc.) in a directory with the same filename prefix.
Default kind to save non-HTML content. If this kind is selected for an HTML page, the behavior is the same as the `HTML_ONLY` kind.
Save the page as HTML. Only the top-level document is saved, excluding subresources.
Save the page as [MHTML](https://en.wikipedia.org/wiki/MHTML).
Status of a programmatic Save As call. Indicates the result of the `ShowSaveAsUI` method.
Did not perform Save As because the end user cancelled or the `Cancel` property on `ICoreWebView2SaveAsUIShowingEventArgs` was set to TRUE.
Could not perform Save As because the destination file path already exists and replacing files was not allowed by the `AllowReplace` property.
Could not perform Save As because the destination file path is an invalid path. + +
The path is invalid when it is empty, a relative path, or a directory, or when the parent path does not exist.
Could not perform Save As because the `Kind` property selection is not supported due to content MIME type or system limits. + +
See the `COREWEBVIEW2_SAVE_AS_KIND` enum for MIME type limits. + +
System limits include when the `HTML_ONLY` kind is selected for an error page at child mode, or when the `COMPLETE` kind is selected and the WebView is running in an App Container.
The ShowSaveAsUI method call completed successfully. By default, the system Save As dialog opens. If `SuppressDefaultDialog` is set to TRUE, the system dialog is skipped.
Specifies the JavaScript dialog type used in the ICoreWebView2ScriptDialogOpeningEventHandler interface.
Indicates that the dialog uses the window.alert JavaScript function.
Indicates that the dialog uses the beforeunload JavaScript event.
Indicates that the dialog uses the window.confirm JavaScript function.
Indicates that the dialog uses the window.prompt JavaScript function.
Set ScrollBar style on `ICoreWebView2EnvironmentOptions` during environment creation.
Browser default ScrollBar style.
@@ -1445,66 +1508,86 @@
Specifies the action type when server certificate error is detected to be used in the ICoreWebView2ServerCertificateErrorDetectedEventArgs interface.
Indicates to ignore the warning and continue the request with the TLS certificate. This decision is cached for the RequestUri's host and the server certificate in the session.
Indicates to reject the certificate and cancel the request.
Indicates to display the default TLS interstitial error page to user for page navigations. For others TLS certificate is rejected and the request is cancelled.
Specifies the desired access from script to CoreWebView2SharedBuffer.
Script from web page only has read access to the shared buffer.
Script from web page has read and write access to the shared buffer.
Indicates the text direction of the notification.
Indicates that the notification text direction adopts the browser's language setting behavior.
Indicates that the notification text is left-to-right.
Indicates that the notification text is right-to-left.
Tracking prevention levels.
The default level of tracking prevention. Set to this level to protect against social media tracking on top of malicious trackers. Content and ads will likely be less personalized.
See [Current tracking prevention behavior](/microsoft-edge/web-platform/tracking-prevention#current-tracking-prevention-behavior) for fine-grained information on what is being blocked with this level and can change with different Edge versions.
The least restrictive level of tracking prevention. Set to this level to protect against malicious trackers but allows most other trackers and personalize content and ads.
See [Current tracking prevention behavior](/microsoft-edge/web-platform/tracking-prevention#current-tracking-prevention-behavior) for fine-grained information on what is being blocked with this level and can change with different Edge versions.
Tracking prevention is turned off.
The most restrictive level of tracking prevention. Set to this level to protect against malicious trackers and most trackers across sites. Content and ads will likely have minimal personalization. @@ -1513,232 +1596,232 @@
See [Current tracking prevention behavior](/microsoft-edge/web-platform/tracking-prevention#current-tracking-prevention-behavior) for fine-grained information on what is being blocked with this level and can change with different Edge versions.
Indicates the error status values for web navigations.
Indicates that a connection to the destination was not established.
Indicates that the SSL certificate common name does not match the web address.
Indicates that the SSL certificate has expired.
Indicates that the SSL certificate is not valid. The certificate may not match the public key pins for the host name, the certificate is signed by an untrusted authority or using a weak sign algorithm, the certificate claimed DNS names violate name constraints, the certificate contains a weak key, the validity period of the certificate is too long, lack of revocation information or revocation mechanism, non-unique host name, lack of certificate transparency information, or the certificate is chained to a [legacy Symantec root](https://security.googleblog.com/2018/03/distrust-of-symantec-pki-immediate.html).
Indicates that the SSL certificate has been revoked.
Indicates that the SSL client certificate contains errors.
Indicates that the connection was stopped.
Indicates that the connection was reset.
Indicates that the Internet connection has been lost.
Indicates that the server returned an invalid or unrecognized response.
Indicates that the provided host name was not able to be resolved.
Indicates that the operation was canceled. This status code is also used in the following cases: - When the app cancels a navigation via NavigationStarting event. - For original navigation if the app navigates the WebView2 in a rapid succession away after the load for original navigation commenced, but before it completed.
Indicates that the request redirect failed.
Indicates that the host is unreachable.
Indicates that the connection has timed out.
Indicates that an unexpected error occurred.
Indicates that an unknown error occurred.
Indicates that user is prompted with a login, waiting on user action. Initial navigation to a login site will always return this even if app provides credential using BasicAuthenticationRequested. HTTP response status code in this case is 401. See status code reference here: https://developer.mozilla.org/docs/Web/HTTP/Status.
Indicates that user lacks proper authentication credentials for a proxy server. HTTP response status code in this case is 407. See status code reference here: https://developer.mozilla.org/docs/Web/HTTP/Status.
Specifies the web resource request contexts.
Specifies all resources.
Specifies a CSP Violation Report.
Specifies a document resource.
Specifies an EventSource API communication.
Specifies a Fetch API communication.
Specifies a font resource.
Specifies an image resource.
Specifies a Web App Manifest.
Specifies another media resource such as a video.
Specifies an other resource.
Specifies a Ping request.
Specifies a script resource.
Specifies a Signed HTTP Exchange.
Specifies a CSS resource.
Specifies a TextTrack resource.
Specifies a WebSocket API communication.
Specifies an XML HTTP request, Fetch and EventSource API communication.
Specifies the source of `WebResourceRequested` event.
Indicates that web resource is requested from any supported source.
Indicates that web resource is requested from main page including dedicated workers and iframes.
Indicates that no web resource is requested.
Indicates that web resource is requested from service worker.
Indicates that web resource is requested from shared worker.
@@ -1749,87 +1832,87 @@
DLL export to create a WebView2 environment with a custom version of WebView2 Runtime, user data folder, and with or without additional options.
Represents a reference to a delegate that receives change notifications.
@@ -1844,7 +1927,7 @@
@@ -1857,784 +1940,804 @@
Global instance of TWVLoader used to simplify the WebView2 initialization and destruction.
WebView2 enables you to host web content using the latest Microsoft Edge browser and web technology.
Event args for the AcceleratorKeyPressed event.
This is a continuation of the ICoreWebView2AcceleratorKeyPressedEventArgs interface.
Receives AcceleratorKeyPressed events.
Receives the result of the AddScriptToExecuteOnDocumentCreated method.
Event args for the BasicAuthenticationRequested event. Will contain the request that led to the HTTP authorization challenge, the challenge and allows the host to provide authentication response or cancel the request.
Receives `BasicAuthenticationRequested` events.
Represents a Basic HTTP authentication response that contains a user name and a password as according to RFC7617 (https://tools.ietf.org/html/rfc7617)
Provides a set of properties for managing an Extension, which includes an ID, name, and whether it is enabled or not, and the ability to Remove the Extension, and enable or disable it.
Receives the result of the `Enable` method.
A collection of ICoreWebView2BrowserExtension.
Receives the result of the `Remove` method.
Event args for the BrowserProcessExited event.
Receives BrowserProcessExited events.
Receives `BytesReceivedChanged` events.
Receives the result of the `CallDevToolsProtocolMethod` method.
Receives the result of the CapturePreview method. The result is written to the stream provided in the CapturePreview method.
Provides access to the certificate metadata.
Receives the result of the `ClearBrowsingData` method.
Receives the result of the ClearServerCertificateErrorActions method.
Provides access to the client certificate metadata.
A collection of ICoreWebView2ClientCertificate.
Event args for the ClientCertificateRequested event.
Receives `ClientCertificateRequested` events.
This interface is an extension of the ICoreWebView2Controller interface to support visual hosting. An object implementing the ICoreWebView2CompositionController interface will also implement ICoreWebView2Controller. Callers are expected to use ICoreWebView2Controller for resizing, visibility, focus, and so on, and then use ICoreWebView2CompositionController to connect to a composition tree and provide input meant for the WebView.
A continuation of the ICoreWebView2CompositionController interface.
This interface is the continuation of the ICoreWebView2CompositionController2 interface to manage drag and drop.
This Interface includes an API which enables non-client hit-testing support for WebView2.
Receives ContainsFullScreenElementChanged events.
Receives ContentLoading events.
Receives `ContentLoading` events.
Represents a context menu item of a context menu displayed by WebView.
Represents a collection of ContextMenuItem objects. Used to get, remove and add ContextMenuItem objects at the specified index.
Event args for the ContextMenuRequested event. Will contain the selection information and a collection of all of the default context menu items that the WebView would show. Allows the app to draw its own context menu or add/remove from the default context menu.
Receives ContextMenuRequested events.
Represents the information regarding the context menu target. Includes the context selected and the appropriate data used for the actions of a context menu.
The owner of the `CoreWebView2` object that provides support for resizing, showing and hiding, focusing, and other functionality related to windowing and composition. The `CoreWebView2Controller` owns the `CoreWebView2`, and if all references to the `CoreWebView2Controller` go away, the WebView is closed.
A continuation of the ICoreWebView2Controller interface.
A continuation of the ICoreWebView2Controller2 interface.
This is the ICoreWebView2Controller4 interface. The ICoreWebView2Controller4 provides interface to enable/disable external drop.
This interface is used to manage profile options that created by 'CreateCoreWebView2ControllerOptions'.
This is the interface in ControllerOptions for ScriptLocale.
Provides a set of properties that are used to manage an ICoreWebView2Cookie.
A collection of ICoreWebView2Cookie.
Creates, adds or updates, gets, or or view the cookies. The changes would apply to the context of the user profile. That is, other WebViews under the same user profile could be affected.
Receives the result of the `CreateCoreWebView2CompositionController` method.
Receives the result of the `CreateCoreWebView2Controller` method.
Receives the result of the `CreateCoreWebView2Environment` method.
Receives `CursorChanged` events.
Receives `CustomItemSelected` events.
Represents the registration of a custom scheme with the CoreWebView2Environment. This allows the WebView2 app to be able to handle WebResourceRequested event for requests with the specified scheme and be able to navigate the WebView2 to the custom scheme. Once the environment is created, the registrations are valid and immutable throughout the lifetime of the associated WebView2s' browser process and any WebView2 environments sharing the browser process must be created with identical custom scheme registrations, otherwise the environment creation will fail. Any further attempts to register the same scheme will fail during environment creation. The URIs of registered custom schemes will be treated similar to http URIs for their origins. They will have tuple origins for URIs with host and opaque origins for URIs without host as specified in [7.5 Origin - HTML Living Standard](https://html.spec.whatwg.org/multipage/origin.html)
Example: custom-scheme-with-host://hostname/path/to/resource has origin of custom-scheme-with-host://hostname. custom-scheme-without-host:path/to/resource has origin of custom-scheme-without-host:path/to/resource. For WebResourceRequested event, the cases of request URIs and filter URIs with custom schemes will be normalized according to generic URI syntax rules. Any non-ASCII characters will be preserved. The registered custom schemes also participate in [CORS](https://developer.mozilla.org/docs/Web/HTTP/CORS) and adheres to [CSP](https://developer.mozilla.org/docs/Web/HTTP/CSP). The app needs to set the appropriate access headers in its WebResourceRequested event handler to allow CORS requests.
This interface is used to complete deferrals on event args that support getting deferrals using the GetDeferral method.
Event args for the DevToolsProtocolEventReceived event.
This is a continuation of the ICoreWebView2DevToolsProtocolEventReceivedEventArgs interface that provides the session ID of the target where the event originates from.
Receives `DevToolsProtocolEventReceived` events.
A Receiver is created for a particular DevTools Protocol event and allows you to subscribe and unsubscribe from that event. Obtained from the WebView object using GetDevToolsProtocolEventReceiver.
Receives DocumentTitleChanged events. Use the DocumentTitle property to get the modified title.
Event args for the DOMContentLoaded event.
Receives DOMContentLoaded events.
Represents a download operation. Gives access to the download's metadata and supports a user canceling, pausing, or resuming the download.
Event args for the DownloadStarting event.
Receives `DownloadStarting` events.
Represents the WebView2 Environment. WebViews created from an environment run on the browser process specified with environment parameters and objects created from an environment should be used in the same environment. Using it in different environments are not guaranteed to be compatible and may fail.
This interface is used to create ICoreWebView2ControllerOptions object, which can be passed as a parameter in CreateCoreWebView2ControllerWithOptions and CreateCoreWebView2CompositionControllerWithOptions function for multiple profiles support. The profile will be created on disk or opened when calling CreateCoreWebView2ControllerWithOptions or CreateCoreWebView2CompositionControllerWithOptions no matter InPrivate mode is enabled or not, and it will be released in memory when the corresponding controller is closed but still remain on disk. If you create a WebView2Controller with {ProfileName="name", InPrivate=false} and then later create another one with {ProfileName="name", InPrivate=true}, these two controllers using the same profile would be allowed to run at the same time. As WebView2 is built on top of Edge browser, it follows Edge's behavior pattern. To create an InPrivate WebView, we gets an off-the-record profile (an InPrivate profile) from a regular profile, then create the WebView with the off-the-record profile.
A continuation of the ICoreWebView2Environment interface for getting the crash dump folder path.
A continuation of the ICoreWebView2Environment interface for creating shared buffer object.
A continuation of the ICoreWebView2Environment interface for getting process with associated information.
This is ICoreWebView2Environment14 that exposes new methods to create Filesystem access related DOM objects.
A continuation of the ICoreWebView2Environment interface.
A continuation of the ICoreWebView2Environment2 interface.
A continuation of the ICoreWebView2Environment3 interface.
A continuation of the ICoreWebView2Environment4 interface that supports the BrowserProcessExited event.
This interface is an extension of the ICoreWebView2Environment that supports creating print settings for printing to PDF.
This interface is an extension of the ICoreWebView2Environment. An object implementing the ICoreWebView2Environment7 interface will also implement ICoreWebView2Environment.
A continuation of the ICoreWebView2Environment7 interface that supports the ProcessInfosChanged event.
A continuation of the ICoreWebView2Environment interface for creating CoreWebView2 ContextMenuItem objects.
Options used to create WebView2 Environment. A default implementation is provided in WebView2EnvironmentOptions.h.
Additional options used to create WebView2 Environment. A default implementation is provided in WebView2EnvironmentOptions.h.
Additional options used to create WebView2 Environment to manage crash reporting.
Additional options used to create WebView2 Environment that manages custom scheme registration.
Additional options used to create WebView2 Environment to manage tracking prevention.
Additional options used to create WebView2 Environment to manage browser extensions.
Additional options used to create the WebView2 Environment that support specifying the `ReleaseChannels` and `ChannelSearchKind`.
Additional options used to create WebView2 Environment.
Receives `EstimatedEndTimeChanged` events.
Receives the result of the ExecuteScript method.
This is the result for ExecuteScriptWithResult.
Receives the result of the `ExecuteScriptWithResult` method.
Receives `FaviconChanged` events.
Representation of a DOM [File](https://developer.mozilla.org/docs/Web/API/File) object passed via WebMessage. You can use this object to obtain the path of a File dropped on WebView2.
Representation of a DOM [FileSystemHandle](https://developer.mozilla.org/docs/Web/API/FileSystemHandle) object.
Receives `GotFocus` events.
ICoreWebView2Frame provides direct access to the iframes information. You can get an ICoreWebView2Frame by handling the ICoreWebView2_4.add_FrameCreated event.
A continuation of the ICoreWebView2Frame interface with navigation events, executing script and posting web messages.
This is an extension of the ICoreWebView2Frame interface that supports PermissionRequested
This is an extension of the ICoreWebView2Frame interface that supports shared buffer based on file mapping.
This is an extension of the ICoreWebView2Frame interface that provides the `FrameId` property.
Receives `ContentLoading` events.
Event args for the FrameCreated events.
Receives `FrameCreated` events.
Receives `Destroyed` events.
Receives `DOMContentLoaded` events.
Provides a set of properties for a frame in the ICoreWebView2.
A continuation of the ICoreWebView2FrameInfo interface that provides `ParentFrameInfo`, `FrameId` and `FrameKind` properties.
Collection of FrameInfos (name and source). Used to list the affected frames' info when a frame-only render process failure occurs in the ICoreWebView2.
Iterator for a collection of FrameInfos. For more info, see ICoreWebView2ProcessFailedEventArgs2 and ICoreWebView2FrameInfoCollection.
Receives `NameChanged` events.
Receives `NavigationCompleted` events.
Receives `NavigationStarting` events.
Receives `PermissionRequested` events.
Receives `WebMessageReceived` events.
Receives the result of the GetCookies method.
Receives the result of the `GetFavicon` method.
Receives the result of the `GetNonDefaultPermissionSettings` method.
Receives the result of the `GetProcessExtendedInfos` method.
Receives HistoryChanged events.
Iterator for a collection of HTTP headers. For more information, navigate to ICoreWebView2HttpRequestHeaders and ICoreWebView2HttpResponseHeaders.
HTTP request headers. Used to inspect the HTTP request on WebResourceRequested event and NavigationStarting event.
HTTP response headers. Used to construct a WebResourceResponse for the WebResourceRequested event.
Receives `IsDefaultDownloadDialogOpenChanged` events.
Receives `IsDocumentPlayingAudioChanged` events.
Receives `IsMutedChanged` events.
Event args for LaunchingExternalUriScheme event.
Receives `LaunchingExternalUriScheme` events.
Event args for the MoveFocusRequested event.
Receives MoveFocusRequested events.
Event args for the NavigationCompleted event.
This is an interface for the StatusCode property of ICoreWebView2NavigationCompletedEventArgs
Receives NavigationCompleted events.
Event args for the NavigationStarting event.
The AdditionalAllowedFrameAncestors API that enable developers to provide additional allowed frame ancestors.
The NavigationKind API that enables developers to get more information about navigation type.
Receives NavigationStarting events.
Receives NewBrowserVersionAvailable events.
Event args for the NewWindowRequested event. The event is run when content inside webview requested to a open a new window (through window.open() and so on).
This is a continuation of the ICoreWebView2NewWindowRequestedEventArgs interface.
This is a continuation of the ICoreWebView2NewWindowRequestedEventArgs interface.
Receives NewWindowRequested events.
This is the Interface for non-client region change event args.
Receives `NonClientRegionChanged` events.
This is the ICoreWebView2Notification that represents a [HTML Notification object](https://developer.mozilla.org/docs/Web/API/Notification).
Receives `CloseRequested` events.
Event args for the `NotificationReceived` event. \snippet ScenarioNotificationReceived.cpp NotificationReceived
Receives `NotificationReceived` events.
Represents a collection of generic objects. Used to get, remove and add objects at the specified index.
A collection of objects.
Event args for the PermissionRequested event.
This is a continuation of the ICoreWebView2PermissionRequestedEventArgs interface.
This is a continuation of the ICoreWebView2PermissionRequestedEventArgs interface.
Receives PermissionRequested events.
Provides a set of properties for a permission setting.
Read-only collection of PermissionSettings (origin, kind, and state). Used to list the nondefault permission settings on the profile that are persisted across sessions.
@@ -2645,221 +2748,236 @@
Receives the result of the Print method.
Settings used by the PrintToPdf method.
Settings used by the Print method.
Receives the result of the `PrintToPdf` method.
Receives the result of the PrintToPdfStream method. errorCode returns S_OK if the PrintToPdfStream operation succeeded. The printable pdf data is returned in the pdfStream object.
Provides process with associated extended information in the `ICoreWebView2Environment`.
A collection of ICoreWebView2ProcessExtendedInfo.
Event args for the ProcessFailed event.
A continuation of the ICoreWebView2ProcessFailedEventArgs interface.
A continuation of the ICoreWebView2ProcessFailedEventArgs2 interface for getting blocked file for code integrity process failures.
Receives ProcessFailed events.
Provides a set of properties for a process in the ICoreWebView2Environment.
A collection of ICoreWebView2ProcessInfo.
eceives `ProcessInfosChanged` events.
Provides a set of properties to configure a Profile object.
Profile2 interface.
This is an extension of the ICoreWebView2Profile interface to control levels of tracking prevention.
This is the ICoreWebView2Profile interface for the permission management APIs.
This is the ICoreWebView2Profile interface for cookie manager.
Interfaces in profile for managing password-autosave and general-autofill.
Interfaces in profile for managing browser extensions.
This is the profile interface that manages profile deletion.
Receives the result of the `AddBrowserExtension` method.
Receives `Deleted` events.
Receives the result of the `GetBrowserExtensions` method.
Receives `RasterizationScaleChanged` events.
A collection of RECT.
The event args for `SaveAsUIShowing` event.
Receives `SaveAsUIShowing` events.
Event args for the ScriptDialogOpening event.
Receives ScriptDialogOpening events.
This interface represents a JavaScript exception. If the CoreWebView2.ExecuteScriptWithResult result has Succeeded as false, you can use the result's Exception property to get the script exception.
Event args for the ServerCertificateErrorDetected event.
Receives `ServerCertificateErrorDetected` events.
Receives the result of the `SetPermissionState` method.
Defines properties that enable, disable, or modify WebView features. Changes to IsGeneralAutofillEnabled and IsPasswordAutosaveEnabled apply immediately, while other setting changes made after NavigationStarting event do not apply until the next top-level navigation.
A continuation of the ICoreWebView2Settings interface that manages the user agent.
A continuation of the ICoreWebView2Settings interface that manages whether browser accelerator keys are enabled.
A continuation of the ICoreWebView2Settings interface to manage autofill.
A continuation of the ICoreWebView2Settings interface to manage pinch zoom.
A continuation of the ICoreWebView2Settings interface to manage swipe navigation.
A continuation of the ICoreWebView2Settings interface to hide Pdf toolbar items.
A continuation of the ICoreWebView2Settings interface to manage smartscreen.
A continuation of the ICoreWebView2Settings interface to manage non-client regions.
The shared buffer object that is created by [CreateSharedBuffer](https://learn.microsoft.com/en-us/microsoft-edge/webview2/reference/win32/icorewebview2environment12#createsharedbuffer). The object is presented to script as ArrayBuffer when posted to script with [PostSharedBufferToScript](/microsoft-edge/webview2/reference/win32/icorewebview2_17#postsharedbuffertoscript).
Receives the result of the `ShowSaveAsUI` method.
This is the ICoreWebView_23 interface for PostWebMessageAsJsonWithAdditionalObjects.
This is the ICoreWebView2_24 interface that manages WebView2 Web Notification functionality.
This is the ICoreWebView2_25 interface.
A continuation of the ICoreWebView2_2 interface.
* Missing HANDLE declaration ************** WEBVIEW4DELPHI ************** *
* tagRect is identical to TRect. ************** WEBVIEW4DELPHI ************** *
Event args for the AcceleratorKeyPressed event.
Receives AcceleratorKeyPressed events.
Receives the result of the AddScriptToExecuteOnDocumentCreated method.
Event args for the BasicAuthenticationRequested event. Will contain the request that led to the HTTP authorization challenge, the challenge and allows the host to provide authentication response or cancel the request.
The caller implements this interface to handle the BasicAuthenticationRequested event.
Represents a Basic HTTP authentication response that contains a user name and a password as according to RFC7617 (https://tools.ietf.org/html/rfc7617)
Provides a set of properties for managing an Extension, which includes an ID, name, and whether it is enabled or not, and the ability to Remove the Extension, and enable or disable it.
The caller implements this interface to receive the result of setting the browser Extension as enabled or disabled. If enabled, the browser Extension is running in WebView instances. If disabled, the browser Extension is not running in WebView instances.
A collection of ICoreWebView2BrowserExtension.
The caller implements this interface to receive the result of removing the browser Extension from the Profile.
Event args for the BrowserProcessExited event.
Receives BrowserProcessExited events.
Implements the interface to receive BytesReceivedChanged event. Use the ICoreWebView2DownloadOperation.BytesReceived property to get the received bytes count.
Receives CallDevToolsProtocolMethod completion results.
Receives the result of the CapturePreview method. The result is written to the stream provided in the CapturePreview method.
Provides access to the certificate metadata.
The caller implements this interface to receive the ClearBrowsingData result.
Receives the result of the ClearServerCertificateErrorActions method.
Provides access to the client certificate metadata.
A collection of ICoreWebView2ClientCertificate.
Event args for the ClientCertificateRequested event.
An event handler for the ClientCertificateRequested event.
This interface is an extension of the ICoreWebView2Controller interface to support visual hosting. An object implementing the ICoreWebView2CompositionController interface will also implement ICoreWebView2Controller. Callers are expected to use ICoreWebView2Controller for resizing, visibility, focus, and so on, and then use ICoreWebView2CompositionController to connect to a composition tree and provide input meant for the WebView.
Receives ContainsFullScreenElementChanged events.
Receives ContentLoading events.
Receives `ContentLoading` events.
Represents a context menu item of a context menu displayed by WebView.
Represents a collection of ContextMenuItem objects. Used to get, remove and add ContextMenuItem objects at the specified index.
Event args for the ContextMenuRequested event. Will contain the selection information and a collection of all of the default context menu items that the WebView would show. Allows the app to draw its own context menu or add/remove from the default context menu.
Receives ContextMenuRequested events.
Represents the information regarding the context menu target. Includes the context selected and the appropriate data used for the actions of a context menu.
The owner of the `CoreWebView2` object that provides support for resizing, showing and hiding, focusing, and other functionality related to windowing and composition. The `CoreWebView2Controller` owns the `CoreWebView2`, and if all references to the `CoreWebView2Controller` go away, the WebView is closed.
@@ -4584,42 +4757,42 @@
Provides a set of properties that are used to manage an ICoreWebView2Cookie.
A collection of ICoreWebView2Cookie.
Creates, adds or updates, gets, or or view the cookies. The changes would apply to the context of the user profile. That is, other WebViews under the same user profile could be affected.
The caller implements this interface to receive the CoreWebView2Controller created via CreateCoreWebView2CompositionController.
Receives the CoreWebView2Controller created using CreateCoreWebView2Controller.
The caller implements this interface to receive CursorChanged events. Use the Cursor property to get the new cursor.
Raised to notify the host that the end user selected a custom ContextMenuItem. CustomItemSelected event is raised on the specific ContextMenuItem that the end user selected.
@@ -4630,305 +4803,320 @@
This interface is used to complete deferrals on event args that support getting deferrals using the GetDeferral method.
Event args for the DevToolsProtocolEventReceived event.
Receives DevToolsProtocolEventReceived events from the WebView.
Receives DocumentTitleChanged events. Use the DocumentTitle property to get the modified title.
Event args for the DOMContentLoaded event.
Receives DOMContentLoaded events.
Represents a download operation. Gives access to the download's metadata and supports a user canceling, pausing, or resuming the download.
Event args for the DownloadStarting event.
Add an event handler for the DownloadStarting event.
Represents the WebView2 Environment. WebViews created from an environment run on the browser process specified with environment parameters and objects created from an environment should be used in the same environment. Using it in different environments are not guaranteed to be compatible and may fail.
Receives the WebView2Environment created using CreateCoreWebView2Environment.
Options used to create WebView2 Environment. A default implementation is provided in WebView2EnvironmentOptions.h.
Implements the interface to receive EstimatedEndTimeChanged event. Use the ICoreWebView2DownloadOperation.EstimatedEndTime property to get the new estimated end time.
Receives the result of the ExecuteScript method.
This is the result for ExecuteScriptWithResult.
This is the callback for ExecuteScriptWithResult
This interface is a handler for when the Favicon is changed. The sender is the ICoreWebView2 object the top-level document of which has changed favicon and the eventArgs is nullptr. Use the FaviconUri property and GetFavicon method to obtain the favicon data. The second argument is always null. For more information see add_FaviconChanged.
Representation of a DOM [File](https://developer.mozilla.org/docs/Web/API/File) object passed via WebMessage. You can use this object to obtain the path of a File dropped on WebView2.
ICoreWebView2Frame provides direct access to the iframes information. You can get an ICoreWebView2Frame by handling the ICoreWebView2_4.add_FrameCreated event.
Receives ContentLoading events for iframe.
Event args for the FrameCreated events.
Receives FrameCreated event.
Receives FrameDestroyed event.
Receives DOMContentLoaded events for iframe.
Provides a set of properties for a frame in the ICoreWebView2.
Collection of FrameInfos (name and source). Used to list the affected frames' info when a frame-only render process failure occurs in the ICoreWebView2.
Iterator for a collection of FrameInfos. For more info, see ICoreWebView2ProcessFailedEventArgs2 and ICoreWebView2FrameInfoCollection.
Receives FrameNameChanged event.
Receives NavigationCompleted events.
Receives NavigationCompleted events for iframe.
Receives NavigationStarting events.
Receives NavigationStarting events for iframe.
Receives PermissionRequested events for iframes.
Receives WebMessageReceived events for iframe.
Receives the result of the GetCookies method. The result is written to the cookie list provided in the GetCookies method call.
This interface is a handler for when the Favicon is changed. The sender is the ICoreWebView2 object the top-level document of which has changed favicon and the eventArgs is nullptr. Use the FaviconUri property and GetFavicon method to obtain the favicon data. The second argument is always null. For more information see add_FaviconChanged.
The caller implements this interface to handle the result of GetNonDefaultPermissionSettings.
Receives the result of the `GetProcessExtendedInfos` method. The result is written to the collection of `ProcessExtendedInfo`s provided in the `GetProcessExtendedInfos` method call.
Receives GotFocus and LostFocus events.
Receives HistoryChanged events.
Iterator for a collection of HTTP headers. For more information, navigate to ICoreWebView2HttpRequestHeaders and ICoreWebView2HttpResponseHeaders.
HTTP request headers. Used to inspect the HTTP request on WebResourceRequested event and NavigationStarting event.
HTTP response headers. Used to construct a WebResourceResponse for the WebResourceRequested event.
Implements the interface to receive IsDefaultDownloadDialogOpenChanged events.
Implements the interface to receive IsDocumentPlayingAudioChanged events. Use the IsDocumentPlayingAudio property to get the audio playing state.
Implements the interface to receive IsMutedChanged events. Use the IsMuted property to get the mute state.
Event args for LaunchingExternalUriScheme event.
Event handler for the LaunchingExternalUriScheme event.
Receives GotFocus and LostFocus events.
Event args for the MoveFocusRequested event.
Receives MoveFocusRequested events.
Event args for the NavigationCompleted event.
Receives NavigationCompleted events.
Event args for the NavigationStarting event.
Receives NavigationStarting events.
Receives NewBrowserVersionAvailable events.
Event args for the NewWindowRequested event. The event is run when content inside webview requested to a open a new window (through window.open() and so on).
Receives NewWindowRequested events.
This is the Interface for non-client region change event args.
This is the Interface of the event handler for the non-client region changed event.
Receives `NonClientRegionChanged` events. event.
Receives `CloseRequested` events.
Event args for the `NotificationReceived` event.
Receives `NotificationReceived` events.
A collection of RECT.
The event args for `SaveAsUIShowing` event.
Receives `SaveAsUIShowing` events.
Event args for the ScriptDialogOpening event.
The shared buffer object that is created by CreateSharedBuffer. The object is presented to script as ArrayBuffer when posted to script with PostSharedBufferToScript.
Receives the result of the `ShowSaveAsUI` method.
Event args for the SourceChanged event.
Receives SourceChanged events.
Implements the interface to receive StateChanged event. Use the ICoreWebView2DownloadOperation.State property to get the current state, which can be in progress, interrupted, or completed. Use the ICoreWebView2DownloadOperation.InterruptReason property to get the interrupt reason if the download is interrupted.
Receives StatusBarTextChanged events.
A collection of strings.
The caller implements this interface to receive the TrySuspend result.
Event args for the WebMessageReceived event.
Receives WebMessageReceived events.
Event args for the WebResourceRequested event.
Runs when a URL request (through network, file, and so on) is made in the webview for a Web resource matching resource context filter and URL specified in AddWebResourceRequestedFilter. The host views and modifies the request or provide a response in a similar pattern to HTTP, in which case the request immediately completed. This may not contain any request headers that are added by the network stack, such as an Authorization header.
An HTTP request used with the WebResourceRequested event.
An HTTP request used with the WebResourceRequested event.
An HTTP response used with the WebResourceRequested event.
Event args for the WebResourceResponseReceived event.
Receives WebResourceResponseReceived events.
View of the HTTP representation for a web resource response. The properties of this object are not mutable. This response view is used with the TWVBrowserBase.OnWebResourceResponseReceived event.
Receives the result of the ICoreWebView2WebResourceResponseView.GetContent method.
Receives WindowCloseRequested events.
@@ -5194,361 +5397,376 @@
Implements the interface to receive ZoomFactorChanged events. Use the ICoreWebView2Controller.ZoomFactor property to get the modified zoom factor.
Record used by GetDLLVersion to get the DLL version information
Loader events
Custom events
Browser events
Debug log values used by TWVLoader.DebugLog
Debug log level used when the logging is enabled
Blink editing commands used by the "Input.dispatchKeyEvent" DevTools method.
Event type used by TWVBrowserBase.SimulateKeyEvent
TWVLoader status values
Autoplay policy types used by TWVLoader.AutoplayPolicy. See the –autoplay-policy switch.
Mode for how the Bounds property is interpreted in relation to the RasterizationScale property.
VCL and LCL version of TWVBrowserBase that puts together all browser procedures, functions, properties and events in one place. It has all you need to create, modify and destroy a web browser.
Parent class of TWVBrowser and TWVFMXBrowser that puts together all browser procedures, functions, properties and events in one place. It has all you need to create, modify and destroy a web browser.
Specifies the browser process exit type used in the ICoreWebView2BrowserProcessExitedEventArgs interface.
Specifies the datatype for the ICoreWebView2Profile2.ClearBrowsingData method.
Specifies the image format for the ICoreWebView2.CapturePreview method.
The channel search kind determines the order that release channels are searched for during environment creation. The default behavior is to search for and use the most stable channel found on the device. The order from most to least stable is: WebView2 Runtime -> Beta -> Dev -> Canary. Switch the order to prefer the least stable channel in order to perform pre-release testing. See `COREWEBVIEW2_RELEASE_CHANNELS` for descriptions of channels.
Used by TWVBrowserBase.ClearDataForOrigin to clear the storage
Specifies the client certificate kind.
A value representing RGBA color (Red, Green, Blue, Alpha) for WebView2. Each component takes a value from 0 to 255, with 0 being no intensity and 255 being the highest intensity.
Kind of cookie SameSite status used in the ICoreWebView2Cookie interface. These fields match those as specified in https://developer.mozilla.org/docs/Web/HTTP/Cookies#. Learn more about SameSite cookies here: https://tools.ietf.org/html/draft-west-first-party-cookies-07
Record with all the information to create a TCoreWebView2CustomSchemeRegistration instance to register a custom scheme.
The default download dialog can be aligned to any of the WebView corners by setting the DefaultDownloadDialogCornerAlignment property. The default position is top-right corner.
Reason why a download was interrupted.
State of the download operation.
Specifies the image format to use for favicon.
Kind of CoreWebView2FileSystemHandle as described in [FileSystemHandle.kind](https://developer.mozilla.org/docs/Web/API/FileSystemHandle/kind)
Allowed permissions of a CoreWebView2FileSystemHandle as described in [FileSystemHandle.requestPermission()](https://developer.mozilla.org/docs/Web/API/FileSystemHandle/requestPermission)
FMX version of TWVBrowserBase that puts together all browser procedures, functions, properties and events in one place. It has all you need to create, modify and destroy a web browser.
Parent control used by FMX applications to show the web contents.
Indicates the frame type used in the `ICoreWebView2FrameInfo` interface.
Kind of cross origin resource access allowed for host resources during download. Note that other normal access checks like same origin DOM access check and [Content Security Policy](https://developer.mozilla.org/docs/Web/HTTP/CSP) still apply. The following table illustrates the host resource cross origin access according to access context and COREWEBVIEW2_HOST_RESOURCE_ACCESS_KIND.
Cross Origin Access Context | DENY | ALLOW | DENY_CORS — | — | — | — From DOM like src of img, script or iframe element| Deny | Allow | Allow From Script like Fetch or XMLHttpRequest| Deny | Allow | Deny
Specifies the key event type that triggered an AcceleratorKeyPressed event.
Class used to simplify the WebView2 initialization and destruction.
Specifies memory usage target level of WebView.
Specifies the menu item kind for the ICoreWebView2ContextMenuItem.get_Kind method
Indicates the kind of context for which the context menu was created for the `ICoreWebView2ContextMenuTarget::get_Kind` method. This enum will always represent the active element that caused the context menu request. If there is a selection with multiple images, audio and text, for example, the element that the end user right clicks on within this selection will be the option represented by this enum.
Mouse event type used by SendMouseInput to convey the type of mouse event being sent to WebView. The values of this enum align with the matching WM_* window messages.
Mouse event virtual keys associated with a COREWEBVIEW2_MOUSE_EVENT_KIND for SendMouseInput. These values can be combined into a bit flag if more than one virtual key is pressed for the event. The values of this enum align with the matching MK_* mouse keys.
Specifies the reason for moving focus.
Specifies the navigation kind of each navigation.
This enum contains values representing possible regions a given point lies within.
PDF toolbar item. This enum must be in sync with ToolBarItem in pdf-store-data-types.ts Specifies the PDF toolbar item types used for the ICoreWebView2Settings.put_HiddenPdfToolbarItems method.
Indicates the type of a permission request.
Specifies the response to a permission request.
Pointer event type used by SendPointerInput to convey the type of pointer event being sent to WebView. The values of this enum align with the matching WM_POINTER* window messages.
An enum to represent the options for WebView2 color scheme: auto, light, or dark.
Specifies the collation for a print.
Specifies the color mode for a print.
Specifies the print dialog kind.
Specifies the duplex option for a print.
Specifies the media size for a print.
The orientation for printing, used by the Orientation property on ICoreWebView2PrintSettings.
Indicates the status for printing.
Specifies the process failure type used in the `ICoreWebView2ProcessFailedEventArgs` interface. The values in this enum make reference to the process kinds in the Chromium architecture. For more information about what these processes are and what they do, see [Browser Architecture - Inside look at modern web browser](https://developers.google.com/web/updates/2018/09/inside-browser-part1).
Specifies the process failure reason used in the ICoreWebView2ProcessFailedEventHandler interface.
Indicates the process type used in the ICoreWebView2ProcessInfo interface.
Class used by the TWVLoader.ProxySettigns property to configure a custom proxy server using the following command line switches: –no-proxy-server, –proxy-auto-detect, –proxy-bypass-list, –proxy-pac-url and –proxy-server.
@@ -5915,31 +6138,48 @@
Specifies Save As kind selection options for `ICoreWebView2SaveAsUIShowingEventArgs`. + +
For HTML documents, we support 3 Save As kinds: HTML_ONLY, SINGLE_FILE and COMPLETE. For non-HTML documents, you must use DEFAULT. MIME types of `text/html` and `application/xhtml+xml` are considered HTML documents.
Status of a programmatic Save As call. Indicates the result of the `ShowSaveAsUI` method.
Specifies the JavaScript dialog type used in the ICoreWebView2ScriptDialogOpeningEventHandler interface.
Set ScrollBar style on `ICoreWebView2EnvironmentOptions` during environment creation.
Specifies the action type when server certificate error is detected to be used in the ICoreWebView2ServerCertificateErrorDetectedEventArgs interface.
Specifies the desired access from script to CoreWebView2SharedBuffer.
Represents the state of a setting.
Indicates the text direction of the notification.
Parent control used by VCL and LCL applications to show the web contents.
* Missing HANDLE declaration ************** WEBVIEW4DELPHI ************** *
TypeLibrary major version
TypeLibrary minor version
* Reserved IDs used in some DevTools functions *
* Reserved IDs used in some JavaScript functions *
* These constants are declared in the "Windows" unit but some old Delphi versions don't have them. We have to add "WV2_" to be compatible with C++ Builder. *
Specifies Save As kind selection options for `ICoreWebView2SaveAsUIShowingEventArgs`. + +
For HTML documents, we support 3 Save As kinds: HTML_ONLY, SINGLE_FILE and COMPLETE. For non-HTML documents, you must use DEFAULT. MIME types of `text/html` and `application/xhtml+xml` are considered HTML documents.
Status of a programmatic Save As call. Indicates the result of the `ShowSaveAsUI` method.
Specifies the JavaScript dialog type used in the ICoreWebView2ScriptDialogOpeningEventHandler interface.
Specifies the desired access from script to CoreWebView2SharedBuffer.
Indicates the text direction of the notification.
Tracking prevention levels.
Indicates the error status values for web navigations.
Specifies the web resource request contexts.
Specifies the source of `WebResourceRequested` event.
* Missing HANDLE declaration ************** WEBVIEW4DELPHI ************** *
* tagRect is identical to TRect. ************** WEBVIEW4DELPHI ************** *
Loader events
Custom events
Browser events
Debug log values used by TWVLoader.DebugLog
Debug log level used when the logging is enabled
Blink editing commands used by the "Input.dispatchKeyEvent" DevTools method.
Event type used by TWVBrowserBase.SimulateKeyEvent
TWVLoader status values
Autoplay policy types used by TWVLoader.AutoplayPolicy. See the –autoplay-policy switch.
Mode for how the Bounds property is interpreted in relation to the RasterizationScale property.
Specifies the browser process exit type used in the ICoreWebView2BrowserProcessExitedEventArgs interface.
Specifies the datatype for the ICoreWebView2Profile2.ClearBrowsingData method.
Specifies the image format for the ICoreWebView2.CapturePreview method.
The channel search kind determines the order that release channels are searched for during environment creation. The default behavior is to search for and use the most stable channel found on the device. The order from most to least stable is: WebView2 Runtime -> Beta -> Dev -> Canary. Switch the order to prefer the least stable channel in order to perform pre-release testing. See `COREWEBVIEW2_RELEASE_CHANNELS` for descriptions of channels.
Used by TWVBrowserBase.ClearDataForOrigin to clear the storage
Specifies the client certificate kind.
A value representing RGBA color (Red, Green, Blue, Alpha) for WebView2. Each component takes a value from 0 to 255, with 0 being no intensity and 255 being the highest intensity.
Kind of cookie SameSite status used in the ICoreWebView2Cookie interface. These fields match those as specified in https://developer.mozilla.org/docs/Web/HTTP/Cookies#. Learn more about SameSite cookies here: https://tools.ietf.org/html/draft-west-first-party-cookies-07
The default download dialog can be aligned to any of the WebView corners by setting the DefaultDownloadDialogCornerAlignment property. The default position is top-right corner.
Reason why a download was interrupted.
State of the download operation.
Specifies the image format to use for favicon.
Kind of CoreWebView2FileSystemHandle as described in [FileSystemHandle.kind](https://developer.mozilla.org/docs/Web/API/FileSystemHandle/kind)
Allowed permissions of a CoreWebView2FileSystemHandle as described in [FileSystemHandle.requestPermission()](https://developer.mozilla.org/docs/Web/API/FileSystemHandle/requestPermission)
Indicates the frame type used in the `ICoreWebView2FrameInfo` interface.
Kind of cross origin resource access allowed for host resources during download. Note that other normal access checks like same origin DOM access check and [Content Security Policy](https://developer.mozilla.org/docs/Web/HTTP/CSP) still apply. The following table illustrates the host resource cross origin access according to access context and COREWEBVIEW2_HOST_RESOURCE_ACCESS_KIND.
Cross Origin Access Context | DENY | ALLOW | DENY_CORS — | — | — | — From DOM like src of img, script or iframe element| Deny | Allow | Allow From Script like Fetch or XMLHttpRequest| Deny | Allow | Deny
Specifies the key event type that triggered an AcceleratorKeyPressed event.
Specifies memory usage target level of WebView.
Specifies the menu item kind for the ICoreWebView2ContextMenuItem.get_Kind method
Indicates the kind of context for which the context menu was created for the `ICoreWebView2ContextMenuTarget::get_Kind` method. This enum will always represent the active element that caused the context menu request. If there is a selection with multiple images, audio and text, for example, the element that the end user right clicks on within this selection will be the option represented by this enum.
Mouse event type used by SendMouseInput to convey the type of mouse event being sent to WebView. The values of this enum align with the matching WM_* window messages.
Mouse event virtual keys associated with a COREWEBVIEW2_MOUSE_EVENT_KIND for SendMouseInput. These values can be combined into a bit flag if more than one virtual key is pressed for the event. The values of this enum align with the matching MK_* mouse keys.
Specifies the reason for moving focus.
Specifies the navigation kind of each navigation.
This enum contains values representing possible regions a given point lies within.
PDF toolbar item. This enum must be in sync with ToolBarItem in pdf-store-data-types.ts Specifies the PDF toolbar item types used for the ICoreWebView2Settings.put_HiddenPdfToolbarItems method.
Indicates the type of a permission request.
Specifies the response to a permission request.
Pointer event type used by SendPointerInput to convey the type of pointer event being sent to WebView. The values of this enum align with the matching WM_POINTER* window messages.
An enum to represent the options for WebView2 color scheme: auto, light, or dark.
Specifies the collation for a print.
Specifies the color mode for a print.
Specifies the print dialog kind.
Specifies the duplex option for a print.
Specifies the media size for a print.
The orientation for printing, used by the Orientation property on ICoreWebView2PrintSettings.
Indicates the status for printing.
Specifies the process failure type used in the `ICoreWebView2ProcessFailedEventArgs` interface. The values in this enum make reference to the process kinds in the Chromium architecture. For more information about what these processes are and what they do, see [Browser Architecture - Inside look at modern web browser](https://developers.google.com/web/updates/2018/09/inside-browser-part1).
Specifies the process failure reason used in the ICoreWebView2ProcessFailedEventHandler interface.
Indicates the process type used in the ICoreWebView2ProcessInfo interface.
@@ -952,31 +989,48 @@
Specifies Save As kind selection options for `ICoreWebView2SaveAsUIShowingEventArgs`. + +
For HTML documents, we support 3 Save As kinds: HTML_ONLY, SINGLE_FILE and COMPLETE. For non-HTML documents, you must use DEFAULT. MIME types of `text/html` and `application/xhtml+xml` are considered HTML documents.
Status of a programmatic Save As call. Indicates the result of the `ShowSaveAsUI` method.
Specifies the JavaScript dialog type used in the ICoreWebView2ScriptDialogOpeningEventHandler interface.
Set ScrollBar style on `ICoreWebView2EnvironmentOptions` during environment creation.
Specifies the action type when server certificate error is detected to be used in the ICoreWebView2ServerCertificateErrorDetectedEventArgs interface.
Specifies the desired access from script to CoreWebView2SharedBuffer.
Represents the state of a setting.
Indicates the text direction of the notification.
Specifies the source of `WebResourceRequested` event.
* Missing HANDLE declaration ************** WEBVIEW4DELPHI ************** *
property OnExecuteScriptWithResultCompleted;
property OnNonClientRegionChanged;
property OnNotificationReceived;
property OnNotificationCloseRequested;
property OnSaveAsUIShowing;
property OnShowSaveAsUICompleted;
If a deferral is not taken on the event args, the external URI scheme launch is blocked until the event handler returns. If a deferral is taken, the external URI scheme launch is blocked until the deferral is completed. The host also has the option to cancel the URI scheme launch. -
The `NavigationStarting` and `NavigationCompleted` events will be raised, regardless of whether the `Cancel` property is set to `TRUE` or `FALSE`. The `NavigationCompleted` event will be raised with the `IsSuccess` property set to `FALSE` and the `WebErrorStatus` property set to `ConnectionAborted` regardless of whether the host sets the `Cancel` property on the `ICoreWebView2LaunchingExternalUriSchemeEventArgs`. The `SourceChanged`, `ContentLoading`, and `HistoryChanged` events will not be raised for this navigation to the external URI scheme regardless of the `Cancel` property. +
The `OnNavigationStarting` and `OnNavigationCompleted` events will be raised, regardless of whether the `Cancel` property is set to `TRUE` or `FALSE`. The `OnNavigationCompleted` event will be raised with the `IsSuccess` property set to `FALSE` and the `WebErrorStatus` property set to `ConnectionAborted` regardless of whether the host sets the `Cancel` property on the `ICoreWebView2LaunchingExternalUriSchemeEventArgs`. The `OnSourceChanged`, `OnContentLoading`, and `OnHistoryChanged` events will not be raised for this navigation to the external URI scheme regardless of the `Cancel` property. -
The `OnLaunchingExternalUriScheme` event will be raised after the `NavigationStarting` event and before the `NavigationCompleted` event. +
The `OnLaunchingExternalUriScheme` event will be raised after the `OnNavigationStarting` event and before the `OnNavigationCompleted` event.
The default `CoreWebView2Settings` will also be updated upon navigation to an external URI scheme. If a setting on the `CoreWebView2Settings` interface has been changed, navigating to an external URI scheme will trigger the `CoreWebView2Settings` to update.
The WebView2 may not display the default dialog based on user settings, browser settings, and whether the origin is determined as a [trustworthy origin](https://w3c.github.io/webappsec-secure-contexts# potentially-trustworthy-origin); however, the event will still be raised. -
If the request is initiated by a cross-origin frame without a user gesture, the request will be blocked and the `OnLaunchingExternalUriScheme` event will not be raised. A URI scheme may be blocked for safety reasons. In this case the `LaunchingExternalUriScheme` event will not be raised. The default dialog may show an "always allow" checkbox which allows the user to opt-in to relaxed security (i.e. skipping future default dialogs) for the combination of the URI scheme and the origin of the page initiating this external URI scheme launch. The checkbox is offered so long as the group policy to show the checkbox is not explicitly disabled and there is a trustworthy initiating origin. If the user has checked this box, future attempts to launch this URI scheme will still raise the event. +
If the request is initiated by a cross-origin frame without a user gesture, the request will be blocked and the `OnLaunchingExternalUriScheme` event will not be raised.
@@ -1841,6 +1861,72 @@
<see href="https://learn.microsoft.com/en-us/microsoft-edge/webview2/reference/win32/icorewebview2_21#executescriptwithresult">See the ICoreWebView2_21 article.)
++ | property OnNonClientRegionChanged; |
+
+ This item has no description. Showing description inherited from TWVBrowserBase.OnNonClientRegionChanged. + This event is fired when regions which are marked as non-client in the app html have changed. So either when new regions have been marked, or unmarked, or the region(s) have been changed to a different kind. + + <see href="https://learn.microsoft.com/en-us/microsoft-edge/webview2/reference/win32/icorewebview2compositioncontroller4#add_nonclientregionchanged">See the ICoreWebView2CompositionController4 article.) + |
+ | property OnNotificationReceived; |
+
+ This item has no description. Showing description inherited from TWVBrowserBase.OnNotificationReceived. + + + Event for non-persistent notifications. + + If a deferral is not taken on the event args, the subsequent scripts after the DOM notification creation call (i.e. `Notification()`) are blocked until the event handler returns. If a deferral is taken, the scripts are blocked until the deferral is completed. + + + + <see href="https://learn.microsoft.com/en-us/microsoft-edge/webview2/reference/win32/icorewebview2_24#add_notificationreceived">See the ICoreWebView2_24 article.) + |
+ | property OnNotificationCloseRequested; |
+
+ This item has no description. Showing description inherited from TWVBrowserBase.OnNotificationCloseRequested. + This event is raised when the notification is closed by the web code, such as through `notification.close()`. You don't need to call `ReportClosed` since this is coming from the web code. + + <see href="https://learn.microsoft.com/en-us/microsoft-edge/webview2/reference/win32/icorewebview2notification#add_closerequested">See the ICoreWebView2Notification article.) + |
+ | property OnSaveAsUIShowing; |
+
+ This item has no description. Showing description inherited from TWVBrowserBase.OnSaveAsUIShowing. + This event is raised when save as is triggered, programmatically or manually. + + <see href="https://learn.microsoft.com/en-us/microsoft-edge/webview2/reference/win32/icorewebview2_25#add_saveasuishowing">See the ICoreWebView2_25 article.) + |
+ | property OnShowSaveAsUICompleted; |
+
+ This item has no description. Showing description inherited from TWVBrowserBase.OnShowSaveAsUICompleted. + This event receives the result of the `ShowSaveAsUI` method. + + <see href="https://learn.microsoft.com/en-us/microsoft-edge/webview2/reference/win32/icorewebview2_25#showsaveasui">See the ICoreWebView2_25 article.) + |