public void setSelectionCells(Object[] cells) {
		if (cells != null) {
			if (selectionMode == GraphSelectionModel.SINGLE_GRAPH_SELECTION
					&& cells.length > 0)
				cells = new Object[] { cells[cells.length - 1] };
			cellStates.clear();
			Vector change = new Vector();
			Set newSelection = new LinkedHashSet();
			for (int i = 0; i < cells.length; i++) {
				if (cells[i] != null) {
					selection.remove(cells[i]);
					change.addElement(new CellPlaceHolder(cells[i], !selection
							.remove(cells[i])));
					select(newSelection, cells[i]);
					Object parent = graph.getModel().getParent(cells[i]);
					if (parent != null)
						change.addElement(new CellPlaceHolder(parent, false));
				}
			}
			Iterator it = selection.iterator();
			while (it.hasNext()) {
				Object cell = it.next();
				while (cell != null) {
					change.addElement(new CellPlaceHolder(cell, false));
					cell = graph.getModel().getParent(cell);
				}
			}
			selection = newSelection;
			if (change.size() > 0) {
				notifyCellChange(change);
			}
		}
	}