/** * Set the current selection to this row. * * @param rowno index into rowList */ public void setSelectedRow(int rowno) { if ((rowno < 0) || (rowno >= model.getRowCount())) return; if (debugSetPath) System.out.println("TreeTableSorted setSelected " + rowno); selectedRow = model.getRow(rowno); TreePath path = model.getPath(selectedRow); if (path != null) table.setSelectionPath(path); // for mysterious reasons, gotta do it again later invokeSetPath(); ensureRowIsVisible(rowno); }