MENUIT~1.H
上传用户:lianyisd
上传日期:2019-11-03
资源大小:5188k
文件大小:1k
- // MenuItemList.h: interface for the CMenuItemList class.
- //
- //////////////////////////////////////////////////////////////////////
- #if !defined(AFX_MENUITEMLIST_H__97C679A7_6399_11D4_B5A9_00105A74D1DF__INCLUDED_)
- #define AFX_MENUITEMLIST_H__97C679A7_6399_11D4_B5A9_00105A74D1DF__INCLUDED_
- #if _MSC_VER > 1000
- #pragma once
- #endif // _MSC_VER > 1000
- enum MenuStyle
- {
- TGZ_MS_Normal , TGZ_MS_NoIconed , TGZ_MS_Static ,
- TGZ_MS_Bitmap , TGZ_MS_Pushed , TGZ_MS_Checked
- //, TGZ_MS_RadioSelected
- };
- struct MenuItem
- {
- CString m_strMenuText;
- UINT m_iIndex;
- UINT m_iID;
- int m_iImageID;
- // MenuStyle m_MenuStyle;
- MenuItem * m_pNextItem;
- MenuItem * m_pLastItem;
- // MenuItem * m_pThisItem;
- };
- class CMenuItemList
- {
- public:
- CMenuItemList();
- virtual ~CMenuItemList();
- public:
- int m_nCount;
- MenuItem * m_pLastItem;
- MenuItem * m_pHead;
- MenuItem * m_pTail;
- public:
- int FindItemImageByID(unsigned int nID);
- unsigned int FindItemIndexByID ( unsigned int nID);
- CString FindItemTextByID( unsigned int nID);
- void RemoveTail();
- void RemoveAllItems();
- void Add(MenuItem mItem);
- void Remove( unsigned int nIndex);
- };
- #endif // !defined(AFX_MENUITEMLIST_H__97C679A7_6399_11D4_B5A9_00105A74D1DF__INCLUDED_)