MCPcopy Create free account
hub / github.com/OpenSourcePhysics/osp / addSelectionRows

Method addSelectionRows

unused/javax/swing/JTree.java:1791–1802  ·  view source on GitHub ↗

Adds the paths at each of the specified rows to the current selection. @param rows an array of ints specifying the rows to add, where 0 indicates the first row in the display

(int[] rows)

Source from the content-addressed store, hash-verified

1789 * where 0 indicates the first row in the display
1790 */
1791 public void addSelectionRows(int[] rows) {
1792 TreeUI ui = getUI();
1793
1794 if(ui != null && rows != null) {
1795 int numRows = rows.length;
1796 TreePath[] paths = new TreePath[numRows];
1797
1798 for(int counter = 0; counter < numRows; counter++)
1799 paths[counter] = ui.getPathForRow(this, rows[counter]);
1800 addSelectionPaths(paths);
1801 }
1802 }
1803
1804 /**
1805 * Returns the last path component of the selected path. This is

Callers 1

addSelectionRowMethod · 0.95

Calls 3

getUIMethod · 0.95
addSelectionPathsMethod · 0.95
getPathForRowMethod · 0.80

Tested by

no test coverage detected