Package org.gwt.mosaic.ui.client.layout

Examples of org.gwt.mosaic.ui.client.layout.BoxLayoutData


      panel.getElement().setId("process-history-search-view");
    panel.setPadding(0);
    panel.setWidgetSpacing(5);

    final ToolBar toolbar = new ToolBar();
    panel.add(toolbar, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
   
    toolbar.add(new Button("Search", new ClickHandler() {

      @Override
      public void onClick(ClickEvent clickEvent) {

                if (definitionList.getItemCount() < 1) {
                    return;
                }

        String proDef = definitionList.getValue(definitionList.getSelectedIndex());

                String definitionId = null;

                for (ProcessDefinitionRef ref : processDefinitions) {
                    if (proDef.equals(ref.getName())) {
                        definitionId = ref.getId();
                    }
                }

        String theStatus = processStatusList.getValue(processStatusList.getSelectedIndex());
        Date theDate = startTime.getValue();
        if (theDate == null) {
          theDate = new Date(103,1,1);
        }
        Date edate = endTime.getValue();
        if (edate == null) {
          edate = new Date();
        }
        String ckey = correlationKey.getValue();
       
        ProcessSearchEvent event = new ProcessSearchEvent();
        event.setDefinitionKey(definitionId);
        event.setStatus(theStatus);
        event.setStartTime(theDate.getTime());
        event.setEndTime(edate.getTime());
        event.setPage(page);
        event.setKey(ckey);
       
        controller.handleEvent(new Event(LoadProcessHistoryAction.ID, event));
      }
     
    }) );
   
    final MosaicPanel formPanel = new MosaicPanel(new BoxLayout(BoxLayout.Orientation.VERTICAL));
    panel.add(formPanel, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));

    BoxLayoutData bld1 = new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL);
        bld1.setPreferredWidth("130px");
       
        final MosaicPanel processDefBox = new MosaicPanel(new BoxLayout());
    processDefBox.add(new Label("Process Definition: "), bld1);
   
    definitionList = new ListBox();
    for (ProcessDefinitionRef ref : processDefinitions) {
      definitionList.addItem(ref.getName());
    }
    processDefBox.add(definitionList);
       
        formPanel.add(processDefBox);      
        formPanel.add(createProcessStatusListBox(bld1));   
        formPanel.add(createCorrelationKeyTextBox(bld1));   
        formPanel.add(createStartTimeDateBox(bld1));       
        formPanel.add(createEndTimeDateBox(bld1));

        prevButton=new Button("<< Previous", new ClickHandler() {

      @Override
      public void onClick(ClickEvent clickEvent) {

                if (definitionList.getItemCount() < 1) {
                    return;
                }

        String proDef = definitionList.getValue(definitionList.getSelectedIndex());

                String definitionId = null;

                for (ProcessDefinitionRef ref : processDefinitions) {
                    if (proDef.equals(ref.getName())) {
                        definitionId = ref.getId();
                    }
                }

        String theStatus = processStatusList.getValue(processStatusList.getSelectedIndex());
        Date theDate = startTime.getValue();
        if (theDate == null) {
          theDate = new Date(103,1,1);
        }
        Date edate = endTime.getValue();
        if (edate == null) {
          edate = new Date();
        }
        String ckey = correlationKey.getValue();
       
        ProcessSearchEvent event = new ProcessSearchEvent();
        event.setDefinitionKey(definitionId);
        event.setStatus(theStatus);
        event.setStartTime(theDate.getTime());
        event.setEndTime(edate.getTime());
       
        page--;
       
        if (page == 0) {
          prevButton.setEnabled(false);
        }
       
        pageLabel.setText(""+(page+1));
        event.setPage(page);
        event.setKey(ckey);
       
        controller.handleEvent(new Event(LoadProcessHistoryAction.ID, event));
      }
     
    });
        prevButton.setEnabled(false);

        nextButton=new Button("Next >>", new ClickHandler() {

      @Override
      public void onClick(ClickEvent clickEvent) {

                if (definitionList.getItemCount() < 1) {
                    return;
                }

        String proDef = definitionList.getValue(definitionList.getSelectedIndex());

                String definitionId = null;

                for (ProcessDefinitionRef ref : processDefinitions) {
                    if (proDef.equals(ref.getName())) {
                        definitionId = ref.getId();
                    }
                }

        String theStatus = processStatusList.getValue(processStatusList.getSelectedIndex());
        Date theDate = startTime.getValue();
        if (theDate == null) {
          theDate = new Date(103,1,1);
        }
        Date edate = endTime.getValue();
        if (edate == null) {
          edate = new Date();
        }
        String ckey = correlationKey.getValue();
       
        ProcessSearchEvent event = new ProcessSearchEvent();
        event.setDefinitionKey(definitionId);
        event.setStatus(theStatus);
        event.setStartTime(theDate.getTime());
        event.setEndTime(edate.getTime());
       
        page++;
       
        pageLabel.setText(""+(page+1));
       
        event.setPage(page);
        event.setKey(ckey);
       
        controller.handleEvent(new Event(LoadProcessHistoryAction.ID, event));
      }
     
    });
        nextButton.setEnabled(false);
       
    MosaicPanel buttonBox = new MosaicPanel(new BoxLayout());
    buttonBox.add(prevButton);
    buttonBox.add(nextButton);
   
    pageLabel = new Label("1");
   
    buttonBox.add(pageLabel);   
       
    buttonBox.setWidgetSpacing(10);
   
    panel.add(buttonBox, new BoxLayoutData());
   
    ProcessHistoryInstanceListView listview = new ProcessHistoryInstanceListView();
    final DecoratedTabLayoutPanel tabPanel = new DecoratedTabLayoutPanel(false);
    listview.provideWidget(new ProvisioningCallback(){

      @Override
      public void onSuccess(Widget instance) {
        tabPanel.add(instance, "History Instances");     
      }

      @Override
      public void onUnavailable() {
       
      }
     
    });
   
    panel.add(tabPanel, new BoxLayoutData(BoxLayoutData.FillStyle.BOTH));

        callback.onSuccess(panel);
  }
View Full Code Here


    this.toolSetId = id;

    if (w != null)
    {
      w.getElement().setId(toolSetId);
      this.add(w, new BoxLayoutData(BoxLayoutData.FillStyle.BOTH));
    }

    // tool links
    for (Tool t : toolSet.getAllProvidedTools()) {
      this.addLink(t.getName(), t);
View Full Code Here

                .noErrorHandling()
                .sendNowWith(ErraiBus.get());
          }
        }
    );
    this.add(button, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
  }
View Full Code Here

    infoPanel.add(loadingImageContainer);
    infoPanel.add(img);
    infoPanel.add(html);
    infoPanel.add(btn);

    this.add(logoPanel, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
    this.add(infoPanel, new BoxLayoutData(177, 50));
  }
View Full Code Here

    this.clear();
    this.selection = null;

    Label desc = new Label("Please enter a process definition ID");
    //desc.setStyleName("bpm-label-header");
    this.add(desc, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));

    suggestBox = new SuggestBox(
        createOracle(definitions)
    );

    suggestBox.addEventHandler(
        new SuggestionHandler()
        {
          public void onSuggestionSelected(SuggestionEvent suggestionEvent)
          {
            selection = suggestionEvent.getSelectedSuggestion().getReplacementString();
          }
        }
    );

    this.add(suggestBox);

    Grid g = new Grid(2,2);
    g.setWidget(0,0, new Label("ID: "));
    g.setWidget(0,1, suggestBox);

    Button button = new Button(delegate.getActionName(),
        new ClickListener()
        {
          public void onClick(Widget widget)
          {
            if(selection!=null)
            {
              delegate.handleResult(selection);
              parent.close();
            }
          }
        });

    g.setWidget(1,1, button);
    this.add(g, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));

    invalidate();
  }
View Full Code Here

      toolBox.setWidgetSpacing(5);
      //toolBox.setLayout(new BoxLayout(BoxLayout.Orientation.VERTICAL));

      final ToolBar toolBar = new ToolBar();
      toolBar.add(createMenuBtn());
      toolBox.add(toolBar, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));

      // loading panel
      loadingPanel = new LayoutPanel();
      loadingPanel.add(new Label("Loading, please wait..."));
      loadingPanel.setVisible(false);

      // assembly
      layout.add(toolBox, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
      layout.add(loadingPanel, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
      layout.add(frame, new BoxLayoutData(BoxLayoutData.FillStyle.BOTH));

      this.add(layout);

      // views and actions
      controller.addView(
View Full Code Here

    grid = new PropertyGrid(
        new String[] {"ID:", "Key:", "State", "Start Date:", "Activity:"}
    );

    this.add(grid, new BoxLayoutData(BoxLayoutData.FillStyle.BOTH));

    LayoutPanel buttonPanel = new LayoutPanel(new BoxLayout(BoxLayout.Orientation.VERTICAL) );
    diagramBtn = new Button("Diagram",
        new ClickListener()
        {
View Full Code Here

    layout.setStyleName("bpm-window-layout");
    layout.setPadding(5);

    Label header = new Label("Instance: "+inst.getId());
    header.setStyleName("bpm-label-header");
    layout.add(header, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));

    diagramWindowPanel.addWindowCloseListener(new WindowCloseListener() {
      public void onWindowClosed() {
        diagramWindowPanel = null;

      }

      public String onWindowClosing() {
        return null;
      }
    });


    layout.add(diagramView, new BoxLayoutData(BoxLayoutData.FillStyle.BOTH));
    diagramWindowPanel.setWidget(layout);

    WindowUtil.addMaximizeButton(diagramWindowPanel, Caption.CaptionRegion.RIGHT);
    WindowUtil.addMinimizeButton(diagramWindowPanel, Caption.CaptionRegion.RIGHT);
View Full Code Here

  {
    if(!initialized)
    {
      this.propGrid = new PropertyGrid(new String[]{"Deployment ID:"});

      this.add(propGrid, new BoxLayoutData(BoxLayoutData.FillStyle.VERTICAL));
      this.add(resources, new BoxLayoutData(BoxLayoutData.FillStyle.BOTH));
     
      this.initialized = true;
    }
  }
View Full Code Here

  {
    if(!initialized)
    {
      this.propGrid = new PropertyGrid(new String[]{"Deployment ID:"});

      this.add(propGrid, new BoxLayoutData(BoxLayoutData.FillStyle.BOTH));
      final Button button = new Button("View Deployment", new ClickListener(){

        public void onClick(Widget widget)
        {
          controller.handleEvent(
View Full Code Here

TOP

Related Classes of org.gwt.mosaic.ui.client.layout.BoxLayoutData

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.