WPF WindowsFormsHost Touch Screen not working
- What version of the product are you using?
- 1、Nuget 53
- 2、build from a branch 49.0.2623
- What architecture x86 or x64?
- x64
- On what operating system?
- Win7
- Are you using
WinForms,WPForOffScreen?- WPF
- What steps will reproduce the problem?
- Reference :CefSharp.dll CefSharp.Core.dll CefSharp.Winform.dll
- Use 'WindowsFormsHost' control in my wpf program
- Create 'ChromiumWebBrowser' and add it to 'WindowsFormsHost'
- After running, you can display the page, but no Touch effect
- What is the expected output? What do you see instead?
- Can touch scroll and pinch
@ccnucheng You are a god amongst men. Great job discovering the fix, and amazing community dedication for sharing it in such detail.
Maybe you can use the WPF control. It fix in https://github.com/cefsharp/CefSharp/pull/2745
I found another way to solve this problem. Just disbale Chrome Legacy Window with disable-legacy-window.
Windows 7 won't send WM_TOUCH messages to the window when it's a child of a WPF window. So touch won't work. Its window style may be part of the reason. But there's no document about this.
The effect of disabling this window is here.
In some scenarios, I think this solution is better than disabling RealTimeStylus and use WmTouchDevice.