More updates to url links to be compatible with stock intel map

This commit is contained in:
Kevin
2013-04-11 23:11:50 -07:00
parent fc3dde2b7a
commit 79af80d0c3
5 changed files with 19 additions and 8 deletions

View File

@ -99,6 +99,7 @@ window.handleDataResponse = function(data, textStatus, jqXHR) {
if(!window.getPaddedBounds().contains(latlng)
&& selectedPortal !== ent[0]
&& urlPortal !== ent[0]
&& !(urlPortalLL && urlPortalLL[0] === latlng[0] && urlPortalLL[1] === latlng[1])
) return;
if('imageByUrl' in ent[2] && 'imageUrl' in ent[2].imageByUrl) {
@ -177,6 +178,11 @@ window.handlePortalsRender = function(portals) {
$.each(portals, function(ind, portal) {
//~ if(selectedPortal === portal[0]) portalUpdateAvailable = true;
if(urlPortal && portal[0] === urlPortal) portalInUrlAvailable = true;
if(urlPortalLL && urlPortalLL[0] === portal[2].locationE6.latE6/1E6 && urlPortalLL[1] === portal[2].locationE6.lngE6/1E6) {
urlPortal = portal[0];
portalInUrlAvailable = true;
urlPortalLL = null;
}
renderPortal(portal);
});