class NoFocusButton extends JButton { public NoFocusButton(String s) { super(s); } public boolean isRequestFocusEnabled() { return false; } public boolean isFocusTraversable() { return false; } }