[OpenLayers-Users] "interesting" cross browser problem with mouse click position

percy percyd at pdx.edu
Wed Oct 25 21:33:38 EDT 2006


Hi All,

We are attempting to use an openlayers frontend to a kamap tiled backend.

My test page, http://ngmdb.usgs.gov/ol/examples/ngmdb4.html , works
great in both "major" browsers. However when we integrate it into the
main search page (which is not yet on a public site, but here's a
simpler Kamap version: http://ngmdb.usgs.gov/ngm_compsearch_map.html) we
get errant behaviour with regard to how the mouseclicks are handled by
OpenLayers in FireFox!

One of our programmers in Academic and Research Computing took a look at
it and came up with the below observation:

"i took the test file you showed me
http://ngmdb.usgs.gov/ol/examples/ngmdb4.html, which seems to work fine 
in firefox with the doubleclick recentering and zoom box (using shift). 
the difference between that file and the fully working file at
http://ngmdb.usgs.gov/ngmdb_work/ngm_compsearch_map9.html is that your 
test page doesn't require you to scroll down to see the map, but the 
other does! you see, when the doubleclick event occurs, the position on 
the page where the click occurs gets recorded. but the position may or 
may not be offset by how far down the screen you've scrolled (it depends 
on the browser).

to see this in action, just edit your test file by sticking in this div 
just after the body tag:

<div style="width:600px;height:800px;background-color:#008800;">
Push the map down the screen
</div>

and then load the test file in a browser. firefox will exhibit the same 
breaking behavior as it does on the working page!"

Has anyone else run into a problem like this?

Thanks for the help, and the great mapping interface,
Percy

-- 
David Percy
Geospatial Data Manager
Geology Department
Portland State University
http://gisgeek.pdx.edu
503-725-3373






More information about the Users mailing list