@Inject
  BudgetSiderView(
      Binder uiBinder,
      BudgetCell budgetCell,
      Resources resources,
      SiderListStyle siderListResources) {
    this.keyProvider = setupKeyProvider();
    this.dataProvider = new ListDataProvider<Budget>(keyProvider);

    budgetList = new CellList<Budget>(budgetCell, siderListResources);
    selectionModel = new SingleSelectionModel<Budget>(keyProvider);

    // Init The UI Binder
    initWidget(uiBinder.createAndBindUi(this));

    // Set up CSS Style Classes
    addNew.setStylePrimaryName(resources.buttonStyleCss().button());
    addNew.setStyleName(resources.buttonStyleCss().medium(), true);
    addNew.setStyleName(resources.buttonStyleCss().gray(), true);

    budgetList.setKeyboardSelectionPolicy(
        HasKeyboardSelectionPolicy.KeyboardSelectionPolicy.DISABLED);
    budgetList.setSelectionModel(selectionModel);
    dataProvider.addDataDisplay(budgetList);

    selectionModel.addSelectionChangeHandler(
        new SelectionChangeEvent.Handler() {
          @Override
          public void onSelectionChange(SelectionChangeEvent selectionChangeEvent) {
            getUiHandlers().budgetSelected(selectionModel.getSelectedObject());
          }
        });
  }
  // Helper method to make list of buttons on left side of View
  public void makeSideBar(HorizontalPanel hp) {
    VerticalPanel sidePanel = new VerticalPanel();
    hp.add(sidePanel);
    sidePanel.setSize("72px", "98px");

    Button postAdButton = new Button("Post Ad");
    postAdButton.setStyleName("sideBarButton");
    postAdButton.setText("Post Ad");
    // add a clickListener to the button
    postAdButton.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            viewPostAdForm();
          }
        });
    sidePanel.add(postAdButton);

    Button viewAdsButton = new Button("View Ads");
    viewAdsButton.setStyleName("sideBarButton");
    viewAdsButton.setText("View Ads");
    // add a clickListener to the button
    viewAdsButton.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            control.viewAdDataFromServer();
          }
        });
    sidePanel.add(viewAdsButton);

    Hyperlink adminHyperlink = new Hyperlink("Admin Page", false, "newHistoryToken");
    sidePanel.add(adminHyperlink);
  }
  public InputWidgetTypingQwerty(
      PacketProblem problem,
      AnswerView answerView,
      QuestionPanel questionPanel,
      LetterType letterType,
      SessionData sessionData) {
    super(problem, answerView, questionPanel, sessionData);
    this.letterType = letterType;

    setHorizontalAlignment(ALIGN_LEFT);
    for (int row = 0; row < LETTERS.length; ++row) {
      HorizontalPanel panel = new HorizontalPanel();

      HTML space = new HTML();
      space.setPixelSize(row * 20, 1);
      panel.add(space);

      String letters = LETTERS[row];
      for (int column = 0; column < letters.length(); ++column) {
        Button button = new Button(letters.substring(column, column + 1), this);
        button.setStyleName(STYLE_NAME_LETTER);
        panel.add(button);
        buttons.add(button);
      }

      if (row + 1 == LETTERS.length) {
        panel.add(buttonDelete);
        panel.add(buttonOk);
        buttonDelete.setStyleName(STYLE_NAME_CONTROL);
        buttonOk.setStyleName(STYLE_NAME_CONTROL);
      }

      add(panel);
    }
  }
  private Panel createButtons() {

    final HorizontalPanel panel = new HorizontalPanel();

    Button save = new Button("Save");
    save.setStyleName("button");
    save.addClickListener(
        new ClickListener() {

          public void onClick(Widget widget) {
            if (validateFormInput()) {
              createNote(inputNoteTitle.getText(), inputNoteText.getText());
              resetForm();
            }
          }
        });

    Button clear = new Button("Clear");
    save.setStyleName("button");
    clear.addClickListener(
        new ClickListener() {

          public void onClick(Widget widget) {
            resetForm();
          }
        });

    panel.add(save);
    panel.add(clear);

    return panel;
  }
Exemple #5
0
  private void createInputTableRowFor(FactPort factPort) {
    if (longExampleValues) {
      TextBox nameBox = CTextChangeHandler.createTextBox(factPort, "name");
      SuggestBox typeBox =
          CTextChangeHandler.createTypeSuggestBox(
              (ServiceDesigner) factPort.getServiceScreen().get("serviceDesigner"),
              factPort,
              "factType");
      TextArea exampleArea =
          CTextChangeHandler.createTextArea(factPort, "10cm", "8cm", "exampleValue");

      int inputNumRows = inputPortTable.getRowCount();
      inputPortTable.getRowFormatter().addStyleName(inputNumRows, "FindStyleForAlignTop");

      // add the text and suggest boxes
      inputPortTable.setWidget(inputNumRows, 0, nameBox);

      inputPortTable.setWidget(inputNumRows, 1, typeBox);
      inputPortTable.setWidget(inputNumRows, 2, exampleArea);
      // add remove button
      Button removePortButton = new Button("Remove precondition");
      removePortButton.setStyleName("fastButton");
      RemoveInputPortHandler inputPortHandler = new RemoveInputPortHandler();
      inputPortHandler.setFactPort(factPort);
      removePortButton.addClickHandler(inputPortHandler);

      inputPortTable.setWidget(inputNumRows, 3, removePortButton);

      // updateListener
      UpdateTransformationTabListener updateTabListener = new UpdateTransformationTabListener();
      factPort.addPropertyChangeListener("name", updateTabListener);
      factPort.addPropertyChangeListener("factType", updateTabListener);
      factPort.addPropertyChangeListener("exampleValue", updateTabListener);
    } else {
      TextBox nameBox = CTextChangeHandler.createTextBox(factPort, "name");
      SuggestBox typeBox =
          CTextChangeHandler.createTypeSuggestBox(
              (ServiceDesigner) factPort.getServiceScreen().get("serviceDesigner"),
              factPort,
              "factType");
      TextBox exampleBox = CTextChangeHandler.createTextBox(factPort, "exampleValue");

      int inputNumRows = inputPortTable.getRowCount();

      // add the text and suggest boxes
      inputPortTable.setWidget(inputNumRows, 0, nameBox);
      inputPortTable.setWidget(inputNumRows, 1, typeBox);
      inputPortTable.setWidget(inputNumRows, 2, exampleBox);

      // add remove button
      Button removePortButton = new Button("Remove precondition");
      removePortButton.setStyleName("fastButton");
      RemoveInputPortHandler inputPortHandler = new RemoveInputPortHandler();
      inputPortHandler.setFactPort(factPort);
      removePortButton.addClickHandler(inputPortHandler);
      inputPortTable.setWidget(inputNumRows, 3, removePortButton);
    }
  }
 @Override
 public void resetQuestionView() {
   openEndedQuestionText.setHTML("");
   hintsButton.setText(i18n.GL0667());
   hintsButton.getElement().setAttribute("alt", i18n.GL0667());
   hintsButton.getElement().setAttribute("title", i18n.GL0667());
   hintsButton.setStyleName(oeStyle.hintsActiveButton());
   explanaionButton.setStyleName(oeStyle.hintsActiveButton());
   explanationContainer.removeStyleName(oeStyle.explanationTextBorder());
   hintsContainer.clear();
   explanationContainer.clear();
   clearAnswerOptionsContainer();
   openEndedQuestionImage.getElement().removeAttribute("src");
 }
  public TransferElementPanel() {

    mainPnl = new FlowPanel();
    nodeList = new ArrayList<String>();
    container = new FlowPanel();
    container.setStyleName("trnsfrElmt-containerPnl");

    closeBtn = new Button();
    closeBtn.setStyleName("endpt-list-pnl-close-btn");

    HTMLPanel hdr = new HTMLPanel("Transfer Element");
    hdr.setStyleName("trnsfrElmnt-list-hdr");
    hdr.add(closeBtn);

    trnsfrElmntOkBtn = new SwitchButton("OK");
    trnsfrElmntOkBtn.setStyleName("priLvl-btn");
    FlowPanel btnPnl = new FlowPanel();
    btnPnl.setStyleName("trnsfrElem-btnPnl");
    btnPnl.add(trnsfrElmntOkBtn);

    nodeContainer = new FlowPanel();
    nodeContainer.setStyleName("node-wdgt-cntr");
    container.add(hdr);
    container.add(nodeContainer);
    container.add(btnPnl);

    mainPnl.setStyleName("endpt-list-pnl");
    mainPnl.add(container);
    // mainPnl.add(btnPnl);

    hide();

    initWidget(mainPnl);
  }
  public PainelPesquisarView() {
    hpPainelPesquisar = new HorizontalPanel();
    hpPainelPesquisar.setStyleName("hpPainelPesquisar");

    tbPesquisar = new TextBox();
    tbPesquisar.setStyleName("tbPesquisar");

    btnPesquisar = new Button("");
    btnPesquisar.setStyleName("btnPesquisar");

    hpPainelPesquisar.add(tbPesquisar);
    hpPainelPesquisar.add(btnPesquisar);
    hpPainelPesquisar.setCellWidth(tbPesquisar, "38%");

    hpPainelLabelContatos = new HorizontalPanel();
    hpPainelLabelContatos.setStyleName("hpPainelLabelContatos");

    lbContatos = new Label("Contatos");
    lbContatos.setStyleName("lbContatos");

    hpPainelLabelContatos.add(lbContatos);
    hpPainelLabelContatos.setHorizontalAlignment(VerticalPanel.ALIGN_CENTER);
    hpPainelLabelContatos.setVerticalAlignment(VerticalPanel.ALIGN_MIDDLE);

    vpPainelPesquisar = new VerticalPanel();
    vpPainelPesquisar.setStyleName("vpPainelPesquisar");

    vpPainelPesquisar.add(hpPainelPesquisar);
    vpPainelPesquisar.add(hpPainelLabelContatos);

    initWidget(vpPainelPesquisar);
  }
Exemple #9
0
  private void createOutputTableRowFor(FactPort factPort) {
    TextBox nameBox = CTextChangeHandler.createTextBox(factPort, "name");
    SuggestBox typeBox =
        CTextChangeHandler.createTypeSuggestBox(
            (ServiceDesigner) factPort.getServiceScreen2().get("serviceDesigner"),
            factPort,
            "factType");

    int outputNumRows = outputPortTable.getRowCount();

    // add the text and suggest boxes
    outputPortTable.setWidget(outputNumRows, 0, nameBox);
    outputPortTable.setWidget(outputNumRows, 1, typeBox);

    // add remove button
    Button removePortButton = new Button("Remove postcondition");
    removePortButton.setStyleName("fastButton");
    RemoveOutputPortHandler outputPortHandler = new RemoveOutputPortHandler();
    outputPortHandler.setFactPort(factPort);
    removePortButton.addClickHandler(outputPortHandler);
    outputPortTable.setWidget(outputNumRows, 3, removePortButton);

    // updateListener
    UpdateTransformationTabListener updateTabListener = new UpdateTransformationTabListener();
    factPort.addPropertyChangeListener("name", updateTabListener);
    factPort.addPropertyChangeListener("factType", updateTabListener);
  }
Exemple #10
0
 public static Button getButton(String text, String styleName) {
   Button b = new Button(text);
   if (null != styleName) {
     b.setStyleName(styleName);
   }
   b.setTitle(text);
   updateNameAndId(b, text.replaceAll(" ", ""));
   return b;
 }
 @UiHandler("explanaionButton")
 public void ClickOnExplanationButton(ClickEvent clickEvent) {
   if (explanaionButton.getStyleName().equals(oeStyle.hintsActiveButton())) {
     explanationContainer.add(getHTML(collectionItemDo.getResource().getExplanation()));
     explanationContainer.addStyleName(oeStyle.explanationTextBorder());
     explanaionButton.setStyleName(oeStyle.hintsInActiveButton());
     startExplanationDataLogEvent(collectionItemDo.getResource().getExplanation());
   }
 }
 private Button getTestButton() {
   final Button b = new Button("TEST");
   b.setStyleName("gwt-Button");
   b.addClickHandler(
       new ClickHandler() {
         @Override
         public void onClick(ClickEvent event) {}
       });
   return b;
 }
  public SettingsPageGenerated() {

    FlowPanel flowPanel = new FlowPanel();
    flowPanel.setStyleName("gwt-SettingsPage");
    initWidget(flowPanel);
    flowPanel.setSize("100%", "100%");

    FlowPanel flowPanel_1 = new FlowPanel();
    flowPanel.add(flowPanel_1);
    flowPanel_1.setStyleName("gwt-insidePanel");

    Label lblZmieHaso = new Label("Zmień hasło");
    flowPanel_1.add(lblZmieHaso);
    lblZmieHaso.setStyleName("gwt-GroupLabel");

    FlexTable flexTable = new FlexTable();
    flexTable.setStyleName("gwt-table");
    flowPanel_1.add(flexTable);

    Label lblStareHaso = new Label("STARE HASŁO");
    lblStareHaso.setStyleName("gwt-LabelCustom");
    flexTable.setWidget(0, 0, lblStareHaso);

    oldPassTextBox = new PasswordTextBox();
    flexTable.setWidget(0, 1, oldPassTextBox);

    Label lblNoweHaso = new Label("NOWE HASŁO");
    lblNoweHaso.setStyleName("gwt-LabelCustom");
    flexTable.setWidget(1, 0, lblNoweHaso);

    newPassTextBox = new PasswordTextBox();
    flexTable.setWidget(1, 1, newPassTextBox);

    Label lblPowtrzHaso = new Label("POWTÓRZ HASŁO");
    lblPowtrzHaso.setStyleName("gwt-LabelCustom");
    flexTable.setWidget(2, 0, lblPowtrzHaso);
    flexTable.getCellFormatter().setHorizontalAlignment(2, 0, HasHorizontalAlignment.ALIGN_RIGHT);
    flexTable.getCellFormatter().setHorizontalAlignment(1, 0, HasHorizontalAlignment.ALIGN_RIGHT);
    flexTable.getCellFormatter().setHorizontalAlignment(0, 0, HasHorizontalAlignment.ALIGN_RIGHT);

    newPassConfirmTextBox = new PasswordTextBox();
    flexTable.setWidget(2, 1, newPassConfirmTextBox);

    changePassButton = new Button("New button");
    changePassButton.setStyleName("gwt-ButtonCustom");
    changePassButton.setText("Zmień");
    flexTable.setWidget(3, 1, changePassButton);
    flexTable.getCellFormatter().setHorizontalAlignment(3, 1, HasHorizontalAlignment.ALIGN_RIGHT);

    errorLabel = new Label("");
    errorLabel.setStyleName("gwt-LabelErr");
    flowPanel_1.add(errorLabel);
  }
 @UiHandler("hintsButton")
 public void ClickOnHintButton(ClickEvent clickEvent) {
   if (hintsButton.getStyleName().equals(oeStyle.hintsActiveButton())) {
     if (collectionItemDo.getResource().getHints().size() > hintsLength) {
       startHintDataLogEvent(getQuestionHintsDo(hintsLength).getHintId());
       hintsContainer.add(
           getHTML(getQuestionHintsDo(hintsLength).getHintText(), oeStyle.hintsText()));
       hintsButton.setText(
           ""
               + i18n.GL0317()
               + " ("
               + ((collectionItemDo.getResource().getHints().size() - hintsLength) - 1)
               + " Left)");
       hintsButton
           .getElement()
           .setAttribute(
               "alt",
               " "
                   + i18n.GL0317()
                   + " ("
                   + collectionItemDo.getResource().getHints().size()
                   + " Left)");
       hintsButton
           .getElement()
           .setAttribute(
               "title",
               " "
                   + i18n.GL0317()
                   + " ("
                   + collectionItemDo.getResource().getHints().size()
                   + " Left)");
       hintsLength++;
       if (collectionItemDo.getResource().getHints().size() == hintsLength) {
         hintsButton.setStyleName(oeStyle.hintsInActiveButton());
       }
     } else {
       hintsButton.setStyleName(oeStyle.hintsInActiveButton());
     }
   }
 }
 private Button buildRemoveParameterButton(final HorizontalPanel entry) {
   Button remButton = new Button();
   remButton.setStyleName(removeParamButton.getStyleName());
   remButton.setHTML(removeParamButton.getHTML());
   remButton.addClickHandler(
       new ClickHandler() {
         public void onClick(ClickEvent event) {
           removeParameter(entry);
           enableSaveButton();
         }
       });
   return remButton;
 }
  private Widget createFooter() {
    Button applyButton = new Button(field.getApplyButtonLabel(), new ApplyClickHandler());
    applyButton.getElement().setId("applyButton");
    applyButton.setStyleName("goon-Button");
    applyButton.getElement().getStyle().setMarginTop(Widgets.defaultSpacing, Unit.PX);

    Button cancelButton = new Button("Abbrechen", new CancelClickHandler());
    cancelButton.getElement().setId("cancelButton");
    cancelButton.setStyleName("goon-Button");

    BuilderPanel buttonRow = new BuilderPanel().setHorizontal().setSpacing(0);

    buttonRow.setChildTextAlign(TextAlign.RIGHT);
    buttonRow.add(Widgets.horizontalSpacer());
    buttonRow.setChildWidth("1px");

    List<? extends IsWidget> additionalButtons = field.getAdditionalDialogButtons(this);
    buttonRow.addWithPadding(3, new Object[] {cancelButton});
    buttonRow.addWithPadding(3, new Object[] {additionalButtons});
    buttonRow.addWithPadding(3, new Object[] {applyButton});

    return buttonRow.asWidget();
  }
Exemple #17
0
  @SuppressWarnings("unchecked")
  public Widget createOutputPortTable() {
    VerticalPanel outputPanel = new VerticalPanel();

    Label hintLabel =
        new Label("Define the postcondtion where this resource will deliver results:");

    outputPanel.add(hintLabel);

    outputPortTable = new FlexTable();

    int numRows = outputPortTable.getRowCount();

    // Add new output port Button
    Button addOutputPortButton = new Button("Add postcondition");
    addOutputPortButton.setStyleName("fastButton");
    addOutputPortButton.addClickHandler(new AddNewOutputPortHandler());
    outputPortTable.setWidget(numRows, 0, addOutputPortButton);
    numRows++;

    // add output header row
    outputPortTable.setWidget(numRows, 0, new Label("Postcondition name"));
    outputPortTable.setWidget(numRows, 1, new Label("Postcondition type"));
    numRows++;

    // add rows for existing output fact ports
    Iterator<FactPort> iteratorOfPostconditions = buildingBlock.iteratorOfPostconditions();
    while (iteratorOfPostconditions.hasNext()) {
      FactPort factPort = iteratorOfPostconditions.next();

      // per fact port add one row with three text boxes for name, type, and example value
      createOutputTableRowFor(factPort);
    }

    if (longExampleValues) {
      // updateListener
      UpdateTransformationTabListener updateTabListener = new UpdateTransformationTabListener();
      buildingBlock.addPropertyChangeListener(
          BuildingBlock.PROPERTY_POSTCONDITIONS, updateTabListener);
    }

    // return the panel
    outputPortTable.ensureDebugId("cwFlexTable");

    outputPanel.add(outputPortTable);

    return outputPanel;
  }
  protected Button createStartProcessInstanceButton(
      final FormTerminationHandler formTerminationHandler) {
    final Button startInstanceButton =
        new Button(FormsResourceBundle.getMessages().caseStartButtonLabel());
    startInstanceButton.setStyleName("bonita_form_button");
    startInstanceButton.addClickHandler(
        new ClickHandler() {

          @Override
          public void onClick(final ClickEvent event) {
            startInstanceButton.setEnabled(false);
            formsServiceAsync.skipForm(formID, urlContext, formTerminationHandler);
          }
        });
    return startInstanceButton;
  }
  public void addText(String TextoBoton) {

    //		if (!TextoBoton.isEmpty()
    //				&& TextoBoton.length() > 2) {
    Button btnNewButton_1 = new Button("<img src=\"Users.gif\">" + TextoBoton);
    btnNewButton_1.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            Button sourceB = ((Button) event.getSource());
            verticalPanel_1.remove(sourceB);
            if (verticalPanel_1.getWidgetCount() == 0) SaveNewUsers.setVisible(false);
          }
        });
    btnNewButton_1.addMouseDownHandler(
        new MouseDownHandler() {
          public void onMouseDown(MouseDownEvent event) {
            ((Button) event.getSource()).setStyleName("gwt-ButtonPush");
          }
        });
    btnNewButton_1.addMouseOutHandler(
        new MouseOutHandler() {
          public void onMouseOut(MouseOutEvent event) {
            ((Button) event.getSource()).setStyleName("gwt-ButtonTOP");
          }
        });
    btnNewButton_1.addMouseOverHandler(
        new MouseOverHandler() {
          public void onMouseOver(MouseOverEvent event) {
            ((Button) event.getSource()).setStyleName("gwt-ButtonTOPOver");
          }
        });
    btnNewButton_1.setStyleName("gwt-ButtonTOP");
    btnNewButton_1.setText(TextoBoton);
    btnNewButton_1.setHTML("<img src=\"Users.gif\">" + TextoBoton);
    verticalPanel_1.add(btnNewButton_1);
    btnNewButton_1.setSize("100%", "100%");
    SaveNewUsers.setVisible(true);
    //		} else
    //			Window.alert("The User need to be a valid reference");
  }
  public ChangePriorityLvlPanel() {

    closeBtn = new Button();
    closeBtn.setStyleName("endpt-list-pnl-close-btn");

    HTMLPanel hdr = new HTMLPanel("Change Priority Level");
    hdr.setStyleName("endpt-list-hdr");
    hdr.add(closeBtn);

    container = new FlowPanel();

    container.add(hdr);

    priLvlCntnrWdgt = new FlowPanel();
    priLvlCntnrWdgt.setStyleName("priLvl-wdgt-cntr");

    buildPriLvlPnls();

    container.add(priLvlCntnrWdgt);

    priLvlBtnCntr = new FlowPanel();
    priLvlBtnCntr.setStyleName("priLvl-btn-pnl");

    prilvlBtn = new SwitchButton("OK");
    prilvlBtn.setStyleName("priLvl-btn");

    priLvlBtnCntr.add(prilvlBtn);

    container.add(priLvlBtnCntr);

    mainPnl = new FlowPanel();

    mainPnl.setStyleName("endpt-list-pnl");
    mainPnl.add(container);

    hide();

    initWidget(mainPnl);
  }
  public LikeListe(ArrayList<Like> likeListe) {

    /** Label f�r eine kurze Information �ber das DialogFenster */
    LabelInformation = new Label("Nutzer, denen das gefaellt:");
    LabelInformation.setStyleName("LabelInformation");

    /** FlexTable f�r darstellung der Nutzer */
    FlexTableLikeListe = new FlexTable();
    FlexTableLikeListe.setStyleName("FlexTableLikeListe");

    // Durchlauf durch die LikeListe welche als Paramenter im Konstruktor �bergeben wurde. Jeder
    // Nutzer wird in einer row hinzugef�gt.
    for (int i = 0; i < likeListe.size(); i++) {
      FlexTableLikeListe.setHTML(
          i,
          0,
          likeListe.get(i).getNutzer().getVorname() + " " + likeListe.get(i).getNutzer().getName());
    }

    /** Button mit Hilfe man die DialogBox wieder schlie�en kann */
    ButtonSchliessen = new Button("Schlie&szligen");
    ButtonSchliessen.setStyleName("ButtonSchliessen");
    ButtonSchliessen.addClickHandler(
        new ClickHandler() {

          public void onClick(ClickEvent event) {
            hide();
          }
        });

    /** DockPanel welches die zuvor initialisierten Elemente B�ndelt */
    DockPanel dock = new DockPanel();
    dock.setSpacing(4);
    dock.add(LabelInformation, DockPanel.NORTH);
    dock.add(FlexTableLikeListe, DockPanel.NORTH);
    dock.add(ButtonSchliessen, DockPanel.NORTH);
    dock.setWidth("100%");
    setWidget(dock);
  }
Exemple #22
0
  private Widget makeWordSearch() {
    // Make some radio buttons, all in one group.
    final RadioButton standardRadio = new RadioButton("tipPretrage", "Standardna riječ");
    RadioButton dialectRadio = new RadioButton("tipPretrage", "Dijalektna riječ");
    dialectRadio.setValue(true);

    FlowPanel form = new FlowPanel();
    form.setStyleName("form-search");

    FlowPanel innerForm = new FlowPanel();
    innerForm.setStyleName("inner-form-search");

    HorizontalPanel hp = new HorizontalPanel();
    Label lblRijec = new Label("Riječ:");
    lblRijec.setStyleName("form-label");
    hp.add(lblRijec);
    rijec = new TextBox();
    rijec.setStyleName("search-query");
    hp.setVerticalAlignment(HorizontalPanel.ALIGN_MIDDLE);
    hp.setHorizontalAlignment(HorizontalPanel.ALIGN_CENTER);
    hp.add(rijec);
    innerForm.add(hp);

    HorizontalPanel hpMisto = new HorizontalPanel();
    Label lblMisto = new Label("Lokacija:");
    lblMisto.setStyleName("form-label");
    hpMisto.setVerticalAlignment(HorizontalPanel.ALIGN_MIDDLE);
    hpMisto.add(lblMisto);
    misto = new TextBox();
    misto.setStyleName("search-query");
    hpMisto.add(misto);
    innerForm.add(hpMisto);

    form.add(innerForm);

    FlowPanel panel = new FlowPanel();
    panel.setStyleName("form-search");
    panel.add(standardRadio);
    panel.add(dialectRadio);
    panel.add(form);

    FlowPanel op = new FlowPanel();
    op.setStyleName("kontrole");
    Button searchBtn =
        new Button(
            "Traži",
            new ClickHandler() {

              @Override
              public void onClick(ClickEvent event) {
                bartInstance.table.setRowCount(0);
                if (standardRadio.getValue()) {
                  bartInstance.searchWord(rijec.getText(), 0, misto.getText());
                } else {
                  bartInstance.searchDialectWord(rijec.getText(), 0, misto.getText());
                }

                hide();
              }
            });
    op.add(searchBtn);
    Button closeBtn =
        new Button(
            "Odustani",
            new ClickHandler() {

              @Override
              public void onClick(ClickEvent event) {
                hide();
              }
            });
    op.add(closeBtn);

    searchBtn.setStyleName("btn btn-primary btn-large padded-right");
    closeBtn.setStyleName("btn btn-primary btn-large");

    panel.add(op);

    return panel;
  }
 private void init() {
   sidebar_collapse.setStyleName("btn btn-default");
   sidebar_collapseIcon.setAttribute("class", "fa fa-angle-left");
 }
  public ScheduleEditor(ScheduleDialogType type) {
    super();
    isBlockoutDialog = (type == ScheduleDialogType.BLOCKOUT);
    startTimePicker = new TimePicker();

    setStylePrimaryName("scheduleEditor"); // $NON-NLS-1$

    scheduleCombo = createScheduleCombo();
    Label l = new Label(MSGS.recurrenceColon());
    l.setStyleName(SCHEDULE_LABEL);
    add(l);
    add(scheduleCombo);

    SimplePanel hspacer = new SimplePanel();
    hspacer.setWidth("100px"); // $NON-NLS-1$

    if (!isBlockoutDialog) {
      startTimePanel = createStartTimePanel();
      add(startTimePanel);
    } else {

      // Blockout End TimePicker
      blockoutEndTimePicker = new TimePicker();
      blockoutEndTimePicker.setHour("01"); // $NON-NLS-1$
      blockoutEndTimePicker.setMinute("00"); // $NON-NLS-1$
      blockoutEndTimePicker.setTimeOfDay(TimeUtil.TimeOfDay.PM);

      // Blockout End Caption Panel
      blockoutEndTimePicker.getElement().getStyle().setDisplay(Display.NONE);

      final String[] daysList = new String[365];
      final String[] hoursList = new String[24];
      final String[] minutesList = new String[60];

      // Populate list
      for (Integer i = 0; i < 365; i++) {
        String iStr = i.toString();
        daysList[i] = iStr;

        if (i < 60) {
          minutesList[i] = iStr;
          if (i < 24) {
            hoursList[i] = iStr;
          }
        }
      }

      // Units of time Drop Down
      daysListBox = new ListBox();
      daysListBox.getElement().setId("daysListBox"); // $NON-NLS-1$
      populateListItems(daysListBox, daysList, 0, 365);

      final Label daysLabel = new Label(MSGS.dayOrDays());
      daysLabel.getElement().setAttribute("for", daysListBox.getElement().getId()); // $NON-NLS-1$

      hoursListBox = new ListBox();
      hoursListBox.getElement().setId("hoursListBox"); // $NON-NLS-1$
      populateListItems(hoursListBox, hoursList, 0, 24);

      final Label hoursLabel = new Label(MSGS.hourOrHours());
      hoursLabel.getElement().setAttribute("for", hoursListBox.getElement().getId()); // $NON-NLS-1$

      minutesListBox = new ListBox();
      minutesListBox.getElement().setId("minutesListBox"); // $NON-NLS-1$
      populateListItems(minutesListBox, minutesList, 0, 60);

      final Label minutesLabel = new Label(MSGS.minuteOrMinutes());
      minutesLabel
          .getElement()
          .setAttribute("for", minutesListBox.getElement().getId()); // $NON-NLS-1$

      final HorizontalPanel durationPanel = new HorizontalPanel();
      durationPanel.setVerticalAlignment(VerticalPanel.ALIGN_MIDDLE);
      durationPanel.setSpacing(blockoutEndTimePicker.getSpacing());
      durationPanel.add(daysListBox);
      durationPanel.add(daysLabel);
      durationPanel.add(hoursListBox);
      durationPanel.add(hoursLabel);
      durationPanel.add(minutesListBox);
      durationPanel.add(minutesLabel);

      // Bind change handler
      this.scheduleCombo.addChangeHandler(
          new ChangeHandler() {

            @Override
            public void onChange(ChangeEvent event) {
              String scheduleType = scheduleCombo.getItemText(scheduleCombo.getSelectedIndex());

              if (ScheduleType.RUN_ONCE.toString().equals(scheduleType)) {
                show(
                    true,
                    daysListBox,
                    daysLabel,
                    hoursListBox,
                    hoursLabel,
                    minutesListBox,
                    minutesLabel);

                populateListItems(daysListBox, daysList, 0, 365);
                populateListItems(hoursListBox, hoursList, 0, 24);
                populateListItems(minutesListBox, minutesList, 0, 60);

              } else if (ScheduleType.HOURS.toString().equals(scheduleType)) {
                hide(true, daysListBox, daysLabel, hoursListBox, hoursLabel);
                show(true, minutesListBox, minutesLabel);

                populateListItems(minutesListBox, minutesList, 0, 60);

              } else if (ScheduleType.DAILY.toString().equals(scheduleType)) {
                hide(true, daysListBox, daysLabel);
                show(true, hoursListBox, hoursLabel, minutesListBox, minutesLabel);

                populateListItems(hoursListBox, hoursList, 0, 24);
                populateListItems(minutesListBox, minutesList, 0, 60);

              } else if (ScheduleType.WEEKLY.toString().equals(scheduleType)) {
                show(
                    true,
                    daysListBox,
                    daysLabel,
                    hoursListBox,
                    hoursLabel,
                    minutesListBox,
                    minutesLabel);

                populateListItems(daysListBox, daysList, 0, 7);
                populateListItems(hoursListBox, hoursList, 0, 24);
                populateListItems(minutesListBox, minutesList, 0, 60);

              } else if (ScheduleType.MONTHLY.toString().equals(scheduleType)) {
                show(
                    true,
                    daysListBox,
                    daysLabel,
                    hoursListBox,
                    hoursLabel,
                    minutesListBox,
                    minutesLabel);

                populateListItems(daysListBox, daysList, 0, 28);
                populateListItems(hoursListBox, hoursList, 0, 24);
                populateListItems(minutesListBox, minutesList, 0, 60);

              } else if (ScheduleType.YEARLY.toString().equals(scheduleType)) {
                show(
                    true,
                    daysListBox,
                    daysLabel,
                    hoursListBox,
                    hoursLabel,
                    minutesListBox,
                    minutesLabel);

                populateListItems(daysListBox, daysList, 0, 365);
                populateListItems(hoursListBox, hoursList, 0, 24);
                populateListItems(minutesListBox, minutesList, 0, 60);
              }
            }
          });

      /*
       * Radio Buttons for duration
       */
      this.durationRadioButton =
          new RadioButton("durationRadioGroup", "durationRadioButton"); // $NON-NLS-1$ //$NON-NLS-2$
      this.durationRadioButton.setText(MSGS.duration());
      this.durationRadioButton.setValue(Boolean.TRUE);
      this.durationRadioButton.addClickHandler(
          new ClickHandler() {

            @Override
            public void onClick(ClickEvent event) {
              blockoutEndTimePicker.getElement().getStyle().setDisplay(Display.NONE);
              durationPanel.getElement().getStyle().clearDisplay();
            }
          });

      this.endTimeRadioButton =
          new RadioButton("durationRadioGroup", "endTimeRadioButton"); // $NON-NLS-1$ //$NON-NLS-2$
      this.endTimeRadioButton.setText(MSGS.endTime());
      this.endTimeRadioButton.addClickHandler(
          new ClickHandler() {

            @Override
            public void onClick(ClickEvent event) {
              blockoutEndTimePicker.getElement().getStyle().clearDisplay();
              durationPanel.getElement().getStyle().setDisplay(Display.NONE);
            }
          });

      // Radio Buttons Panel
      HorizontalPanel radioButtonsPanel = new HorizontalPanel();
      radioButtonsPanel.setVerticalAlignment(VerticalPanel.ALIGN_MIDDLE);
      radioButtonsPanel.add(this.durationRadioButton);
      radioButtonsPanel.add(this.endTimeRadioButton);

      // Ends Panel
      VerticalPanel endsPanel = new VerticalPanel();
      endsPanel.add(radioButtonsPanel);
      endsPanel.add(blockoutEndTimePicker);
      endsPanel.add(durationPanel);

      // Blockout period
      CaptionPanel blockoutStartCaptionPanel = new CaptionPanel(MSGS.startTime());
      HorizontalPanel blockoutStartPanel = new HorizontalPanel();
      blockoutStartPanel.add(getStartTimePicker());
      timeZonePicker = new ListBox();
      timeZonePicker.setStyleName("timeZonePicker");
      timeZonePicker.setVisibleItemCount(1);
      blockoutStartPanel.add(timeZonePicker);
      timeZonePicker.getElement().getParentElement().getStyle().setPaddingTop(5, Unit.PX);

      blockoutStartCaptionPanel.add(blockoutStartPanel);
      populateTimeZonePicker();

      // Ends Caption Panel
      CaptionPanel endCaptionPanel = new CaptionPanel(MSGS.endsCaptionTitle());
      endCaptionPanel.add(endsPanel);

      VerticalPanel blockoutPanel = new VerticalPanel();
      blockoutPanel.setWidth("100%"); // $NON-NLS-1$
      blockoutPanel.add(blockoutStartCaptionPanel);
      blockoutPanel.add(endCaptionPanel);

      add(blockoutPanel);
    }

    VerticalPanel vp = new VerticalPanel();
    vp.setWidth("100%"); // $NON-NLS-1$
    add(vp);
    setCellHeight(vp, "100%"); // $NON-NLS-1$

    runOnceEditor = new RunOnceEditor(startTimePicker);
    vp.add(runOnceEditor);
    scheduleTypeMap.put(ScheduleType.RUN_ONCE, runOnceEditor);
    runOnceEditor.setVisible(true);

    recurrenceEditor = new RecurrenceEditor(startTimePicker);
    vp.add(recurrenceEditor);
    scheduleTypeMap.put(ScheduleType.SECONDS, recurrenceEditor);
    scheduleTypeMap.put(ScheduleType.MINUTES, recurrenceEditor);
    scheduleTypeMap.put(ScheduleType.HOURS, recurrenceEditor);
    scheduleTypeMap.put(ScheduleType.DAILY, recurrenceEditor);
    scheduleTypeMap.put(ScheduleType.WEEKLY, recurrenceEditor);
    scheduleTypeMap.put(ScheduleType.MONTHLY, recurrenceEditor);
    scheduleTypeMap.put(ScheduleType.YEARLY, recurrenceEditor);
    recurrenceEditor.setVisible(false);

    cronEditor = new CronEditor();
    scheduleTypeMap.put(ScheduleType.CRON, cronEditor);
    cronEditor.setVisible(false);

    if (!isBlockoutDialog) {
      vp.add(cronEditor);

      VerticalPanel blockoutButtonPanel = new VerticalPanel();
      blockoutButtonPanel.setWidth("100%"); // $NON-NLS-1$
      // blockoutButtonPanel.setHeight("30%");
      blockoutButtonPanel.setHorizontalAlignment(VerticalPanel.ALIGN_CENTER);
      blockoutButtonPanel.setVerticalAlignment(VerticalPanel.ALIGN_MIDDLE);

      // We want to add a button to check for blockout conflicts
      blockoutCheckButton.setStyleName("pentaho-button"); // $NON-NLS-1$
      blockoutCheckButton.getElement().setId("blockout-check-button"); // $NON-NLS-1$
      blockoutCheckButton.setVisible(false);

      hspacer.setHeight("50px"); // $NON-NLS-1$
      blockoutButtonPanel.add(hspacer);
      blockoutButtonPanel.add(blockoutCheckButton);

      vp.add(hspacer);
      add(blockoutButtonPanel);
    }

    configureOnChangeHandler();
  }
  public iCalCalendarPanel() {

    // style this element as absolute position
    DOM.setStyleAttribute(this.getElement(), "position", "absolute");
    DOM.setStyleAttribute(this.getElement(), "top", "0px");
    DOM.setStyleAttribute(this.getElement(), "left", "0px");
    DOM.setStyleAttribute(this.getElement(), "padding", "0px");

    DOM.setStyleAttribute(DOM.getElementById("messageBox"), "display", "none");

    mainLayoutPanel.setWidth("100%");
    add(mainLayoutPanel);

    // add header
    headerPanel.setStyleName("gwt-cal-HeaderPanel");
    DOM.setInnerHTML(headerPanel.getElement(), "&nbsp;");
    footerPanel.setStyleName("gwt-cal-FooterPanel");
    DOM.setInnerHTML(headerPanel.getElement(), "&nbsp;");
    mainLayoutPanel.add(headerPanel, DockPanel.NORTH);
    mainLayoutPanel.add(footerPanel, DockPanel.SOUTH);

    // add left panel
    datePicker.setValue(new Date());
    dateLayoutPanel.add(datePicker, DockPanel.SOUTH);
    dateLayoutPanel.add(splitterPanel, DockPanel.SOUTH);
    splitterPanel.setStyleName("splitter");
    mainLayoutPanel.add(dateLayoutPanel, DockPanel.WEST);

    // CalendarFormat.INSTANCE.setFirstDayOfWeek(1);

    // change hour offset to false to facilitate iCal style
    settings.setOffsetHourLabels(true);
    settings.setTimeBlockClickNumber(Click.Double);
    // create day view
    calendar = new Calendar();
    calendar.setSettings(settings);
    // set style as google-cal
    calendar.setWidth("100%");
    // set today as default date
    mainLayoutPanel.add(calendar, DockPanel.CENTER);
    mainLayoutPanel.setCellVerticalAlignment(dateLayoutPanel, HasAlignment.ALIGN_BOTTOM);
    dateLayoutPanel.setCellVerticalAlignment(datePicker, HasAlignment.ALIGN_BOTTOM);
    dateLayoutPanel.setWidth("168px");

    // add today button
    todayButton.setStyleName("todayButton");
    todayButton.setText("Today");
    todayButton.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            datePicker.setValue(new Date(), true);
            // dayView.setDate(new Date());
          }
        });
    previousDayButton.setStyleName("previousButton");
    previousDayButton.setHTML("&laquo;");
    previousDayButton.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            Date d = datePicker.getValue();
            d.setDate(d.getDate() - 1);
            datePicker.setValue(d, true);
          }
        });
    nextDayButton.setStyleName("nextButton");
    nextDayButton.setHTML("&raquo;");
    nextDayButton.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            Date d = datePicker.getValue();
            d.setDate(d.getDate() + 1);
            datePicker.setValue(d, true);
          }
        });
    headerPanelLayout.setWidget(0, 0, todayButton);
    headerPanelLayout.setWidget(0, 1, previousDayButton);

    oneDayButton.setText("1 Day");
    oneDayButton.setStyleName("dayButton");
    threeDayButton.setText("3 Day");
    threeDayButton.setStyleName("dayButton");
    threeDayButton.addStyleName("active");
    activeDayButton = threeDayButton;
    weekDayButton.setText("Work Week");
    weekDayButton.setStyleName("dayButton");
    monthButton.setText("Month");
    monthButton.setStyleName("dayButton");
    headerPanelLayout.setWidget(0, 2, oneDayButton);
    headerPanelLayout.setWidget(0, 3, threeDayButton);
    headerPanelLayout.setWidget(0, 4, weekDayButton);
    headerPanelLayout.setWidget(0, 5, monthButton);
    headerPanelLayout.setWidget(0, 6, nextDayButton);
    headerPanelLayout.setHTML(0, 7, "&nbsp;");

    headerPanelLayout.getCellFormatter().setWidth(0, 0, "50%");
    headerPanelLayout.getCellFormatter().setWidth(0, 7, "50%");

    headerPanelLayout.setWidth("100%");
    headerPanelLayout.setCellPadding(0);
    headerPanelLayout.setCellSpacing(0);
    headerPanel.add(headerPanelLayout);

    footerPanel.add(
        new HTML(
            "<a href='http://code.google.com/p/gwt-cal'>gwt-cal</a> widget for Google Web Toolkit, GPLv3, by <a href='http://www.google.com/profiles/Brad.Rydzewski'>Brad Rydzewski</a>"));

    oneDayButton.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            activeDayButton.removeStyleName("active");
            activeDayButton = oneDayButton;
            activeDayButton.addStyleName("active");
            calendar.setView(CalendarViews.DAY, 1);
            // calendar.scrollToHour(6);
          }
        });
    threeDayButton.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            activeDayButton.removeStyleName("active");
            activeDayButton = threeDayButton;
            activeDayButton.addStyleName("active");
            calendar.setView(CalendarViews.DAY, 3);
            // calendar.scrollToHour(6);
          }
        });
    weekDayButton.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            activeDayButton.removeStyleName("active");
            activeDayButton = weekDayButton;
            activeDayButton.addStyleName("active");
            calendar.setView(CalendarViews.DAY, 5);
            // calendar.scrollToHour(6);
          }
        });
    monthButton.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            activeDayButton.removeStyleName("active");
            activeDayButton = monthButton;
            activeDayButton.addStyleName("active");
            calendar.setView(CalendarViews.MONTH);
          }
        });

    datePicker.addValueChangeHandler(
        new ValueChangeHandler<Date>() {
          public void onValueChange(ValueChangeEvent<Date> event) {
            calendar.setDate(event.getValue());
          }
        });
    calendar.addDeleteHandler(
        new DeleteHandler<Appointment>() {
          public void onDelete(DeleteEvent<Appointment> event) {
            boolean commit =
                Window.confirm(
                    "Are you sure you want to delete appointment \""
                        + event.getTarget().getTitle()
                        + "\"");
            if (commit == false) {
              event.setCancelled(true);
              System.out.println("cancelled appointment deletion");
            }
          }
        });
    calendar.addOpenHandler(
        new OpenHandler<Appointment>() {
          public void onOpen(OpenEvent<Appointment> event) {
            Window.alert("You double-clicked appointment \"" + event.getTarget().getTitle() + "\"");
          }
        });

    calendar.addSelectionHandler(
        new SelectionHandler<Appointment>() {
          public void onSelection(SelectionEvent<Appointment> event) {
            System.out.println("selected " + event.getSelectedItem().getTitle());
          }
        });

    calendar.addTimeBlockClickHandler(
        new TimeBlockClickHandler<Date>() {
          public void onTimeBlockClick(TimeBlockClickEvent<Date> event) {
            Window.alert("you clicked time block " + event.getTarget());
          }
        });

    /* Generate random appointments */
    AppointmentBuilder.appointmentsPerDay = 5;
    AppointmentBuilder.HOURS = new Integer[] {7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19};
    AppointmentBuilder.MINUTES = new Integer[] {0, 30};
    AppointmentBuilder.DURATIONS = new Integer[] {60, 90, 120, 180, 240, 600};
    AppointmentBuilder.DESCRIPTIONS[1] = "Best show on TV!";

    ArrayList<Appointment> appointments = AppointmentBuilder.build(AppointmentBuilder.ICAL_STYLES);
    /* Add appointments to day view */
    calendar.suspendLayout();
    calendar.addAppointments(appointments);

    calendar.resumeLayout();

    // window events to handle resizing
    Window.enableScrolling(false);
    Window.addResizeHandler(
        new ResizeHandler() {
          public void onResize(ResizeEvent event) {
            int h = event.getHeight();
            calendar.setHeight(
                h - headerPanel.getOffsetHeight() - footerPanel.getOffsetHeight() + "px");
          }
        });
    Scheduler.get()
        .scheduleDeferred(
            new ScheduledCommand() {
              public void execute() {
                calendar.setHeight(
                    Window.getClientHeight()
                        - headerPanel.getOffsetHeight()
                        - footerPanel.getOffsetHeight()
                        + "px");
                calendar.scrollToHour(6);
              }
            });
  }
Exemple #26
0
  /** SearchControl */
  public SearchControl() {
    table = new FlexTable();
    table.setCellPadding(2);
    table.setCellSpacing(2);
    scrollPanel = new ScrollPanel(table);
    advancedView = new CheckBox(Main.i18n("search.view.advanced"));
    advancedView.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            if (advancedView.getValue()) {
              clean();
              switchSearchMode(SEARCH_MODE_ADVANCED);
            } else {
              clean();
              switchSearchMode(SEARCH_MODE_SIMPLE);
            }
          }
        });
    compactResultsView = new CheckBox(Main.i18n("search.view.compact.results"));
    compactResultsView.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            if (compactResultsView.getValue()) {
              switchResultsViewMode(RESULTS_VIEW_COMPACT);
              table.getCellFormatter().setVisible(2, 0, false); // hide view property groups
            } else {
              switchResultsViewMode(RESULTS_VIEW_NORMAL);
              table.getCellFormatter().setVisible(2, 0, true); // show view property groups
            }
          }
        });
    showPropertyGroups = new CheckBox(Main.i18n("search.view.propety.groups"));
    showPropertyGroups.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            if (searchButton.isEnabled()) {
              executeSearch();
            }
          }
        });
    saveUserNews = new CheckBox(Main.i18n("search.save.as.news"));
    searchSavedName = new TextBox();
    searchSavedName.setWidth("200");
    controlSearch = new ControlSearchIn();
    resultPage = new ListBox();
    resultPage.addItem("10", "10");
    resultPage.addItem("20", "20");
    resultPage.addItem("30", "30");
    resultPage.addItem("50", "50");
    resultPage.addItem("100", "100");

    keyUpHandler =
        new KeyUpHandler() {
          @Override
          public void onKeyUp(KeyUpEvent event) {
            evaluateSearchButtonVisible();

            if (KeyCodes.KEY_ENTER == event.getNativeKeyCode() && searchButton.isEnabled()) {
              executeSearch();
            }
          }
        };

    searchButton =
        new Button(
            Main.i18n("button.search"),
            new ClickHandler() {
              @Override
              public void onClick(ClickEvent event) {
                executeSearch();
              }
            });

    cleanButton =
        new Button(
            Main.i18n("button.clean"),
            new ClickHandler() {
              @Override
              public void onClick(ClickEvent event) {
                clean();
              }
            });

    saveSearchButton =
        new Button(
            Main.i18n("button.save.search"),
            new ClickHandler() {
              @Override
              public void onClick(ClickEvent event) {
                long domain = 0;
                SearchNormal searchNormal =
                    Main.get().mainPanel.search.searchBrowser.searchIn.searchNormal;
                SearchAdvanced searchAdvanced =
                    Main.get().mainPanel.search.searchBrowser.searchIn.searchAdvanced;
                String operator = GWTQueryParams.OPERATOR_AND;
                params = new GWTQueryParams();

                if (!searchAdvanced.path.getText().equals("")) {
                  params.setPath(searchAdvanced.path.getText());
                } else {
                  params.setPath(
                      searchNormal.context.getValue(searchNormal.context.getSelectedIndex()));
                }

                if (!searchAdvanced.categoryUuid.equals("")) {
                  params.setCategoryUuid(searchAdvanced.categoryUuid);
                  params.setCategoryPath(
                      searchAdvanced.categoryPath.getText().substring(16)); // removes /okm:category
                }

                params.setContent(searchNormal.content.getText());
                params.setName(searchNormal.name.getText());
                params.setKeywords(searchNormal.keywords.getText());
                params.setProperties(
                    Main.get().mainPanel.search.searchBrowser.searchIn.getProperties());
                params.setAuthor(
                    searchNormal.userListBox.getValue(searchNormal.userListBox.getSelectedIndex()));
                params.setLastModifiedFrom(searchNormal.modifyDateFrom);
                params.setLastModifiedTo(searchNormal.modifyDateTo);
                params.setDashboard(saveUserNews.getValue());
                params.setMailFrom(searchAdvanced.from.getText());
                params.setMailTo(searchAdvanced.to.getText());
                params.setMailSubject(searchAdvanced.subject.getText());

                if (searchAdvanced.typeDocument.getValue()) {
                  domain += GWTQueryParams.DOCUMENT;
                }

                if (searchAdvanced.typeFolder.getValue()) {
                  domain += GWTQueryParams.FOLDER;
                }

                if (searchAdvanced.typeMail.getValue()) {
                  domain += GWTQueryParams.MAIL;
                }

                params.setDomain(domain);

                if (searchTypeAnd.getValue()) {
                  operator = GWTQueryParams.OPERATOR_AND;
                } else {
                  operator = GWTQueryParams.OPERATOR_OR;
                }

                params.setOperator(operator);

                // Removes dates if dashboard is checked
                if (saveUserNews.getValue()) {
                  params.setLastModifiedFrom(null);
                  params.setLastModifiedTo(null);
                }

                params.setMimeType(
                    searchAdvanced.mimeTypes.getValue(searchAdvanced.mimeTypes.getSelectedIndex()));

                if (!searchSavedName.getText().equals("")) {
                  saveSearchButton.setEnabled(false);
                  params.setQueryName(searchSavedName.getText());
                  isUserNews = params.isDashboard();
                  saveSearch(params, "sql");
                }
              }
            });

    searchSavedName.addKeyUpHandler(
        new KeyUpHandler() {
          @Override
          public void onKeyUp(KeyUpEvent event) {
            evalueSaveSearchButtonVisible();
          }
        });

    searchButton.setEnabled(false);
    saveSearchButton.setEnabled(false);

    // Type of search
    searchTypePanel = new HorizontalPanel();
    searchTypePanel.setVisible(true); // On OpenKM 4.0 has hidden AND / OR option list
    searchTypeAnd = new CheckBox("AND");
    searchTypeOr = new CheckBox("OR");
    searchTypeAnd.setValue(true);
    searchTypeOr.setValue(false);

    searchTypeAnd.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            searchTypeOr.setValue(
                !searchTypeAnd.getValue()); // Always set changed between and and or type
          }
        });

    searchTypeOr.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            searchTypeAnd.setValue(
                !searchTypeOr.getValue()); // Always set changed between and and or type
          }
        });

    HTML space1 = new HTML("");
    searchTypePanel.add(searchTypeAnd);
    searchTypePanel.add(space1);
    searchTypePanel.add(searchTypeOr);
    searchTypePanel.setCellWidth(space1, "10");

    table.setWidget(0, 0, advancedView);
    table.setWidget(1, 0, compactResultsView);
    table.setWidget(2, 0, showPropertyGroups);
    table.setWidget(3, 0, saveUserNews);
    table.setWidget(4, 0, saveSearchButton);
    table.setWidget(4, 1, searchSavedName);

    resultsPageText = new HTML(Main.i18n("search.page.results"));
    table.setWidget(5, 0, resultsPageText);
    table.setWidget(5, 1, resultPage);

    searchTypeText = new HTML(Main.i18n("search.type"));
    table.setHTML(6, 0, Main.i18n("search.type"));
    table.setWidget(6, 1, searchTypePanel);

    table.setWidget(6, 0, cleanButton);
    table.setWidget(6, 1, searchButton);

    table.setWidget(7, 0, controlSearch);

    table.getCellFormatter().setHorizontalAlignment(4, 0, HasAlignment.ALIGN_RIGHT);
    table.getCellFormatter().setHorizontalAlignment(5, 0, HasAlignment.ALIGN_RIGHT);
    table.getCellFormatter().setHorizontalAlignment(6, 0, HasAlignment.ALIGN_RIGHT);
    table.getFlexCellFormatter().setColSpan(0, 0, 2);
    table.getFlexCellFormatter().setColSpan(1, 0, 2);
    table.getFlexCellFormatter().setColSpan(2, 0, 2);
    table.getFlexCellFormatter().setColSpan(3, 0, 2);
    table.getFlexCellFormatter().setColSpan(7, 0, 2);

    // By default is enabled search mode simple
    table.getCellFormatter().setVisible(3, 0, false);
    table.getCellFormatter().setVisible(4, 0, false);
    table.getCellFormatter().setVisible(4, 1, false);

    searchButton.setStyleName("okm-YesButton");
    saveSearchButton.setStyleName("okm-AddButton");
    saveSearchButton.addStyleName("okm-NoWrap");
    cleanButton.setStyleName("okm-NoButton");
    searchSavedName.setStyleName("okm-Input");
    resultPage.setStyleName("okm-Input");

    initWidget(scrollPanel);
  }
 @Override
 public void addButton(SafeHtml label, ClickHandler handler) {
   Button button = new Button(label.asString(), handler);
   button.setStyleName(style.button());
   self.add(button, controls);
 }
  public SeleccionCatalogoPopupPanel(
      CatalogoClient catalogo,
      Label catalogLabel,
      Label openCatalogLabel,
      EditorActivityPopupPanel yo) {

    super(true);
    Catalogo = catalogo;
    LPrivate = catalogLabel;
    LPublic = openCatalogLabel;
    Father = yo;
    GeneralPanel = new AbsolutePanel();
    setAnimationEnabled(true);
    HorizontalPanel PanelActivityH = new HorizontalPanel();
    PanelActivity = new VerticalPanel();
    EditorZone = new SimplePanel();
    EditorZone.setHeight(Constants.TAMANO_PANEL_EDICION);
    EditorZone.setVisible(false);
    PanelActivity.add(EditorZone);
    PanelActivity.add(PanelActivityH);
    PanelActivityH.setVerticalAlignment(HasVerticalAlignment.ALIGN_MIDDLE);
    PanelActivityH.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_CENTER);
    PanelActivityH.setSpacing(4);

    GeneralPanel.add(PanelActivity, 0, 0);
    setWidget(GeneralPanel);
    GeneralPanel.setSize(
        Window.getClientWidth() + Constants.PX, Window.getClientHeight() + Constants.PX);
    // PanelActivityH.setSize("100%", "100%");
    // PanelActivity.setSize("100%", "100%");
    PanelActivity.setVerticalAlignment(HasVerticalAlignment.ALIGN_MIDDLE);
    PanelActivity.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_CENTER);

    SelectTeacherCatalogButton = new Button(SeleccionCatalogoPopupPanel.BOTTON_TEACHER_CATALOG);
    SelectTeacherCatalogButton.setSize("100%", "100%");
    SelectTeacherCatalogButton.addMouseDownHandler(
        new MouseDownHandler() {
          public void onMouseDown(MouseDownEvent event) {
            ((Button) event.getSource()).setStyleName("gwt-ButtonCenterPush");
          }
        });
    SelectTeacherCatalogButton.addMouseOutHandler(
        new MouseOutHandler() {
          public void onMouseOut(MouseOutEvent event) {
            ((Button) event.getSource()).setStyleName("gwt-ButtonCenter");
          }
        });
    SelectTeacherCatalogButton.addMouseOverHandler(
        new MouseOverHandler() {
          public void onMouseOver(MouseOverEvent event) {
            ((Button) event.getSource()).setStyleName("gwt-ButtonCenterOver");
          }
        });
    SelectTeacherCatalogButton.setStyleName("gwt-ButtonCenter");
    SelectTeacherCatalogButton.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            LPrivate.setText("Teacher Catalog :" + Catalogo.getCatalogName());
            LoadingPanel.getInstance().center();
            LoadingPanel.getInstance().setLabelTexto(ConstantsInformation.LOADING);
            bookReaderServiceHolder.loadCatalogById(
                Catalogo.getId(),
                new AsyncCallback<CatalogoClient>() {

                  @Override
                  public void onSuccess(CatalogoClient result) {
                    LoadingPanel.getInstance().hide();
                    Father.setSelectedCatalog(result);
                    Father.setPanel_Selecion_Default_Visibility(true);
                    hide();
                  }

                  @Override
                  public void onFailure(Throwable caught) {
                    LoadingPanel.getInstance().hide();
                    Window.alert(ConstantsError.ERROR_LOADING_CATALOG);
                    hide();
                  }
                });
          }
        });
    PanelActivityH.add(SelectTeacherCatalogButton);

    SelectOpenCatalogButton = new Button(SeleccionCatalogoPopupPanel.BOTTON_OPEN_CATALOG);
    SelectOpenCatalogButton.setSize("100%", "100%");
    SelectOpenCatalogButton.addMouseDownHandler(
        new MouseDownHandler() {
          public void onMouseDown(MouseDownEvent event) {
            ((Button) event.getSource()).setStyleName("gwt-ButtonCenterPush");
          }
        });
    SelectOpenCatalogButton.addMouseOutHandler(
        new MouseOutHandler() {
          public void onMouseOut(MouseOutEvent event) {
            ((Button) event.getSource()).setStyleName("gwt-ButtonCenter");
          }
        });
    SelectOpenCatalogButton.addMouseOverHandler(
        new MouseOverHandler() {
          public void onMouseOver(MouseOverEvent event) {
            ((Button) event.getSource()).setStyleName("gwt-ButtonCenterOver");
          }
        });
    SelectOpenCatalogButton.setStyleName("gwt-ButtonCenter");
    SelectOpenCatalogButton.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            LPublic.setText("Open Catalog :" + Catalogo.getCatalogName());
            Father.setSelectedCatalogPublic(Catalogo);
            hide();
          }
        });
    PanelActivityH.add(SelectOpenCatalogButton);
    PanelEdicion = new AbsolutePanel();
  }
  public DialogListaPontoEncontro(
      final InfoCaronaServerAsync controller, final String idSessao, final String idCarona) {
    novosPontos = "";
    listaNovosPontosEncontros = new ArrayList<InfoPontoEncontro>();
    this.idCarona = idCarona;
    this.controller = controller;

    setText("Pontos de Encontro - ID: " + idCarona);
    setAnimationEnabled(true);
    setGlassEnabled(true);
    center();

    VerticalPanel panelListaPontoEncontro = new VerticalPanel();
    tabelaPontoEncontro = new CellTable<InfoPontoEncontro>();
    tabelaPontoEncontro.setWidth("400px");
    dataProvider = new ListDataProvider<InfoPontoEncontro>();

    SimplePager.Resources pagerResources = GWT.create(SimplePager.Resources.class);
    SimplePager pager = new SimplePager(TextLocation.CENTER, pagerResources, false, 0, true);
    pager.setDisplay(tabelaPontoEncontro);
    pager.setPageSize(5);

    TextColumn<InfoPontoEncontro> colunaIdPontoEncontro =
        new TextColumn<InfoPontoEncontro>() {
          @Override
          public String getValue(InfoPontoEncontro pontoEncontro) {
            return pontoEncontro.getIdPontoEncontro();
          }
        };

    TextColumn<InfoPontoEncontro> colunaPontosEncontro =
        new TextColumn<InfoPontoEncontro>() {
          @Override
          public String getValue(InfoPontoEncontro pontoEncontro) {
            return pontoEncontro.getPontoEncontro();
          }
        };

    tabelaPontoEncontro.addColumn(colunaPontosEncontro, "Pontos de Encontro");
    listaPontoEncontros = new ArrayList<InfoPontoEncontro>();
    populaTabela();

    HorizontalPanel hPanel01 = new HorizontalPanel();
    final TextBox boxNovoPontoEncontro = new TextBox();
    boxNovoPontoEncontro.setWidth("200px");
    boxNovoPontoEncontro.setStyleName("boxModificada");

    Button buttonAdicionarOutroPontoEncontro = new Button();
    buttonAdicionarOutroPontoEncontro.setStyleName("botaoModificado");
    buttonAdicionarOutroPontoEncontro.setTitle("Adicionar Sugestão");
    buttonAdicionarOutroPontoEncontro.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            if (boxNovoPontoEncontro.getText().trim().equals("")) {
              DialogMensagemUsuario dialogErro =
                  new DialogMensagemUsuario("Falhou", "Ponto de Encontro Inválido");
              dialogErro.show();
            } else {
              novosPontos += boxNovoPontoEncontro.getText().trim() + ";";
              InfoPontoEncontro novoPontoEncontro =
                  new InfoPontoEncontro("00", boxNovoPontoEncontro.getText().trim());
              boxNovoPontoEncontro.setText("");

              listaNovosPontosEncontros.add(novoPontoEncontro);
              listaPontoEncontros = new ArrayList<InfoPontoEncontro>();

              for (InfoPontoEncontro novoPonto : listaNovosPontosEncontros) {
                listaPontoEncontros.add(novoPonto);
              }

              populaTabela();
            }
          }
        });

    Image imageFiltro = new Image("imagens/adicionar.png");
    imageFiltro.setSize("15px", "15px");
    buttonAdicionarOutroPontoEncontro.getElement().appendChild(imageFiltro.getElement());

    Button buttonSalvarNovosPontos = new Button("Salvar");
    buttonSalvarNovosPontos.setStyleName("botaoModificado");
    buttonSalvarNovosPontos.addClickHandler(
        new ClickHandler() {

          @Override
          public void onClick(ClickEvent event) {
            controller.cadastrarNovosPontosEncontro(
                idSessao,
                idCarona,
                novosPontos,
                new AsyncCallback<String>() {

                  @Override
                  public void onFailure(Throwable caught) {
                    DialogMensagemUsuario dialogSucess =
                        new DialogMensagemUsuario("Erro", caught.getMessage());
                    dialogSucess.show();
                  }

                  @Override
                  public void onSuccess(String result) {
                    DialogMensagemUsuario dialogSucess =
                        new DialogMensagemUsuario(
                            "ID: " + result, "Pontos de Encontro Cadastrados com Sucesso!");
                    dialogSucess.show();
                    hide();
                  }
                });
          }
        });

    Button buttonFechar = new Button("Fechar");
    buttonFechar.setStyleName("botaoModificado");

    buttonFechar.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            hide();
          }
        });

    colunaPontosEncontro.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_LEFT);

    hPanel01.setCellVerticalAlignment(boxNovoPontoEncontro, HasVerticalAlignment.ALIGN_BOTTOM);
    hPanel01.setCellVerticalAlignment(buttonSalvarNovosPontos, HasVerticalAlignment.ALIGN_TOP);
    hPanel01.setCellVerticalAlignment(
        buttonAdicionarOutroPontoEncontro, HasVerticalAlignment.ALIGN_TOP);
    hPanel01.setCellVerticalAlignment(buttonFechar, HasVerticalAlignment.ALIGN_TOP);
    hPanel01.setCellHorizontalAlignment(boxNovoPontoEncontro, HasHorizontalAlignment.ALIGN_CENTER);
    hPanel01.setCellHorizontalAlignment(
        buttonSalvarNovosPontos, HasHorizontalAlignment.ALIGN_CENTER);
    hPanel01.setCellHorizontalAlignment(
        buttonAdicionarOutroPontoEncontro, HasHorizontalAlignment.ALIGN_CENTER);
    hPanel01.setCellHorizontalAlignment(buttonFechar, HasHorizontalAlignment.ALIGN_CENTER);
    hPanel01.setWidth("100%");
    hPanel01.setSpacing(6);

    hPanel01.add(boxNovoPontoEncontro);
    hPanel01.add(buttonAdicionarOutroPontoEncontro);
    hPanel01.add(buttonSalvarNovosPontos);
    hPanel01.add(buttonFechar);

    panelListaPontoEncontro.add(tabelaPontoEncontro);
    panelListaPontoEncontro.add(pager);
    panelListaPontoEncontro.add(hPanel01);

    panelListaPontoEncontro.setCellVerticalAlignment(
        tabelaPontoEncontro, HasVerticalAlignment.ALIGN_MIDDLE);
    panelListaPontoEncontro.setCellVerticalAlignment(pager, HasVerticalAlignment.ALIGN_MIDDLE);

    panelListaPontoEncontro.setCellHorizontalAlignment(
        tabelaPontoEncontro, HasHorizontalAlignment.ALIGN_CENTER);
    panelListaPontoEncontro.setCellHorizontalAlignment(pager, HasHorizontalAlignment.ALIGN_CENTER);
    panelListaPontoEncontro.setSpacing(8);

    setWidget(panelListaPontoEncontro);
  }
Exemple #30
0
  @SuppressWarnings("deprecation")
  Rform(
      final ServiceInitialization si,
      final LoginScreen lscr,
      final UniversityForm ufm,
      final StudentData sdata) {
    misc mi = new misc();

    mainForm = new VerticalPanel();
    mainForm.setWidth("100%");

    AbsolutePanel absolutePanel = new AbsolutePanel();
    absolutePanel.setSize("1000px", "162px");
    mainForm.add(absolutePanel);

    Button btnCancel = new Button("New button");
    btnCancel.setStyleName("logout");
    btnCancel.addClickHandler(
        new ClickHandler() {
          @SuppressWarnings("deprecation")
          public void onClick(ClickEvent event) {

            ufm.getTabPanel().remove(getMainForm());
            ufm.getTabPanel().selectTab(0);
          }
        });
    btnCancel.setText("Cancel");
    absolutePanel.add(btnCancel, 936, 0);

    txSummary = new TextArea();
    absolutePanel.add(txSummary, 157, 10);
    txSummary.setSize("246px", "39px");

    cbApplicationStatus = new ListBox();
    absolutePanel.add(cbApplicationStatus, 447, 20);
    cbApplicationStatus.setSize("166px", "22px");

    mi.fillListBox(cbApplicationStatus, si, "data/applicationStatus.txt");

    // updating department index
    si.getGuiDataServiceAsync()
        .getDepartmentIndex(
            sdata.getApplicationStatus(),
            "data/applicationStatus.txt",
            new AsyncCallback<Integer>() {

              @Override
              public void onFailure(Throwable caught) {}

              @Override
              public void onSuccess(Integer result) {
                if (result != -1) {
                  cbApplicationStatus.setItemSelected(result, true);
                }
              }
            });

    // update summary from the database
    txSummary.setText(mi.isNull(sdata.getSummary()) ? sdata.getSummary() : "");

    Button btUpdate = new Button("New button");
    btUpdate.setStyleName("logout");
    btUpdate.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {

            StudentData sd = new StudentData();
            sd.setSummary(txSummary.getText());
            sd.setApplicationStatus(
                cbApplicationStatus.getItemText(cbApplicationStatus.getSelectedIndex()));

            // sdata.getAddress();

            sd.setAddress(sdata.getAddress());
            sd.setAppliedSchoolName(sdata.getAppliedSchoolName());
            sd.setCity(sdata.getCity());
            sd.setCountry(sdata.getCountry());
            sd.setDepartment(sdata.getDepartment());
            sd.setEmail(sdata.getEmail());
            sd.setFirstName(sdata.getFirstName());
            sd.setLastName(sdata.getLastName());
            sd.setLemail(sdata.getLemail());
            sd.setMajor(sdata.getMajor());
            sd.setMiddleName(sdata.getMiddleName());
            sd.setState(sdata.getState());
            sd.setStudiedSchoolCity(sdata.getStudiedSchoolCity());
            sd.setStudiedSchoolCountry(sdata.getStudiedSchoolCountry());
            sd.setStudiedSchoolName(sdata.getStudiedSchoolName());
            sd.setZip(sdata.getZip());
            sd.setDate(sdata.getDate());

            sd.setUcode(sdata.getUcode());

            sd.setComboBox_1_1(sdata.getComboBox_1_1());
            sd.setComboBox_1_2(sdata.getComboBox_1_2());
            sd.setComboBox_1_3(sdata.getComboBox_1_3());
            sd.setComboBox_1_4(sdata.getComboBox_1_4());
            sd.setComboBox_1_5(sdata.getComboBox_1_5());
            sd.setComboBox_1_6(sdata.getComboBox_1_6());
            sd.setComboBox_1_7(sdata.getComboBox_1_7());
            sd.setComboBox_1_8(sdata.getComboBox_1_8());

            sd.setComboBox_2_1(sdata.getComboBox_2_1());
            sd.setComboBox_2_2(sdata.getComboBox_2_2());
            sd.setComboBox_2_3(sdata.getComboBox_2_3());
            sd.setComboBox_2_4(sdata.getComboBox_2_4());
            sd.setComboBox_2_5(sdata.getComboBox_2_5());
            sd.setComboBox_2_6(sdata.getComboBox_2_6());
            sd.setComboBox_2_7(sdata.getComboBox_2_7());
            sd.setComboBox_2_8(sdata.getComboBox_2_8());

            sd.setComboBox_3_1(sdata.getComboBox_3_1());
            sd.setComboBox_3_2(sdata.getComboBox_3_2());
            sd.setComboBox_3_3(sdata.getComboBox_3_3());
            sd.setComboBox_3_4(sdata.getComboBox_3_4());
            sd.setComboBox_3_5(sdata.getComboBox_3_5());
            sd.setComboBox_3_6(sdata.getComboBox_3_6());
            sd.setComboBox_3_7(sdata.getComboBox_3_7());
            sd.setComboBox_3_8(sdata.getComboBox_3_8());

            sd.setComboBox_4_1(sdata.getComboBox_4_1());
            sd.setComboBox_4_2(sdata.getComboBox_4_2());
            sd.setComboBox_4_3(sdata.getComboBox_4_3());
            sd.setComboBox_4_4(sdata.getComboBox_4_4());
            sd.setComboBox_4_5(sdata.getComboBox_4_5());
            sd.setComboBox_4_6(sdata.getComboBox_4_6());
            sd.setComboBox_4_7(sdata.getComboBox_4_7());
            sd.setComboBox_4_8(sdata.getComboBox_4_8());

            sd.setComboBox_5_1(sdata.getComboBox_5_1());
            sd.setComboBox_5_2(sdata.getComboBox_5_2());
            sd.setComboBox_5_3(sdata.getComboBox_5_3());
            sd.setComboBox_5_4(sdata.getComboBox_5_4());
            sd.setComboBox_5_5(sdata.getComboBox_5_5());
            sd.setComboBox_5_6(sdata.getComboBox_5_6());
            sd.setComboBox_5_7(sdata.getComboBox_5_7());
            sd.setComboBox_5_8(sdata.getComboBox_5_8());

            sd.setComboBox_6_1(sdata.getComboBox_6_1());
            sd.setComboBox_6_2(sdata.getComboBox_6_2());
            sd.setComboBox_6_3(sdata.getComboBox_6_3());
            sd.setComboBox_6_4(sdata.getComboBox_6_4());
            sd.setComboBox_6_5(sdata.getComboBox_6_5());
            sd.setComboBox_6_6(sdata.getComboBox_6_6());
            sd.setComboBox_6_7(sdata.getComboBox_6_7());
            sd.setComboBox_6_8(sdata.getComboBox_6_8());

            sd.setComboBox_7_1(sdata.getComboBox_7_1());
            sd.setComboBox_7_2(sdata.getComboBox_7_2());
            sd.setComboBox_7_3(sdata.getComboBox_7_3());
            sd.setComboBox_7_4(sdata.getComboBox_7_4());
            sd.setComboBox_7_5(sdata.getComboBox_7_5());
            sd.setComboBox_7_6(sdata.getComboBox_7_6());
            sd.setComboBox_7_7(sdata.getComboBox_7_7());
            sd.setComboBox_7_8(sdata.getComboBox_7_8());

            sd.setComboBox_8_1(sdata.getComboBox_8_1());
            sd.setComboBox_8_2(sdata.getComboBox_8_2());
            sd.setComboBox_8_3(sdata.getComboBox_8_3());
            sd.setComboBox_8_4(sdata.getComboBox_8_4());
            sd.setComboBox_8_5(sdata.getComboBox_8_5());
            sd.setComboBox_8_6(sdata.getComboBox_8_6());
            sd.setComboBox_8_7(sdata.getComboBox_8_7());
            sd.setComboBox_8_8(sdata.getComboBox_8_8());

            sd.setTextBox_1_1(sdata.getTextBox_1_1());
            sd.setTextBox_1_2(sdata.getTextBox_1_2());
            sd.setTextBox_1_3(sdata.getTextBox_1_3());
            sd.setTextBox_1_4(sdata.getTextBox_1_4());
            sd.setTextBox_1_5(sdata.getTextBox_1_5());
            sd.setTextBox_1_6(sdata.getTextBox_1_6());
            sd.setTextBox_1_7(sdata.getTextBox_1_7());
            sd.setTextBox_1_8(sdata.getTextBox_1_8());

            sd.setTextBox_1_1(sdata.getTextBox_1_1());
            sd.setTextBox_1_2(sdata.getTextBox_1_2());
            sd.setTextBox_1_3(sdata.getTextBox_1_3());
            sd.setTextBox_1_4(sdata.getTextBox_1_4());
            sd.setTextBox_1_5(sdata.getTextBox_1_5());
            sd.setTextBox_1_6(sdata.getTextBox_1_6());
            sd.setTextBox_1_7(sdata.getTextBox_1_7());
            sd.setTextBox_1_8(sdata.getTextBox_1_8());

            sd.setTextBox_2_1(sdata.getTextBox_2_1());
            sd.setTextBox_2_2(sdata.getTextBox_2_2());
            sd.setTextBox_2_3(sdata.getTextBox_2_3());
            sd.setTextBox_2_4(sdata.getTextBox_2_4());
            sd.setTextBox_2_5(sdata.getTextBox_2_5());
            sd.setTextBox_2_6(sdata.getTextBox_2_6());
            sd.setTextBox_2_7(sdata.getTextBox_2_7());
            sd.setTextBox_2_8(sdata.getTextBox_2_8());

            sd.setTextBox_3_1(sdata.getTextBox_3_1());
            sd.setTextBox_3_2(sdata.getTextBox_3_2());
            sd.setTextBox_3_3(sdata.getTextBox_3_3());
            sd.setTextBox_3_4(sdata.getTextBox_3_4());
            sd.setTextBox_3_5(sdata.getTextBox_3_5());
            sd.setTextBox_3_6(sdata.getTextBox_3_6());
            sd.setTextBox_3_7(sdata.getTextBox_3_7());
            sd.setTextBox_3_8(sdata.getTextBox_3_8());

            sd.setTextBox_4_1(sdata.getTextBox_4_1());
            sd.setTextBox_4_2(sdata.getTextBox_4_2());
            sd.setTextBox_4_3(sdata.getTextBox_4_3());
            sd.setTextBox_4_4(sdata.getTextBox_4_4());
            sd.setTextBox_4_5(sdata.getTextBox_4_5());
            sd.setTextBox_4_6(sdata.getTextBox_4_6());
            sd.setTextBox_4_7(sdata.getTextBox_4_7());
            sd.setTextBox_4_8(sdata.getTextBox_4_8());

            sd.setTextBox_5_1(sdata.getTextBox_5_1());
            sd.setTextBox_5_2(sdata.getTextBox_5_2());
            sd.setTextBox_5_3(sdata.getTextBox_5_3());
            sd.setTextBox_5_4(sdata.getTextBox_5_4());
            sd.setTextBox_5_5(sdata.getTextBox_5_5());
            sd.setTextBox_5_6(sdata.getTextBox_5_6());
            sd.setTextBox_5_7(sdata.getTextBox_5_7());
            sd.setTextBox_5_8(sdata.getTextBox_5_8());

            sd.setTextBox_6_1(sdata.getTextBox_6_1());
            sd.setTextBox_6_2(sdata.getTextBox_6_2());
            sd.setTextBox_6_3(sdata.getTextBox_6_3());
            sd.setTextBox_6_4(sdata.getTextBox_6_4());
            sd.setTextBox_6_5(sdata.getTextBox_6_5());
            sd.setTextBox_6_6(sdata.getTextBox_6_6());
            sd.setTextBox_6_7(sdata.getTextBox_6_7());
            sd.setTextBox_6_8(sdata.getTextBox_6_8());

            sd.setTextBox_7_1(sdata.getTextBox_7_1());
            sd.setTextBox_7_2(sdata.getTextBox_7_2());
            sd.setTextBox_7_3(sdata.getTextBox_7_3());
            sd.setTextBox_7_4(sdata.getTextBox_7_4());
            sd.setTextBox_7_5(sdata.getTextBox_7_5());
            sd.setTextBox_7_6(sdata.getTextBox_7_6());
            sd.setTextBox_7_7(sdata.getTextBox_7_7());
            sd.setTextBox_7_8(sdata.getTextBox_7_8());

            sd.setTextBox_8_1(sdata.getTextBox_8_1());
            sd.setTextBox_8_2(sdata.getTextBox_8_2());
            sd.setTextBox_8_3(sdata.getTextBox_8_3());
            sd.setTextBox_8_4(sdata.getTextBox_8_4());
            sd.setTextBox_8_5(sdata.getTextBox_8_5());
            sd.setTextBox_8_6(sdata.getTextBox_8_6());
            sd.setTextBox_8_7(sdata.getTextBox_8_7());
            sd.setTextBox_8_8(sdata.getTextBox_8_8());

            try {
              si.getStudentDataServiceAsync()
                  .addRegStudentData(
                      sdata,
                      sd,
                      new AsyncCallback<String>() {

                        @Override
                        public void onFailure(Throwable caught) {

                          Window.alert("error from server");
                        }

                        @Override
                        public void onSuccess(String result) {
                          if (result != null) {
                            if (result.equals("ok")) {
                              Window.alert("Changed applied ");
                            }
                          }
                        }
                      });
            } catch (LoggedInException e) {

              e.printStackTrace();
            }
          }
        });
    btUpdate.setText("Update");
    absolutePanel.add(btUpdate, 646, 18);

    // retrieve image from server
    ImageData id = new ImageData();
    id.setEmail(sdata.getEmail());
    id.setFirstName(sdata.getFirstName());
    id.setLastName(sdata.getLastName());
    id.setName("sem1");

    try {
      si.getImageDataServiceAsync()
          .readAllImage(
              id,
              new AsyncCallback<String[]>() {

                @Override
                public void onFailure(Throwable caught) {}

                @Override
                public void onSuccess(String[] result) {
                  String[] vid = result;
                  gid = result;

                  if (vid != null) {

                    for (int i = 0; i < vid.length; i++) {

                      if (vid[i] == null) {
                        continue;
                      }

                      long img = Long.parseLong(vid[i]);

                      switch (i) {
                        case 0:
                          {
                            if (img != 0L) {
                              btnSem1.setEnabled(true);
                            }
                            break;
                          }

                        case 1:
                          {
                            if (img != 0L) {
                              btnSem2.setEnabled(true);
                            }
                            break;
                          }

                        case 2:
                          {
                            if (img != 0L) {
                              btnSem3.setEnabled(true);
                            }
                            break;
                          }

                        case 3:
                          {
                            if (img != 0L) {
                              btnSem4.setEnabled(true);
                            }
                            break;
                          }

                        case 4:
                          {
                            if (img != 0L) {
                              btnSem5.setEnabled(true);
                            }
                            break;
                          }

                        case 5:
                          {
                            if (img != 0L) {
                              btnSem6.setEnabled(true);
                            }
                            break;
                          }

                        case 6:
                          {
                            if (img != 0L) {
                              btnSem7.setEnabled(true);
                            }
                            break;
                          }

                        case 7:
                          {
                            if (img != 0L) {
                              btnSem8.setEnabled(true);
                            }
                            break;
                          }
                      }
                    }
                  }
                }
              });
    } catch (LoggedInException e) {

      e.printStackTrace();
    }

    btnSem1 = new Button("New button");
    btnSem1.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            Window.open(
                GWT.getModuleBaseURL() + "imgsource?id=" + Long.parseLong(gid[0]), "_blank", null);
          }
        });
    btnSem1.setEnabled(false);
    btnSem1.setText("Semester 1");
    absolutePanel.add(btnSem1, 10, 70);

    btnSem2 = new Button("New button");
    btnSem2.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            Window.open(
                GWT.getModuleBaseURL() + "imgsource?id=" + Long.parseLong(gid[1]), "_blank", null);
          }
        });
    btnSem2.setEnabled(false);
    btnSem2.setText("Semester 2");
    absolutePanel.add(btnSem2, 107, 70);

    btnSem3 = new Button("New button");
    btnSem3.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            Window.open(
                GWT.getModuleBaseURL() + "imgsource?id=" + Long.parseLong(gid[2]), "_blank", null);
          }
        });
    btnSem3.setEnabled(false);
    btnSem3.setText("Semester 3");
    absolutePanel.add(btnSem3, 202, 70);

    btnSem4 = new Button("New button");
    btnSem4.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            Window.open(
                GWT.getModuleBaseURL() + "imgsource?id=" + Long.parseLong(gid[3]), "_blank", null);
          }
        });
    btnSem4.setEnabled(false);
    btnSem4.setText("Semester 4");
    absolutePanel.add(btnSem4, 298, 70);

    btnSem5 = new Button("New button");
    btnSem5.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            Window.open(
                GWT.getModuleBaseURL() + "imgsource?id=" + Long.parseLong(gid[4]), "_blank", null);
          }
        });
    btnSem5.setEnabled(false);
    btnSem5.setText("Semester 5");
    absolutePanel.add(btnSem5, 10, 116);

    btnSem6 = new Button("New button");
    btnSem6.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            Window.open(
                GWT.getModuleBaseURL() + "imgsource?id=" + Long.parseLong(gid[5]), "_blank", null);
          }
        });
    btnSem6.setEnabled(false);
    btnSem6.setText("Semester 6");
    absolutePanel.add(btnSem6, 107, 116);

    btnSem7 = new Button("New button");
    btnSem7.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            Window.open(
                GWT.getModuleBaseURL() + "imgsource?id=" + Long.parseLong(gid[6]), "_blank", null);
          }
        });
    btnSem7.setEnabled(false);
    btnSem7.setText("Semester 7");
    absolutePanel.add(btnSem7, 202, 116);

    btnSem8 = new Button("New button");
    btnSem8.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            Window.open(
                GWT.getModuleBaseURL() + "imgsource?id=" + Long.parseLong(gid[7]), "_blank", null);
          }
        });
    btnSem8.setEnabled(false);
    btnSem8.setText("Semester 8");
    absolutePanel.add(btnSem8, 298, 116);

    ScrollPanel scrollPanel = new ScrollPanel();
    mainForm.add(scrollPanel);

    String univ = sdata.getAddress();
    String dept = sdata.getDepartment();

    HTML html =
        new HTML(
            "<hr/><br/> <b> Application Status : </b>"
                + "<font size="
                + 3
                + " color=red>"
                + sdata.getApplicationStatus()
                + "</font>"
                + "<br/> <b> Summary : </b>"
                + "<font size="
                + 3
                + " color=red>"
                + sdata.getSummary()
                + "</font>"
                + "<hr/> <b>School Name: </b>"
                + "<font size="
                + 3
                + " color=Black>"
                + sdata.getAppliedSchoolName()
                + "</font>"
                + "<br/> <b> Department: </b>"
                + "<font size="
                + 3
                + " color=Black>"
                + sdata.getDepartment()
                + "</font>"
                + "<br/>  <b>Major: </b>"
                + "<font size="
                + 3
                + " color=Black>"
                + sdata.getMajor()
                + "</font>"
                // +"<br/>  <b>Graduation Date:
                // </b>"+DateTimeFormat.getFormat("MM/dd/yyyy").format(sdata.getDateGraduation())

                + "<br/>  <b>Graduation Date: </b>"
                + "<font size="
                + 3
                + " color=Black>"
                + sdata.getDateGraduation()
                + "</font>"
                + "<br/>  <b>Comment: </b>"
                + "<font size="
                + 3
                + " color=Black>"
                + sdata.getTxtComment()
                + "</font>"
                + "<hr/> <br/> <b> FirstName: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getFirstName()
                + "</font>"
                + "<span style="
                + "padding-left:50px><b>MiddleName: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getMiddleName()
                + "</font>"
                + "<span>"
                + "<span style="
                + "padding-left:50px><b>LastName: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getLastName()
                + "</font>"
                + "<span>"
                + "<br/> <b> Address: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getAddress()
                + "</font>"
                + "<br/> <b> City: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getCity()
                + "</font>"
                + "<br/> <b> State: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getState()
                + "</font>"
                + "<br/> <b> Zip: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getZip()
                + "</font>"
                + "<br/> <b> Country: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getCountry()
                + "</font>"
                + "<br/> <b> Email: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getEmail()
                + "</font>"
                + "<br/> <b> School Name: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getStudiedSchoolName()
                + "</font>"
                + "<br/> <b> City: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getStudiedSchoolCity()
                + "</font>"
                + "<br/> <b> Country: </b>"
                + "<font size="
                + 3
                + " color=orange>"
                + sdata.getStudiedSchoolCountry()
                + "</font>"
                + "<hr/><table border="
                + "1>"
                + "<tr>"
                + "<td>"
                + "<b> Semester 1 </b>"
                + "</td>"
                + "<td>"
                + "<b> Semester 2 </b>"
                + "</td>"
                + "<td>"
                + "<b> Semester 3 </b>"
                + "</td>"
                + "<td>"
                + "<b> Semester 4 </b>"
                + "</td>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_1_1()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_1_1()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_2_1()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_2_1()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_3_1()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_3_1()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_4_1()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_4_1()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_1_2()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_1_2()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_2_2()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_2_2()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_3_2()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_3_2()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_4_2()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_4_2()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_1_3()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_1_3()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_2_3()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_2_3()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_3_3()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_3_3()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_4_3()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_4_3()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_1_4()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_1_4()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_2_4()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_2_4()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_3_4()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_3_4()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_4_4()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_4_4()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_1_5()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_1_5()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_2_5()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_2_5()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_3_5()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_3_5()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_4_5()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_4_5()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_1_6()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_1_6()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_2_6()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_2_6()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_3_6()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_3_6()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_4_6()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_4_6()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_1_7()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_1_7()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_2_7()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_2_7()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_3_7()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_3_7()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_4_7()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_4_7()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_1_8()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_1_8()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_2_8()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_2_8()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_3_8()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_3_8()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_4_8()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_4_8()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + ":"
                + "</td>"
                + "<td>"
                + ":"
                + "</td>"
                + "<td>"
                + ":"
                + "</td>"
                + "<td>"
                + ":"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<b> Semester 5 </b>"
                + "</td>"
                + "<td>"
                + "<b> Semester 6 </b>"
                + "</td>"
                + "<td>"
                + "<b> Semester 7 </b>"
                + "</td>"
                + "<td>"
                + "<b> Semester 8 </b>"
                + "</td>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_5_1()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_5_1()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_6_1()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_6_1()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_7_1()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_7_1()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_8_1()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_8_1()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_5_2()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_5_2()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_6_2()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_6_2()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_7_2()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_7_2()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_8_2()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_8_2()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_5_3()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_5_3()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_6_3()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_6_3()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_7_3()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_7_3()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_8_3()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_8_3()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_5_4()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_5_4()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_6_4()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_6_4()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_7_4()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_7_4()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_8_4()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_8_4()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_5_5()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_5_5()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_6_5()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_6_5()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_7_5()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_7_5()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_8_5()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_8_5()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_5_6()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_5_6()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_6_6()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_6_6()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_7_6()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_7_6()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_8_6()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_8_6()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_5_7()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_5_7()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_6_7()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_6_7()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_7_7()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_7_7()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_8_7()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_8_7()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "<tr>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_5_8()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_5_8()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_6_8()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_6_8()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_7_8()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_7_8()
                + "</font>"
                + "</td>"
                + "<td>"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getComboBox_8_8()
                + "</font>"
                + ":"
                + "<font size="
                + 3
                + " color=green>"
                + sdata.getTextBox_8_8()
                + "</font>"
                + "</td>"
                + "</tr>"
                + "</table>",
            true);
    scrollPanel.setWidget(html);
    html.setSize("100%", "100%");
  }