@Override
    public void mousePressed(MouseEvent e) {
        if (e.getX() < 0 || e.getY() < 0 || e.getX() > Minesweeper.myWidth * Minesweeper.SIZE || e.getY() > Minesweeper.myHeight * Minesweeper.SIZE) {
            return;
        }
        boolean left = e.getButton() == MouseEvent.BUTTON1,
                right = e.getButton() == MouseEvent.BUTTON3,
                middle = e.getButton() == MouseEvent.BUTTON2;
        if (right) { //handle right press
            rightDown = true;
            if (leftDown) {
                board.teaseChord(board.spaceAt(e.getX(), e.getY()));
                board.teaseSmile();
                chordTeasing = true;
            } else {
                board.cycleState(board.spaceAt(e.getX(), e.getY()));
            }
        } else if (left) { //handle left press
            leftDown = true;
            if (rightDown) {
                board.teaseChord(board.spaceAt(e.getX(), e.getY()));
                board.teaseSmile();
                chordTeasing = true;
            } else {
                board.spaceAt(e.getX(), e.getY()).tease();
                board.teaseSmile();
            }
        }
        lastX = e.getX();
        lastY = e.getY();
    }