List of usage examples for javax.swing.text JTextComponent setFocusable
public void setFocusable(boolean focusable)
From source file:com.haulmont.cuba.desktop.gui.components.DesktopPickerField.java
@Override public void updateEnabled() { super.updateEnabled(); boolean resultEnabled = isEnabledWithParent(); for (DesktopButton button : buttons) { button.setParentEnabled(resultEnabled); }// ww w. java 2 s .c o m if (impl.getEditor() instanceof JTextComponent) { JTextComponent editor = (JTextComponent) impl.getEditor(); editor.setFocusable(resultEnabled); } }