Java JTree Expand expandPathOnEdt(final JTree tree, final TreePath path)

Here you can find the source of expandPathOnEdt(final JTree tree, final TreePath path)

Description

expand Path On Edt

License

Open Source License

Declaration

public static void expandPathOnEdt(final JTree tree, final TreePath path) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import javax.swing.JTree;
import javax.swing.SwingUtilities;

import javax.swing.tree.TreePath;

public class Main {
    public static void expandPathOnEdt(final JTree tree, final TreePath path) {
        SwingUtilities.invokeLater(new Runnable() {
            public void run() {
                tree.expandPath(path);//from  w w  w .java  2s  .c o m
            }
        });
    }
}

Related

  1. expandLevels(JTree tree, int levels, boolean expand)
  2. expandNodesAtLevel(int level, JTree tree, TreePath parent)
  3. expandOrCollapseAllRows(final JTree tree, final boolean expand)
  4. expandOrCollapseJTree(JTree tree, boolean expand)
  5. expandPath(JTree tree, TreePath tp)
  6. expandPaths(JTree tree, Collection paths)
  7. expandTree(JTree tree, boolean expand)
  8. expandTree(JTree tree, TreeNode start, int level)
  9. expandTreeLevels(JTree tree, TreePath parent, boolean expand, int desiredLevel)