public XMLTreePanel() {
        XMLTreeCellRenderer renderer = new XMLTreeCellRenderer();

        setLayout(new BorderLayout());
        model = new XMLTreeModel();
        tree = new JTree();
        tree.setModel(model);
        tree.setShowsRootHandles(true);
        tree.setEditable(false);
        tree.setCellRenderer(renderer);

        JScrollPane pane = new JScrollPane(tree);
        pane.setPreferredSize(new Dimension(400, 600));

        add(pane, "Center");

        final JTextField text = new JTextField();
        text.setEditable(false);
        add(text, "South");

        tree.addTreeSelectionListener(new TreeSelectionListener() {
            @Override
            public void valueChanged(TreeSelectionEvent e) {
                Object lpc = e.getPath().getLastPathComponent();
                if (lpc instanceof XMLTreeNode) {
                    text.setText("Tipo de Elemento: " + ((XMLTreeNode) lpc).getNodeName());
                    node_selecionado = (XMLTreeNode) lpc;
                    XMLInfoPanel.alteraInfo((XMLTreeNode) lpc);
                }
            }
        });
        tree.addMouseListener(new MouseAdapter() {
            @Override
            public void mousePressed(MouseEvent e) {
                int selRow = tree.getRowForLocation(e.getX(), e.getY());
                TreePath selPath = tree.getPathForLocation(e.getX(), e.getY());
                if (selRow != -1) {
                    if (e.getClickCount() == 2) {
                        if (((XMLTreeNode) selPath.getLastPathComponent()).getNodeName().equals(PainelDeControle.TAG_ARQUIVO)) {
                            String conteudo;
                            try {
                                String caminho = getCaminhoSelecionado(false);
                                conteudo = PainelDeControle.middleware.lerArquivo(caminho);
                                new GMASEditor(conteudo, caminho);
                            } catch (RemoteException ex) {
                                Logger.getLogger(XMLTreePanel.class.getName()).log(Level.SEVERE, null, ex);
                            }
                        }
                    }
                }
            }
        });
    }