Ejemplo n.º 1
0
 public void renderInitialization(final Widget widget) throws IOException {
   Tree tree = (Tree) widget;
   JSWriter writer = JSWriter.getWriterFor(tree);
   StringBuffer style = new StringBuffer();
   if ((tree.getStyle() & SWT.MULTI) != 0) {
     style.append("multi|");
   }
   if ((tree.getStyle() & SWT.CHECK) != 0) {
     style.append("check|");
   }
   if ((tree.getStyle() & SWT.VIRTUAL) != 0) {
     style.append("virtual|");
   }
   writer.newWidget("org.eclipse.swt.widgets.Tree", new Object[] {style.toString()});
   ControlLCAUtil.writeStyleFlags(tree);
 }
 public void renderInitialization(final Widget widget) throws IOException {
   ScrolledComposite scrolledComposite = (ScrolledComposite) widget;
   JSWriter writer = JSWriter.getWriterFor(scrolledComposite);
   writer.newWidget(QX_TYPE);
   ControlLCAUtil.writeStyleFlags(scrolledComposite);
 }