/**
   * Static Init
   *
   * @throws Exception
   */
  private void init() throws Exception {
    fResource.setMold("select");
    fResource.addEventListener(Events.ON_SELECT, this);
    delete.addEventListener(Events.ON_CLICK, this);
    confirmPanel.addComponentsLeft(delete);
    confirmPanel.addActionListener(Events.ON_CLICK, this);
    //
    this.appendChild(mainPanel);
    mainPanel.makeNoStrip();
    mainPanel.setStyle("background-color: transparent");

    Rows rows = new Rows();
    mainPanel.appendChild(rows);
    Row row = new Row();
    row.appendChild(LayoutUtils.makeRightAlign(lResource));
    row.appendChild(fResource);
    row.appendChild(new Label(" "));
    rows.appendChild(row);

    row = new Row();
    row.setSpans("1, 2");
    row.appendChild(LayoutUtils.makeRightAlign(lDate));
    Div div = new Div();
    div.appendChild(fDateFrom);
    div.appendChild(fTimeFrom);
    fTimeFrom.setStyle("margin-left: 5px");
    row.appendChild(div);
    rows.appendChild(row);

    row = new Row();
    row.appendChild(LayoutUtils.makeRightAlign(lQty));
    row.appendChild(fQty);
    row.appendChild(lUOM);
    rows.appendChild(row);

    row = new Row();
    row.setSpans("1, 2");
    row.appendChild(LayoutUtils.makeRightAlign(lName));
    row.appendChild(fName);
    fName.setStyle("width: 100%");
    rows.appendChild(row);

    row = new Row();
    row.setSpans("1, 2");
    row.appendChild(LayoutUtils.makeRightAlign(lDescription));
    row.appendChild(fDescription);
    fDescription.setMultiline(true);
    fDescription.setRows(3);
    fDescription.setStyle("width: 100%");
    rows.appendChild(row);

    row = new Row();
    row.setSpans("3");
    row.appendChild(new Label(" "));
    rows.appendChild(row);

    row = new Row();
    row.setSpans("3");
    row.appendChild(confirmPanel);
    rows.appendChild(row);
    //
  } //	jbInit
Beispiel #2
0
  private void init() {
    Grid grid = new Grid();
    grid.setWidth("100%");
    grid.setHeight("100%");
    grid.setStyle("margin:0; padding:0; position: absolute; align: center; valign: center;");
    grid.makeNoStrip();
    grid.setOddRowSclass("even");

    Rows rows = new Rows();
    grid.appendChild(rows);

    Row row = new Row();
    rows.appendChild(row);
    Div div = new Div();
    div.setAlign("right");
    div.appendChild(lNode);
    row.appendChild(div);
    row.appendChild(fNode);
    fNode.setWidth("100%");
    fNode.setReadonly(true);

    row = new Row();
    rows.appendChild(row);
    row.setValign("top");
    div = new Div();
    div.setAlign("right");
    div.appendChild(lDesctiption);
    row.appendChild(div);
    row.appendChild(fDescription);
    fDescription.setMultiline(true);
    fDescription.setWidth("100%");
    fDescription.setReadonly(true);

    row = new Row();
    rows.appendChild(row);
    div = new Div();
    div.setAlign("right");
    div.appendChild(lHelp);
    row.appendChild(div);
    row.appendChild(fHelp);
    fHelp.setMultiline(true);
    fHelp.setWidth("100%");
    fHelp.setReadonly(true);
    fHelp.setRows(3);
    row.appendChild(new Label());

    row = new Row();
    rows.appendChild(row);
    div = new Div();
    div.setAlign("right");
    div.appendChild(lHistory);
    row.appendChild(div);
    row.appendChild(fHistory);
    row.appendChild(new Label());

    row = new Row();
    rows.appendChild(row);
    div = new Div();
    div.setAlign("right");
    div.appendChild(lAnswer);
    row.appendChild(div);
    Hbox hbox = new Hbox();
    hbox.appendChild(fAnswerText);
    hbox.appendChild(fAnswerList);
    hbox.appendChild(fAnswerButton);
    fAnswerButton.addEventListener(Events.ON_CLICK, this);
    row.appendChild(hbox);
    row.appendChild(bZoom);
    bZoom.addEventListener(Events.ON_CLICK, this);

    row = new Row();
    rows.appendChild(row);
    div = new Div();
    div.setAlign("right");
    div.appendChild(lTextMsg);
    row.appendChild(div);
    row.appendChild(fTextMsg);
    fTextMsg.setMultiline(true);
    fTextMsg.setWidth("100%");
    row.appendChild(new Label());

    row = new Row();
    rows.appendChild(row);
    div = new Div();
    div.setAlign("right");
    div.appendChild(lForward);
    row.appendChild(div);
    hbox = new Hbox();
    hbox.appendChild(fForward.getComponent());
    hbox.appendChild(lOptional);
    row.appendChild(hbox);
    row.appendChild(bOK);
    bOK.addEventListener(Events.ON_CLICK, this);

    Borderlayout layout = new Borderlayout();
    layout.setWidth("100%");
    layout.setHeight("100%");
    layout.setStyle("background-color: transparent; position: absolute;");

    North north = new North();
    north.appendChild(listbox);
    north.setSplittable(true);
    north.setFlex(true);
    north.setHeight("50%");
    layout.appendChild(north);
    north.setStyle("background-color: transparent");
    listbox.addEventListener(Events.ON_SELECT, this);

    Center center = new Center();
    center.appendChild(grid);
    layout.appendChild(center);
    center.setStyle("background-color: transparent");
    center.setFlex(true);

    South south = new South();
    south.appendChild(statusBar);
    layout.appendChild(south);
    south.setStyle("background-color: transparent");

    this.appendChild(layout);
    this.setStyle("height: 100%; width: 100%; position: absolute;");
  }