www.gusucode.com > mbcguitools 工具箱 matlab 源码程序 > mbcguitools/@mbcmultiview/@Action/createMenuItem.m
function hMenu = createMenuItem(obj, hParent) %CREATEMENUITEM Create a menu item for the action % % HMENU = CREATEMENUITEM(OBJ, HPARENT) creates a new uimenu object with % HPARENT as a parent. When the menu item is selected it will execute the % action. % Copyright 2005-2010 The MathWorks, Inc. and Ford Global Technologies, Inc. nMenus = obj.numRequiredMenus; for n = 1:nMenus hMenu(n) = uimenu('Parent', hParent); end obj.attachToMenu(hMenu);