Skip to content

Commit 4ed2f45

Browse files
authored
Merge pull request #119 from ioa747/v2.2.1-alpha
V2.2.1 alpha
2 parents 094fbc7 + d12a981 commit 4ed2f45

18 files changed

Lines changed: 917 additions & 115 deletions

NetWebView2Lib.au3

Lines changed: 77 additions & 63 deletions
Large diffs are not rendered by default.

README.md

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -62,18 +62,19 @@ https://www.autoitscript.com/forum/topic/213375-webview2autoit-autoit-webview2-c
6262
This project is provided "as-is". You are free to use, modify, and distribute it for both personal and commercial projects.
6363

6464

65+
6566
<p align="center">
6667
<img src="https://raw.githubusercontent.com/andreasbm/readme/master/assets/lines/rainbow.png" width="100%">
6768
</p>
6869

6970

70-
## 🚀 What's New in v2.2.0-alpha - Event Object Refactoring
71+
## 🚀 What's New in v2.2.1-alpha - UI Responsiveness & Refactoring
7172

7273
This release marks a major architectural milestone for the library by introducing **Event Object Refactoring**. Key events have been transitioned from passing raw data (strings) to passing full **COM-visible objects**, granting developers absolute control over the application's navigation flow.
7374

7475
### ⚡ Key Features & Enhancements
7576

76-
### 1. Advanced Navigation Control (`IWebView2NavigationStartingEventArgs`)
77+
#### 1. Advanced Navigation Control (`IWebView2NavigationStartingEventArgs`)
7778

7879
Navigation is no longer a passive process. With the new `Args` object, you can programmatically intervene in the navigation lifecycle before it even begins.
7980

@@ -94,6 +95,14 @@ We are moving away from "Raw Parameter" callbacks toward an **Object-Oriented Ev
9495

9596
- **Future-Proofing**: Adding new metadata in future WebView2 updates will no longer break existing user code, as new properties will simply be appended to the existing object.
9697

98+
#### 3. UI Responsiveness & Interception-Based Locking (Critical Patch)
99+
100+
Following the initial alpha release, we identified and resolved a critical issue where Developer Tools (F12) and Right-Click menus could become unresponsive after navigation.
101+
102+
- **Interception-Based Locking**: We moved away from toggling engine-level properties (which caused state lag) to a robust **C# Interception Model**. Features are kept "On" at the engine level but are blocked via the `_isLocked` flag in C#, ensuring the "Inspect" menu item never disappears.
103+
- **C# Fast Path**: Common actions like F12 are now handled instantly within the C# layer, bypassing the AutoIt COM overhead for maximum performance.
104+
- **Guaranteed Unlock**: Improved the AutoIt navigation functions (`_NetWebView2_Navigate`) to ensure the browser is always unlocked, even if a navigation times out or fails.
105+
97106

98107
### 🏗️ Architectural Inheritance & Refactoring
99108

@@ -107,12 +116,13 @@ Building on the foundation of v2.1.0, this version further strengthens the **Eve
107116
> **Why this matters:** The shift to objects transforms **NetWebView2Lib** from a "simple browser wrapper" into a **Professional-Grade SDK** for AutoIt. It brings low-level control—previously reserved for languages like C# or C++—directly into the hands of the AutoIt developer.
108117
109118

119+
110120
<p align="center">
111121
<img src="https://raw.githubusercontent.com/andreasbm/readme/master/assets/lines/rainbow.png" width="100%">
112122
</p>
113123

114124

115-
## 📖 NetWebView2Lib Version 2.2.0-alpha (Quick Reference)
125+
## 📖 NetWebView2Lib Version 2.2.1-alpha (Quick Reference)
116126

117127
### 🟦 WebView2Manager (ProgId: NetWebView2Lib.WebView2Manager)
118128

@@ -281,10 +291,14 @@ Locks down the WebView by disabling context menus, dev tools, zoom control, defa
281291
Re-enables the features previously restricted by `LockWebView()` (ContextMenus, DevTools, Zoom, ErrorPages, Dialogs, Keys, Popups).
282292
`object.UnLockWebView()`
283293

284-
##### 🧊 DisableBrowserFeatures
294+
##### 🧊 DisableBrowserFeatures [LEGACY]
285295
Disables major browser features for a controlled environment (Unified with `LockWebView`).
286296
`object.DisableBrowserFeatures()`
287297

298+
##### 🧊 EnableBrowserFeatures [LEGACY]
299+
Disables major browser features for a controlled environment (Unified with `UnLockWebView`).
300+
`object.EnableBrowserFeatures()`
301+
288302
##### 🧊 GoBack
289303
Navigates back to the previous page in history.
290304
`object.GoBack()`
@@ -562,8 +576,8 @@ Sets a global default folder or file path for all browser downloads. If a direct
562576
Cancels active downloads. If `uri` is empty or omitted, cancels all active downloads.
563577
`object.CancelDownloads([Uri As String])`
564578

565-
##### 🧊 ExportPageData
566-
[LEGACY] Consolidated into **CaptureSnapshot**.
579+
##### 🧊 ExportPageData [LEGACY]
580+
Consolidated into **CaptureSnapshot**.
567581
`object.ExportPageData(Format As Integer, FilePath As String)`
568582

569583
##### 🧊 PrintToPdfStream

bin/x64/NetWebView2Lib.dll

512 Bytes
Binary file not shown.

bin/x64/NetWebView2Lib.tlb

0 Bytes
Binary file not shown.

bin/x86/NetWebView2Lib.dll

512 Bytes
Binary file not shown.

bin/x86/NetWebView2Lib.tlb

0 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)