Welcome Guest Search | Active Topics | Sign In | Register

Touch messages in WebBrowser/WebView Options
Clarence
Posted: Friday, August 21, 2020 5:10:42 AM
Rank: Member
Groups: Member

Joined: 9/29/2019
Posts: 13
Hi,

I saw this thread:

https://www.essentialobjects.com/forum/postst11550_Touch-screen-and-WebBrowserWebView.aspx

I also need to catch touch message (specifically right click) to disable it. Has it been implemented in 2020 ?

Thanks.
eo_support
Posted: Friday, August 21, 2020 11:10:44 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,217
Hi,

We have looked into this issue and apparently it is more complicated than we though. We have no problem re-routing WM_TOUCH through application. However the problem is the parameter of the WM_TOUCH message is a "touch handle" that is only valid in the original process --- in this case is the browser engine process, as such you will not be able to get additional touch information inside your process. This makes rerouting this message through your process useless.

To achieve your goal, you can consider using WebView.JSInitCode to inject some JavaScript into the web page that monitors the touch event. All touch event information will be available to your JavaScript code since this is entirely inside the browser engine. You can then perform whatever logic there. If you need to communicate to your application, you can use JavaScript extension to do so:

https://www.essentialobjects.com/doc/webbrowser/advanced/jsext.aspx

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.