📄 menubar.h
字号:
#if !defined(AFX_MENUBAR_H__E5638E48_7863_11D5_91A0_BB6868378677__INCLUDED_)
#define AFX_MENUBAR_H__E5638E48_7863_11D5_91A0_BB6868378677__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// MenuBar.h : header file
//
/////////////////////////////////////////////////////////////////////////////
//该类整合了本程序,不是通用类。
// CMenuBar window
class CMenuBar : public CToolBar
{
// Construction
public:
CMenuBar();
virtual ~CMenuBar();
// Attributes
public:
// Operations
public:
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CMenuBar)
public:
protected:
//}}AFX_VIRTUAL
// Implementation
public:
static LRESULT CALLBACK MenuInputFilter(int nCode, WPARAM wParam, LPARAM lParam);
HWND Create(HWND ParentWnd);
virtual BOOL OnCommand( WPARAM wParam, LPARAM lParam );
private:
BOOL InitMenuBar();
BOOL CreateFavorateMenu();
BOOL OnMenuInput(MSG* pMsg);
void TrackPopup();
void PressButton(int nIndex, BOOL bPress);
inline int AddString(LPCTSTR lpszString);
// Generated message map functions
protected:
//{{AFX_MSG(CMenuBar)
afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
afx_msg LRESULT OnPopupMenu(WPARAM, LPARAM);
afx_msg void OnDrawItem(int nIDCtl, LPDRAWITEMSTRUCT lpDrawItemStruct);
afx_msg void OnMeasureItem(int nIDCtl, LPMEASUREITEMSTRUCT lpMeasureItemStruct);
afx_msg void OnMenuCommand(WPARAM wParam, LPARAM lParam);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
private:
inline void GetURLFromURLShortcutFile(LPCTSTR lpszURLFileName, LPTSTR lpszURL, UINT cch);
void FreeMenuResource(HMENU hMenu);
HMENU CreateMenuForFolder(LPCTSTR lpszFolderName);
BOOL IsURLFile(LPCTSTR lpszFileName);
inline void Draw3DRect(HDC hdc, int x, int y, int cx, int cy);
int m_nPressed;
int m_nPriMenuItemCount;
BOOL m_bTrack;
HICON m_hIeIcon, m_hFolderIcon;
HMENU m_hMenu;
HIMAGELIST m_hImgList;
CPoint m_ptMouse;
CStringArray m_URLStringArray;
UINT m_uMenuIDOrder;
};
typedef struct _tagMenuItemData
{
LPTSTR lpszMenuText;
int nMenuIndex;
BOOL bIsFolder;
} MenuItemData, *PMenuItemData;
/////////////////////////////////////////////////////////////////////////////
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_MENUBAR_H__E5638E48_7863_11D5_91A0_BB6868378677__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -