[webkit-qt] Getting a QWebElement based on mouse position

Stefan Bogner sbogner at gmail.com
Wed Nov 23 14:35:28 PST 2011


Hi,

you wrote:
> As you said later, QMouseEvent::pos()  is better, but you really should be 
> checking the return value before using it. page()->frameAt() will return a 
> NULL if you give it an invalid coordinate which is why your call segfaulted.

thanks for your reply. That was in fact the reason for the segfault.

In the meantime I got a pointer on IRC (thanks again ostap!), even mainFrame() 
seems to return all elements for the whole page even though the page I am 
displaying consists of 11 frames. So this seems to be the most reliable and 
save solution, and it is working fine. :-)

Thanks!
Stefan


More information about the webkit-qt mailing list