/** * Changes the <code>mousePressed</code> property. The property tells * whether the left mouse button is currently pressed or not. Clients * should not invoke this method unless they handle all mouse events. * @param mousePressed whether button 1 is pressed */ protected void setMousePressed( boolean mousePressed ) { if( this.mousePressed != mousePressed ){ this.mousePressed = mousePressed; for( BasicButtonModelListener listener : listeners() ){ listener.mousePressed( this, mousePressed ); } changed(); } }