Search in sources :

Example 6 with ICellEditor

use of net.sourceforge.nattable.edit.editor.ICellEditor in project translationstudio8 by heartsome.

the class BodyCellEditorMouseEventMatcher method matches.

public boolean matches(NatTable natTable, MouseEvent event, LabelStack regionLabels) {
    if (regionLabels != null && regionLabels.hasLabel(GridRegion.BODY)) {
        LayerCell cell = natTable.getCellByPosition(natTable.getColumnPositionByX(event.x), natTable.getRowPositionByY(event.y));
        ICellEditor cellEditor = natTable.getConfigRegistry().getConfigAttribute(EditConfigAttributes.CELL_EDITOR, cell.getDisplayMode(), cell.getConfigLabels().getLabels());
        if (cellEditorClass.isInstance(cellEditor)) {
            return true;
        }
    }
    return false;
}
Also used : LayerCell(net.sourceforge.nattable.layer.cell.LayerCell) ICellEditor(net.sourceforge.nattable.edit.editor.ICellEditor)

Aggregations

ICellEditor (net.sourceforge.nattable.edit.editor.ICellEditor)6 PositionCoordinate (net.sourceforge.nattable.coordinate.PositionCoordinate)3 IDisplayConverter (net.sourceforge.nattable.data.convert.IDisplayConverter)2 IDataValidator (net.sourceforge.nattable.data.validate.IDataValidator)2 LayerCell (net.sourceforge.nattable.layer.cell.LayerCell)2 CellStyleProxy (net.sourceforge.nattable.style.CellStyleProxy)2 IStyle (net.sourceforge.nattable.style.IStyle)2 EditableManager (net.heartsome.cat.ts.ui.xliffeditor.nattable.celleditor.EditableManager)1 SourceEditMode (net.heartsome.cat.ts.ui.xliffeditor.nattable.celleditor.SourceEditMode)1 StyledTextCellEditor (net.heartsome.cat.ts.ui.xliffeditor.nattable.editor.StyledTextCellEditor)1 XLIFFEditorImplWithNatTable (net.heartsome.cat.ts.ui.xliffeditor.nattable.editor.XLIFFEditorImplWithNatTable)1 IConfigRegistry (net.sourceforge.nattable.config.IConfigRegistry)1 UpdateDataCommand (net.sourceforge.nattable.edit.command.UpdateDataCommand)1 InlineCellEditEvent (net.sourceforge.nattable.edit.event.InlineCellEditEvent)1 MultiCellEditDialog (net.sourceforge.nattable.edit.gui.MultiCellEditDialog)1 ILayer (net.sourceforge.nattable.layer.ILayer)1 ILayerListener (net.sourceforge.nattable.layer.ILayerListener)1 LabelStack (net.sourceforge.nattable.layer.LabelStack)1 ITickUpdateHandler (net.sourceforge.nattable.tickupdate.ITickUpdateHandler)1 Rectangle (org.eclipse.swt.graphics.Rectangle)1