[OpenLayers-Users] MousDefaults with yahoo map
Christopher Schmidt
crschmidt at metacarta.com
Fri Sep 12 07:08:53 EDT 2008
On Thu, Sep 11, 2008 at 11:53:24PM -0700, crinolium wrote:
>
> Hi,
>
> there are two examples of yahoo. Did you see the "OpenLayers Spherical
> Mercator Example"? I tried to rebuilt it, but had the error of the not
> working double-click once again. But in the example it works. I don't know,
> what they have done to make it work.
So,
It looks like Yahoo! changed their API such that OpenLayers breaks.
When you have another OpenLayers Layer (like a WMS layer, as is the case
in the spherical mercator example) over the Yahoo! layer, then clicks
are caught by that layer, and the Yahoo layer can't stop them.
We intentionally try to prevent this with the EventPane, but it seems
that that no longer works in the case of Yahoo.
As a temporary workaround, simply add:
map.addLayer(new OpenLayers.Layer.Vector());
to your map. (If you have to support Safari 2 or Safari on the iPhone,
you'll need to use trunk/2.7 for this to work.)
Regards,
--
Christopher Schmidt
MetaCarta
More information about the Users
mailing list