We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I am unable to capture and handle MouseWheel and PreviewMouseWheel events in Edge WebView2 WPF app.
I am pressing (Ctrl + Mouse wheel scroll) and c# app is not capturing the events.
Blocking. My app's basic functions are not working due to this issue.
Stable release (WebView2 Runtime)
133.0.3065.59
1.0.3065.39
WPF
Windows 10
10.0.19045.5371
Code to reproduce:
using Microsoft.Web.WebView2.Core; using System; using System.Windows; using System.Windows.Input; namespace WpfApp { public partial class MainWindow : Window { private double zoomFactor = 1.0; public MainWindow() { InitializeComponent(); InitializeWebView(); } private async void InitializeWebView() { await webView.EnsureCoreWebView2Async(null); webView.CoreWebView2.Navigate("https://example.com"); // Replace with your desired URL } private void Window_MouseWheel(object sender, MouseWheelEventArgs e) { // Check the direction of the scroll if (e.Delta > 0) // Scrolling up { ZoomIn(); } else // Scrolling down { ZoomOut(); } // Mark the event as handled to prevent further processing e.Handled = true; } private void ZoomIn() { zoomFactor += 0.1; webView.CoreWebView2.ZoomFactor = zoomFactor; } private void ZoomOut() { zoomFactor = Math.Max(0.1, zoomFactor - 0.1); // Prevent zooming out too much webView.CoreWebView2.ZoomFactor = zoomFactor; } } }
No, issue does not reproduce in the corresponding Edge version
Don't know
No response
The text was updated successfully, but these errors were encountered:
@sivMSFT
Sorry, something went wrong.
Badhri
No branches or pull requests
What happened?
I am unable to capture and handle MouseWheel and PreviewMouseWheel events in Edge WebView2 WPF app.
I am pressing (Ctrl + Mouse wheel scroll) and c# app is not capturing the events.
Importance
Blocking. My app's basic functions are not working due to this issue.
Runtime Channel
Stable release (WebView2 Runtime)
Runtime Version
133.0.3065.59
SDK Version
1.0.3065.39
Framework
WPF
Operating System
Windows 10
OS Version
10.0.19045.5371
Repro steps
Code to reproduce:
Repros in Edge Browser
No, issue does not reproduce in the corresponding Edge version
Regression
Don't know
Last working version (if regression)
No response
The text was updated successfully, but these errors were encountered: