Wait for dom:loaded to fire before initialising the map

Also very all our use of window.onload and switch to using dom:loaded
instead where we can - the main case where we can't is when using a
vector layer as IE will fail unless the page is completely loaded.
This commit is contained in:
Tom Hughes 2011-07-07 10:02:42 +01:00
parent cb4f1e62a0
commit 7e4ceec192
3 changed files with 10 additions and 13 deletions

View file

@ -57,7 +57,8 @@
var bbox = new OpenLayers.Bounds(minlon, minlat, maxlon, maxlat);
bounds.extend(bbox);
box = addBoxToMap(bbox, "<%= edit.id %>", true);
addBoxToMap(bbox, "<%= edit.id %>", true);
<% end %>
vectors.events.on({