views:

86

answers:

1

We have a mapping form in our application that needs a Google Earth background image, and as you can't use the Google Earth plugin in a browser that is under a panel, we use a second form to show the background image. We have a transparent panel on the mapping form that the drawing is done on while Google Earth is drawn on a form held in sync below.

We achieve transparency by giving the form a transparency key of 255, 250, 250 and setting the panel background to this color before drawing on it. Although now after looking at the information available online it appears that the panel shouldn't ever get cursor events.

This works perfectly in most cases, but on one or two customers machines (one is definatly Windows 7) the cursor will not work correctly on the panel where it is transparent. If the cursor is placed over a drawn area of the map then it all work fine.

I think the issue is due to transparancy click through but as it works in most cases I'm not sure what is exactly going on. We've updated all of the graphics drivers to see if there is a custom setting on the customers machine but this hasn't helped.

Does someone have a definative description of what the transparency key does? Is there a way to absolutly set that the panel should recieve the mouse events?

EDIT
Added detail about transparency key.

A: 

Try intercepting the WM_HITTEST message in the WndProc for the Form window and when you know it is over the client area return the appropriate HTCLIENT value. It could be that the default window processing is sometimes returning a different value.

Phil Wright