fix gotoobject giving 0 ra or 0 dec

This commit is contained in:
Matthieu Baumann
2024-04-25 09:21:13 +02:00
parent d655d8f8bd
commit 669fb26114
4 changed files with 5 additions and 5 deletions

View File

@@ -8,8 +8,8 @@
"dateModified": "2023-01-31",
"issueTracker": "https://github.com/cds-astro/aladin-lite/issues",
"name": "Aladin Lite",
"version": "3.3.2",
"softwareVersion": "3.3.2",
"version": "3.3.3-beta",
"softwareVersion": "3.3.3-beta",
"description": "An astronomical HiPS visualizer in the browser.",
"identifier": "10.5281/zenodo.7638833",
"applicationCategory": "Astronomy, Visualization",

View File

@@ -3,7 +3,7 @@ name = "aladin-lite"
description = "Aladin Lite v3 introduces a new graphical engine written in Rust with the use of WebGL"
license = "BSD-3-Clause"
repository = "https://github.com/cds-astro/aladin-lite"
version = "3.3.2"
version = "3.3.3-beta"
authors = [ "baumannmatthieu0@gmail.com", "matthieu.baumann@astro.unistra.fr",]
edition = "2018"

View File

@@ -1009,7 +1009,6 @@ export let Aladin = (function () {
var coo = new Coo();
coo.parse(targetName);
// Convert from view coo sys to icrs
const [ra, dec] = this.wasm.viewToICRSCooSys(coo.lon, coo.lat);
this.view.pointTo(ra, dec);

View File

@@ -1865,9 +1865,10 @@ export let View = (function () {
ra = parseFloat(ra);
dec = parseFloat(dec);
if (!ra || !dec) {
if (!Number.isFinite(ra) || !Number.isFinite(dec)) {
return;
}
this.viewCenter.lon = ra;
this.viewCenter.lat = dec;
//this.updateLocation({lon: this.viewCenter.lon, lat: this.viewCenter.lat});