Exemple #1
0
 public GHASlideInWindow() {
   setWidth100();
   setMinWidth(GHAUiHelper.MIN_WIDTH);
   setTop(GHAUiHelper.getTopSpace());
   setHeight(GHAUiHelper.getBottomSectionHeight() - 5);
   setLeft(-5);
   setVisibility(Visibility.HIDDEN);
   setAnimateTime(GHAUiHelper.DEFAULT_ANIMATION_TIME);
   GHAUiHelper.addGHAResizeHandler(this);
 }
Exemple #2
0
  @Override
  public void close() {
    RootPanel.get("slideInWindowsBackDiv").removeStyleName("dim");
    RootPanel.get("slideInWindowsBackDiv").getElement().getStyle().setZIndex(-80000);

    GHAUiHelper.removeGHAResizeHandler(this);
    hide(
        new AnimationCallback() {

          @Override
          public void execute(boolean earlyFinish) {
            destroy();
          }
        });
  }
Exemple #3
0
  public EIASearchForm(String title) {
    super(title);

    form.setItems(
        serialNumber,
        fixedAssetIdentifier,
        stateSelectItem,
        bpiObuSelectItem,
        workingAreaLocationSelectItem,
        facilityLocationSelectItem,
        obuSelectItem,
        baseRoleSelectItem);
    form.setAutoFocus(true);
    serialNumber.setSelectOnFocus(true);

    final KeyUpHandler searchKeyUpHandler =
        new KeyUpHandler() {

          @Override
          public void onKeyUp(KeyUpEvent event) {
            if (event.getKeyName().equals("Enter")) {
              search();
            }
          }
        };
    // actualCostItem.addKeyUpHandler(searchKeyUpHandler);
    serialNumber.addKeyUpHandler(searchKeyUpHandler);
    fixedAssetIdentifier.addKeyUpHandler(searchKeyUpHandler);
    stateSelectItem.addKeyUpHandler(searchKeyUpHandler);
    bpiObuSelectItem.addKeyUpHandler(searchKeyUpHandler);
    workingAreaLocationSelectItem.addKeyUpHandler(searchKeyUpHandler);
    facilityLocationSelectItem.addKeyUpHandler(searchKeyUpHandler);
    obuSelectItem.addKeyUpHandler(searchKeyUpHandler);
    baseRoleSelectItem.addKeyUpHandler(searchKeyUpHandler);

    final VLayout sideButtons =
        GHAUiHelper.createBar(
            new GHASearchButton(searchClickHandler),
            new GHACleanButton(
                new ClickHandler() {

                  @Override
                  public void onClick(ClickEvent event) {
                    clean();
                  }
                }),
            new GHACancelButton(
                new ClickHandler() {

                  @Override
                  public void onClick(ClickEvent event) {
                    hide();
                    clean();
                  }
                }));

    final HLayout formLayout = new HLayout();
    formLayout.setPadding(10);
    formLayout.setHeight(GHAUiHelper.DEFAULT_INNER_TOP_SECTION_HEIGHT + "px");
    formLayout.setDefaultLayoutAlign(VerticalAlignment.CENTER);
    formLayout.addMembers(form, new LayoutSpacer(), sideButtons);

    addMembers(
        formLayout,
        GHAUiHelper.verticalGraySeparator(GHAUiHelper.V_SEPARATOR_HEIGHT + "px"),
        resultSet);
    fill();
  }
Exemple #4
0
 @Override
 public void onResize(ResizeEvent event) {
   setHeight(GHAUiHelper.getBottomSectionHeight() - 5);
 }