1 4 package org.oddjob.designer.components; 5 6 import java.awt.Component ; 7 8 import org.oddjob.designer.arooa.ElementWrapper; 9 import org.oddjob.designer.factory.DesignFactory; 10 import org.oddjob.designer.factory.SimpleHierarchy; 11 import org.oddjob.designer.model.ComponentAction; 12 import org.oddjob.designer.model.FormDefinition; 13 import org.oddjob.designer.model.StandardForm; 14 import org.oddjob.designer.model.TransferComponentAction; 15 16 19 public class FolderDC extends InsertableDC { 20 21 private Component mainForm; 22 23 public FormDefinition form() { 24 return new StandardForm(tag()) 25 .addGroup(basePanel()); 26 } 27 28 public SimpleHierarchy availableActions() { 29 return new SimpleHierarchy(ComponentAction.class) 30 .addHierarchy(DesignFactory.childActions(this, "").setName("Add Job")); 31 } 32 33 36 public ComponentAction[] transferActions(String xml) { 37 return new ComponentAction[] { 38 new TransferComponentAction(this, xml, "Add Job", "") 39 }; 40 } 41 42 public void addComponent(Object child) { 43 childHelper.addChild(child); 44 } 45 46 public ElementWrapper[] elements() { 47 return childElements(); 48 } 49 50 } 51 | Popular Tags |