From cf1789eb681a648b164c69e337ac622251423e85 Mon Sep 17 00:00:00 2001 From: elioat Date: Sun, 22 Dec 2024 11:31:32 -0500 Subject: * --- js/pixel-art/pixel/app.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'js/pixel-art/pixel/app.js') diff --git a/js/pixel-art/pixel/app.js b/js/pixel-art/pixel/app.js index e99b542..3e37db8 100644 --- a/js/pixel-art/pixel/app.js +++ b/js/pixel-art/pixel/app.js @@ -42,11 +42,9 @@ document.getElementById('panLeftBtn').addEventListener('click', () => handlePanB document.getElementById('panRightBtn').addEventListener('click', () => handlePanButton('right')); document.getElementById('centerViewBtn').addEventListener('click', resetView); -// Initialization resizeCanvas(); loadFromLocalStorage(); -// Functions function initializeGrid() { grid = Array(gridWidth).fill().map(() => Array(gridHeight).fill(null)); } @@ -289,8 +287,8 @@ function handleZoom(factor) { if (newCellSize === cellSize) return; - const centerX = (canvas.width / 2 - offsetX) / cellSize; - const centerY = (canvas.height / 2 - offsetY) / cellSize; + // const centerX = (canvas.width / 2 - offsetX) / cellSize; + // const centerY = (canvas.height / 2 - offsetY) / cellSize; cellSize = newCellSize; -- cgit 1.4.1-2-gfad0