pasteAction.enable();
pasteAction.setEnabled(true);
    static JMenuBar createMenuBar() {	JMenuItem mi;        HashMap mnemonics = new HashMap();        int mask = Toolkit.getDefaultToolkit().getMenuShortcutKeyMask();        JMenuBar menuBar = new JMenuBar();	// create "File" Menu        JMenu menuFile = new JMenu("File");	mnemonics.put(menuFile, new Integer(KeyEvent.VK_F));        mi = menuFile.add(openAction);        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_O, mask));        mi = menuFile.add(saveAction);        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_S, mask));        menuFile.add(saveAsAction);        menuFile.addSeparator();        menuFile.add(importAction);        menuFile.add(exportAction);        menuFile.add(importAllAction);        if (!MacUtils.isMac()) {	    menuFile.addSeparator();	    menuFile.add(exitAction);	}	menuBar.add(menuFile);	// create "Library" Menu        JMenu menuLib = new JMenu("Library");	mnemonics.put(menuLib, new Integer(KeyEvent.VK_L));        menuLib.add(transferSceneAction);        menuLib.addSeparator();        menuLib.add(sortAction);        menuLib.add(searchAction);        menuLib.add(crossBreedAction);        menuLib.add(dupAction);        menuLib.addSeparator();	mi = menuLib.add(newAction);	mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_N, mask));        menuLib.add(newSceneAction);	menuBar.add(menuLib);	// create "Patch" Menu        JMenu menuPatch = new JMenu("Patch");	mnemonics.put(menuPatch, new Integer(KeyEvent.VK_P));        mi = menuPatch.add(copyAction);        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_COPY, 0));        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_C, mask));        mi = menuPatch.add(cutAction);        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_CUT, 0));        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_X, mask));        mi = menuPatch.add(pasteAction);        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_PASTE, 0));        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_V, mask));        mi = menuPatch.add(deleteAction);        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_DELETE, 0));        menuPatch.addSeparator();        mi = menuPatch.add(sendAction);        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_T, mask));        menuPatch.add(sendToAction);        menuPatch.add(storeAction);        menuPatch.add(receiveAction); // phil@muqus.com        menuPatch.addSeparator();        mi = menuPatch.add(editAction);        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_E, mask));        mi = menuPatch.add(playAction);        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_P, mask));        menuPatch.addSeparator(); 	menuPatch.add(reassignAction);        menuPatch.add(extractAction);        menuPatch.addSeparator();        menuPatch.add(newPatchAction);	menuPatch.add(uploadAction);        menuBar.add(menuPatch);	menuPatch.addMenuListener(new MenuListener() {		public void menuCanceled(MenuEvent e) {		}		public void menuDeselected(MenuEvent e) {		}		public void menuSelected(MenuEvent e) {		    pasteAction.enable();		}	    });	// create "Window" menu	JMenu menuWindow = JSLDesktop.createWindowMenu();	menuBar.add(menuWindow);	// create "Help" menu        JMenu menuHelp = new JMenu("Help");	mnemonics.put(menuHelp, new Integer(KeyEvent.VK_H));	mi = menuHelp.add(docsAction);        mi.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_HELP, 0));	// J2SE 1.4.2 is not ready for HTML of www.jsynthlib.org site	//mi = menuHelp.add(homePageAction);	mi = menuHelp.add(licenseAction);	if (!MacUtils.isMac())	    menuHelp.add(aboutAction);        menuBar.add(menuHelp);	// set keyboard short cut	if (!MacUtils.isMac())	    setMnemonics(mnemonics);        return menuBar;    }