Fix URL updating in Potlatch 1

Potlatch 1 has hard coded calls to updatelinks, so rename the
updatelinks function to updateLinks and add an updatelinks function
using the old style argument list for Potlatch 1 to call.
This commit is contained in:
Tom Hughes 2013-12-01 22:37:04 +00:00
parent a30a29f41a
commit d5a765588f
5 changed files with 14 additions and 5 deletions

View file

@ -58,7 +58,7 @@ function remoteEditHandler(bbox, select) {
* Called as the user scrolls/zooms around to maniplate hrefs of the
* view tab and various other links
*/
function updatelinks(loc, zoom, layers, object) {
function updateLinks(loc, zoom, layers, object) {
$(".geolink").each(function(index, link) {
var href = link.href.split(/[?#]/)[0],
args = querystring.parse(link.search.substring(1)),

View file

@ -144,7 +144,7 @@ $(document).ready(function () {
expiry.setYear(expiry.getFullYear() + 10);
map.on('moveend layeradd layerremove', function() {
updatelinks(
updateLinks(
map.getCenter().wrap(),
map.getZoom(),
map.getLayersCode(),