View Full Version : how to bring a window in front of GoogleEarth plugin?

1 Jan 2011, 1:20 AM

I create GE instance by using method: google.earth.createInstance(<panelbody>, <callback>, {});
Later on, the user can click on a button, which generate a new window (using JS Ext toolkit)

But than, a problem pops-up: the generated window is always behind the <panelbody> which contains googleEarth plugin…
Tried all the tricks, founds in forums, that should bring the window visible to the user: show(), toFront(), setting windowMgr.xseeed…

Notices that even if the <callback> is empty – the <panelbody> still "hide" the generated window. Therefore, I suspect the createInstance() setup the <panelbody> contexts to be un-hidden - but don't know how to change it.

Any solutions ?

Thanks in advance

3 Jan 2011, 7:14 AM
You need to use a shim.

Because the google earth plugin is a windowed npapi/activex browser plugin, it isn’t included in the browsers normal z order, instead it will always be on top of the other html elements.
There is a workaround though, by using an iframe shim on your new ext window it will be visible through your google earth plugin.

Luckily ext has built in supports for shims by setting Ext.useShims = true and shim: true in your window configuration object.