Element theSelectedElement = (Element) theSelectedNode.getUserObject();
try {
String thePanelKey = theSelectedElement.getName();
EditorPanel theEditorPanel = (EditorPanel) builtPanels.get( thePanelKey );
// if not found, create panel
if ( theEditorPanel == null ) {
// try the generator
theEditorPanel = panelGenerator.getPanelFor( theSelectedElement );
// if none found, use default
if ( theEditorPanel == null ) {
// get the cc plugin class
Class theBuilderClass = getRegistry().getPluginClass( thePanelKey );
// if no builder class, just show the default panel
if ( theBuilderClass == null ) {
showNullEditor();
detailsPanel.scrollToAnchor( theSelectedElement.getName() );
return;
}
theEditorPanel = new DefaultElementPanel( theBuilderClass );
}
else {
theEditorPanel.setProjectBrowser( this );
}
builtPanels.put( thePanelKey, theEditorPanel );
// wrap with standard navigation panel
//DefaultNavigationPanel theNavigationPanel = new DefaultNavigationPanel(this, (PropertiesPanel) theEditorPanel );
addPanel( (JPanel) theEditorPanel, thePanelKey );
}
theEditorPanel.setElement( theSelectedElement );
showPanel( thePanelKey );
detailsPanel.scrollToAnchor( theSelectedElement.getName() );
}
catch ( Exception e ) {