October 26, 2011

VladLvov VladLvov
Lab Rat
4 posts

How to capture HTML document mouse events?

 

Hello, I am new to QT and Qt WebKit. I am trying to port my .Net application that use MS WebBrowser control to QT. With MS WebBrowser component I was able to subscribe to HTML document mouse events but I cannot find similar functionality in the QT WebKit.
Could you point me to a sample that handles mouse events using Qt WebKit?
Thank you,
Vladimir

2 replies

October 26, 2011

peppe peppe
Ant Farmer
1026 posts

I don’t think you can in an easy way — you should install (f.i. via jQuery or similar) javascript functions for the events you’re interested into, then make those functions call slots of some QObject object you register inside the page. See also

 Signature 

Software Engineer
KDAB (UK) Ltd., a KDAB Group company

October 26, 2011

VladLvov VladLvov
Lab Rat
4 posts

Thank you for your prompt respond. That is exactly what I need.

 
  ‹‹ Does the Qtwebkit in Qt for embedded use minimal configuration?      Memory size increases per page load ››

You must log in to post a reply. Not a member yet? Register here!