Skip to content

Commit 8579fea

Browse files
authored
Revise README for v2.2.1-alpha1
Updated README.md to reflect new features and enhancements in version 2.2.1-alpha1, including event object refactoring and UI responsiveness improvements.
1 parent ba4a6c0 commit 8579fea

1 file changed

Lines changed: 11 additions & 15 deletions

File tree

README.md

Lines changed: 11 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ A powerful bridge that allows **AutoIt** to use the modern **Microsoft Edge WebV
66
https://www.autoitscript.com/forum/topic/213375-webview2autoit-autoit-webview2-component-com-interop
77

88
---
9-
109
### 🚀 Key Features
1110

1211
* **Chromium Engine**: Leverage the speed and security of modern Microsoft Edge.
@@ -55,7 +54,6 @@ https://www.autoitscript.com/forum/topic/213375-webview2autoit-autoit-webview2-c
5554

5655

5756
---
58-
5957
### ⚖️ License
6058

6159
This project is provided "as-is". You are free to use, modify, and distribute it for both personal and commercial projects.
@@ -64,14 +62,13 @@ This project is provided "as-is". You are free to use, modify, and distribute it
6462
<p align="center">
6563
<img src="https://raw.githubusercontent.com/andreasbm/readme/master/assets/lines/rainbow.png" width="100%">
6664
</p>
67-
68-
# 🚀 What's New in v2.2.1-alpha1 - UI Responsiveness & Refactoring
65+
## 🚀 What's New in v2.2.1-alpha1 - UI Responsiveness & Refactoring
6966

7067
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.
7168

72-
## ⚡ Key Features & Enhancements
69+
### ⚡ Key Features & Enhancements
7370

74-
### 1. Advanced Navigation Control (`IWebView2NavigationStartingEventArgs`)
71+
#### 1. Advanced Navigation Control (`IWebView2NavigationStartingEventArgs`)
7572
Navigation is no longer a passive process.
7673
With the new `Args` object, you can programmatically intervene in the navigation lifecycle before it even begins.
7774

@@ -83,14 +80,14 @@ With the new `Args` object, you can programmatically intervene in the navigation
8380

8481
- **`NavigationId`**: A unique identifier for precise request tracking across complex web sessions.
8582

86-
### 2. Event Object Refactoring & API Maturity
83+
#### 2. Event Object Refactoring & API Maturity
8784
We are moving away from "Raw Parameter" callbacks toward an **Object-Oriented Event Model**.
8885

8986
- **Breaking Change**: `OnNavigationStarting` and `OnFrameNavigationStarting` now return an **Args Object**. This change is essential to support bi-directional communication (e.g., AutoIt telling C# to `Cancel = True`).
9087

9188
- **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.
9289

93-
### 3. UI Responsiveness & Interception-Based Locking (Critical Patch)
90+
#### 3. UI Responsiveness & Interception-Based Locking (Critical Patch)
9491
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.
9592

9693
- **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.
@@ -99,7 +96,7 @@ Following the initial alpha release, we identified and resolved a critical issue
9996

10097
- **Guaranteed Unlock**: Improved the AutoIt navigation functions (`_NetWebView2_Navigate`) to ensure the browser is always unlocked, even if a navigation times out or fails.
10198

102-
### 4. Refactored: OnDownloadStarting Event
99+
#### 4. Refactored: OnDownloadStarting Event
103100
- **Transitioned from a parameter-based signature to a robust, object-oriented argument model.**
104101
- **New Argument Wrapper**: `IWebView2DownloadStartingEventArgs` provides access to `Uri`, `ResultFilePath`, `Handled`, `Cancel`, `MimeType`, `ContentDisposition`, and `TotalBytesToReceive`.
105102

@@ -109,21 +106,21 @@ Following the initial alpha release, we identified and resolved a critical issue
109106

110107
- **Improved: Download Logic**: Automatic redirection to `_customDownloadPath` is now applied *before* the event fires, allowing **AutoIt** to see and potentially override the final destination.
111108

112-
### 5. Refactored: OnDownloadStateChanged Event
109+
#### 5. Refactored: OnDownloadStateChanged Event
113110
- **Transitioned to an object-oriented argument model for consistent event handling.**
114111
- **New Argument Wrapper**: `IWebView2DownloadStateChangedEventArgs`
115112
provides access to `State`, `Uri`, `TotalBytesToReceive`, `BytesReceived`, and a new `PercentComplete` helper.
116113

117114
- **Buffered Property Pattern**: Applied to ensure thread-safe progress updates during rapid download cycles.
118115

119-
### 6. Fixed: HTTP Status Code Detection
116+
#### 6. Fixed: HTTP Status Code Detection
120117
- Resolved a bug where `OnWebResourceResponseReceived` failed to fire due to a missing legacy header hack. Replaced with native `ResourceContext` detection.
121118

122119

123-
> [!IMPORTANT]
120+
> [!CAUTION]
124121
> **Breaking Change**: If you have custom scripts using `OnWebResourceResponseReceived` or `OnDownloadStateChanged`, please update their signatures to use the new `$oArgs` object as demonstrated in the updated examples.
125122
126-
## 🏗️ Architectural Inheritance & Refactoring
123+
### 🏗️ Architectural Inheritance & Refactoring
127124

128125
Building on the foundation of v2.1.0, this version further strengthens the **Event Wrapper** hierarchy:
129126

@@ -139,11 +136,10 @@ Building on the foundation of v2.1.0, this version further strengthens the **Eve
139136
<img src="https://raw.githubusercontent.com/andreasbm/readme/master/assets/lines/rainbow.png" width="100%">
140137
</p>
141138

142-
## 📖 NetWebView2Lib Version 2.2.1-alpha (Quick Reference)
143-
144139

145140
## 📖 NetWebView2Lib Version 2.2.1-alpha (Quick Reference)
146141

142+
147143
### 🟦 WebView2Manager (ProgId: NetWebView2Lib.WebView2Manager)
148144

149145
#### ===🔧 Properties===

0 commit comments

Comments
 (0)