Ejemplo n.º 1
0
 // -- Component --//
 public void beforeChildAdded(Component child, Component refChild) {
   if (child instanceof Caption) {
     if (_caption != null && _caption != child)
       throw new UiException("Only one caption is allowed: " + this);
   } else if (refChild instanceof Caption) {
     throw new UiException("caption must be the first child");
   }
   super.beforeChildAdded(child, refChild);
 }
Ejemplo n.º 2
0
 // -- Component --//
 public void beforeChildAdded(Component child, Component refChild) {
   if (child instanceof Toolbar) {
     if (_toolbar != null && _toolbar != child)
       throw new UiException("Only one Toolbar is allowed: " + this);
   } else if (child instanceof Tabs) {
     if (_tabs != null && _tabs != child)
       throw new UiException("Only one tabs is allowed: " + this);
   } else if (child instanceof Tabpanels) {
     if (_tabpanels != null && _tabpanels != child)
       throw new UiException("Only one tabpanels is allowed: " + this);
   } else {
     throw new UiException("Unsupported child for tabbox: " + child);
   }
   super.beforeChildAdded(child, refChild);
 }
Ejemplo n.º 3
0
 public void beforeChildAdded(Component child, Component refChild) {
   if (!(child instanceof Treeitem))
     throw new UiException("Unsupported child for treechildren: " + child);
   super.beforeChildAdded(child, refChild);
 }
Ejemplo n.º 4
0
 public void beforeChildAdded(Component child, Component refChild) {
   if (!(child instanceof Listfooter))
     throw new UiException("Unsupported child for listfoot: " + child);
   super.beforeChildAdded(child, refChild);
 }