kiwi.ui
Class ImmutableCellEditor
java.lang.Object
|
+--kiwi.ui.AbstractCellEditor
|
+--kiwi.ui.ImmutableCellEditor
- All Implemented Interfaces:
- javax.swing.CellEditor, javax.swing.table.TableCellEditor
- public class ImmutableCellEditor
- extends AbstractCellEditor
- implements javax.swing.table.TableCellEditor
This class is a workaround for a bug in JFC. It is basically an
implementation of TableCellEditor
that uses a
JLabel
so that the cell will not be editable.
This class will be deprecated in Kiwi 1.2.
- Author:
- Mark Lindner, PING Software Group
- See Also:
TableCellEditor
Field Summary |
private javax.swing.JLabel |
label
|
Method Summary |
java.lang.Object |
getCellEditorValue()
Get the value of this editor. |
java.awt.Component |
getTableCellEditorComponent(javax.swing.JTable table,
java.lang.Object value,
boolean isSelected,
int row,
int column)
Construct a new ImmutableCellEditor . |
boolean |
isCellEditable(java.util.EventObject anEvent)
Check if this cell is editable. |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait |
Methods inherited from interface javax.swing.CellEditor |
addCellEditorListener, cancelCellEditing, removeCellEditorListener, shouldSelectCell, stopCellEditing |
label
private javax.swing.JLabel label
ImmutableCellEditor
public ImmutableCellEditor()
getTableCellEditorComponent
public java.awt.Component getTableCellEditorComponent(javax.swing.JTable table,
java.lang.Object value,
boolean isSelected,
int row,
int column)
- Construct a new
ImmutableCellEditor
.
public ImmutableCellEditor()
{
}
/** Get the editor component.
- Specified by:
getTableCellEditorComponent
in interface javax.swing.table.TableCellEditor
- Returns:
- The
JLabel
.
getCellEditorValue
public java.lang.Object getCellEditorValue()
- Get the value of this editor.
- Specified by:
getCellEditorValue
in interface javax.swing.CellEditor
- Overrides:
getCellEditorValue
in class AbstractCellEditor
- Returns:
- The text displayed by the
JLabel
.
isCellEditable
public boolean isCellEditable(java.util.EventObject anEvent)
- Check if this cell is editable.
- Specified by:
isCellEditable
in interface javax.swing.CellEditor
- Overrides:
isCellEditable
in class AbstractCellEditor
- Returns:
- Always false.