1 14 package org.wings; 15 16 import org.wings.io.Device; 17 18 import java.io.IOException ; 19 20 24 public class SCellRendererPane 25 extends SContainer { 26 private final transient static org.apache.commons.logging.Log log = org.apache.commons.logging.LogFactory.getLog("org.wings"); 27 28 31 public SCellRendererPane() { 32 super(); 33 setLayout(null); 34 setVisible(false); 35 } 36 37 40 public void write(Device d) { 41 } 42 43 48 public SComponent addComponent(SComponent c, Object constraints, int index) { 49 if (c.getParent() == this) { 50 return null; 51 } else { 52 return super.addComponent(c, constraints, index); 53 } 54 } 55 56 61 public void writeComponent(Device d, SComponent c, SComponent p) 62 throws IOException { 63 if (getParent() == null) 64 log.warn("SCellRendererPane: parent == null!"); 65 66 if (getParentFrame() == null) 67 log.warn("SCellRendererPane: parentFrame == null!"); 68 69 if (c == null) { 70 return; 71 } 72 73 if (c.getParent() != this) { 74 this.addComponent(c); 75 } 76 77 c.write(d); 78 } 79 } 80 81 82 | Popular Tags |