Пример #1
0
  public Widget getCenterPanel() {
    Viewport viewport = new Viewport();
    viewport.setLayout(new BorderLayout());
    ContentPanel north = new ContentPanel();
    ContentPanel west = new ContentPanel();
    ContentPanel center = new ContentPanel();
    center.setHeading("BorderLayout");
    ContentPanel east = new ContentPanel();
    ContentPanel south = new ContentPanel();
    east.setHeading("PolicyDetails");
    west.add(createClientDetails());
    west.setHeading("ClientDetails");
    north.setHeading("AccountDetails");
    BorderLayoutData northData = new BorderLayoutData(LayoutRegion.NORTH, 150);
    // northData.setMargins(new Margins(5));
    northData.setCollapsible(false);
    northData.setSplit(false);
    BorderLayoutData westData = new BorderLayoutData(LayoutRegion.WEST, 680);
    westData.setCollapsible(false);
    westData.setSplit(false);
    // westData.setMargins(new Margins(0, 5, 0, 5));
    FlexTable ft = new FlexTable();
    ft.setText(0, 0, "MSISDN:");
    ft.setText(0, 1, "State:");
    ft.setText(0, 2, "PolicyID:");
    ft.setWidth("1365px");
    ft.setHeight("10px");
    // ft.setSize("500", "75");
    ft.setBorderWidth(1);
    north.add(getSearchPanel());
    north.add(ft);
    BorderLayoutData eastData = new BorderLayoutData(LayoutRegion.EAST, 680);
    // eastData.setMargins(new Margins(0, 5, 0, 5));
    FlexTable polictTable = new FlexTable();

    polictTable.setText(0, 0, "PolicyID:");
    polictTable.setText(1, 0, "Name:");
    polictTable.setText(2, 0, "Policy:");
    polictTable.setText(3, 0, "Description:");
    polictTable.setWidth("679px");
    polictTable.setHeight("360px");
    // ft.setSize("500", "75");
    polictTable.setBorderWidth(1);
    east.add(polictTable);
    eastData.setCollapsible(false);
    eastData.setSplit(false);
    BorderLayoutData southData = new BorderLayoutData(LayoutRegion.SOUTH, 10);
    // southData.setMargins(new Margins(5));
    southData.setCollapsible(false);
    viewport.add(north, northData);
    viewport.add(west, westData);
    viewport.add(east, eastData);
    viewport.add(south, southData);
    // con.setCenterWidget(center, centerData);
    return viewport;
  }
Пример #2
0
  private Window createStatisticWindow() {

    Window w = new Window();
    w.setIcon(IconHelper.createStyle("bogus"));
    w.setMinimizable(true);
    w.setMaximizable(true);
    w.setHeading("Statistics ");
    w.setSize(400, 400);

    w.setLayout(new AccordionLayout());

    ContentPanel cp = new ContentPanel();
    cp.setHeading("Most contacted friends this month");
    cp.setFrame(false);
    cp.setSize(300, 300);

    Frame frame = new Frame();
    frame.setUrl("chart.html");
    frame.setLayoutData(new FitLayout());
    cp.setLayout(new FitLayout());
    cp.add(frame);

    w.add(cp);

    cp = new ContentPanel();
    cp.setHeading("Most contacted friends in total");
    cp.setFrame(false);
    cp.setSize(300, 300);

    frame = new Frame();
    frame.setUrl(
        "https://chart.googleapis.com/chart?cht=p3&chs=350x200&chd=t:70,30,10&&chl=Hollie|Emerson|Christinal");
    frame.setLayoutData(new FitLayout());
    cp.setLayout(new FitLayout());
    cp.add(frame);

    w.add(cp);

    cp = new ContentPanel();
    cp.setHeading("Average sms per day last two weeks");
    cp.setFrame(false);
    cp.setSize(300, 300);

    frame = new Frame();
    frame.setUrl(
        "https://chart.googleapis.com/chart?cht=lc&chs=350x200&chd=t:25,50,70,90,25,44,56,34,23,56,0,0,34,5,5,103,3,2,6,13&&chl=1|2|3|4|5|6|7|8|9|10|11|12|13|14&chxt=x,y");
    frame.setLayoutData(new FitLayout());
    cp.setLayout(new FitLayout());
    cp.add(frame);

    w.add(cp);

    return w;
  }
Пример #3
0
  private void adminMenu(ContentPanel accordionPanel) {
    /* Administracion */
    ContentPanel adminCP = new ContentPanel();
    adminCP.setAnimCollapse(false);
    adminCP.setHeading("Administracion");
    adminCP.setLayout(new RowLayout(Orientation.VERTICAL));

    Button area = new Button("ABM- Area");
    area.setWidth("100%");
    area.addListener(
        Events.OnClick,
        new Listener<BaseEvent>() {
          @Override
          public void handleEvent(BaseEvent be) {
            ABMArea a = new ABMArea();
            a.show();
          }
        });
    adminCP.add(area);
    Button tiporev = new Button("ABM- TipoRelevamiento");
    tiporev.setWidth("100%");
    adminCP.add(tiporev);

    Button tema = new Button("ABM- Tema");

    tema.setWidth("100%");
    adminCP.add(tema);

    accordionPanel.add(adminCP);
  }
Пример #4
0
 public ContentPanel getNewContentPanel() {
   ContentPanel contentPanel = new ContentPanel();
   contentPanel.setLayout(new FitLayout());
   contentPanel.setHeading(getPanelTitle());
   IconSupplier.setIcon(contentPanel, IconSupplier.getReportIconName());
   return contentPanel;
 }
Пример #5
0
  private Window createGeolocationWindow() {

    final Window w = new Window();
    w.setMinimizable(true);
    w.setMaximizable(true);
    w.setIcon(IconHelper.createStyle("accordion"));
    w.setHeading("Contact list");
    w.setWidth(500);
    w.setHeight(500);
    w.setLayout(new FitLayout());

    ContentPanel cp = new ContentPanel();
    cp.setAnimCollapse(false);
    cp.setHeading("Localize your friends");
    cp.setScrollMode(Scroll.NONE);
    cp.setLayout(new FitLayout());

    Frame frame = new Frame();
    frame.setUrl("geolocation.html");
    frame.setLayoutData(new FitLayout());
    cp.add(frame);

    w.add(cp);
    return w;
  }
  protected void initUI() {
    TabItem west = (TabItem) Registry.get(AppView.TAB_STORAGE);
    ContentPanel clusters = new ContentPanel();
    clusters.setAnimCollapse(false);
    clusters.setHeading("Storage Engines");
    clusters.addListener(
        Events.Expand,
        new Listener<ComponentEvent>() {
          public void handleEvent(ComponentEvent be) {
            Dispatcher.get().dispatch(AppEvents.NAV_STORAGE);
          }
        });

    storageEnginesPanel = new StorageEnginesPanel();
    storageEnginesPanel
        .getGrid()
        .getSelectionModel()
        .addSelectionChangedListener(
            new SelectionChangedListener<StorageEngine>() {
              @Override
              public void selectionChanged(SelectionChangedEvent<StorageEngine> se) {
                AppEvent evt = new AppEvent(AppEvents.VIEW_STORAGE_ENGINE, se.getSelectedItem());
                Dispatcher.forwardEvent(evt);
              }
            });
    clusters.add(storageEnginesPanel, new BorderLayoutData(LayoutRegion.CENTER));

    west.add(clusters);
  }
Пример #7
0
  private ContentPanel buildConfigBloc(ConfigGroup configGroup, ImageResource icon) {
    final ContentPanel cPanel = new ContentPanel(new ColumnLayout());
    cPanel.setHeading(
        "<div class='config-title'>" + I18nUtils.getString(configGroup.key) + "</div>");
    cPanel.getHeader().addStyleName("config-header");
    cPanel.setCollapsible(true);
    cPanel.setAnimCollapse(false);
    cPanel.collapse();
    cPanel.setIcon(AbstractImagePrototype.create(icon));
    cPanel.addListener(
        Events.Expand,
        new Listener<ComponentEvent>() {

          @Override
          public void handleEvent(ComponentEvent be) {
            cPanel.layout(true);
          }
        });

    cPanel.getHeader().addDomHandler(this, ClickEvent.getType());
    mapConfigGroupPanel.put(configGroup, cPanel);
    mapHeaderGroup.put(cPanel.getHeader(), cPanel);

    return cPanel;
  }
Пример #8
0
  private void createViewDSInfoPanel() {
    BorderLayoutData data = new BorderLayoutData(Style.LayoutRegion.EAST, 475, 100, 750);
    data.setMargins(new Margins(1, 1, 1, 5));
    data.setCollapsible(true);

    viewDsInfoPanel = new ContentPanel();
    viewDsInfoPanel.setLayout(new CenterLayout());
    viewDsInfoPanel.setLayoutOnChange(true);
    //        filterPanel.setAnimCollapse(true);
    viewDsInfoPanel.setId("eastPanel");
    viewDsInfoPanel.setBodyBorder(false);
    viewDsInfoPanel.setIcon(HarvesterUI.ICONS.view_info_icon());
    viewDsInfoPanel.setHeading(HarvesterUI.CONSTANTS.viewDataSetInformation());
    LabelToolItem noDsSelectedLabel = new LabelToolItem(HarvesterUI.CONSTANTS.noDataSetSelected());
    noDsSelectedLabel.setStyleName("noDataSetSelected");
    viewDsInfoPanel.add(noDsSelectedLabel);

    mainBorderLayout.addListener(
        Events.Expand,
        new Listener<BorderLayoutEvent>() {
          @Override
          public void handleEvent(BorderLayoutEvent be) {
            if (be.getRegion().equals(Style.LayoutRegion.EAST)) setOnExpandDataSet();
          }
        });

    mainGridPanel.add(viewDsInfoPanel, data);
  }
Пример #9
0
 private ContentPanel getApplicationPanel() {
   if (applicationPanel == null) {
     applicationPanel = new ContentPanel();
     applicationPanel.setSize("221px", "85px");
     applicationPanel.setHeading("Application");
     applicationPanel.setLayout(new FitLayout());
     applicationPanel.add(getLayoutContainer_1(), new FitData(10, 30, 10, 10));
   }
   return applicationPanel;
 }
Пример #10
0
 private ContentPanel getJobnamePanel() {
   if (jobnamePanel == null) {
     jobnamePanel = new ContentPanel();
     jobnamePanel.setWidth("314px");
     jobnamePanel.setHeading("Jobname & group");
     jobnamePanel.setLayout(new FitLayout());
     jobnamePanel.add(getFirstRowLeftSide(), new FitData(10));
   }
   return jobnamePanel;
 }
Пример #11
0
  private void showRepoTree(Repository repo) {
    if (repo == null) {
      return;
    }

    repoTreePanel.setHeading((String) repo.get("name") + " Repository Content");
    repoTreeBinding.selectRepository(repo);

    repoPanel.removeAll();
    repoPanel.add(repoTree);
  }
Пример #12
0
 private ContentPanel getEmailPanel() {
   if (emailPanel == null) {
     emailPanel = new ContentPanel();
     emailPanel.setWidth("275px");
     emailPanel.setLayout(new FitLayout());
     emailPanel.setHeading("Email");
     emailPanel.setCollapsible(false);
     emailPanel.add(getFirstRowRightSide(), new FitData(10));
   }
   return emailPanel;
 }
Пример #13
0
 private ContentPanel getCpusPanel() {
   if (cpusPanel == null) {
     cpusPanel = new ContentPanel();
     cpusPanel.setSize("106px", "84px");
     cpusPanel.setHideCollapseTool(true);
     cpusPanel.setHeading("CPUs");
     cpusPanel.setLayout(new FitLayout());
     cpusPanel.add(getLayoutContainer(), new FitData(10));
   }
   return cpusPanel;
 }
Пример #14
0
 private void emptyDataSetPanel() {
   // Only do when visible to enhance performance
   if (viewDsInfoPanel.isExpanded()) {
     viewDsInfoPanel.removeAll();
     LabelToolItem noDsSelectedLabel =
         new LabelToolItem(HarvesterUI.CONSTANTS.noDataSetSelected());
     noDsSelectedLabel.setStyleName("noDataSetSelected");
     viewDsInfoPanel.setLayout(new CenterLayout());
     viewDsInfoPanel.setHeading(HarvesterUI.CONSTANTS.viewDataSetInformation());
     viewDsInfoPanel.add(noDsSelectedLabel);
   }
 }
Пример #15
0
 private ContentPanel getCommandLinePanel() {
   if (commandLinePanel == null) {
     commandLinePanel = new ContentPanel();
     commandLinePanel.setHideCollapseTool(true);
     commandLinePanel.setSize("413px", "196px");
     commandLinePanel.setLayout(new FitLayout());
     commandLinePanel.setHeading("Commandline");
     commandLinePanel.setCollapsible(true);
     commandLinePanel.add(getTextAreaContainer(), new FitData(10));
   }
   return commandLinePanel;
 }
Пример #16
0
 public void updateStatus(
     ConfigGroup configGroup, ConfigStatus status, String message, boolean bling) {
   ContentPanel contentPanel = mapConfigGroupPanel.get(configGroup);
   if (null != contentPanel) {
     String headling = I18nUtils.getString(configGroup.key);
     if (null != message) {
       headling += message;
     }
     String s = decorateStatus(headling, status, null, bling);
     contentPanel.setHeading(s);
   }
 }
Пример #17
0
  private void initUI() {
    long time = new java.util.Date().getTime();
    GWT.log("Initializing the UI ", null);

    permissions = Registry.get(Constants.LOGIN_USER_PERMISSIONS);

    //		container = new LayoutContainer();
    container = new ContentPanel();
    container.setLayout(new BorderLayout());
    container.setHeading("User Profile");

    formButtonContainer = new LayoutContainer();
    formButtonContainer.setScrollMode(Scroll.AUTO);

    TableLayout identlayout = new TableLayout(2);
    identlayout.setWidth("100%");
    identlayout.setCellSpacing(5);
    identlayout.setCellVerticalAlign(VerticalAlignment.TOP);

    TableLayout formlayout = new TableLayout(2);
    formlayout.setWidth("100%");
    formlayout.setCellSpacing(5);
    formlayout.setCellVerticalAlign(VerticalAlignment.TOP);

    formContainer = new LayoutContainer();
    //			formContainer.setBorders(true);
    formContainer.setLayout(formlayout);
    leftFormPanel = setupUserLeftForm("", 1);
    rightFormPanel = setupUserRightForm("", 8);

    formContainer.add(leftFormPanel);
    formContainer.add(rightFormPanel);
    buttonPanel = setupButtonPanel(17);

    formButtonContainer.add(formContainer);
    formButtonContainer.add(buttonPanel);

    // check permissions
    checkPermissins();

    BorderLayoutData data = new BorderLayoutData(LayoutRegion.CENTER);
    data.setMargins(new Margins(4, 2, 4, 2));
    container.add(formButtonContainer, data);

    LayoutContainer wrapper = (LayoutContainer) Registry.get(Constants.CENTER_PANEL);
    wrapper.removeAll();
    wrapper.add(container);
    wrapper.layout();
    GWT.log("Done Initializing the UI in " + (new java.util.Date().getTime() - time), null);
  }
Пример #18
0
 private ContentPanel getWalltimeContainer() {
   if (walltimeContainer == null) {
     walltimeContainer = new ContentPanel();
     walltimeContainer.setHeight("83px");
     walltimeContainer.setHideCollapseTool(true);
     walltimeContainer.setHeading("Walltime");
     walltimeContainer.setCollapsible(true);
     FitLayout fitLayout = new FitLayout();
     fitLayout.setExtraStyle("");
     walltimeContainer.setLayout(fitLayout);
     walltimeContainer.add(getWallTimeFormPanel(), new FitData(0));
   }
   return walltimeContainer;
 }
Пример #19
0
  /** This widget can be used to display the actions that are considered relevant */
  public WidgetSpecialActions() {
    Listener<ComponentEvent> l =
        new Listener<ComponentEvent>() {
          public void handleEvent(ComponentEvent ce) {
            DataList l = (DataList) ce.component;
            ServiceVisualizerManager.displayService(l.getSelectedItem().getId());
          }
        };
    ContentPanel frame = new ContentPanel();
    frame.setFrame(true);
    frame.setCollapsible(true);
    frame.setAnimCollapse(false);
    frame.setHeading("Interesting actions");

    final DataList list = new DataList();
    list.setFlatStyle(true);

    list.addListener(Events.SelectionChange, l);

    DataListItem item = new DataListItem();
    item.setText("Get Twitter followers");
    item.setId("http://soa4all.eu/twitter/getFollowers");
    list.add(item);

    item = new DataListItem();
    item.setText("Watson Search");
    item.setId("http://soa4all.eu/watson/search");
    list.add(item);

    item = new DataListItem();
    item.setText("BT Scenario 1");
    item.setStyleAttribute("color", "#00FF00");
    item.setId("http://soa4all.eu/composed/BTscenario1");
    list.add(item);

    item = new DataListItem();
    item.setText("Get Twitter Follower (Semantic)");
    item.setId("http://soa4all.eu/twitter/getFollowersSemantic");
    list.add(item);

    item = new DataListItem();
    item.setText("Profile Details (Fake Service)");
    item.setId("http://soa4all.eu/twitter/getProfileDetails");
    list.add(item);

    frame.setLayout(new FitLayout());
    frame.add(list);

    initWidget(frame);
  }
Пример #20
0
  public LibraryData(HorizontalPanel lp, DrakeGeneticsServiceAsync drakeGeneticsService) {
    this.libraryPanel = lp;

    final DrakeGeneticsServiceAsync dgs = drakeGeneticsService;
    drakeGeneticsService.getLibrary(
        new AsyncCallback<LibraryNode>() {
          public void onSuccess(LibraryNode results) {
            getTreeModelSucceeded(results, dgs);
          }

          public void onFailure(Throwable caught) {
            getTreeModelFailed(caught);
          }
        });

    treePanel.setHeaderVisible(true);
    treePanel.setLayout(new FitLayout());
    treePanel.setHeading("Publications");

    tree.setDisplayProperty("name");
    tree.setWidth(200);
    // tree.setHeight(450);
    tree.setHeight(670);
    tree.addListener(
        Events.OnClick,
        new Listener<TreePanelEvent<ModelData>>() {

          public void handleEvent(TreePanelEvent<ModelData> be) {
            ModelData item = be.getItem();
            String url = (String) item.get("url");
            if (url != null && !url.equals("")) {
              if (url.startsWith("/")) {
                url = url.substring(1);
              }
              libraryDocumentPanel.setUrl(GWT.getHostPageBaseURL() + url);
            }
          }
        });

    treePanel.add(tree);

    libraryPanel.add(treePanel);

    libraryDocumentPanel.setHeaderVisible(false);
    libraryDocumentPanel.setWidth(494);
    // libraryDocumentPanel.setHeight(451);
    libraryDocumentPanel.setHeight(671);
    libraryDocumentPanel.setUrl(GWT.getHostPageBaseURL() + "Library/index.html");
    libraryPanel.add(libraryDocumentPanel);
  }
Пример #21
0
  private void reportesMenu(ContentPanel accordionPanel) {
    /* Reportes */

    ContentPanel reportesCP = new ContentPanel();
    reportesCP.setAnimCollapse(false);
    reportesCP.setHeading("Reportes");
    reportesCP.setLayout(new RowLayout(Orientation.VERTICAL));

    Button insp = new Button("Inspecciones");
    insp.setWidth("100%");
    reportesCP.add(insp);

    accordionPanel.add(reportesCP);
  }
Пример #22
0
  private ContentPanel createMulti() {
    ContentPanel panel = new SamplePanel();
    panel.setHeading("Multi Columns");

    ToolBar toolBar = new ToolBar();
    panel.setTopComponent(toolBar);

    ButtonGroup group = new ButtonGroup(2);
    group.setHeading("Clipboard");

    Button btn = new Button("Cool", IconHelper.createStyle("add16"));
    group.add(btn);

    btn = new Button("Cut", IconHelper.createStyle("add16"));
    Menu menu = new Menu();
    menu.add(new MenuItem("Copy me"));
    btn.setMenu(menu);
    group.add(btn);

    btn = new Button("Copy", IconHelper.createStyle("add16"));
    group.add(btn);

    btn = new Button("Paste", IconHelper.createStyle("add16"));
    group.add(btn);

    toolBar.add(group);

    group = new ButtonGroup(2);
    group.setHeading("Other Bugus Actions");

    btn = new Button("Cool", IconHelper.createStyle("add16"));
    group.add(btn);

    btn = new Button("Cut", IconHelper.createStyle("add16"));
    menu = new Menu();
    menu.add(new MenuItem("Copy me"));
    btn.setMenu(menu);
    group.add(btn);

    btn = new Button("Copy", IconHelper.createStyle("add16"));
    group.add(btn);

    btn = new Button("Paste", IconHelper.createStyle("add16"));
    group.add(btn);

    toolBar.add(group);
    return panel;
  }
Пример #23
0
  @Override
  protected void onRender(Element parent, int index) {
    super.onRender(parent, index);
    setLayout(new FlowLayout(10));

    ContentPanel accordionPanel = new ContentPanel();
    accordionPanel.setHeading("Menu Siu");
    accordionPanel.setBodyBorder(false);
    accordionPanel.setLayout(new AccordionLayout());
    accordionPanel.setHeight(500);
    tablero(accordionPanel);
    reportesMenu(accordionPanel);
    adminMenu(accordionPanel);
    populateMenu(accordionPanel);
    add(accordionPanel);
  }
Пример #24
0
 private ContentPanel getStageFileList() {
   if (stageFileList == null) {
     stageFileList = new ContentPanel();
     stageFileList.setBodyBorder(false);
     stageFileList.setBorders(true);
     stageFileList.setSize("177px", "195px");
     stageFileList.setHideCollapseTool(true);
     stageFileList.setLayout(new FitLayout());
     stageFileList.add(getListView(), new FitData(10));
     stageFileList.setHeading("Job directory");
     stageFileList.setCollapsible(true);
     stageFileList.addButton(getRemoveFileButton());
     stageFileList.addButton(getAddFileButton());
   }
   return stageFileList;
 }
Пример #25
0
 private static Widget createClientDetails() {
   LayoutContainer ct = new LayoutContainer();
   ct.setLayout(new BorderLayout());
   ContentPanel clientDetailsEast = new ContentPanel();
   ContentPanel clientDetailsWest = new ContentPanel();
   clientDetailsWest.setHeading("Clients");
   BorderLayoutData eastClientData = new BorderLayoutData(LayoutRegion.EAST, 500);
   eastClientData.setCollapsible(false);
   eastClientData.setSplit(false);
   BorderLayoutData westClientData = new BorderLayoutData(LayoutRegion.WEST, 230);
   westClientData.setCollapsible(false);
   westClientData.setSplit(false);
   ct.setBorders(false);
   ct.add(clientDetailsEast, eastClientData);
   ct.add(clientDetailsWest, westClientData);
   return ct;
 }
Пример #26
0
  @Override
  protected void onRender(Element parent, int index) {
    super.onRender(parent, index);
    ContentPanel cp = new ContentPanel();
    cp.setHeading("Charts Gallery");
    cp.setFrame(true);
    cp.setSize(700, 350);
    cp.setLayout(new BorderLayout());

    BorderLayoutData eastData = new BorderLayoutData(LayoutRegion.EAST, 370);

    BorderLayoutData centerData = new BorderLayoutData(LayoutRegion.CENTER);
    centerData.setMargins(new Margins(0, 5, 0, 0));

    cp.add(getChart(), centerData);
    cp.add(getDetails(), eastData);

    add(cp, new MarginData(20));
  }
Пример #27
0
 /**
  * ******************************************************* View Info Side Panel Functions
  * ********************************************************
  */
 private void editPanelInfo(DataSourceUI dataSourceUI) {
   // Only do when visible to enhance performance
   if (viewDsInfoPanel.isExpanded()) {
     DataSetSideViewInfo dataSetViewInfo = new DataSetSideViewInfo();
     dataSetViewInfo.createForm(dataSourceUI);
     viewDsInfoPanel.removeAll();
     viewDsInfoPanel.setLayout(new FitLayout());
     viewDsInfoPanel.add(dataSetViewInfo);
     viewDsInfoPanel.setHeading(
         HarvesterUI.CONSTANTS.viewDataSet()
             + ": "
             + dataSourceUI.getDataSourceSet()
             + " ("
             + HarvesterUI.CONSTANTS.dataProvider()
             + ": "
             + dataSourceUI.getDataSetParent().getName()
             + ")");
   }
 }
Пример #28
0
  private void tablero(ContentPanel accordionPanel) {
    /* Reportes */
    ContentPanel tablero = new ContentPanel();
    tablero.setAnimCollapse(false);
    tablero.setHeading("Tablero Partido");
    tablero.setLayout(new RowLayout(Orientation.VERTICAL));
    Button tableroControl = new Button("Tablero Control");

    tableroControl.addListener(
        Events.OnClick,
        new Listener<BaseEvent>() {
          @Override
          public void handleEvent(BaseEvent be) {
            TableroView tableroView = new TableroView();
            tableroView.show();
          }
        });

    tableroControl.setWidth(135);
    tablero.add(tableroControl);

    accordionPanel.add(tablero);
  }
Пример #29
0
  /** Creates the east. */
  private void createEast() {
    BorderLayoutData data =
        new BorderLayoutData(LayoutRegion.EAST, Constants.EASTH_PANEL_DIMENSION);
    data.setMargins(new Margins(5, 0, 5, 5));
    data.setCollapsible(true);
    data.setSplit(true);
    east = new ContentPanel();
    east.setBodyBorder(false);
    east.setLayout(new AccordionLayout());
    east.setHeading(I18nProvider.getMessages().accordionLabel());
    east.setScrollMode(Scroll.AUTO);

    east.addListener(
        Events.Resize,
        new Listener<BaseEvent>() {

          public void handleEvent(BaseEvent be) {
            Dispatcher.forwardEvent(GeoGWTEvents.UPDATE_MAP_SIZE);
            // Dispatcher.forwardEvent(GeofenceEvents.UPDATE_SOUTH_SIZE);
          }
        });
    east.addListener(
        Events.Move,
        new Listener<BaseEvent>() {

          public void handleEvent(BaseEvent be) {
            Dispatcher.forwardEvent(GeoGWTEvents.UPDATE_MAP_SIZE);
            // Dispatcher.forwardEvent(GeofenceEvents.UPDATE_SOUTH_SIZE);
          }
        });
    east.setStyleAttribute("height", "auto");
    east.setStyleAttribute("width", "auto");
    configureAccordionPanel();
    east.setMonitorWindowResize(true);
    east.setLayoutOnChange(true);
    viewport.add(east, data);
  }
Пример #30
0
  private void buildAdvancedOptionsPanel() {
    advancedOptions.setHeading("Advanced Search Options");
    VerticalPanel vp = new VerticalPanel();
    advancedOptions.setLayout(new FillLayout());

    common.setChecked(true);
    common.setText("Search Common Names");

    sciName.setText("Search Scientific Names");
    sciName.setChecked(true);

    HorizontalPanel hp1 = new HorizontalPanel();
    countryOfOcc.setText("Country of Occurrence");
    hp1.add(countryOfOcc);
    hp1.add(countryOfOccText);

    HorizontalPanel hp2 = new HorizontalPanel();
    assessor.setText("Assessor");
    hp2.add(assessor);
    hp2.add(assessorText);

    common.setWidth("100px");
    sciName.setWidth("100px");

    // panel.add(showAdvanced);
    vp.add(new HTML("<b>Taxon Filters:</b>"));
    vp.add(common);
    vp.add(sciName);
    vp.add(new HTML("<hr><b>Assessment Filters:</b>"));
    vp.add(hp1);
    vp.add(hp2);
    advancedOptions.add(vp);

    // if(advancedSearch)/

  }