This commit is contained in:
Luis Fernando Molina committed 2020-09-12 13:45:45 +02:00
1 parent f13bf71add
commit fd5d0b4da3
2 files changed
+88 -84

No files matched your search

+6 -2
View File
@@ -822,8 +822,12 @@ function newPlotter() {
imagePosition.x = dataPoint.x
imagePosition.y = dataPoint.y
let imageToDraw = canvas.designSpace.iconCollection.get(imageName)
if (imageToDraw.canDrawIcon === true) {
browserCanvasContext.drawImage(imageToDraw, imagePosition.x - imageSize / 2 + offsetX, imagePosition.y - imageSize / 2 - offsetY, imageSize, imageSize)
if (imageToDraw !== undefined) {
if (imageToDraw.canDrawIcon === true) {
browserCanvasContext.drawImage(imageToDraw, imagePosition.x - imageSize / 2 + offsetX, imagePosition.y - imageSize / 2 - offsetY, imageSize, imageSize)
}
} else {
console.log('Can not plot image named '+ imageName + ' of product ' + productDefinition.name + ' because it does not exist.')
}
}