public void mouseReleased(MouseEvent e) {
        synchronized (mouseLock) {
            mousePressed = false;
        }
        if (e.getButton() == MouseEvent.BUTTON1) {
           for (DrawListener listener : listeners)
               listener.mouseReleased(userX(e.getX()), userY(e.getY()));
        }
    }