down

shows if the mouse was held down while on top of the button last frame

Examples



const button = $.makeButton(80, $.h/2, 120, 30,"Up!");

function update() {
    button.draw();

    if (button.down) {
        button.label = "Down!";
    } else {
        button.label = "Up!";
    }
}