Java tutorial
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package org.balisunrise.vaadin.components.header; import com.vaadin.ui.HorizontalLayout; import java.util.LinkedList; import java.util.List; /** * * @author Glauco */ public class FastMenuBar extends HorizontalLayout { private List<FastMenuItem> menuItems; public FastMenuBar() { init(); } private void init() { setSizeUndefined(); setHeight("100%"); setStyleName("b-fast-menu-bar"); menuItems = new LinkedList<>(); menuItems.add(new FastMenuItem()); menuItems.add(new FastMenuItem()); for (FastMenuItem mi : menuItems) { addComponent(mi); } } }