Sfoglia il codice sorgente

Always center the image

master
Fen Dweller 5 anni fa
parent
commit
b9d99d2cbe
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. +1
    -1
      xray.js

+ 1
- 1
xray.js Vedi File

@@ -526,7 +526,7 @@ function setup() {
[baseCtx, baseCtxResized, overlayCtx, overlayCtxResized, shadowCtx].forEach(ctx => { [baseCtx, baseCtxResized, overlayCtx, overlayCtxResized, shadowCtx].forEach(ctx => {
ctx.canvas.width = width; ctx.canvas.width = width;
ctx.canvas.height = height; ctx.canvas.height = height;
ctx.canvas.style.left = fitScreen ? (availableWidth - width) / 2 + "px" : 0;
ctx.canvas.style.left = (availableWidth - width) / 2 + "px";
ctx.canvas.style.top = fitScreen ? (availableHeight - height) / 2 + "px" : 0; ctx.canvas.style.top = fitScreen ? (availableHeight - height) / 2 + "px" : 0;
}); });


Loading…
Annulla
Salva