/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package org.geoforge.guillcogc.treenode;
import java.awt.event.ActionListener;
import javax.swing.tree.DefaultTreeModel;
import org.geoforge.guillc.tree.GfrTreAbs;
import org.geoforge.awt.image.GfrFactoryIconAbs;
import org.geoforge.io.awt.image.GfrFactoryIconAppGfr;
import org.geoforge.wrpbasprssynogc.GfrWrpBasSynObjNameTloWms;
/**
*
* @author robert
*/
abstract public class GfrNodCtrMovFolderLblLyrPrjWmsLyrAbs extends GfrNodCtrMovFolderLblLyrPrjWmsAbs
{
protected GfrNodCtrMovFolderLblLyrPrjWmsLyrAbs(
ActionListener alrControllerSpcPrj,
ActionListener alrControllerPrs,
String strIdUnique,
GfrTreAbs tre,
ActionListener alrParentPanelMvc,
String strIdOwner)
throws Exception
{
super(
alrControllerSpcPrj,
alrControllerPrs,
strIdUnique,
tre,
alrParentPanelMvc,
strIdOwner,
GfrWrpBasSynObjNameTloWms.getInstance().getValueTitleLayerFolder(strIdUnique),
GfrFactoryIconAppGfr.s_getFolder(GfrFactoryIconAbs.INT_SIZE_XXSMALL)
);
}
@Override
protected void _loadChildren() throws Exception
{
String[] strsIdFolderChild = GfrWrpBasSynObjNameTloWms.getInstance().getIdsFolderChildrenFromFolderParent(super._strId);
_loadChildrenFolder(strsIdFolderChild);
String[] strsIdLeafChild = GfrWrpBasSynObjNameTloWms.getInstance().getIdsLeafChildrenFromFolderParent(super._strId);
_loadChildrenLeaf(strsIdLeafChild);
boolean blnShouldUpdate = false;
if (strsIdFolderChild!=null && strsIdFolderChild.length>0)
blnShouldUpdate = true;
else if (strsIdLeafChild!=null && strsIdLeafChild.length>0)
blnShouldUpdate = true;
if (blnShouldUpdate)
{
DefaultTreeModel dtm = (DefaultTreeModel) super._tree.getModel();
dtm.nodeStructureChanged(this);
}
}
}