1786 |
{ |
{ |
1787 |
BasicTreeUI.this.tree.collapsePath(path); |
BasicTreeUI.this.tree.collapsePath(path); |
1788 |
BasicTreeUI.this.tree.fireTreeCollapsed(path); |
BasicTreeUI.this.tree.fireTreeCollapsed(path); |
1789 |
} else |
} |
1790 |
|
else |
1791 |
{ |
{ |
1792 |
BasicTreeUI.this.tree.expandPath(path); |
BasicTreeUI.this.tree.expandPath(path); |
1793 |
BasicTreeUI.this.tree.fireTreeExpanded(path); |
BasicTreeUI.this.tree.fireTreeExpanded(path); |
1800 |
{ |
{ |
1801 |
BasicTreeUI.this.tree.getSelectionModel().clearSelection(); |
BasicTreeUI.this.tree.getSelectionModel().clearSelection(); |
1802 |
BasicTreeUI.this.tree.addSelectionRow(row); |
BasicTreeUI.this.tree.addSelectionRow(row); |
1803 |
} else if (BasicTreeUI.this.tree.getSelectionModel() |
} |
1804 |
|
else if (BasicTreeUI.this.tree.getSelectionModel() |
1805 |
.getSelectionMode() == TreeSelectionModel.CONTIGUOUS_TREE_SELECTION) |
.getSelectionMode() == TreeSelectionModel.CONTIGUOUS_TREE_SELECTION) |
1806 |
{ |
{ |
1807 |
// TODO |
// TODO |
1808 |
} else |
} |
1809 |
|
else |
1810 |
{ |
{ |
1811 |
BasicTreeUI.this.tree.getSelectionModel().setSelectionMode( |
BasicTreeUI.this.tree.getSelectionModel().setSelectionMode( |
1812 |
TreeSelectionModel.DISCONTIGUOUS_TREE_SELECTION); |
TreeSelectionModel.DISCONTIGUOUS_TREE_SELECTION); |
2381 |
0, false); |
0, false); |
2382 |
rendererPane.paintComponent(g, comp, tree, |
rendererPane.paintComponent(g, comp, tree, |
2383 |
getCellBounds(x, y, leaf)); |
getCellBounds(x, y, leaf)); |
2384 |
} else |
} |
2385 |
|
else |
2386 |
{ |
{ |
2387 |
Component c = tree.getCellRenderer().getTreeCellRendererComponent( |
Component c = tree.getCellRenderer().getTreeCellRendererComponent( |
2388 |
tree, leaf, false, false, true, 0, false); |
tree, leaf, false, false, true, 0, false); |
2417 |
false, 0, false); |
false, 0, false); |
2418 |
rendererPane.paintComponent(g, comp, tree, getCellBounds(x, y, |
rendererPane.paintComponent(g, comp, tree, getCellBounds(x, y, |
2419 |
nonLeaf)); |
nonLeaf)); |
2420 |
} else |
} |
2421 |
|
else |
2422 |
{ |
{ |
2423 |
Component c = tree.getCellRenderer().getTreeCellRendererComponent( |
Component c = tree.getCellRenderer().getTreeCellRendererComponent( |
2424 |
tree, nonLeaf, false, expanded, false, 0, false); |
tree, nonLeaf, false, expanded, false, 0, false); |
2459 |
{ |
{ |
2460 |
paintLeaf(g, indentation, descent, tree, curr); |
paintLeaf(g, indentation, descent, tree, curr); |
2461 |
descent += getRowHeight(); |
descent += getRowHeight(); |
2462 |
} else |
} |
2463 |
|
else |
2464 |
{ |
{ |
2465 |
if (depth > 0 || tree.isRootVisible()) |
if (depth > 0 || tree.isRootVisible()) |
2466 |
{ |
{ |