/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.icentricApp.client;

import com.smartgwt.client.util.SC;
import com.smartgwt.client.widgets.layout.VLayout;
import com.smartgwt.client.widgets.menu.Menu;
import com.smartgwt.client.widgets.menu.MenuBar;
import com.smartgwt.client.widgets.menu.MenuItem;
import com.smartgwt.client.widgets.menu.events.MenuItemClickEvent;

/**
 *
 * @author jeni
 */
public class TestPanel extends VLayout{
    
    public TestPanel(){
        MenuBar menuBar = new MenuBar();
        
        Menu editMenu = new Menu();
        editMenu.setShowShadow(true);
        editMenu.setShadowDepth(10);
        editMenu.setTitle("Test Menu");
        
        MenuItem addItem = new MenuItem("Create Invoice", "appStyles/icons/16/icon_add.png", "Ctrl+N");
        addItem.addClickHandler(new com.smartgwt.client.widgets.menu.events.ClickHandler() {

            public void onClick(MenuItemClickEvent event) {
                SC.say("Menu clicked!");
            }
        });
        
        editMenu.setItems(addItem);
        menuBar.setMenus(editMenu);
        
        setMembers(menuBar);
    }
    
}
