00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #pragma once
00023
00024 #include "PPageBase.h"
00025 #include "PlayerListCtrl.h"
00026 #include "StaticLink.h"
00027
00028
00029
00030 class CPPageAccelTbl : public CPPageBase
00031 {
00032 DECLARE_DYNAMIC(CPPageAccelTbl)
00033
00034 private:
00035 enum {COL_CMD, COL_MOD, COL_KEY, COL_TYPE, COL_ID, COL_MOUSE, COL_APPCMD, COL_RMCMD, COL_RMREPCNT};
00036 CList<wmcmd> m_wmcmds;
00037
00038 void SetupList();
00039
00040 int m_counter;
00041
00042 public:
00043 CPPageAccelTbl();
00044 virtual ~CPPageAccelTbl();
00045
00046 static CString MakeAccelModLabel(BYTE fVirt);
00047 static CString MakeAccelVkeyLabel(WORD key, bool fVirtKey);
00048 static CString MakeAccelShortcutLabel(UINT id);
00049 static CString MakeAccelShortcutLabel(ACCEL& a);
00050 static CString MakeMouseButtonLabel(UINT mouse);
00051 static CString MakeAppCommandLabel(UINT id);
00052
00053 enum {APPCOMMAND_LAST=APPCOMMAND_MEDIA_CHANNEL_DOWN};
00054
00055
00056 enum { IDD = IDD_PPAGEACCELTBL };
00057 CPlayerListCtrl m_list;
00058 BOOL m_fWinLirc;
00059 CString m_WinLircAddr;
00060 CEdit m_WinLircEdit;
00061 CStaticLink m_WinLircLink;
00062 BOOL m_fUIce;
00063 CString m_UIceAddr;
00064 CEdit m_UIceEdit;
00065 CStaticLink m_UIceLink;
00066
00067 protected:
00068 virtual void DoDataExchange(CDataExchange* pDX);
00069 virtual BOOL OnInitDialog();
00070 virtual BOOL OnApply();
00071 virtual BOOL PreTranslateMessage(MSG* pMsg);
00072 virtual BOOL OnSetActive();
00073 virtual BOOL OnKillActive();
00074
00075 DECLARE_MESSAGE_MAP()
00076
00077 public:
00078 afx_msg void OnBeginlabeleditList(NMHDR* pNMHDR, LRESULT* pResult);
00079 afx_msg void OnDolabeleditList(NMHDR* pNMHDR, LRESULT* pResult);
00080 afx_msg void OnEndlabeleditList(NMHDR* pNMHDR, LRESULT* pResult);
00081 afx_msg void OnBnClickedButton1();
00082 afx_msg void OnBnClickedButton2();
00083 afx_msg HBRUSH OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor);
00084 afx_msg void OnTimer(UINT nIDEvent);
00085 };