private void populate()
    {
        if (isPopulated == false) {
            for (int y = 0; y < gridSize; y++) {
                for (int x = 0; x < gridSize; x++) {
                    squares[x][y] = new Square(this, x, y);
                }
            }
            isPopulated = true;
        }
    }