Skip to content

Commit 2e94ef7

Browse files
committed
Update to WebView2 NuGet 1.0.3856.49
1 parent 9f36cd5 commit 2e94ef7

10 files changed

Lines changed: 21 additions & 10 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ WebView4Delphi is an open source project created by Salvador Díaz Fau to embed
33

44
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.
55

6-
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.3800.47](https://www.nuget.org/packages/Microsoft.Web.WebView2) to embed a web browser.
6+
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.3856.49](https://www.nuget.org/packages/Microsoft.Web.WebView2) to embed a web browser.
77

88
WebView4Delphi was developed and tested on Delphi 13, Delphi XE2, Delphi 7 and Lazarus 4.6/FPC 3.2.2.
99
Delphi 6 requires installing the [second Delphi 6 patch](https://support.embarcadero.com/kr/article/38607).

bin32/WebView2Loader.dll

480 Bytes
Binary file not shown.

bin64/WebView2Loader.dll

984 Bytes
Binary file not shown.

demos/Delphi_VCL/CustomSchemeBrowser/uCustomSchemeBrowser.pas

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,9 @@ procedure TMainForm.WVBrowser1AfterCreated(Sender: TObject);
100100
AddressPnl.Enabled := True;
101101

102102
// Filter all requests to the custom scheme
103-
WVBrowser1.AddWebResourceRequestedFilter(MY_CUSTOM_SCHEME + '*', COREWEBVIEW2_WEB_RESOURCE_CONTEXT_ALL);
103+
WVBrowser1.AddWebResourceRequestedFilterWithRequestSourceKinds(MY_CUSTOM_SCHEME + '*',
104+
COREWEBVIEW2_WEB_RESOURCE_CONTEXT_ALL,
105+
COREWEBVIEW2_WEB_RESOURCE_REQUEST_SOURCE_KINDS_ALL);
104106
end;
105107

106108
procedure TMainForm.WVBrowser1DocumentTitleChanged(Sender: TObject);

demos/Delphi_VCL/DLLBrowser/uWebBrowserForm.dfm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ object WebBrowserForm: TWebBrowserForm
1111
Font.Name = 'Segoe UI'
1212
Font.Style = []
1313
Position = poScreenCenter
14+
OnClose = FormClose
1415
OnShow = FormShow
1516
TextHeight = 15
1617
object WVWindowParent1: TWVWindowParent

demos/Delphi_VCL/DLLBrowser/uWebBrowserForm.pas

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,9 @@ TWebBrowserForm = class(TForm)
2626
GoBtn: TButton;
2727

2828
procedure Timer1Timer(Sender: TObject);
29-
procedure FormShow(Sender: TObject);
3029
procedure GoBtnClick(Sender: TObject);
30+
procedure FormShow(Sender: TObject);
31+
procedure FormClose(Sender: TObject; var Action: TCloseAction);
3132

3233
procedure WVBrowser1AfterCreated(Sender: TObject);
3334
procedure WVBrowser1DocumentTitleChanged(Sender: TObject);
@@ -71,6 +72,11 @@ implementation
7172
// uWVLoader.pas. All browsers should be already destroyed before GlobalWebView2Loader
7273
// is destroyed.
7374

75+
procedure TWebBrowserForm.FormClose(Sender: TObject; var Action: TCloseAction);
76+
begin
77+
Action := caFree;
78+
end;
79+
7480
procedure TWebBrowserForm.FormShow(Sender: TObject);
7581
begin
7682
if GlobalWebView2Loader.InitializationError then

demos/Lazarus/CustomSchemeBrowser/uCustomSchemeBrowser.pas

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,9 @@ procedure TMainForm.WVBrowser1AfterCreated(Sender: TObject);
9797
AddressPnl.Enabled := True;
9898

9999
// Filter all requests to the custom scheme
100-
WVBrowser1.AddWebResourceRequestedFilter(MY_CUSTOM_SCHEME + '*', COREWEBVIEW2_WEB_RESOURCE_CONTEXT_ALL);
100+
WVBrowser1.AddWebResourceRequestedFilterWithRequestSourceKinds(MY_CUSTOM_SCHEME + '*',
101+
COREWEBVIEW2_WEB_RESOURCE_CONTEXT_ALL,
102+
COREWEBVIEW2_WEB_RESOURCE_REQUEST_SOURCE_KINDS_ALL);
101103
end;
102104

103105
procedure TMainForm.WVBrowser1DocumentTitleChanged(Sender: TObject);

packages/webview4delphi.lpk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
</CompilerOptions>
1717
<Description Value="WebView4Delphi is an open source project created by Salvador Díaz Fau to embed Chromium-based browsers in applications made with Delphi or Lazarus/FPC."/>
1818
<License Value="MIT"/>
19-
<Version Major="1" Release="3800" Build="47"/>
19+
<Version Major="1" Release="3856" Build="49"/>
2020
<Files Count="68">
2121
<Item1>
2222
<Filename Value="..\source\uWVBrowser.pas"/>

source/uWVVersion.inc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
WEBVIEW2LOADERLIB_VERSION_MAJOR = 1;
22
WEBVIEW2LOADERLIB_VERSION_MINOR = 0;
3-
WEBVIEW2LOADERLIB_VERSION_RELEASE = 3800;
4-
WEBVIEW2LOADERLIB_VERSION_BUILD = 47;
3+
WEBVIEW2LOADERLIB_VERSION_RELEASE = 3856;
4+
WEBVIEW2LOADERLIB_VERSION_BUILD = 49;
55

66
// For full API compatibility, WebView4Delphi requires the same
77
// WebView2 Runtime version mentioned in the release notes :
88
// https://docs.microsoft.com/en-us/microsoft-edge/webview2/release-notes
9-
CHROMIUM_VERSION_MAJOR = 145;
9+
CHROMIUM_VERSION_MAJOR = 146;
1010
CHROMIUM_VERSION_MINOR = 0;
1111
CHROMIUM_VERSION_RELEASE = WEBVIEW2LOADERLIB_VERSION_RELEASE;
1212
CHROMIUM_VERSION_BUILD = WEBVIEW2LOADERLIB_VERSION_BUILD;

update_WebView4Delphi.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
"UpdateLazPackages" : [
33
{
44
"ForceNotify" : true,
5-
"InternalVersion" : 52,
5+
"InternalVersion" : 53,
66
"Name" : "webview4delphi.lpk",
7-
"Version" : "1.0.3800.47"
7+
"Version" : "1.0.3856.49"
88
}
99
],
1010
"UpdatePackageData" : {

0 commit comments

Comments
 (0)