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);
  }
Exemplo n.º 2
0
  private VerticalPanel buildExtras() {

    HorizontalPanel extsBaseRow = new HorizontalPanel();

    ToggleButton bShowOnly = new ToggleButton(new Image("images/button_eye.gif"), this);
    bShowOnly.setTitle("Click to hide all route segments except this one! Click again to restore.");
    extsBaseRow.add(bShowOnly);

    soClick = new HTML("<div class=\"togglelink\">詳細內容</div>");
    soClick.setTitle("顯示詳細內容.");
    soClick.addClickListener(this);
    extsBaseRow.add(soClick);

    VerticalPanel exts = new VerticalPanel();
    exts.add(extsBaseRow);

    detailPanel = buildStopOvers();
    exts.add(detailPanel);

    exts.setStyleName("extras");
    extsBaseRow.setStyleName("base_row");
    bShowOnly.setStyleName("eye");
    detailPanel.setStyleName("stopovers");
    return exts;
  }
Exemplo n.º 3
0
  public MainPanel() {
    super(Unit.PX);

    Image logoUfcg = new Image(Adicionais.RESOURCES.logoUfcg());
    Image logoAdicionais = new Image(Adicionais.RESOURCES.logoAdicionais());
    HorizontalPanel header = new HorizontalPanel();
    header.add(logoUfcg);
    header.setCellVerticalAlignment(logoUfcg, HasVerticalAlignment.ALIGN_MIDDLE);
    header.add(logoAdicionais);
    header.setCellHorizontalAlignment(logoAdicionais, HasHorizontalAlignment.ALIGN_RIGHT);
    header.setWidth("100%");
    header.setStyleName(Adicionais.RESOURCES.css().header());
    this.addNorth(header, 88);

    VerticalPanel footer = new VerticalPanel();
    Label developersLabel =
        new Label("Desenvolvido por Cleber Gonçalves de Sousa e Vitor Morato Almeida");
    developersLabel.setStyleName(Adicionais.RESOURCES.css().developers());
    footer.add(developersLabel);

    this.addSouth(footer, 23);
    footer.setWidth("100%");
    footer.setStyleName(Adicionais.RESOURCES.css().footer());

    this.contentArea = new SimplePanel();
    this.contentArea.setStyleName(Adicionais.RESOURCES.css().content());
    this.add(this.contentArea);
  }
Exemplo n.º 4
0
  /**
   * Builds the main toolbar.
   *
   * @return the main toolbar
   */
  private HorizontalPanel buildToolBar() {
    HorizontalPanel toolbarPanel = new HorizontalPanel();
    toolbarPanel.setVerticalAlignment(HorizontalPanel.ALIGN_MIDDLE);
    toolbarPanel.setStyleName("lab-Toolbar");
    toolbarPanel.add(
        buildButton(
            resources.blankFile(),
            "New Project",
            new CreateNewProjectDialogWidget().openDialogForNewProjectCommand()));
    toolbarPanel.add(buildButton(resources.openIcon(), "Open Project", createBlankCommand()));
    toolbarPanel.add(buildButton(resources.saveIcon(), "Save Project", createBlankCommand()));
    toolbarPanel.add(buildSeparator());
    toolbarPanel.add(buildButton(resources.refreshIcon(), "Refresh", createBlankCommand()));
    toolbarPanel.add(buildSeparator());
    toolbarPanel.add(
        buildButton(
            resources.copyIcon(),
            "Clone Project",
            (new GitCloneDialogWidget().openDialogForGITCloneCommand())));
    toolbarPanel.add(buildSeparator());
    toolbarPanel.add(
        buildButton(
            resources.uploadIcon(), "Deploy Project", (new DeployDialog().openMenuDialog())));

    return toolbarPanel;
  }
  /**
   * Creates an empty dialog box specifying its "auto-hide" property. It should not be shown until
   * its child widget has been added using {@link #add(Widget)}.
   *
   * @param autoHide <code>true</code> if the dialog should be automatically hidden when the user
   *     clicks outside of it
   * @param modal <code>true</code> if keyboard and mouse events for widgets not contained by the
   *     dialog should be ignored
   */
  public MyDialogBox(boolean autoHide, boolean modal) {
    super(autoHide, modal);
    dock = new HorizontalPanel();
    dock.add(caption);
    HorizontalPanel hp = new HorizontalPanel();
    hp.setSpacing(0);
    dock.setHorizontalAlignment(HorizontalPanel.ALIGN_RIGHT);

    listener = new DialogListener(this);
    minimiseBtn.addClickListener(listener);
    maximiseBtn.addClickListener(listener);
    closeBtn.addClickListener(listener);

    hp.add(minimiseBtn);
    hp.add(maximiseBtn);
    hp.add(closeBtn);
    dock.add(hp);
    panel.add(dock);

    panel.setHeight("100%");
    panel.setSpacing(0);

    sp = new ScrollPanel();
    panel.add(sp);
    super.setWidget(panel);

    setStyleName("gwt-DialogBox");
    dock.setStyleName("Caption");
    caption.addMouseListener(this);
  }
Exemplo n.º 6
0
  public ActionRetractFactWidget(RuleModeller modeller, ActionRetractFact model, Boolean readOnly) {
    super(modeller);
    HorizontalPanel layout = new HorizontalPanel();
    layout.setWidth("100%");
    layout.setStyleName("model-builderInner-Background");

    if (readOnly == null) {
      this.readOnly =
          !modeller
              .getSuggestionCompletions()
              .containsFactType(modeller.getModel().getLHSBindingType(model.variableName));
    } else {
      this.readOnly = readOnly;
    }

    if (this.readOnly) {
      layout.addStyleName("editor-disabled-widget");
    }

    String desc =
        modeller.getModel().getLHSBindingType(model.variableName) + " [" + model.variableName + "]";
    layout.add(
        new SmallLabel(
            HumanReadable.getActionDisplayName("retract") + "&nbsp;<b>" + desc + "</b>"));

    // This widget couldn't be modified.
    this.setModified(false);

    initWidget(layout);
  }
  /**
   * Page widgets.
   *
   * @param cellTree the cell tree
   */
  public void createPageView(CellTree cellTree) {
    this.cellTree = cellTree;
    mainPanel.setStyleName("div-wrapper"); // main div

    SimplePanel leftPanel = new SimplePanel();
    leftPanel.getElement().setId("leftPanel_SimplePanel");
    leftPanel.setStyleName("div-first bottomPadding10px"); // left side div which will  have tree

    SimplePanel rightPanel = new SimplePanel();
    rightPanel.getElement().setId("rightPanel_SimplePanel");
    rightPanel.setStyleName("div-second"); // right div having tree creation inputs.

    VerticalPanel treePanel = new VerticalPanel();
    treePanel.getElement().setId("treePanel_VerticalPanel");
    HorizontalPanel expandCollapse = new HorizontalPanel();
    expandCollapse.getElement().setId("expandCollapse_HorizontalPanel");
    expandCollapse.setStyleName("leftAndTopPadding");
    expandCollapse.setSize("100px", "20px");
    buttonExpand.setStylePrimaryName("expandAllButton");
    buttonCollapse.setStylePrimaryName("collapseAllButton");
    buttonExpand.setTitle("Expand All (Shift +)");
    buttonCollapse.setTitle("Collapse All (Shift -)");
    expandCollapse.add(buttonExpand);
    expandCollapse.add(buttonCollapse);
    buttonExpand.setFocus(true);
    buttonCollapse.setVisible(true);

    treePanel.add(expandCollapse);
    treePanel.add(cellTree);
    leftPanel.add(treePanel);

    SimplePanel bottomSavePanel = new SimplePanel();
    bottomSavePanel.getElement().setId("bottomSavePanel_SimplePanel");
    bottomSavePanel.setStyleName("div-first buttonPadding");
    VerticalPanel vp = new VerticalPanel();
    HorizontalPanel savePanel = new HorizontalPanel();
    savePanel.getElement().setId("savePanel_VerticalPanel");
    savePanel.add(new SpacerWidget());
    //		savePanel.add(errorMessageDisplay);
    vp.add(successMessageDisplay);
    //		saveBtn.setTitle("Ctrl+Alt+s");
    savePanel.add(saveBtn);
    validateBtn.setTitle("Validate");
    savePanel.add(validateBtn);
    vp.add(warningMessageDisplay);
    vp.add(savePanel);
    bottomSavePanel.add(vp);

    SimplePanel errPanel = new SimplePanel();
    errPanel.getElement().setId("errPanel_SimplePanel");
    errPanel.add(errorMessageDisplay);
    mainPanel.add(errPanel);
    mainPanel.add(leftPanel);
    mainPanel.add(rightPanel);
    mainPanel.add(bottomSavePanel);
    focusPanel.addKeyDownHandler(this);
    focusPanel.addFocusHandler(this);
    cellTreeHandlers();
  }
Exemplo n.º 8
0
    public CourseSelectorWidget() {

      courseHorizontalPanel = new HorizontalPanel();
      courseVerticalPanel = new VerticalPanel();
      courseHorizontalPanel.add(courseVerticalPanel);

      courseHorizontalPanel.setStyleName("courseSelectorPanel");
      courseSelectLabel = new Label();
      courseSelectLabel.setStyleName("courseSelectLabel");

      HorizontalPanel courseInputPanel = new HorizontalPanel();
      courseLabel = new Label(constants.course() + ": ");
      courseListBox = new ListBox();
      courseListBox.insertItem("<" + constants.select() + ">", 0);
      courseInputPanel.add(courseLabel);
      courseInputPanel.add(courseListBox);

      tariffInputPanel = new HorizontalPanel();
      tariffLabel = new Label(constants.tariff() + ": ");
      tariffListBox = new ListBox();
      tariffListBox.insertItem("<" + constants.select() + ">", 0);
      tariffInputPanel.add(tariffLabel);
      tariffInputPanel.add(tariffListBox);

      HorizontalPanel gradeInputPanel = new HorizontalPanel();
      gradeLabel = new Label(constants.grade() + ": ");
      gradeListBox = new ListBox();
      gradeListBox.insertItem("<" + constants.select() + ">", 0);
      gradeInputPanel.add(gradeLabel);
      gradeInputPanel.add(gradeListBox);

      deleteButton = new Image("/imgs/Symbol_Delete.png");
      deleteButton.setStyleName("clickable");
      deleteButton.addClickHandler(
          new ClickHandler() {
            public void onClick(ClickEvent event) {
              courseSelectorWrapper.remove(index - 1);

              int j = 0;
              for (int i = 0; i < 15; i++) {

                if (!courseList.get(i).getCourseSelector().isAttached()) {
                  courseList.get(i).resetSelector();

                } else {
                  courseList.get(i).setCourseLabel(j + 1);
                  j++;
                }
              }
            }
          });

      courseVerticalPanel.add(courseSelectLabel);
      courseVerticalPanel.add(courseInputPanel);
      courseVerticalPanel.add(tariffInputPanel);
      courseVerticalPanel.add(gradeInputPanel);
      courseHorizontalPanel.add(deleteButton);
    }
Exemplo n.º 9
0
  @Inject
  public MainView(IndexDisplayer indexDisplayer) {

    c.setStyleName("tab");
    c.addStyleName("first");
    p.setStyleName("tab");

    message.setStyleName("messageBar");
    message.setVisible(false);

    int i;
    for (i = 0; i < 5; i++) {
      startIndex.addItem(indexDisplayer.getDisplay(i), Integer.toString(i));
    }
    for (i = 5; i < 10; i++) {
      lastIndex.addItem(indexDisplayer.getDisplay(i), Integer.toString(i));
    }

    startIndex.setSelectedIndex(0);
    lastIndex.setSelectedIndex(0);

    HorizontalPanel hp = new HorizontalPanel();
    hp.setVerticalAlignment(HasVerticalAlignment.ALIGN_MIDDLE);
    hp.add(new Label("Start Index: "));
    hp.add(startIndex);
    hp.add(new Label("End Index: "));
    hp.add(lastIndex);
    hp.setSpacing(5);

    bar.add(c);
    bar.add(p);
    bar.setStyleName("tabs");

    mainPanel = new VerticalPanel();
    mainPanel.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_RIGHT);
    clearHistory.setStyleName("link");
    mainPanel.add(clearHistory);

    mainPanel.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_LEFT);
    mainPanel.add(hp);
    mainPanel.add(bar);
    mainPanel.add(message);
    mainPanel.add(bodyContainer);
    mainPanel.add(filter);
    mainPanel.add(filterActivate);
    mainPanel.add(filterModule);
    mainPanel.add(hasBeenThere);
    mainPanel.add(broadcastInfo);
    mainPanel.add(showStatus);
    mainPanel.add(activateStatus);
    wait.add(new Label("Wait"));

    initWidget(mainPanel);

    bodyContainer.setStyleName("body");
    bodyContainer.setWidget(new Label("Click on one of the tab to start."));
  }
Exemplo n.º 10
0
    public Widget getTable(TermMoveObject tmObj) {
      if (!tmObj.isTermListEmpty()) {
        HashMap<String, ArrayList<TermObject>> termList = tmObj.getTermList();
        HashMap<String, TermRelationshipObject> termRelList = tmObj.getTermRelList();

        ArrayList<String> termlanglist = new ArrayList<String>(termList.keySet());
        ArrayList<String> sortedlanglist = new ArrayList<String>();
        for (LanguageCode langCode : MainApp.languageCode) {
          String lang = langCode.getLanguageCode().toLowerCase();

          if (termlanglist.contains(lang)) {
            termlanglist.remove(lang);
            if (MainApp.userPreference.isHideNonselectedlanguages()) {
              if (!MainApp.userSelectedLanguage.contains(lang)) {
                lang = "";
              }
            }
            if (!lang.equals("")) sortedlanglist.add(lang);
          }
        }
        sortedlanglist.addAll(termlanglist);

        FlexTable table = new FlexTable();
        table.setWidget(0, 0, new HTML(constants.conceptLanguage()));
        table.setWidget(0, 1, new HTML("&nbsp;"));

        table.getColumnFormatter().setWidth(1, "80%");
        int i = 1;
        for (String language : sortedlanglist) {
          table.setWidget(
              i, 0, new HTML(getFullnameofLanguage(language) + " (" + language.toString() + ")"));
          ArrayList<TermObject> list = (ArrayList<TermObject>) termList.get(language);
          table.setWidget(i, 1, getTermTable(list, termRelList));
          i++;
        }

        VerticalPanel panel = new VerticalPanel();
        String str =
            "This action will move following terms in different languages and remove all their current relationships with other terms if exists. Please click browse button to select the new concept and click OK button to move or Cancel button to cancel the task?";
        HTML msg = new HTML(str);
        HorizontalPanel msghp = new HorizontalPanel();
        msghp.setStyleName("language-message");
        msghp.add(msg);
        msghp.setSpacing(10);
        panel.add(msg);
        panel.add(getConceptBrowseButton());
        panel.add(
            GridStyle.setTableConceptDetailStyleTop(
                table, "gstFR1", "gstFC1", "gstR1", "gstPanel1", true));
        panel.setWidth("100%");
        return panel;

      } else {
        Label sayNo = new Label(constants.conceptNoTerm());
        return sayNo;
      }
    }
Exemplo n.º 11
0
  @Override
  protected Widget createMainWidget() {
    VerticalPanel panel = new VerticalPanel();
    panel.setStyleName(ThemeStyles.INSTANCE.fileUploadPanel());

    // directory panel
    HorizontalPanel directoryPanel = new HorizontalPanel();
    directoryPanel.setWidth("100%");
    directoryPanel.setStyleName(ThemeStyles.INSTANCE.fileUploadField());

    // directory name (informational field)
    panel.add(new Label("Target directory:"));
    directoryNameWidget_ = new DirectoryNameWidget();
    directoryNameWidget_.setDirectory(targetDirectory_);
    directoryPanel.add(directoryNameWidget_);

    // browse directory button
    // JJA: removed browse button (was causing confusion for users who
    // thought it was what they should press to browse local files)
    /*
    Button browseButton = new Button("Browse...",
                                     new BrowseDirectoryClickHandler());
    browseButton.getElement().getStyle().setMarginRight(5, Unit.PX);
    directoryPanel.add(browseButton);
    directoryPanel.setCellHorizontalAlignment(
                                        browseButton,
                                        HasHorizontalAlignment.ALIGN_RIGHT);
    */
    panel.add(directoryPanel);

    // filename field
    panel.add(new Label("File to upload:"));
    fileUpload_ = new FileUpload();
    fileUpload_.setStyleName(ThemeStyles.INSTANCE.fileUploadField());
    fileUpload_.setName("file");
    panel.add(fileUpload_);

    // zip file tip field
    HTML tip =
        new HTML(
            "<b>TIP</b>: To upload multiple files or a "
                + "directory, create a zip file. The zip file will "
                + "be automatically expanded after upload.");
    tip.addStyleName(ThemeStyles.INSTANCE.fileUploadField());
    tip.addStyleName(ThemeStyles.INSTANCE.fileUploadTipLabel());
    panel.add(tip);

    // target directory hidden field
    targetDirectoryHidden_ = new Hidden("targetDirectory", targetDirectory_.getPath());
    panel.add(targetDirectoryHidden_);

    return panel;
  }
Exemplo n.º 12
0
  protected void init() {
    ClickHandler onClick =
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            search();
          }
        };

    HorizontalPanel searchBox = new HorizontalPanel();
    searchBox.setSpacing(10);
    searchBox.setStyleName("SearchBox");
    searchBox.add(new Label(_msgs.awardMedalsMemberSearch()));
    searchBox.add(_search = new TextBox());
    EnterClickAdapter.bind(_search, onClick);
    searchBox.add(new Button(_msgs.awardMedalsFind(), onClick));
    add(searchBox);
  }
Exemplo n.º 13
0
    public TermDetail(ConceptObject conceptObject, TermObject termObject) {
      String text = termObject.getLabel();
      if (text.length() > 100) text = text.substring(0, 70) + "...";
      this.setHTML(
          constants.conceptInformationFor()
              + " <i>"
              + text
              + " ("
              + termObject.getLang()
              + ")</i>&nbsp;["
              + (termObject.isMainLabel()
                  ? constants.conceptPreferredTerm()
                  : constants.conceptNonPreferredTerm())
              + "]");
      TermDetailTabPanel termDetail =
          new TermDetailTabPanel(permissionTable, initData, TermDetail.this);
      termDetail.setURI(termObject, conceptObject);

      VerticalPanel vp = new VerticalPanel();
      vp.setSize("100%", "100%");
      vp.add(termDetail);

      panel.add(vp);
      panel.setCellHeight(vp, "100%");
      panel.setCellWidth(vp, "100%");

      HorizontalPanel buttonPanel = new HorizontalPanel();
      buttonPanel.setSpacing(5);
      buttonPanel.add(cancel);

      HorizontalPanel hp = new HorizontalPanel();
      hp.setSpacing(0);
      hp.setWidth("100%");
      hp.setStyleName("bottombar");
      hp.add(buttonPanel);
      hp.setCellHorizontalAlignment(buttonPanel, HasHorizontalAlignment.ALIGN_RIGHT);

      panel.add(hp);
      cancel.addClickHandler(this);
      panel.setCellHorizontalAlignment(cancel, HasHorizontalAlignment.ALIGN_RIGHT);
      panel.setSize("100%", "100%");
      setWidget(panel);
    }
Exemplo n.º 14
0
  @SuppressWarnings("deprecation")
  private void createInputFormLine() {
    upperLinePanel = new HorizontalPanel();
    upperLinePanel.setStyleName("left");
    mainPanel.add(upperLinePanel);

    createResponseTypeColumn();
    createVarNameColumn();
    createInputTextColumn();
    createRequiredCheckBoxColumn();
    createConditionCheckboxColumn();
    createConditionExpressionPanel();

    lowerLinePanel = new HorizontalPanel();
    mainPanel.add(lowerLinePanel);
    createResponseViewPanel();

    // createScheduledDateColumn(upperLinePanel);
  }
Exemplo n.º 15
0
  public VersionBrowser(
      ClientFactory clientFactory, EventBus eventBus, String uuid, boolean isPackage) {
    this.clientFactory = clientFactory;
    this.eventBus = eventBus;
    this.uuid = uuid;
    this.isPackage = isPackage;

    HorizontalPanel wrapper = new HorizontalPanel();

    ClickHandler clickHandler =
        new ClickHandler() {

          public void onClick(ClickEvent event) {
            clickLoadHistory();
          }
        };
    layout = new FlexTable();
    ClickableLabel vh = new ClickableLabel(constants.VersionHistory1(), clickHandler);
    layout.setWidget(0, 0, vh);
    layout.getCellFormatter().setStyleName(0, 0, "metadata-Widget"); // NON-NLS
    FlexCellFormatter formatter = layout.getFlexCellFormatter();
    formatter.setHorizontalAlignment(0, 0, HasHorizontalAlignment.ALIGN_LEFT);

    refresh = new ImageButton(images.refresh());

    refresh.addClickHandler(clickHandler);

    layout.setWidget(0, 1, refresh);
    formatter.setHorizontalAlignment(0, 1, HasHorizontalAlignment.ALIGN_RIGHT);

    wrapper.setStyleName("version-browser-Border");

    wrapper.add(layout);

    layout.setWidth("100%");
    wrapper.setWidth("100%");

    initWidget(wrapper);
  }
Exemplo n.º 16
0
  // Method response to user click of "Search" menu in top menubar.
  // Causes popup panel to appear
  protected void doPostSearch() {
    VerticalPanel content = new VerticalPanel();
    content.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_CENTER);

    HorizontalPanel inputRow = new HorizontalPanel();
    Label searchTermLabel = new Label("Search Title Term: ");
    final TextBox searchTermTextBox = new TextBox();
    inputRow.add(searchTermLabel);
    inputRow.add(searchTermTextBox);

    HorizontalPanel btnRow = new HorizontalPanel();
    btnRow.setStyleName("search-button-row");
    Button cancelBtn = new Button("Cancel");
    cancelBtn.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            searchPopup.hide();
          }
        });
    Button searchBtn = new Button("Search");
    searchBtn.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            control.handleTitleSearchRequest(searchTermTextBox.getText());
            searchPopup.hide();
          }
        });
    btnRow.add(cancelBtn);
    btnRow.add(new Label(""));
    btnRow.add(searchBtn);

    content.add(inputRow);
    content.add(btnRow);
    searchPopup.setWidget(content);
    searchPopup.center();
  }
Exemplo n.º 17
0
  private Widget getDetailSection() {
    HorizontalPanel panel = new HorizontalPanel();
    panel.setWidth("100%");
    panel.setStyleName("studio-Bottom-Panel");

    VerticalPanel ruleDefPanel = new VerticalPanel();
    ruleDefPanel.setWidth("95%");

    Label lbl = new Label();
    lbl.setText("Rule Definition");
    lbl.setStyleName("studio-Label-Small");

    ruleDef = new TextArea();
    ruleDef.setWidth("100%");
    ruleDef.setVisibleLines(5);
    ruleDef.setReadOnly(true);

    ruleDefPanel.add(lbl);
    ruleDefPanel.add(ruleDef);

    panel.add(ruleDefPanel);

    return panel.asWidget();
  }
Exemplo n.º 18
0
 public void onMouseLeave(Widget sender) {
   if (sender == closeTabImage) {
     MantleImages.images.closeTab().applyTo(closeTabImage);
     if (tabPanel.getTabBar().getSelectedTab() == tabPanel.getWidgetIndex(tabContent)) {
       panel.setStyleName("tabWidget-selected"); // $NON-NLS-1$
       leftCap.setStyleName("tabWidgetCap-selected"); // $NON-NLS-1$
     } else {
       panel.setStyleName("tabWidget"); // $NON-NLS-1$
       leftCap.setStyleName("tabWidgetCap"); // $NON-NLS-1$
     }
   } else {
     if (tabPanel.getTabBar().getSelectedTab() == tabPanel.getWidgetIndex(tabContent)) {
       // don't do anything
     } else {
       panel.setStyleName("tabWidget"); // $NON-NLS-1$
       leftCap.setStyleName("tabWidgetCap"); // $NON-NLS-1$
     }
   }
 }
Exemplo n.º 19
0
  public ComboBox(String cssSuffix) {

    cellList =
        new CellList<String>(
            new TextCell() {
              @Override
              public void render(Context context, String data, SafeHtmlBuilder sb) {
                String cssName =
                    (context.getIndex() % 2 > 0)
                        ? "combobox-item combobox-item-odd"
                        : "combobox-item";

                if (data.equals(currentValue.getText())) cssName += " combobox-item-selected";

                sb.append(TEMPLATE.item(cssName, data));
              }
            });

    final SingleSelectionModel<String> selectionModel = new SingleSelectionModel<String>();
    cellList.setSelectionModel(selectionModel);

    selectionModel.addSelectionChangeHandler(
        new SelectionChangeEvent.Handler() {
          public void onSelectionChange(SelectionChangeEvent event) {
            String selectedValue = selectionModel.getSelectedObject();

            currentValue.setHTML(selectedValue);
            popup.hide();

            onSelection(selectedValue);
          }
        });

    final String panelId = "popup_" + HTMLPanel.createUniqueId();
    popup =
        new PopupPanel(true, true) {

          @Override
          protected void onPreviewNativeEvent(Event.NativePreviewEvent event) {
            if (Event.ONKEYUP == event.getTypeInt()) {
              if (event.getNativeEvent().getKeyCode() == ESCAPE) {
                // Dismiss when escape is pressed
                popup.hide();
              }
            }
          }

          public void onBrowserEvent(Event event) {
            super.onBrowserEvent(event);
          }
        };

    popup.getElement().setId(panelId);

    popup.setStyleName("default-popup");

    popup.setWidget(cellList);

    currentValue = new HTML("&nbsp;");
    currentValue.setStyleName("combobox-value" + cssSuffix);

    header = new HorizontalPanel();
    header.setStyleName("combobox" + cssSuffix);
    header.add(currentValue);

    Image img = new Image(Icons.INSTANCE.comboPicker());
    header.add(img);

    currentValue.getElement().getParentElement().setAttribute("width", "100%");

    img.getParent().getElement().setAttribute("width", "18");

    header.getElement().setAttribute("width", "100%");
    header.getElement().setAttribute("cellspacing", "0");
    header.getElement().setAttribute("cellpadding", "0");
    header.getElement().setAttribute("border", "0");

    ClickHandler clickHandler =
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent clickEvent) {
            openPanel();
          }
        };

    currentValue.addClickHandler(clickHandler);
    img.addClickHandler(clickHandler);
  }
Exemplo n.º 20
0
  public WindowHeader(String title, final PopupPanel callback) {

    final HorizontalPanel header = new HorizontalPanel();
    header.setStyleName("default-window-header");

    HTML titleText = new HTML(title);
    titleText.setStyleName("default-window-title");

    Image closeIcon = new Image(Icons.INSTANCE.close());
    closeIcon.setAltText("Close");
    closeIcon.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent clickEvent) {
            callback.hide();
          }
        });

    Image maximizeIcon = new Image(Icons.INSTANCE.maximize());
    maximizeIcon.setAltText("Min/Maximize");
    maximizeIcon.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent clickEvent) {

            int width = origWidth;
            int height = origHeight;

            int top = origTop;
            int left = origLeft;

            if (origWidth == -1) {
              origWidth = getOffsetWidth();
              origHeight = (int) (origWidth / 1.618) + 50; // TODO: this fails "getOffsetHeight()";
              origLeft = getAbsoluteLeft();
              origTop = getAbsoluteTop();

              width = Window.getClientWidth() - 50;
              height = Window.getClientHeight() - 50;

              top = 25;
              left = 25;
            } else {
              origWidth = -1;
              origHeight = -1;
              origLeft = -1;
              origTop = -1;
            }

            callback.hide();

            callback.setPopupPosition(top, left);
            callback.setWidth(width + "px");
            callback.setHeight(height + "px");

            callback.show();
          }
        });

    header.add(titleText);
    header.add(maximizeIcon);
    header.add(closeIcon);

    initWidget(header);

    titleText.getElement().getParentElement().setAttribute("width", "100%");

    maximizeIcon.getElement().getParentElement().setAttribute("width", "16px");
    maximizeIcon
        .getElement()
        .getParentElement()
        .setAttribute("style", "width:16px;padding-right:5px");

    closeIcon.getElement().getParentElement().setAttribute("width", "16px");
    closeIcon.getElement().getParentElement().setAttribute("style", "width:16px;padding-right:5px");
  }
  public com.google.gwt.user.client.ui.Widget createAndBindUi(
      final com.rhiscom.bpm.console.client.ui.quadrature.CuadraturaPagosCMRViewImpl owner) {

    com.rhiscom.bpm.console.client.ui.quadrature.CuadraturaPagosCMRViewImpl_BinderImpl_GenBundle
        clientBundleFieldNameUnlikelyToCollideWithUserSpecifiedFieldOkay =
            (com.rhiscom.bpm.console.client.ui.quadrature
                    .CuadraturaPagosCMRViewImpl_BinderImpl_GenBundle)
                GWT.create(
                    com.rhiscom.bpm.console.client.ui.quadrature
                        .CuadraturaPagosCMRViewImpl_BinderImpl_GenBundle.class);
    com.rhiscom.bpm.console.client.ui.quadrature.CuadraturaPagosCMRViewImpl_BinderImpl_GenCss_style
        style = clientBundleFieldNameUnlikelyToCollideWithUserSpecifiedFieldOkay.style();
    java.lang.String domId0 = com.google.gwt.dom.client.Document.get().createUniqueId();
    com.google.gwt.user.client.ui.Label title =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HTMLPanel htmlPanel =
        new com.google.gwt.user.client.ui.HTMLPanel(
            template
                .html1(
                    "" + style.titleBackground() + "",
                    "" + style.titleBackgroundPosition() + "",
                    domId0)
                .asString());
    com.google.gwt.user.client.ui.Label lblError =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel3 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label6 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.ListBox sucursalSeleccionada =
        (com.google.gwt.user.client.ui.ListBox)
            GWT.create(com.google.gwt.user.client.ui.ListBox.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel5 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label8 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.datepicker.client.DateBox dateOfBusinessDateBox =
        owner.dateOfBusinessDateBox;
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel7 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.Button filterButton =
        (com.google.gwt.user.client.ui.Button)
            GWT.create(com.google.gwt.user.client.ui.Button.class);
    com.google.gwt.user.client.ui.Button excelButton =
        (com.google.gwt.user.client.ui.Button)
            GWT.create(com.google.gwt.user.client.ui.Button.class);
    com.google.gwt.user.client.ui.Label f_Label10 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblVersionPOS =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel9 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel4 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label14 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label f_Label15 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel13 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label18 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblPagoNormal =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel17 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label20 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblPagoRepactado =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel19 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label22 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblPagoAnulado =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel21 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label24 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTotalPagos =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel23 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel16 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel12 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label27 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label f_Label28 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel26 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label30 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTotalAbonos =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel29 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label32 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTotalAbonoNormal =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel31 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel33 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label35 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTotalAbonosSCTFA =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel34 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel25 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label38 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label f_Label39 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel37 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label41 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTrx217 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel40 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label43 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTrx402 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel42 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label45 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel44 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label47 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTotalCRCMR =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel46 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel36 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel11 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label51 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label f_Label52 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel50 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label54 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTotalPagosSAT =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel53 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label56 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTotalAnulacionesSAT =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel55 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label58 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel57 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label60 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTotalFinalSAT =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel59 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel49 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label63 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label f_Label64 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel62 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label66 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTotalPagosRSAT =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel65 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label68 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTotalAnulacionesRSAT =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel67 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label70 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel69 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.Label f_Label72 =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.Label lblTotalFinalRSAT =
        (com.google.gwt.user.client.ui.Label) GWT.create(com.google.gwt.user.client.ui.Label.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel71 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel61 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel73 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel48 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel2 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);
    com.google.gwt.user.client.ui.VerticalPanel f_VerticalPanel1 =
        (com.google.gwt.user.client.ui.VerticalPanel)
            GWT.create(com.google.gwt.user.client.ui.VerticalPanel.class);

    title.setStyleName("" + style.title() + "");
    title.setText("Cuadratura Pagos CMR");
    htmlPanel.setWidth("100%");
    f_VerticalPanel2.add(htmlPanel);
    f_HorizontalPanel3.setHorizontalAlignment(
        com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_CENTER);
    lblError.setStyleName("lblError");
    lblError.setHorizontalAlignment(
        com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_CENTER);
    lblError.setWidth("99%");
    lblError.setText("Debe ingresar fecha de negocio");
    lblError.setHeight("20px");
    f_HorizontalPanel3.add(lblError);
    f_HorizontalPanel3.setWidth("100%");
    f_VerticalPanel2.add(f_HorizontalPanel3);
    f_Label6.setWidth("100px");
    f_Label6.setText("Sucursal");
    f_Label6.setHeight("");
    f_VerticalPanel5.add(f_Label6);
    sucursalSeleccionada.setWidth("100px");
    sucursalSeleccionada.setHeight("25px");
    f_VerticalPanel5.add(sucursalSeleccionada);
    f_HorizontalPanel4.add(f_VerticalPanel5);
    f_Label8.setText("Fecha de negocio");
    f_VerticalPanel7.add(f_Label8);
    f_VerticalPanel7.add(dateOfBusinessDateBox);
    f_HorizontalPanel4.add(f_VerticalPanel7);
    filterButton.setText("Buscar");
    f_HorizontalPanel4.add(filterButton);
    excelButton.setText("Exportar");
    f_HorizontalPanel4.add(excelButton);
    f_Label10.setText("Versión");
    f_VerticalPanel9.add(f_Label10);
    lblVersionPOS.setStyleName("" + style.secondTitle() + "");
    lblVersionPOS.setWidth("100px");
    lblVersionPOS.setHeight("25px");
    f_VerticalPanel9.add(lblVersionPOS);
    f_HorizontalPanel4.add(f_VerticalPanel9);
    f_HorizontalPanel4.setStyleName("" + style.filters() + "");
    f_HorizontalPanel4.setWidth("100%");
    f_VerticalPanel2.add(f_HorizontalPanel4);
    f_Label14.setStyleName("" + style.secondTitle() + "");
    f_Label14.setText("PLACUAD");
    f_VerticalPanel13.add(f_Label14);
    f_Label15.setStyleName("" + style.secondTitle() + "");
    f_Label15.setWidth("100%");
    f_Label15.setText("CMR");
    f_VerticalPanel13.add(f_Label15);
    f_VerticalPanel13.setWidth("100%");
    f_VerticalPanel12.add(f_VerticalPanel13);
    f_Label18.setHorizontalAlignment(
        com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_LEFT);
    f_Label18.setWidth("215px");
    f_Label18.setText("Pago Normal");
    f_Label18.setHeight("25px");
    f_HorizontalPanel17.add(f_Label18);
    f_HorizontalPanel17.setCellVerticalAlignment(
        f_Label18, com.google.gwt.user.client.ui.HasVerticalAlignment.ALIGN_MIDDLE);
    lblPagoNormal.setWidth("100px");
    lblPagoNormal.setHeight("25px");
    f_HorizontalPanel17.add(lblPagoNormal);
    f_HorizontalPanel17.setCellHorizontalAlignment(
        lblPagoNormal, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel17.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel17.setWidth("100%");
    f_VerticalPanel16.add(f_HorizontalPanel17);
    f_Label20.setWidth("215px");
    f_Label20.setText("Pago Repactado");
    f_Label20.setHeight("25px");
    f_HorizontalPanel19.add(f_Label20);
    lblPagoRepactado.setWidth("100px");
    lblPagoRepactado.setHeight("25px");
    f_HorizontalPanel19.add(lblPagoRepactado);
    f_HorizontalPanel19.setCellHorizontalAlignment(
        lblPagoRepactado, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel19.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel19.setWidth("100%");
    f_VerticalPanel16.add(f_HorizontalPanel19);
    f_Label22.setWidth("215px");
    f_Label22.setText("Pagos Anulados");
    f_Label22.setHeight("25px");
    f_HorizontalPanel21.add(f_Label22);
    lblPagoAnulado.setWidth("100px");
    lblPagoAnulado.setHeight("25px");
    f_HorizontalPanel21.add(lblPagoAnulado);
    f_HorizontalPanel21.setCellHorizontalAlignment(
        lblPagoAnulado, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel21.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel21.setWidth("100%");
    f_VerticalPanel16.add(f_HorizontalPanel21);
    f_Label24.setStyleName("" + style.redTitle() + "");
    f_Label24.setWidth("215px");
    f_Label24.setText("Total Pagos");
    f_Label24.setHeight("25px");
    f_HorizontalPanel23.add(f_Label24);
    lblTotalPagos.setStyleName("" + style.redTitle() + "");
    lblTotalPagos.setWidth("100px");
    lblTotalPagos.setHeight("25px");
    f_HorizontalPanel23.add(lblTotalPagos);
    f_HorizontalPanel23.setCellHorizontalAlignment(
        lblTotalPagos, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel23.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel23.setWidth("100%");
    f_VerticalPanel16.add(f_HorizontalPanel23);
    f_VerticalPanel16.setWidth("100%");
    f_VerticalPanel12.add(f_VerticalPanel16);
    f_VerticalPanel12.setStyleName("" + style.borderDecorator() + "");
    f_VerticalPanel12.setWidth("350px");
    f_HorizontalPanel11.add(f_VerticalPanel12);
    f_Label27.setStyleName("" + style.secondTitle() + "");
    f_Label27.setText("SCTFA");
    f_VerticalPanel26.add(f_Label27);
    f_Label28.setStyleName("" + style.secondTitle() + "");
    f_Label28.setWidth("100%");
    f_Label28.setText("CMR");
    f_VerticalPanel26.add(f_Label28);
    f_VerticalPanel26.setWidth("100%");
    f_VerticalPanel25.add(f_VerticalPanel26);
    f_Label30.setWidth("215px");
    f_Label30.setText("Total Abonos");
    f_Label30.setHeight("25px");
    f_HorizontalPanel29.add(f_Label30);
    f_HorizontalPanel29.setCellWidth(f_Label30, "150px");
    f_HorizontalPanel29.setCellHeight(f_Label30, "25px");
    lblTotalAbonos.setWidth("100px");
    lblTotalAbonos.setHeight("25px");
    f_HorizontalPanel29.add(lblTotalAbonos);
    f_HorizontalPanel29.setCellHorizontalAlignment(
        lblTotalAbonos, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel29.setCellWidth(lblTotalAbonos, "150px");
    f_HorizontalPanel29.setCellHeight(lblTotalAbonos, "25px");
    f_HorizontalPanel29.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel29.setWidth("100%");
    f_VerticalPanel25.add(f_HorizontalPanel29);
    f_Label32.setWidth("215px");
    f_Label32.setText("Total Anulación Abono Normal");
    f_Label32.setHeight("25px");
    f_HorizontalPanel31.add(f_Label32);
    lblTotalAbonoNormal.setHorizontalAlignment(
        com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    lblTotalAbonoNormal.setWidth("100px");
    lblTotalAbonoNormal.setHeight("25px");
    f_HorizontalPanel31.add(lblTotalAbonoNormal);
    f_HorizontalPanel31.setCellHorizontalAlignment(
        lblTotalAbonoNormal, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel31.setCellWidth(lblTotalAbonoNormal, "150px");
    f_HorizontalPanel31.setCellHeight(lblTotalAbonoNormal, "25px");
    f_HorizontalPanel31.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel31.setWidth("100%");
    f_VerticalPanel25.add(f_HorizontalPanel31);
    f_HorizontalPanel33.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel33.setWidth("100%");
    f_HorizontalPanel33.setHeight("25px");
    f_VerticalPanel25.add(f_HorizontalPanel33);
    f_Label35.setStyleName("" + style.redTitle() + "");
    f_Label35.setWidth("215px");
    f_Label35.setText("Total Abonos");
    f_Label35.setHeight("25px");
    f_HorizontalPanel34.add(f_Label35);
    f_HorizontalPanel34.setCellWidth(f_Label35, "198px");
    f_HorizontalPanel34.setCellHeight(f_Label35, "25px");
    lblTotalAbonosSCTFA.setStyleName("" + style.redTitle() + "");
    lblTotalAbonosSCTFA.setWidth("100px");
    lblTotalAbonosSCTFA.setHeight("25px");
    f_HorizontalPanel34.add(lblTotalAbonosSCTFA);
    f_HorizontalPanel34.setCellHorizontalAlignment(
        lblTotalAbonosSCTFA, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel34.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel34.setWidth("100%");
    f_VerticalPanel25.add(f_HorizontalPanel34);
    f_VerticalPanel25.setStyleName("" + style.borderDecorator() + "");
    f_VerticalPanel25.setWidth("350px");
    f_HorizontalPanel11.add(f_VerticalPanel25);
    f_VerticalPanel36.setHorizontalAlignment(
        com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_LEFT);
    f_Label38.setStyleName("" + style.secondTitle() + "");
    f_Label38.setText("CRCMR");
    f_VerticalPanel37.add(f_Label38);
    f_Label39.setStyleName("" + style.secondTitle() + "");
    f_Label39.setText("CMR");
    f_VerticalPanel37.add(f_Label39);
    f_VerticalPanel37.setWidth("100%");
    f_VerticalPanel36.add(f_VerticalPanel37);
    f_Label41.setWidth("215px");
    f_Label41.setText("TRX 217 y 238");
    f_Label41.setHeight("25px");
    f_HorizontalPanel40.add(f_Label41);
    lblTrx217.setWidth("100px");
    lblTrx217.setHeight("25px");
    f_HorizontalPanel40.add(lblTrx217);
    f_HorizontalPanel40.setCellHorizontalAlignment(
        lblTrx217, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel40.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel40.setWidth("100%");
    f_VerticalPanel36.add(f_HorizontalPanel40);
    f_Label43.setWidth("215px");
    f_Label43.setText("TRX 402 y 401");
    f_Label43.setHeight("25px");
    f_HorizontalPanel42.add(f_Label43);
    lblTrx402.setWidth("100px");
    lblTrx402.setHeight("25px");
    f_HorizontalPanel42.add(lblTrx402);
    f_HorizontalPanel42.setCellHorizontalAlignment(
        lblTrx402, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel42.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel42.setWidth("100%");
    f_VerticalPanel36.add(f_HorizontalPanel42);
    f_Label45.setWidth("40%");
    f_Label45.setHeight("25px");
    f_HorizontalPanel44.add(f_Label45);
    f_HorizontalPanel44.setCellHorizontalAlignment(
        f_Label45, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel44.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel44.setWidth("100%");
    f_VerticalPanel36.add(f_HorizontalPanel44);
    f_Label47.setStyleName("" + style.redTitle() + "");
    f_Label47.setWidth("215px");
    f_Label47.setText("Total Abonos");
    f_Label47.setHeight("25px");
    f_HorizontalPanel46.add(f_Label47);
    lblTotalCRCMR.setStyleName("" + style.redTitle() + "");
    lblTotalCRCMR.setWidth("100px");
    lblTotalCRCMR.setHeight("25px");
    f_HorizontalPanel46.add(lblTotalCRCMR);
    f_HorizontalPanel46.setCellHorizontalAlignment(
        lblTotalCRCMR, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel46.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel46.setWidth("100%");
    f_VerticalPanel36.add(f_HorizontalPanel46);
    f_VerticalPanel36.setStyleName("" + style.borderDecorator() + "");
    f_VerticalPanel36.setWidth("350px");
    f_HorizontalPanel11.add(f_VerticalPanel36);
    f_HorizontalPanel11.setSpacing(2);
    f_HorizontalPanel11.setWidth("100%");
    f_VerticalPanel2.add(f_HorizontalPanel11);
    f_VerticalPanel2.setCellWidth(f_HorizontalPanel11, "100%");
    f_Label51.setStyleName("" + style.secondTitle() + "");
    f_Label51.setText("");
    f_VerticalPanel50.add(f_Label51);
    f_Label52.setStyleName("" + style.secondTitle() + "");
    f_Label52.setText("SAT");
    f_VerticalPanel50.add(f_Label52);
    f_VerticalPanel50.setWidth("100%");
    f_VerticalPanel49.add(f_VerticalPanel50);
    f_Label54.setWidth("215px");
    f_Label54.setText("TRX 217 y 238");
    f_Label54.setHeight("25px");
    f_HorizontalPanel53.add(f_Label54);
    lblTotalPagosSAT.setWidth("100px");
    lblTotalPagosSAT.setHeight("25px");
    f_HorizontalPanel53.add(lblTotalPagosSAT);
    f_HorizontalPanel53.setCellHorizontalAlignment(
        lblTotalPagosSAT, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel53.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel53.setWidth("100%");
    f_VerticalPanel49.add(f_HorizontalPanel53);
    f_Label56.setWidth("215px");
    f_Label56.setText("TRX 402 y 401");
    f_Label56.setHeight("25px");
    f_HorizontalPanel55.add(f_Label56);
    lblTotalAnulacionesSAT.setWidth("100px");
    lblTotalAnulacionesSAT.setHeight("25px");
    f_HorizontalPanel55.add(lblTotalAnulacionesSAT);
    f_HorizontalPanel55.setCellHorizontalAlignment(
        lblTotalAnulacionesSAT, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel55.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel55.setWidth("100%");
    f_VerticalPanel49.add(f_HorizontalPanel55);
    f_Label58.setWidth("40%");
    f_Label58.setHeight("25px");
    f_HorizontalPanel57.add(f_Label58);
    f_HorizontalPanel57.setCellHorizontalAlignment(
        f_Label58, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel57.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel57.setWidth("100%");
    f_VerticalPanel49.add(f_HorizontalPanel57);
    f_Label60.setStyleName("" + style.redTitle() + "");
    f_Label60.setWidth("215px");
    f_Label60.setText("Total Abonos");
    f_Label60.setHeight("25px");
    f_HorizontalPanel59.add(f_Label60);
    lblTotalFinalSAT.setStyleName("" + style.redTitle() + "");
    lblTotalFinalSAT.setWidth("100px");
    lblTotalFinalSAT.setHeight("25px");
    f_HorizontalPanel59.add(lblTotalFinalSAT);
    f_HorizontalPanel59.setCellHorizontalAlignment(
        lblTotalFinalSAT, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel59.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel59.setWidth("100%");
    f_VerticalPanel49.add(f_HorizontalPanel59);
    f_VerticalPanel49.setStyleName("" + style.borderDecorator() + "");
    f_VerticalPanel49.setWidth("350px");
    f_HorizontalPanel48.add(f_VerticalPanel49);
    f_Label63.setStyleName("" + style.secondTitle() + "");
    f_Label63.setText("");
    f_VerticalPanel62.add(f_Label63);
    f_Label64.setStyleName("" + style.secondTitle() + "");
    f_Label64.setText("RSAT");
    f_VerticalPanel62.add(f_Label64);
    f_VerticalPanel62.setWidth("100%");
    f_VerticalPanel61.add(f_VerticalPanel62);
    f_Label66.setWidth("215px");
    f_Label66.setText("TRX 217 y 238");
    f_Label66.setHeight("25px");
    f_HorizontalPanel65.add(f_Label66);
    lblTotalPagosRSAT.setWidth("100px");
    lblTotalPagosRSAT.setHeight("25px");
    f_HorizontalPanel65.add(lblTotalPagosRSAT);
    f_HorizontalPanel65.setCellHorizontalAlignment(
        lblTotalPagosRSAT, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel65.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel65.setWidth("100%");
    f_VerticalPanel61.add(f_HorizontalPanel65);
    f_Label68.setWidth("215px");
    f_Label68.setText("TRX 402 y 401");
    f_Label68.setHeight("25px");
    f_HorizontalPanel67.add(f_Label68);
    lblTotalAnulacionesRSAT.setWidth("100px");
    lblTotalAnulacionesRSAT.setHeight("25px");
    f_HorizontalPanel67.add(lblTotalAnulacionesRSAT);
    f_HorizontalPanel67.setCellHorizontalAlignment(
        lblTotalAnulacionesRSAT, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel67.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel67.setWidth("100%");
    f_VerticalPanel61.add(f_HorizontalPanel67);
    f_Label70.setWidth("40%");
    f_Label70.setHeight("25px");
    f_HorizontalPanel69.add(f_Label70);
    f_HorizontalPanel69.setCellHorizontalAlignment(
        f_Label70, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel69.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel69.setWidth("100%");
    f_VerticalPanel61.add(f_HorizontalPanel69);
    f_Label72.setStyleName("" + style.redTitle() + "");
    f_Label72.setWidth("215px");
    f_Label72.setText("Total Abonos");
    f_Label72.setHeight("25px");
    f_HorizontalPanel71.add(f_Label72);
    lblTotalFinalRSAT.setStyleName("" + style.redTitle() + "");
    lblTotalFinalRSAT.setWidth("100px");
    lblTotalFinalRSAT.setHeight("25px");
    f_HorizontalPanel71.add(lblTotalFinalRSAT);
    f_HorizontalPanel71.setCellHorizontalAlignment(
        lblTotalFinalRSAT, com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_RIGHT);
    f_HorizontalPanel71.setStyleName("" + style.borderSimple() + "");
    f_HorizontalPanel71.setWidth("100%");
    f_VerticalPanel61.add(f_HorizontalPanel71);
    f_VerticalPanel61.setStyleName("" + style.borderDecorator() + "");
    f_VerticalPanel61.setWidth("350px");
    f_HorizontalPanel48.add(f_VerticalPanel61);
    f_VerticalPanel73.setHorizontalAlignment(
        com.google.gwt.user.client.ui.HasHorizontalAlignment.ALIGN_LEFT);
    f_VerticalPanel73.setWidth("350px");
    f_HorizontalPanel48.add(f_VerticalPanel73);
    f_HorizontalPanel48.setSpacing(2);
    f_HorizontalPanel48.setWidth("100%");
    f_VerticalPanel2.add(f_HorizontalPanel48);
    f_VerticalPanel2.setWidth("100%");
    f_VerticalPanel1.add(f_VerticalPanel2);
    f_VerticalPanel1.setWidth("100%");

    UiBinderUtil.TempAttachment attachRecord0 = UiBinderUtil.attachToDom(htmlPanel.getElement());
    com.google.gwt.user.client.Element domId0Element =
        com.google.gwt.dom.client.Document.get().getElementById(domId0).cast();
    attachRecord0.detach();
    htmlPanel.addAndReplaceElement(title, domId0Element);

    final com.google.gwt.event.dom.client.ClickHandler
        handlerMethodWithNameVeryUnlikelyToCollideWithUserFieldNames1 =
            new com.google.gwt.event.dom.client.ClickHandler() {
              public void onClick(com.google.gwt.event.dom.client.ClickEvent event) {
                owner.onClickCSV(event);
              }
            };
    filterButton.addClickHandler(handlerMethodWithNameVeryUnlikelyToCollideWithUserFieldNames1);

    final com.google.gwt.event.dom.client.ClickHandler
        handlerMethodWithNameVeryUnlikelyToCollideWithUserFieldNames2 =
            new com.google.gwt.event.dom.client.ClickHandler() {
              public void onClick(com.google.gwt.event.dom.client.ClickEvent event) {
                owner.onClickExcel(event);
              }
            };
    excelButton.addClickHandler(handlerMethodWithNameVeryUnlikelyToCollideWithUserFieldNames2);

    owner.filterButton = filterButton;
    owner.lblError = lblError;
    owner.lblPagoAnulado = lblPagoAnulado;
    owner.lblPagoNormal = lblPagoNormal;
    owner.lblPagoRepactado = lblPagoRepactado;
    owner.lblTotalAbonoNormal = lblTotalAbonoNormal;
    owner.lblTotalAbonos = lblTotalAbonos;
    owner.lblTotalAbonosSCTFA = lblTotalAbonosSCTFA;
    owner.lblTotalAnulacionesRSAT = lblTotalAnulacionesRSAT;
    owner.lblTotalAnulacionesSAT = lblTotalAnulacionesSAT;
    owner.lblTotalCRCMR = lblTotalCRCMR;
    owner.lblTotalFinalRSAT = lblTotalFinalRSAT;
    owner.lblTotalFinalSAT = lblTotalFinalSAT;
    owner.lblTotalPagos = lblTotalPagos;
    owner.lblTotalPagosRSAT = lblTotalPagosRSAT;
    owner.lblTotalPagosSAT = lblTotalPagosSAT;
    owner.lblTrx217 = lblTrx217;
    owner.lblTrx402 = lblTrx402;
    owner.lblVersionPOS = lblVersionPOS;
    owner.sucursalSeleccionada = sucursalSeleccionada;
    clientBundleFieldNameUnlikelyToCollideWithUserSpecifiedFieldOkay.style().ensureInjected();

    return f_VerticalPanel1;
  }
Exemplo n.º 22
0
 /**
  * Sets the caption stylename
  *
  * @param toWysiwym True to adopt wysiwym style
  */
 public void setCaptionStyle(boolean toWysiwym) {
   dock.setStyleName("Caption");
 }
  public ResizableDialogBox(
      final String headerText,
      String okText,
      String cancelText,
      final Widget content,
      final boolean modal) {
    this.content = content;
    boundaryPanel =
        new AbsolutePanel() {
          public void onBrowserEvent(Event event) {
            super.onBrowserEvent(event);
            if (!modal && event.getTypeInt() == Event.ONCLICK) {
              hide();
            }
          }
        };
    boundaryPanel.setSize(
        "100%",
        Window.getClientHeight() + Window.getScrollTop() + "px"); // $NON-NLS-1$ //$NON-NLS-2$
    boundaryPanel.setVisible(true);
    RootPanel.get().add(boundaryPanel, 0, 0);
    boundaryPanel.sinkEvents(Event.ONCLICK);
    boundaryPanel
        .getElement()
        .getStyle()
        .setProperty("cursor", "wait"); // $NON-NLS-1$ //$NON-NLS-2$

    // initialize window controller which provides drag and resize windows
    WindowController windowController = new WindowController(boundaryPanel);

    // content wrapper
    Button ok = new Button(okText);
    ok.setStylePrimaryName("pentaho-button");
    ok.getElement().setAttribute("id", "okButton"); // $NON-NLS-1$ //$NON-NLS-2$
    ok.addClickHandler(
        new ClickHandler() {

          @Override
          public void onClick(ClickEvent event) {
            if (validatorCallback == null
                || (validatorCallback != null && validatorCallback.validate())) {
              try {
                if (callback != null) {
                  callback.okPressed();
                }
              } catch (Throwable dontCare) {
              }
              hide();
            }
          }
        });
    final HorizontalPanel dialogButtonPanel = new HorizontalPanel();
    dialogButtonPanel.setSpacing(2);
    dialogButtonPanel.add(ok);
    if (cancelText != null) {
      Button cancel = new Button(cancelText);
      cancel.setStylePrimaryName("pentaho-button");
      cancel.getElement().setAttribute("id", "cancelButton"); // $NON-NLS-1$ //$NON-NLS-2$
      cancel.addClickHandler(
          new ClickHandler() {

            public void onClick(ClickEvent event) {
              try {
                if (callback != null) {
                  callback.cancelPressed();
                }
              } catch (Throwable dontCare) {
              }
              hide();
            }
          });
      dialogButtonPanel.add(cancel);
    }
    HorizontalPanel dialogButtonPanelWrapper = new HorizontalPanel();
    if (okText != null && cancelText != null) {
      dialogButtonPanelWrapper.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_RIGHT);
    } else {
      dialogButtonPanelWrapper.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_CENTER);
    }
    dialogButtonPanelWrapper.setStyleName("dialogButtonPanel"); // $NON-NLS-1$
    dialogButtonPanelWrapper.setWidth("100%"); // $NON-NLS-1$
    dialogButtonPanelWrapper.add(dialogButtonPanel);

    Grid dialogContent = new Grid(2, 1);
    dialogContent.setCellPadding(0);
    dialogContent.setCellSpacing(0);
    dialogContent.getCellFormatter().setVerticalAlignment(1, 0, HasVerticalAlignment.ALIGN_TOP);
    dialogContent
        .getCellFormatter()
        .setHorizontalAlignment(1, 0, HasHorizontalAlignment.ALIGN_LEFT);
    // add content
    dialogContent.setWidget(0, 0, content);
    dialogContent.getCellFormatter().setVerticalAlignment(0, 0, HasVerticalAlignment.ALIGN_TOP);
    // add button panel
    dialogContent.setWidget(1, 0, dialogButtonPanelWrapper);
    dialogContent.getCellFormatter().setVerticalAlignment(1, 0, HasVerticalAlignment.ALIGN_BOTTOM);
    dialogContent.setWidth("100%"); // $NON-NLS-1$
    dialogContent.setHeight("100%"); // $NON-NLS-1$

    windowPanel = new WindowPanel(windowController, headerText, dialogContent, true);
  }
  public com.google.gwt.user.client.ui.Widget createAndBindUi(
      final com.rhiscom.bpm.console.client.ui.process.ProcessManagementViewImpl owner) {

    com.rhiscom.bpm.console.client.ui.process.ProcessManagementViewImpl_BinderImpl_GenBundle
        clientBundleFieldNameUnlikelyToCollideWithUserSpecifiedFieldOkay =
            (com.rhiscom.bpm.console.client.ui.process
                    .ProcessManagementViewImpl_BinderImpl_GenBundle)
                GWT.create(
                    com.rhiscom.bpm.console.client.ui.process
                        .ProcessManagementViewImpl_BinderImpl_GenBundle.class);
    com.rhiscom.bpm.console.client.ui.process.ProcessManagementViewImpl_BinderImpl_GenCss_style
        style = clientBundleFieldNameUnlikelyToCollideWithUserSpecifiedFieldOkay.style();
    java.lang.String domId0 = com.google.gwt.dom.client.Document.get().createUniqueId();
    com.google.gwt.user.client.ui.MenuItem btnRefrescar =
        new com.google.gwt.user.client.ui.MenuItem("", (com.google.gwt.user.client.Command) null);
    com.google.gwt.user.client.ui.MenuBar menuBarProcesos =
        (com.google.gwt.user.client.ui.MenuBar)
            GWT.create(com.google.gwt.user.client.ui.MenuBar.class);
    com.google.gwt.user.client.ui.HorizontalPanel f_HorizontalPanel1 =
        (com.google.gwt.user.client.ui.HorizontalPanel)
            GWT.create(com.google.gwt.user.client.ui.HorizontalPanel.class);
    java.lang.String domId1 = com.google.gwt.dom.client.Document.get().createUniqueId();
    java.lang.String domId2 = com.google.gwt.dom.client.Document.get().createUniqueId();
    com.google.gwt.user.client.ui.FlexTable flexProcessTable =
        (com.google.gwt.user.client.ui.FlexTable)
            GWT.create(com.google.gwt.user.client.ui.FlexTable.class);
    com.google.gwt.user.client.ui.SimplePanel f_SimplePanel3 =
        (com.google.gwt.user.client.ui.SimplePanel)
            GWT.create(com.google.gwt.user.client.ui.SimplePanel.class);
    com.google.gwt.user.client.ui.HTMLPanel f_HTMLPanel2 =
        new com.google.gwt.user.client.ui.HTMLPanel(template.html1(domId2).asString());
    com.google.gwt.user.client.ui.HTMLPanel htmlPanel =
        new com.google.gwt.user.client.ui.HTMLPanel(template.html2(domId0, domId1).asString());

    btnRefrescar.setStyleName("" + style.gwtMenuItem() + "");
    btnRefrescar.setWidth("130px");
    btnRefrescar.setText("Refrescar definiciones");
    menuBarProcesos.addItem(btnRefrescar);
    menuBarProcesos.setAutoOpen(false);
    menuBarProcesos.setTitle("Main");
    menuBarProcesos.setAnimationEnabled(true);
    f_HorizontalPanel1.add(menuBarProcesos);
    f_HorizontalPanel1.setStyleName("" + style.rightHorizontalPanel() + "");
    f_HorizontalPanel1.setWidth("100%");
    flexProcessTable.setWidth("100%");
    flexProcessTable.setHeight("100%");
    f_SimplePanel3.add(flexProcessTable);
    f_SimplePanel3.setWidth("100%");
    f_SimplePanel3.setHeight("100%");
    f_HTMLPanel2.setWidth("100%");
    f_HTMLPanel2.setHeight("100%");

    UiBinderUtil.TempAttachment attachRecord0 = UiBinderUtil.attachToDom(htmlPanel.getElement());
    com.google.gwt.user.client.Element domId0Element =
        com.google.gwt.dom.client.Document.get().getElementById(domId0).cast();
    UiBinderUtil.TempAttachment attachRecord1 = UiBinderUtil.attachToDom(f_HTMLPanel2.getElement());
    com.google.gwt.user.client.Element domId2Element =
        com.google.gwt.dom.client.Document.get().getElementById(domId2).cast();
    attachRecord1.detach();
    f_HTMLPanel2.addAndReplaceElement(f_SimplePanel3, domId2Element);
    com.google.gwt.user.client.Element domId1Element =
        com.google.gwt.dom.client.Document.get().getElementById(domId1).cast();
    attachRecord0.detach();
    htmlPanel.addAndReplaceElement(f_HorizontalPanel1, domId0Element);
    htmlPanel.addAndReplaceElement(f_HTMLPanel2, domId1Element);

    owner.btnRefrescar = btnRefrescar;
    owner.flexProcessTable = flexProcessTable;
    clientBundleFieldNameUnlikelyToCollideWithUserSpecifiedFieldOkay.style().ensureInjected();

    return htmlPanel;
  }
Exemplo n.º 25
0
  public CompositeToggleButton(String leftText, String rightText, final boolean ask) {
    holder = new HorizontalPanel();
    holder.setStyleName("tae-Composite-ToggleButton");
    holder.addStyleName("no-Padding");
    initWidget(holder);
    left = new com.google.gwt.user.client.ui.ToggleButton(leftText);
    left.setStylePrimaryName("tae-Composite-ToggleButton-Left");
    holder.add(left);
    right = new com.google.gwt.user.client.ui.ToggleButton(rightText);
    right.setStylePrimaryName("tae-Composite-ToggleButton-Right");
    holder.add(right);
    left.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            if (ask) {
              new ConfirmDialog(
                  new ConfirmDialog.RequiresUserResponse() {

                    @Override
                    public void onResponse(boolean response) {
                      if (response) {
                        setValue(true, true);
                      } else {
                        setValue(false, true);
                      }
                    }
                  },
                  "Are you sure you want to change task status?",
                  "YES",
                  "NO");
            } else {
              setValue(true, true);
            }
          }
        });
    right.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {
            if (ask) {
              new ConfirmDialog(
                  new ConfirmDialog.RequiresUserResponse() {

                    @Override
                    public void onResponse(boolean response) {
                      if (response) {
                        setValue(false, true);
                      } else {
                        setValue(true, true);
                      }
                    }
                  },
                  "Are you sure you want to change task status?",
                  "YES",
                  "NO");
            } else {
              setValue(false, true);
            }
          }
        });
  }
Exemplo n.º 26
0
  public TabWidget(
      String text,
      String tooltip,
      final SolutionBrowserPerspective perspective,
      final TabPanel tabPanel,
      final Widget tabContent) {
    // BISERVER-2317 Request for more IDs for Mantle UI elements
    // the id for each tab shall be the text which it displays
    getElement().setId("tab-" + text); // $NON-NLS-1$

    this.tabPanel = tabPanel;
    this.tabContent = tabContent;
    this.perspective = perspective;
    this.fullText = text;
    setVerticalAlignment(HasVerticalAlignment.ALIGN_MIDDLE);

    panel.setStyleName("tabWidget"); // $NON-NLS-1$
    leftCap.setStyleName("tabWidgetCap"); // $NON-NLS-1$
    Image leftCapImage = new Image();
    MantleImages.images.space1x20().applyTo(leftCapImage);
    leftCap.setSpacing(0);
    leftCapImage.setWidth("5px"); // $NON-NLS-1$
    leftCap.add(leftCapImage);

    setLabelText(text);
    setLabelTooltip(tooltip);
    textLabel.setWordWrap(false);
    textLabel.addMouseListener(this);

    tabPanel.addTabListener(
        new TabListener() {

          public boolean onBeforeTabSelected(SourcesTabEvents sender, int tabIndex) {
            return true;
          }

          public void onTabSelected(SourcesTabEvents sender, int tabIndex) {
            ElementUtils.blur(getElement().getParentElement());
            if (tabIndex == tabPanel.getWidgetIndex(tabContent)) {
              panel.setStyleName("tabWidget-selected"); // $NON-NLS-1$
              leftCap.setStyleName("tabWidgetCap-selected"); // $NON-NLS-1$
            } else {
              panel.setStyleName("tabWidget"); // $NON-NLS-1$
              leftCap.setStyleName("tabWidgetCap"); // $NON-NLS-1$
            }
          }
        });

    MantleImages.images.closeTab().applyTo(closeTabImage);
    closeTabImage.setTitle(Messages.getString("closeTab")); // $NON-NLS-1$
    closeTabImage.addMouseListener(this);
    closeTabImage.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            closeTab();
          }
        });
    closeTabImage.getElement().setId("killTab"); // $NON-NLS-1$

    panel.setVerticalAlignment(HasVerticalAlignment.ALIGN_MIDDLE);
    panel.add(textLabel);
    if (perspective != null) {
      panel.add(closeTabImage);
      DOM.setStyleAttribute(
          closeTabImage.getElement(), "margin", "5px"); // $NON-NLS-1$ //$NON-NLS-2$
      DOM.setStyleAttribute(
          textLabel.getElement(), "margin", "5px 0px 5px 0px"); // $NON-NLS-1$ //$NON-NLS-2$
    } else {
      DOM.setStyleAttribute(
          textLabel.getElement(), "margin", "4px 5px 5px 5px"); // $NON-NLS-1$ //$NON-NLS-2$
      DOM.setStyleAttribute(
          textLabel.getElement(), "paddingRight", "5px"); // $NON-NLS-1$ //$NON-NLS-2$
    }

    add(leftCap);
    add(panel);
    sinkEvents(Event.ONDBLCLICK | Event.ONMOUSEUP);
  }
  private Widget buildLoginPanel(boolean openInNewWindowDefault) {
    userTextBox.setWidth("100%"); // $NON-NLS-1$
    passwordTextBox.setWidth("100%"); // $NON-NLS-1$
    usersListBox.setWidth("100%"); // $NON-NLS-1$

    userTextBox.setStyleName("login-panel-label");
    passwordTextBox.setStyleName("login-panel-label");
    newWindowChk.setStyleName("login-panel-label");

    VerticalPanel credentialsPanel = new VerticalPanel();

    credentialsPanel.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_LEFT);
    credentialsPanel.setVerticalAlignment(HasVerticalAlignment.ALIGN_TOP);
    SimplePanel spacer;
    if (showUsersList) {
      // populate default users list box
      addDefaultUsers();
      Label sampleUsersLabel = new Label(Messages.getString("sampleUser") + ":");
      sampleUsersLabel.setStyleName("login-panel-label");
      credentialsPanel.add(sampleUsersLabel); // $NON-NLS-1$ //$NON-NLS-2$
      credentialsPanel.add(usersListBox);
      spacer = new SimplePanel();
      spacer.setHeight("8px"); // $NON-NLS-1$
      credentialsPanel.add(spacer);
    }

    Label usernameLabel = new Label(Messages.getString("username") + ":");
    usernameLabel.setStyleName("login-panel-label");

    credentialsPanel.add(usernameLabel); // $NON-NLS-1$ //$NON-NLS-2$
    credentialsPanel.add(userTextBox);

    spacer = new SimplePanel();
    spacer.setHeight("8px"); // $NON-NLS-1$
    credentialsPanel.add(spacer);

    credentialsPanel.setCellHeight(spacer, "8px"); // $NON-NLS-1$
    HTML passwordLabel = new HTML(Messages.getString("password") + ":");
    passwordLabel.setStyleName("login-panel-label");
    credentialsPanel.add(passwordLabel); // $NON-NLS-1$ //$NON-NLS-2$
    credentialsPanel.add(passwordTextBox);

    boolean reallyShowNewWindowOption = showNewWindowOption;

    String showNewWindowOverride =
        Window.Location.getParameter("showNewWindowOption"); // $NON-NLS-1$
    if (showNewWindowOverride != null && !"".equals(showNewWindowOverride)) { // $NON-NLS-1$
      // if the override is set, we MUST obey it above all else
      reallyShowNewWindowOption = "true".equals(showNewWindowOverride); // $NON-NLS-1$
    } else if (getReturnLocation() != null && !"".equals(getReturnLocation())) { // $NON-NLS-1$
      StringTokenizer st = new StringTokenizer(getReturnLocation(), "?&"); // $NON-NLS-1$
      // first token will be ignored, it is 'up to the ?'
      for (int i = 1; i < st.countTokens(); i++) {
        StringTokenizer paramTokenizer = new StringTokenizer(st.tokenAt(i), "="); // $NON-NLS-1$
        if (paramTokenizer.countTokens() == 2) {
          // we've got a name=value token
          if (paramTokenizer.tokenAt(0).equalsIgnoreCase("showNewWindowOption")) { // $NON-NLS-1$
            reallyShowNewWindowOption = "true".equals(paramTokenizer.tokenAt(1)); // $NON-NLS-1$
            break;
          }
        }
      }
    }

    // New Window checkbox
    if (reallyShowNewWindowOption) {
      spacer = new SimplePanel();
      spacer.setHeight("8px"); // $NON-NLS-1$
      credentialsPanel.add(spacer);
      credentialsPanel.setCellHeight(spacer, "8px"); // $NON-NLS-1$

      newWindowChk.setText(Messages.getString("launchInNewWindow")); // $NON-NLS-1$

      String cookieCheckedVal = Cookies.getCookie("loginNewWindowChecked"); // $NON-NLS-1$
      if (cookieCheckedVal != null) {
        newWindowChk.setValue(Boolean.parseBoolean(cookieCheckedVal));
      } else {
        // default is false, per BISERVER-2384
        newWindowChk.setValue(openInNewWindowDefault);
      }

      credentialsPanel.add(newWindowChk);
    }

    userTextBox.setTabIndex(1);
    passwordTextBox.setTabIndex(2);
    if (reallyShowNewWindowOption) {
      newWindowChk.setTabIndex(3);
    }
    passwordTextBox.setText(""); // $NON-NLS-1$

    setFocusWidget(userTextBox);

    Image lockImage = new Image(GWT.getModuleBaseURL() + "images/icon_login_lock.png");
    HorizontalPanel loginPanel = new HorizontalPanel();
    loginPanel.setSpacing(5);
    loginPanel.setStyleName("login-panel");
    loginPanel.add(lockImage);
    loginPanel.add(credentialsPanel);

    return loginPanel;
  }
Exemplo n.º 28
0
  public Widget asWidget() {

    HorizontalPanel layout = new HorizontalPanel();
    layout.getElement().setAttribute("title", "Notification Center");
    layout.setStyleName("notification-center");

    messageButton = new HTML(MESSAGE_LABEL + ": " + messageCenter.getNewMessageCount());
    messageButton.addStyleName("notification-button");

    ClickHandler clickHandler =
        new ClickHandler() {
          public void onClick(ClickEvent event) {

            int numMessages = fetchMessages(messagePopup);
            if (numMessages == 0) numMessages = 1;

            int width = 250;
            int height = numMessages * 35;

            messagePopup.setPopupPosition(
                messageButton.getAbsoluteLeft() - (width + 10 - messageButton.getOffsetWidth()),
                messageButton.getAbsoluteTop() + 25);

            messagePopup.show();
            Scheduler.get()
                .scheduleDeferred(
                    new Scheduler.ScheduledCommand() {
                      @Override
                      public void execute() {
                        messagePopup.focusOnFirstMessage();
                      }
                    });

            messagePopup.setWidth(width + "px");
            messagePopup.setHeight(height + "px");
          }
        };

    messageButton.addClickHandler(clickHandler);

    messageDisplay = new HorizontalPanel();
    messageDisplay.getElement().setAttribute("role", "log");
    messageDisplay.getElement().setAttribute("aria-live", "polite");
    messageDisplay.getElement().setAttribute("aria-atomic", "true");

    layout.add(messageDisplay);
    layout.add(messageButton);

    messageDisplay
        .getElement()
        .getParentElement()
        .setAttribute("style", "width:100%;padding-right:5px");
    messageDisplay.getElement().getParentElement().setAttribute("align", "right");

    messageButton.getElement().getParentElement().setAttribute("style", "width:60px");
    messageButton.getElement().getParentElement().setAttribute("align", "right");

    // register listener
    messageCenter.addMessageListener(this);
    Console.getEventBus().addHandler(ReloadEvent.TYPE, this);

    return layout;
  }
Exemplo n.º 29
0
  private void initLayout() {

    table = new FlexTable();
    table.setWidth("100%");

    HTML conceptLab = new HTML(constants.exportConcept());
    HTML exportLab = new HTML(constants.exportFormat());
    HTML schemeLab = new HTML(constants.exportScheme());
    HTML dateLab = new HTML(constants.exportDate());
    HTML termCodeLab = new HTML(constants.exportTermCode());

    conceptLab.setWordWrap(false);
    exportLab.setWordWrap(false);
    schemeLab.setWordWrap(false);
    dateLab.setWordWrap(false);
    termCodeLab.setWordWrap(false);

    table.setWidget(0, 0, schemeLab);
    table.setWidget(0, 1, getScheme());
    table.setWidget(1, 0, conceptLab);
    table.setWidget(1, 1, getConcept());
    table.setWidget(2, 0, exportLab);
    table.setWidget(2, 1, getExportFormat());
    // table.setWidget(3, 0, termCodeLab);
    // table.setWidget(3, 1, getTermCode());
    // table.setWidget(4, 0, dateLab);
    // table.setWidget(4, 1, getDatePanel());

    table.getColumnFormatter().setWidth(0, "15%");
    table.getColumnFormatter().setWidth(1, "75%");

    final VerticalPanel exportOption = new VerticalPanel();
    exportOption.setSize("100%", "100%");
    exportOption.add(GridStyle.setTableRowStyle(table, "#F4F4F4", "#E8E8E8", 3));

    final Button export = new Button(constants.exportButton());
    final CheckBox chkZip = new CheckBox(constants.exportUseZip());

    HorizontalPanel bottombar = new HorizontalPanel();
    bottombar.setSpacing(5);
    bottombar.add(chkZip);
    bottombar.add(export);
    bottombar.setSize("100%", "100%");
    bottombar.setStyleName("bottombar");
    bottombar.setCellHorizontalAlignment(chkZip, HasHorizontalAlignment.ALIGN_LEFT);
    bottombar.setCellHorizontalAlignment(export, HasHorizontalAlignment.ALIGN_RIGHT);
    bottombar.setCellVerticalAlignment(export, HasVerticalAlignment.ALIGN_MIDDLE);

    // ButtonbarWidget bottomBarPanel = new ButtonbarWidget(null, bottombar);

    /*ld.setSize("100%", "100%");
    spacer.setSize("100%", "100%");
    spacer.setCellHorizontalAlignment(ld, HasHorizontalAlignment.ALIGN_CENTER);
    spacer.setCellVerticalAlignment(ld, HasVerticalAlignment.ALIGN_MIDDLE);

     Window.addResizeHandler(new ResizeHandler()
        {
        	public void onResize(ResizeEvent event) {
        		spacer.setSize("100%", "100%");
    		}
    	});*/

    VerticalPanel optionPanel = new VerticalPanel();
    optionPanel.setSize("100%", "100%");
    optionPanel.setStyleName("borderbar");
    optionPanel.add(exportOption);
    // optionPanel.add(spacer);
    optionPanel.add(bottombar);
    // optionPanel.setCellHeight(spacer, "100%");
    optionPanel.setCellVerticalAlignment(exportOption, HasVerticalAlignment.ALIGN_TOP);
    optionPanel.setCellVerticalAlignment(bottombar, HasVerticalAlignment.ALIGN_BOTTOM);

    HorizontalPanel langPanel = new HorizontalPanel();
    /*Image img = new Image("images/map-grey.gif");
    final Label lang = new Label(constants.exportSelectLang());
    lang.setSize("150", "100%");
    lang.setStyleName("displayexportLang");
    lang.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_LEFT);
    lang.addClickHandler(new ClickHandler() {
    	public void onClick(ClickEvent event) {
    		if(selectLanguage == null || !selectLanguage.isLoaded)
    			selectLanguage = new SelectLanguage();
    		selectLanguage.show();
    	}
    });

    langPanel.setSize("10%", "100%");
    langPanel.add(img);
    langPanel.add(new HTML("&nbsp;"));
    langPanel.add(lang);
    langPanel.add(new HTML("&nbsp;"));
    langPanel.add(new HTML("&nbsp;"));
    langPanel.setCellWidth(lang, "100%");
    langPanel.setCellHeight(lang, "100%");
    langPanel.setCellVerticalAlignment(img, HasVerticalAlignment.ALIGN_MIDDLE);
    langPanel.setCellVerticalAlignment(lang, HasVerticalAlignment.ALIGN_MIDDLE);
    langPanel.setCellHorizontalAlignment(lang, HasHorizontalAlignment.ALIGN_RIGHT);
    langPanel.setSpacing(1);*/

    VerticalPanel tempmainPanel = new VerticalPanel();
    tempmainPanel.setSpacing(10);
    tempmainPanel.add(optionPanel);

    BodyPanel mainPanel = new BodyPanel(constants.exportTitle(), tempmainPanel, langPanel);

    mainBodypanel.setSize("100%", "100%");
    mainBodypanel.add(mainPanel);
    mainBodypanel.setCellHorizontalAlignment(mainPanel, HasHorizontalAlignment.ALIGN_CENTER);
    mainBodypanel.setCellVerticalAlignment(mainPanel, HasVerticalAlignment.ALIGN_TOP);
    mainBodypanel.setCellWidth(mainPanel, "100%");
    mainBodypanel.setCellHeight(mainPanel, "100%");

    panel.clear();
    panel.setSize("100%", "100%");
    panel.add(mainBodypanel);
    panel.add(loadingDialog);
    panel.setCellHorizontalAlignment(mainPanel, HasHorizontalAlignment.ALIGN_CENTER);
    panel.setCellVerticalAlignment(mainPanel, HasVerticalAlignment.ALIGN_TOP);
    showLoading(false);

    // =================

    export.addClickHandler(
        new ClickHandler() {
          public void onClick(ClickEvent event) {
            if (!format.getValue((format.getSelectedIndex())).equals("")
                && !format.getValue(format.getSelectedIndex()).equals("--None--")) {
              exp.setFormat(format.getValue(format.getSelectedIndex()));
            } else {
              exp.setFormat(null);
            }
            String expformat = exp.getFormat();
            if (expformat == null || expformat.equals("")) {
              Window.alert(constants.exportSelectFormat());
            } else if (exp.getStartDate() != null || exp.getEndDate() != null) {
              if (exp.getStartDate() == null || exp.getEndDate() == null) {
                Window.alert(constants.exportSelectDateRange());
              }
            } else {
              showLoading(true);
              exp.setExpLanguage(userSelectedLanguage);
              exp.setTermCode(termCodeBox.getValue().equals("") ? null : termCodeBox.getValue());

              AsyncCallback<String> callback =
                  new AsyncCallback<String>() {
                    public void onSuccess(String key) {
                      String formattype = format.getValue(format.getSelectedIndex());

                      String filename =
                          "export_"
                              + formattype.toLowerCase()
                              + "_"
                              + DateTimeFormat.getFormat("ddMMyyyyhhmmss").format(new Date());

                      if (formattype.equals(ExportFormat.SKOS)
                          || formattype.equals(ExportFormat.SKOSXL)) filename += ".rdf";
                      else if (formattype.equals(ExportFormat.TBX)) filename += ".tbx";
                      else if (formattype.equals(ExportFormat.OWL_SIMPLE_FORMAT))
                        filename += ".owl";
                      else if (formattype.equals(ExportFormat.OWL_COMPLETE_FORMAT))
                        filename += ".owl";
                      else if (formattype.equals(ExportFormat.RDBMS_SQL_FORMAT)) filename += ".sql";

                      Window.open(
                          GWT.getHostPageBaseURL()
                              + "downloadExportData?filename="
                              + filename
                              + "&key="
                              + key
                              + "&size="
                              + ConfigConstants.ZIPSIZE
                              + "&forcezip="
                              + chkZip.getValue(),
                          "_download",
                          "");
                      showLoading(false);
                    }

                    public void onFailure(Throwable caught) {
                      showLoading(false);
                      ExceptionManager.showException(caught, constants.exportDataFail());
                    }
                  };
              Service.exportService.export(exp, MainApp.userId, 74, MainApp.userOntology, callback);
            }
          }
        });
  }
Exemplo n.º 30
0
  // Method response to user click of "Address" button in a post row
  // Causes popup panel to appear
  protected void doMapPopup(PostData post) {
    VerticalPanel content = new VerticalPanel();
    content.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_CENTER);
    final String address = post.getAddress();

    // Create a Panel to hold the map
    HorizontalPanel mapPanel = new HorizontalPanel();
    mapPanel.setSize("400px", "400px");

    // Create the Google Map object, with set options
    MapOptions myOptions = MapOptions.create();
    myOptions.setZoom(8.0);
    myOptions.setCenter(LatLng.create(-34.397, 150.644));
    myOptions.setMapTypeId(MapTypeId.ROADMAP);
    final GoogleMap map = GoogleMap.create(mapPanel.getElement(), myOptions);

    // GeoCoder is Google Maps API for taking an address and finding
    //  latitude-longitude.
    Geocoder geocoder = Geocoder.create();
    GeocoderRequest request = GeocoderRequest.create();
    request.setAddress(address);

    geocoder.geocode(
        request,
        new Callback() {
          public void handle(JsArray<GeocoderResult> results, GeocoderStatus status) {
            if (status == GeocoderStatus.OK) {
              GeocoderResult location = results.get(0);
              // Bug Fix - Needed to make sure that map is re-sized to parent panel
              map.triggerResize();
              map.setCenter(location.getGeometry().getLocation());
              // Create Marker (red) to show location
              MarkerOptions markerOpts = MarkerOptions.create();
              markerOpts.setMap(map);
              // Title of Marker will be address
              markerOpts.setTitle(address);
              // Place Marker at address location
              markerOpts.setPosition(location.getGeometry().getLocation());
              Marker.create(markerOpts);
            } else {
              Window.alert("Geocode was not successful for the following reason: " + status);
            }
          }
        });

    HorizontalPanel btnRow = new HorizontalPanel();
    btnRow.setStyleName("search-button-row");
    Button cancelBtn = new Button("Cancel");
    cancelBtn.addClickHandler(
        new ClickHandler() {
          @Override
          public void onClick(ClickEvent event) {

            searchPopup.hide();
          }
        });
    btnRow.add(cancelBtn);

    content.add(mapPanel);
    content.add(btnRow);
    searchPopup.setWidget(content);
    searchPopup.center();
  }