diff options
author | Anton Tananaev <anton@traccar.org> | 2023-03-08 06:55:44 -0800 |
---|---|---|
committer | Anton Tananaev <anton@traccar.org> | 2023-03-08 06:55:44 -0800 |
commit | 14574ba0d0b31aa310b6e550451b0a09aa3560dd (patch) | |
tree | bced12d3d8d12f977696e4a7dd0b69b3aadc8d8b /modern/src/map/core | |
parent | ec49b28e2da2dfb66b00e89d74faa9f62a432c5b (diff) | |
download | trackermap-web-14574ba0d0b31aa310b6e550451b0a09aa3560dd.tar.gz trackermap-web-14574ba0d0b31aa310b6e550451b0a09aa3560dd.tar.bz2 trackermap-web-14574ba0d0b31aa310b6e550451b0a09aa3560dd.zip |
Remove Firefox workaround
Diffstat (limited to 'modern/src/map/core')
-rw-r--r-- | modern/src/map/core/mapUtil.js | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/modern/src/map/core/mapUtil.js b/modern/src/map/core/mapUtil.js index 1f8d5d8a..23805a3f 100644 --- a/modern/src/map/core/mapUtil.js +++ b/modern/src/map/core/mapUtil.js @@ -42,11 +42,7 @@ export const prepareIcon = (background, icon, color) => { const iconRatio = 0.5; const imageWidth = canvas.width * iconRatio; const imageHeight = canvas.height * iconRatio; - if (navigator.userAgent.indexOf('Firefox') > 0) { - context.drawImage(icon, (canvas.width - imageWidth) / 2, (canvas.height - imageHeight) / 2, imageWidth, imageHeight); - } else { - context.drawImage(canvasTintImage(icon, color), (canvas.width - imageWidth) / 2, (canvas.height - imageHeight) / 2, imageWidth, imageHeight); - } + context.drawImage(canvasTintImage(icon, color), (canvas.width - imageWidth) / 2, (canvas.height - imageHeight) / 2, imageWidth, imageHeight); } return context.getImageData(0, 0, canvas.width, canvas.height); |