OSDN Git Service

Use the reg command to import/export properties
[xkeymacs/xkeymacs.git] / xkeymacs / propertiesadvanced.h
1 #if !defined(AFX_PROPERTIESADVANCED_H__41C61B2B_97BA_4015_8F1E_CA65AC628E42__INCLUDED_)\r
2 #define AFX_PROPERTIESADVANCED_H__41C61B2B_97BA_4015_8F1E_CA65AC628E42__INCLUDED_\r
3 \r
4 #if _MSC_VER > 1000\r
5 #pragma once\r
6 #endif // _MSC_VER > 1000\r
7 // PropertiesAdvanced.h : header file\r
8 //\r
9 \r
10 #include "resource.h"\r
11 #include "../xkeymacsdll/Commands.h"\r
12 class CProperties;\r
13 \r
14 /////////////////////////////////////////////////////////////////////////////\r
15 // CPropertiesAdvanced dialog\r
16 \r
17 class CPropertiesAdvanced : public CPropertyPage\r
18 {\r
19         DECLARE_DYNCREATE(CPropertiesAdvanced)\r
20 \r
21 // Construction\r
22 public:\r
23         void EnableControl();\r
24         void GetDialogData();\r
25         void SetDialogData();\r
26         CPropertiesAdvanced();\r
27         ~CPropertiesAdvanced();\r
28 \r
29 // Dialog Data\r
30         //{{AFX_DATA(CPropertiesAdvanced)\r
31         enum { IDD = IDD_PROPERTIES_ADVANCED };\r
32         CStatic m_cCurrentlyAssigned;\r
33         CButton m_cResetAll;\r
34         CButton m_cRemove;\r
35         CEdit   m_cNewKey;\r
36         CStatic m_cDescription;\r
37         CListBox        m_cCurrentKeys;\r
38         CListBox        m_cCommands;\r
39         CComboBox       m_cCategory;\r
40         CButton m_cAssign;\r
41         BOOL    m_bEnableCUA;\r
42         //}}AFX_DATA\r
43 \r
44 \r
45 // Overrides\r
46         // ClassWizard generate virtual function overrides\r
47         //{{AFX_VIRTUAL(CPropertiesAdvanced)\r
48         public:\r
49         virtual BOOL OnSetActive();\r
50         virtual BOOL OnKillActive();\r
51         protected:\r
52         virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support\r
53         //}}AFX_VIRTUAL\r
54 \r
55 // Implementation\r
56 protected:\r
57         // Generated message map functions\r
58         //{{AFX_MSG(CPropertiesAdvanced)\r
59         afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);\r
60         virtual BOOL OnInitDialog();\r
61         afx_msg void OnSelchangeCategory();\r
62         afx_msg void OnSelchangeCommands();\r
63         afx_msg void OnSelchangeCurrentKeys();\r
64         afx_msg void OnSetfocusNewKey();\r
65         afx_msg void OnAssign();\r
66         afx_msg void OnRemove();\r
67         afx_msg void OnResetAll();\r
68         afx_msg void OnCX();\r
69         afx_msg void OnKillfocusNewKey();\r
70         afx_msg void OnEnableCua();\r
71         //}}AFX_MSG\r
72         DECLARE_MESSAGE_MAP()\r
73 private:\r
74         static int m_nAppID;\r
75         static BOOL IsFooDown(CString szCommandName);\r
76         static BOOL IsShiftDown();\r
77         static BOOL IsMetaDown();\r
78         static BOOL IsCtrlDown();\r
79         void InitCommandIDs();\r
80         static void SetCmdID(int nType, int nKey, int nComID);\r
81         static int m_nCommandIDs[MAX_COMMAND_TYPE][MAX_KEY];\r
82         static void SetNewKey();\r
83         static int m_nAssignKey;\r
84         static int m_nAssignCommandType;\r
85         static BOOL m_bShift;\r
86         static BOOL m_bM;\r
87         static BOOL m_bC;\r
88         static BOOL m_bC_x;\r
89         static LRESULT CALLBACK KeyboardProc(int code, WPARAM wParam, LPARAM lParam);\r
90         static HHOOK m_hKeyboardHook;\r
91         static CListBox * m_pCurrentKeys;\r
92         static CStatic * m_pCurrentlyAssigned;\r
93         static CButton * m_pAssign;\r
94         static CEdit * m_pNewKey;\r
95         int m_nRemoveKey;\r
96         int m_nRemoveCommandType;\r
97         void ClearNewKey();\r
98         static int m_nCommandID;\r
99         void SetCurrentKeys();\r
100         void SetCommands();\r
101         void InitCategoryList();\r
102         CProperties* m_pProperties;\r
103 };\r
104 \r
105 //{{AFX_INSERT_LOCATION}}\r
106 // Microsoft Visual C++ will insert additional declarations immediately before the previous line.\r
107 \r
108 #include "properties.h"\r
109 \r
110 #endif // !defined(AFX_PROPERTIESADVANCED_H__41C61B2B_97BA_4015_8F1E_CA65AC628E42__INCLUDED_)\r