protected Object getCell(MouseEvent e) { Object cell = super.getCell(e); if (isConnecting()) { if (source != null) { error = validateConnection(source.getCell(), cell); if (error != null && error.length() == 0) { cell = null; // Enables create target inside groups if (createTarget) { error = null; } } } } else if (!isValidSource(cell)) { cell = null; } return cell; }
protected Object getCell(MouseEvent e) { Object cell = super.getCell(e); if (isConnecting()) { if (source != null) { error = validateConnection(source.getCell(), cell); if (error != null && error.length() == 0) { cell = null; // Enables create target inside groups if (createTarget) { error = null; } } } } else if (!isValidSource(cell)) { cell = null; } return cell; }
/** * Uses getCell, getMarkedState and intersects to return the state for * the given event. */ protected mxCellState getState(MouseEvent e) { Object cell = getCell(e); mxGraphView view = graphComponent.getGraph().getView(); mxCellState state = getStateToMark(view.getState(cell)); return (state != null && intersects(state, e)) ? state : null; }
protected Object getCell(MouseEvent e) { mxGraph graph = graphComponent.getGraph(); mxIGraphModel model = graph.getModel(); Object cell = super.getCell(e); if (cell == mxEdgeHandler.this.state.getCell() || (!graph.isConnectableEdges() && model.isEdge(cell))) { cell = null; } return cell; }
/** * Uses getCell, getMarkedState and intersects to return the state for * the given event. */ protected mxCellState getState(MouseEvent e) { Object cell = getCell(e); mxGraphView view = graphComponent.getGraph().getView(); mxCellState state = getStateToMark(view.getState(cell)); return (state != null && intersects(state, e)) ? state : null; }
protected Object getCell(MouseEvent e) { mxGraph graph = graphComponent.getGraph(); mxIGraphModel model = graph.getModel(); Object cell = super.getCell(e); if (cell == mxEdgeHandler.this.state.getCell() || (!graph.isConnectableEdges() && model.isEdge(cell))) { cell = null; } return cell; }
Object cell = super.getCell(e); Object[] cells = (isLocal) ? graph.getSelectionCells() : dragCells;
Object cell = super.getCell(e); Object[] cells = (isLocal) ? graph.getSelectionCells() : dragCells;
Object cell = super.getCell(e); Object[] cells = (isLocal) ? graph.getSelectionCells() : dragCells;