Make doubleclick-follow also set zoom, like clicking the follow arrow does.

This commit is contained in:
Oliver Jowett 2015-01-22 23:12:41 +00:00
parent 5020d75b9e
commit d76b8948b3

View file

@ -851,15 +851,22 @@ function selectPlaneByHex(hex,autofollow) {
SelectedPlane = null;
}
FollowSelected = (autofollow ? true : false);
if (SelectedPlane !== null && autofollow) {
FollowSelected = true;
if (GoogleMap.getZoom() < 8)
GoogleMap.setZoom(8);
} else {
FollowSelected = false;
}
refreshSelected();
}
function toggleFollowSelected() {
FollowSelected = !FollowSelected;
refreshSelected();
if (FollowSelected && GoogleMap.getZoom() < 8)
GoogleMap.setZoom(8);
refreshSelected();
}
function resetMap() {