/** * Processes a key release event that occurred in this cell editor. * <p> * The default implementation of this framework method cancels editing when * the ESC key is pressed. When the RETURN key is pressed the current value * is applied and the cell editor deactivates. Subclasses should call this * method at appropriate times. Subclasses may also extend or reimplement. * </p> * * @param keyEvent * the key event */ protected void keyReleaseOccured(KeyEvent keyEvent) { if (keyEvent.character == '\u001b') { // Escape character fireCancelEditor(); } else if (keyEvent.character == '\r') { // Return key fireApplyEditorValue(); deactivate(); } }
/** * Processes a key release event that occurred in this cell editor. * <p> * The default implementation of this framework method cancels editing when * the ESC key is pressed. When the RETURN key is pressed the current value * is applied and the cell editor deactivates. Subclasses should call this * method at appropriate times. Subclasses may also extend or reimplement. * </p> * * @param keyEvent * the key event */ protected void keyReleaseOccured(KeyEvent keyEvent) { if (keyEvent.character == '\u001b') { // Escape character fireCancelEditor(); } else if (keyEvent.character == '\r') { // Return key fireApplyEditorValue(); deactivate(); } }
/** * Processes a key release event that occurred in this cell editor. * <p> * The default implementation of this framework method cancels editing when * the ESC key is pressed. When the RETURN key is pressed the current value * is applied and the cell editor deactivates. Subclasses should call this * method at appropriate times. Subclasses may also extend or reimplement. * </p> * * @param keyEvent * the key event */ protected void keyReleaseOccured(KeyEvent keyEvent) { if (keyEvent.character == '\u001b') { // Escape character fireCancelEditor(); } else if (keyEvent.character == '\r') { // Return key fireApplyEditorValue(); deactivate(); } }