Johan Vromans wrote: Hi,
I have a Wx::wxHtmlWindow. I can attach events to html links but I also want an action when the user clicks somewhere else in the html window. A wxHtmlCellEvent would seem possible but as opposed to the docs this does not do anything if clicked outside visible contents.
I think not all the display area is covered by cells (and I think it partly depends on the HTML structure).
Attaching an event to the window itself seems to have the strange effect of being handled first. So instead of (expected) cell -> window the event seems to be passed to the window first, and then to the cell. So how can I make an html window clickable while still being able to process html links?
You could attach to the window an event handler that only sets a flag and calls ->Skip on the event; in the event handler for the cell clicked event you reset the flag; in a (new) EVT_IDLE handler you can check if the flag is set and do the processing for the click outside the content; very clunky but it should work.
HTH Mattia