question: public void mouseClicked ( MouseEvent e ) { if ( tryPopup ( e ) ) return ; if ( SwingUtilities . isLeftMouseButton ( e ) ) { int x = e . getX ( ) ; int y = e . getY ( ) ; int idx ; idx = shouldKillIndex ( x , y ) ; if ( idx != - 1 ) { lastIdx = - 1 ; killSearchAtIndex ( idx ) ; } if ( idx == - 1 ) stateChanged ( null ) ; } }
target:  Either closes the selected tab or notifies the listener that a tab was clicked.