/** Will check if the underlying component is a combo box, and if so * suppress the arrow keys. Doesn't try to do anything special for * other components. */ public KeyStroke[] getKeyStrokes() { if (getLegacyInplaceEditor() instanceof JComboBox) { return ComboInplaceEditor.cbKeyStrokes; } else { return null; } }
/** Will check if the underlying component is a combo box, and if so * suppress the arrow keys. Doesn't try to do anything special for * other components. */ public KeyStroke[] getKeyStrokes() { if (getLegacyInplaceEditor() instanceof JComboBox) { return ComboInplaceEditor.cbKeyStrokes; } else { return null; } }
/** Will check if the underlying component is a combo box, and if so * suppress the arrow keys. Doesn't try to do anything special for * other components. */ public KeyStroke[] getKeyStrokes() { if (getLegacyInplaceEditor() instanceof JComboBox) { return ComboInplaceEditor.cbKeyStrokes; } else { return null; } }
/** Connect to the underlying property editor. Will add the component * to this WrapperInplaceEditor's component hierarchy and start listening * on it for action and focus events */ public void connect(java.beans.PropertyEditor pe, PropertyEnv env) { if (legacy != null) { //Should never be called twice without a clear(), but just in case clear(); } if (pe != enh) { enh = (EnhancedPropertyEditor) pe; } Component comp = getLegacyInplaceEditor(); add(comp, BorderLayout.CENTER); listenerAdded = tryAddActionListener(comp); comp.addFocusListener(this); }
/** Connect to the underlying property editor. Will add the component * to this WrapperInplaceEditor's component hierarchy and start listening * on it for action and focus events */ public void connect(java.beans.PropertyEditor pe, PropertyEnv env) { if (legacy != null) { //Should never be called twice without a clear(), but just in case clear(); } if (pe != enh) { enh = (EnhancedPropertyEditor) pe; } Component comp = getLegacyInplaceEditor(); add(comp, BorderLayout.CENTER); listenerAdded = tryAddActionListener(comp); comp.addFocusListener(this); }
/** Connect to the underlying property editor. Will add the component * to this WrapperInplaceEditor's component hierarchy and start listening * on it for action and focus events */ public void connect(java.beans.PropertyEditor pe, PropertyEnv env) { if (legacy != null) { //Should never be called twice without a clear(), but just in case clear(); } if (pe != enh) { enh = (EnhancedPropertyEditor) pe; } Component comp = getLegacyInplaceEditor(); add(comp, BorderLayout.CENTER); listenerAdded = tryAddActionListener(comp); comp.addFocusListener(this); }