com.vaadin.ui.Accordion.addTab()方法的使用及代码示例

x33g5p2x  于2022-01-17 转载在 其他  
字(3.9k)|赞(0)|评价(0)|浏览(113)

本文整理了Java中com.vaadin.ui.Accordion.addTab()方法的一些代码示例,展示了Accordion.addTab()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Accordion.addTab()方法的具体详情如下:
包路径:com.vaadin.ui.Accordion
类名称:Accordion
方法名:addTab

Accordion.addTab介绍

暂无

代码示例

代码示例来源:origin: de.mhus.lib/mhu-lib-vaadin6

public void addComponent(LayoutElement element, Component component, int col1, int row1, int col2, int row2) {
  accordion.addTab(component,element.getTitle());
}

代码示例来源:origin: OpenNMS/opennms

@Override
public void refresh() {
  m_timeslot = 3600;
  try {
    m_timeslot = Math.max(1, Integer.parseInt(getDashletSpec().getParameters().get("timeslot")));
  } catch (NumberFormatException numberFormatException) {
    /**
     * Just ignore
     */
  }
  m_horizontalLayout.removeAllComponents();
  Accordion accordion = new Accordion();
  accordion.setSizeFull();
  injectDashboardStyles();
  Component severity = getComponentSeverity(16);
  Component uei = getComponentUei(16);
  VerticalLayout v1 = new VerticalLayout(severity);
  v1.setSizeFull();
  v1.setComponentAlignment(severity, Alignment.MIDDLE_CENTER);
  v1.setMargin(true);
  accordion.addTab(v1, "by Severity");
  VerticalLayout v2 = new VerticalLayout(uei);
  v2.setSizeFull();
  v2.setComponentAlignment(uei, Alignment.MIDDLE_CENTER);
  v2.setMargin(true);
  accordion.addTab(v2, "by Uei");
  m_horizontalLayout.addComponent(accordion);
}

代码示例来源:origin: org.opennms.features.vaadin-dashlets/dashlet-summary

@Override
public void refresh() {
  m_timeslot = 3600;
  try {
    m_timeslot = Math.max(1, Integer.parseInt(getDashletSpec().getParameters().get("timeslot")));
  } catch (NumberFormatException numberFormatException) {
    /**
     * Just ignore
     */
  }
  m_horizontalLayout.removeAllComponents();
  Accordion accordion = new Accordion();
  accordion.setSizeFull();
  injectDashboardStyles();
  Component severity = getComponentSeverity(16);
  Component uei = getComponentUei(16);
  VerticalLayout v1 = new VerticalLayout(severity);
  v1.setSizeFull();
  v1.setComponentAlignment(severity, Alignment.MIDDLE_CENTER);
  v1.setMargin(true);
  accordion.addTab(v1, "by Severity");
  VerticalLayout v2 = new VerticalLayout(uei);
  v2.setSizeFull();
  v2.setComponentAlignment(uei, Alignment.MIDDLE_CENTER);
  v2.setMargin(true);
  accordion.addTab(v2, "by Uei");
  m_horizontalLayout.addComponent(accordion);
}

代码示例来源:origin: peholmst/vaadin4spring

@Override
  public void createSection(Accordion compositionRoot, SideBarSectionDescriptor descriptor, Collection<SideBarItemDescriptor> itemDescriptors) {
    final Panel panel = new Panel();
    panel.addStyleName(SIDE_BAR_SECTION_STYLE);
    panel.setSizeFull();
    final VerticalLayout layout = new VerticalLayout();
    panel.setContent(layout);
    for (SideBarItemDescriptor item : itemDescriptors) {
      layout.addComponent(itemComponentFactory.createItemComponent(item));
    }
    compositionRoot.addTab(panel, descriptor.getCaption());
  }
}

代码示例来源:origin: OpenNMS/opennms

accordion.addTab(getGraphComponent(i, width, height, timeFrameType, timeFrameValue), getDashletSpec().getParameters().get("nodeLabel" + i) + "/" + getDashletSpec().getParameters().get("resourceTypeLabel" + i) + ": " + getDashletSpec().getParameters().get("resourceLabel" + i));

代码示例来源:origin: org.opennms.features.vaadin-dashlets/dashlet-rrd

accordion.addTab(getGraphComponent(i, width, height, timeFrameType, timeFrameValue), getDashletSpec().getParameters().get("nodeLabel" + i) + "/" + getDashletSpec().getParameters().get("resourceTypeLabel" + i) + ": " + getDashletSpec().getParameters().get("resourceLabel" + i));

代码示例来源:origin: OpenNMS/opennms

verticalLayout.setWidth(DEFAULT_GRAPH_WIDTH_PX, Unit.PIXELS);
accordion.addTab(verticalLayout, data.get("nodeLabel") + "/" + data.get("resourceTypeLabel") + ": " + data.get("resourceLabel"));

代码示例来源:origin: org.opennms.features.vaadin-dashlets/dashlet-ksc

verticalLayout.setWidth(DEFAULT_GRAPH_WIDTH_PX, Unit.PIXELS);
accordion.addTab(verticalLayout, data.get("nodeLabel") + "/" + data.get("resourceTypeLabel") + ": " + data.get("resourceLabel"));

相关文章