Replace use of Event with jQuery methods
Versions of OpenLayers before 2.12 provided a global Event object but this has now been removed, so use jQuery methods instead.
This commit is contained in:
parent
f4a54c18c8
commit
98445b2ab9
2 changed files with 3 additions and 5 deletions
|
@ -37,7 +37,7 @@
|
|||
$("#tr-changeset-" + id).removeClass("selected");
|
||||
}
|
||||
|
||||
function init() {
|
||||
$(document).ready(function () {
|
||||
var map = createMap("changeset_list_map", {
|
||||
controls: [
|
||||
new OpenLayers.Control.Navigation(),
|
||||
|
@ -84,7 +84,5 @@
|
|||
<% else %>
|
||||
map.zoomToExtent(proj(bounds));
|
||||
<% end %>
|
||||
}
|
||||
|
||||
Event.observe(window, "load", init);
|
||||
});
|
||||
</script>
|
||||
|
|
|
@ -288,7 +288,7 @@ end
|
|||
$(document).ready(function () {
|
||||
$("#exportanchor").click(function (e) {
|
||||
$.ajax({ url: "<%= url_for :controller => :export, :action => :start %>" });
|
||||
Event.stop(e);
|
||||
e.preventDefault();
|
||||
});
|
||||
|
||||
<% if params[:action] == 'export' -%>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue