@Override protected void focusLostCancel() { if (PropUtils.psCommitOnFocusLoss && isEditing()) { getEditor().stopCellEditing(); } else { super.focusLostCancel(); } }
protected void focusLostCancel() { if (PropUtils.psCommitOnFocusLoss && isEditing()) { getEditor().stopCellEditing(); } else { super.focusLostCancel(); } }
protected void focusLostCancel() { if (PropUtils.psCommitOnFocusLoss && isEditing()) { getEditor().stopCellEditing(); } else { super.focusLostCancel(); } }
/** Overridden to catch a mouse pressed event over the custom editor * button and invoke the custom editor even if we do not have focus; * otherwise, for example, in the options dialog, clicking from the * tree to the table over the custom editor button will just set focus * to the table, but will not initiate the custom editor dialog */ public void processMouseEvent(MouseEvent me) { if (me.getID() == me.MOUSE_PRESSED) { if (onCustomEditorButton(me) && !hasFocus()) { if (PropUtils.psCommitOnFocusLoss && isEditing()) { getEditor().stopCellEditing(); } int row = rowAtPoint(me.getPoint()); int col = columnAtPoint(me.getPoint()); if (row != -1 && col != -1) { changeSelection(row, col, false, false); getCustomEditorAction().actionPerformed( new ActionEvent (this, ActionEvent.ACTION_PERFORMED, ACTION_CUSTOM_EDITOR)); me.consume(); return; } } } super.processMouseEvent(me); }
/** Overridden to catch a mouse pressed event over the custom editor * button and invoke the custom editor even if we do not have focus; * otherwise, for example, in the options dialog, clicking from the * tree to the table over the custom editor button will just set focus * to the table, but will not initiate the custom editor dialog */ public void processMouseEvent(MouseEvent me) { if (me.getID() == me.MOUSE_PRESSED) { if (onCustomEditorButton(me) && !hasFocus()) { if (PropUtils.psCommitOnFocusLoss && isEditing()) { getEditor().stopCellEditing(); } int row = rowAtPoint(me.getPoint()); int col = columnAtPoint(me.getPoint()); if (row != -1 && col != -1) { changeSelection(row, col, false, false); getCustomEditorAction().actionPerformed( new ActionEvent (this, ActionEvent.ACTION_PERFORMED, ACTION_CUSTOM_EDITOR)); me.consume(); return; } } } super.processMouseEvent(me); }
stopCellEditing(); } else if (ae.getActionCommand() == InplaceEditor.COMMAND_FAILURE) { if (PropUtils.psCommitOnFocusLoss) { stopCellEditing(); } else { cancelCellEditing();
stopCellEditing(); } else if (ae.getActionCommand() == InplaceEditor.COMMAND_FAILURE) { if (PropUtils.psCommitOnFocusLoss) { stopCellEditing(); } else { cancelCellEditing();
stopCellEditing(); } else if (ae.getActionCommand() == InplaceEditor.COMMAND_FAILURE) { if (PropUtils.psCommitOnFocusLoss) { stopCellEditing(); } else { cancelCellEditing();
/** Overridden to store some data in the event of a recoverable change, * such as the row currently being edited */ @Override public void tableChanged(TableModelEvent e) { boolean ed = isEditing(); lastSelectedRow = ed ? getEditingRow() : getSelectionModel().getAnchorSelectionIndex(); if (ed) { getEditor().stopCellEditing(); } super.tableChanged(e); restoreEditingState(); }
getEditor().stopCellEditing();
if( 0 == column ) { getEditor().stopCellEditing(); removeEditor(); getEditor().stopCellEditing();