Search in sources :

Example 1 with DeleteTableCommand

use of com.cubrid.common.ui.er.commands.DeleteTableCommand in project cubrid-manager by CUBRID.

the class TableEditPolicy method createDeleteCommand.

@Override
protected Command createDeleteCommand(GroupRequest request) {
    TablePart tablePart = (TablePart) getHost();
    Rectangle bounds = tablePart.getFigure().getBounds().getCopy();
    ERSchema parent = (ERSchema) (tablePart.getParent().getModel());
    DeleteTableCommand deleteCmd = new DeleteTableCommand();
    deleteCmd.setSchema(parent);
    deleteCmd.setTable((ERTable) (tablePart.getModel()));
    deleteCmd.setOriginalBounds(bounds);
    return deleteCmd;
}
Also used : TablePart(com.cubrid.common.ui.er.part.TablePart) Rectangle(org.eclipse.draw2d.geometry.Rectangle) ERSchema(com.cubrid.common.ui.er.model.ERSchema) DeleteTableCommand(com.cubrid.common.ui.er.commands.DeleteTableCommand)

Aggregations

DeleteTableCommand (com.cubrid.common.ui.er.commands.DeleteTableCommand)1 ERSchema (com.cubrid.common.ui.er.model.ERSchema)1 TablePart (com.cubrid.common.ui.er.part.TablePart)1 Rectangle (org.eclipse.draw2d.geometry.Rectangle)1