void (KeyEvent e) { if (e.getModifiers() == 0 && e.getKeyCode() == KeyEvent.VK_SPACE) { e.consume(); RelativePoint point = RelativePoint.getCenterOf(myComponent); execute(point.toMouseEvent()); setPressedByKeyboard(false); repaintComponent(); return; } super.keyReleased(e); }