mirror of
https://github.com/cds-astro/aladin-lite.git
synced 2025-12-24 12:05:42 -08:00
Using the Utils methods also in the examples
Signed-off-by: Cédric Foellmi <cedric@onekiloparsec.dev>
This commit is contained in:
committed by
onekiloparsec
parent
5d0ec40612
commit
ebf2d06f31
@@ -225,6 +225,7 @@
|
||||
|
||||
<script type="module">
|
||||
import A from '../src/js/A.js';
|
||||
import {Utils} from '../src/js/Utils'
|
||||
|
||||
let aladin;
|
||||
A.init.then(() => {
|
||||
@@ -495,7 +496,7 @@
|
||||
deleteOverlayTimeout = undefined;
|
||||
}
|
||||
isDrawing = true;
|
||||
points.push([drawOverlayCanvas.relMouseCoords(e)]);
|
||||
points.push([Utils.relMouseCoords(e)]);
|
||||
});
|
||||
|
||||
|
||||
@@ -504,7 +505,7 @@
|
||||
e.preventDefault();
|
||||
|
||||
drawOverlayCtx.clearRect(0, 0, drawOverlayCtx.canvas.width, drawOverlayCtx.canvas.height);
|
||||
points[points.length-1].push(drawOverlayCanvas.relMouseCoords(e));
|
||||
points[points.length-1].push(Utils.relMouseCoords(e));
|
||||
|
||||
drawOverlayCtx.beginPath();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user