Package org.jdesktop.swingx.hyperlink

Examples of org.jdesktop.swingx.hyperlink.HyperlinkAction$BrowseVisitor


        // enable rollover
        linkList.setRolloverEnabled(true);
        // set a renderer delegating to a HyperlinkProvider configured
        // with raw HyperlinkAction
        linkList.setCellRenderer(new DefaultListRenderer(new HyperlinkProvider(
                new HyperlinkAction())));
        //</snip>
        DemoUtils.setSnippet("List with hyperlink renderer", linkList);
       
        // <snip> Tree with hyperlink renderer
        // model containing URIs wrapped in treeNodes
        DefaultMutableTreeNode root = new DefaultMutableTreeNode(
                new URI("http://java.net"));
        for (int i = 0; i < linkList.getElementCount(); i++) {
            root.add(new DefaultMutableTreeNode(linkList.getElementAt(i)));
        }
        linkTree.setModel(new DefaultTreeModel(root));
        linkTree.expandAll();
        // enable rollover
        linkTree.setRolloverEnabled(true);
        // set a renderer delegating to wrapper around a HyperlinkProvider
        // configured with a raw HyperlinkAction
        linkTree.setCellRenderer(new DefaultTreeRenderer(new WrappingProvider(
                new HyperlinkProvider(new HyperlinkAction()))));
        // </snip>
        DemoUtils.setSnippet("Tree with hyperlink renderer", linkTree);
       
    }
View Full Code Here

TOP

Related Classes of org.jdesktop.swingx.hyperlink.HyperlinkAction$BrowseVisitor

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.