SECMenuBar Class

class SECMenuBar: public SECCustomToolBar

SECMenuBar replaces your normal menu with a dockable bar that has the look and feel of the Visual Studio and Office 97 menus. The menu bar buttons are represented by a simple button class that contains the HMENU to display when clicked. SECMenuBar uses SECCustomToolBar as a base class. So not only do you get the cool flat look, you also gain complete customization of the menu bar when used in conjuntion with SECToolBarManager. To integrate this class into your own existing aplication that uses the SECToolBarManager takes as little as three lines of code. See VIZ for an example of an application that was converted to use the new menu bar classes. The button map that is used in customizable toolbars to denote combo boxes, two-part buttons, and custom buttons can also be utilized to dynamically swap menus based on the currently active view.

Defined in: TMenuFrm.h

Class Members

SECMenuBar()

Constructor

virtual  ~SECMenuBar()

Destructor

virtual BOOL  CreateEx(DWORD dwExStyle, CWnd* pParentWnd, DWORD dwStyle = WS_VISIBLE | WS_CHILD | CBRS_TOP, UINT nID = AFX_IDW_CONTROLBAR_LAST, LPCTSTR lpszTitle = NULL)

Creates the SECMenuBar window

BOOL  LoadMenu(UINT nIDResource)

Loads the menu specified

BOOL  SwitchMenu(UINT nIDResource)

Switches to the menu specified

virtual void  EnableBitFlag(DWORD dwBit, BOOL bUpdate = FALSE )

Enables the bit flag

virtual void  OnBarStyleChange(DWORD dwOldStyle, DWORD dwNewStyle)

Notifies you when the style is changing

virtual HFONT  GetMenuFont() const

Returns font used for the menu

virtual void  ResetMenus(BOOL bNoUpdate = FALSE)

Resets the menu

virtual BOOL  SetMenuInfo(int nCount, UINT nIDMenu, ...)

Defines the menu resources to use.

UINT  GetCurMenuID() const

Returns the current menu ID