void (MouseEvent e) { if (!isMultiSelectionEnabled() && (e.getModifiers() & Toolkit.getDefaultToolkit().getMenuShortcutKeyMask()) != 0) { // do not toggle selection with ctrl+click event in single-selection mode e.consume(); } if (UIUtil.isActionClick(e, MouseEvent.MOUSE_PRESSED) && isOnNextStepButton(e)) { e.consume(); } boolean isClick = UIUtil.isActionClick(e, MouseEvent.MOUSE_PRESSED) || UIUtil.isActionClick(e, MouseEvent.MOUSE_RELEASED); if (!isClick || myList.locationToIndex(e.getPoint()) == myList.getSelectedIndex() || isMultiSelectionEnabled() && hasMultiSelectionModifier(e)) { super.processMouseEvent(e); } }