• R/O
  • HTTP
  • SSH
  • HTTPS

xkeymacs: Commit


Commit MetaInfo

Revision5a0263c8e57ba13fbe2ea2f4e8d966eda72dab69 (tree)
Time2012-01-27 23:58:03
AuthorKazuhiro Fujieda <fujieda@user...>
CommiterKazuhiro Fujieda

Log Message

Define almost data members out of the shared section.
Rename m_kbdMacro to m_KbdMacro in CCommands.

Change Summary

Incremental Difference

--- a/xkeymacsdll/Commands.cpp
+++ b/xkeymacsdll/Commands.cpp
@@ -10,27 +10,24 @@
1010 #include <math.h>
1111 #include <Imm.h>
1212
13-#pragma data_seg(".xkmcs")
14-DWORD CCommands::m_nNumericArgument = 1;
15-BOOL CCommands::m_bSetMark = FALSE;
16-BOOL CCommands::m_bC_ = FALSE;
17-BOOL CCommands::m_bC_x = FALSE;
18-BOOL CCommands::m_bM_ = FALSE;
19-BOOL CCommands::m_bM_x = FALSE;
20-BOOL CCommands::m_bDefaultNumericArgument = TRUE;
21-BOOL CCommands::m_bNegativeNumericArgument = FALSE;
22-BOOL CCommands::m_bC_u = FALSE;
23-SEARCH_DIRECTION CCommands::m_SearchDirection = NA;
24-BOOL CCommands::m_bFirstFindDialog = FALSE;
25-BOOL CCommands::m_bTemporarilyDisableXKeymacs = FALSE;
13+KbdMacro CCommands::m_KbdMacro;
2614 OriginalWindowPosition CCommands::m_OriginalWindowPosition[MAX_WINDOW] = {'\0'};
27-BOOL CCommands::m_bIsSu = FALSE;
28-#pragma data_seg()
29-
30-KbdMacro CCommands::m_kbdMacro;
15+CArray<CClipboardSnap *, CClipboardSnap *> CCommands::m_oClipboardData;
16+BOOL CCommands::m_bTemporarilyDisableXKeymacs = FALSE;
17+BOOL CCommands::m_bFirstFindDialog = FALSE;
18+BOOL CCommands::m_bC_ = FALSE;
3119 int (*CCommands::m_LastKillCommand)() = NULL;
3220 int (*CCommands::m_LastCommand)() = NULL;
33-CArray<CClipboardSnap *, CClipboardSnap *> CCommands::m_oClipboardData;
21+SEARCH_DIRECTION CCommands::m_SearchDirection = NA;
22+BOOL CCommands::m_bC_u = FALSE;
23+BOOL CCommands::m_bNegativeNumericArgument = FALSE;
24+BOOL CCommands::m_bDefaultNumericArgument = TRUE;
25+BOOL CCommands::m_bM_x = FALSE;
26+BOOL CCommands::m_bM_ = FALSE;
27+BOOL CCommands::m_bC_x = FALSE;
28+BOOL CCommands::m_bSetMark = FALSE;
29+DWORD CCommands::m_nNumericArgument = 1;
30+BOOL CCommands::m_bIsSu = FALSE;
3431
3532 void CCommands::DepressKey(BYTE bVk)
3633 {
@@ -2533,9 +2530,9 @@ int CCommands::StartKbdMacro()
25332530 SdKduSu(VK_F1);
25342531 else {
25352532 if (bC_u())
2536- m_kbdMacro.Call();
2537- m_kbdMacro.Start();
2538- CXkeymacsDll::SetKbMacro(&m_kbdMacro);
2533+ m_KbdMacro.Call();
2534+ m_KbdMacro.Start();
2535+ CXkeymacsDll::SetKbMacro(&m_KbdMacro);
25392536 }
25402537 return Reset(GOTO_HOOK);
25412538 }
@@ -2548,7 +2545,7 @@ int CCommands::EndKbdMacro()
25482545 else if (CUtils::IsHidemaru())
25492546 SdKduSu(VK_F1);
25502547 else {
2551- m_kbdMacro.End();
2548+ m_KbdMacro.End();
25522549 CXkeymacsDll::SetKbMacro(NULL);
25532550 }
25542551 return Reset(GOTO_HOOK);
@@ -2569,7 +2566,7 @@ int CCommands::CallLastKbdMacro()
25692566 } else {
25702567 EndKbdMacro();
25712568 while (m_nNumericArgument--)
2572- m_kbdMacro.Call();
2569+ m_KbdMacro.Call();
25732570 }
25742571 return Reset(GOTO_HOOK);
25752572 }
--- a/xkeymacsdll/Commands.h
+++ b/xkeymacsdll/Commands.h
@@ -173,7 +173,7 @@ public:
173173 static int ForwardChar();
174174
175175 private:
176- static KbdMacro m_kbdMacro;
176+ static KbdMacro m_KbdMacro;
177177 static BOOL CutFollowingWord();
178178 static int CaseWord(CASE_WORD nCase);
179179 static BOOL CopyCurrentLine();
--- a/xkeymacsdll/xkeymacsdll.cpp
+++ b/xkeymacsdll/xkeymacsdll.cpp
@@ -92,12 +92,6 @@ DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved)
9292 Config CXkeymacsDll::m_Config = {0};
9393 bool CXkeymacsDll::m_bEnableKeyboardHook = false;
9494 BOOL CXkeymacsDll::m_bHook = TRUE;
95-DWORD CXkeymacsDll::m_nHookAltRelease = 0;
96-BOOL CXkeymacsDll::m_bRightShift = FALSE;
97-BOOL CXkeymacsDll::m_bRightControl = FALSE;
98-BOOL CXkeymacsDll::m_bRightAlt = FALSE;
99-TCHAR CXkeymacsDll::m_M_xTip[128] = "";
100-BYTE CXkeymacsDll::m_nOriginal[MAX_COMMAND_TYPE][MAX_KEY] = {'\0'};
10195 int CXkeymacsDll::m_nAccelerate = 0;
10296 int CXkeymacsDll::m_nKeyboardSpeed = 31;
10397 HCURSOR CXkeymacsDll::m_hCurrentCursor = NULL;
@@ -112,6 +106,12 @@ HHOOK CXkeymacsDll::m_hHookCallWnd = NULL;
112106 HHOOK CXkeymacsDll::m_hHookCallWndRet = NULL;
113107 HHOOK CXkeymacsDll::m_hHookGetMessage = NULL;
114108 HHOOK CXkeymacsDll::m_hHookShell = NULL;
109+DWORD CXkeymacsDll::m_nHookAltRelease = 0;
110+BOOL CXkeymacsDll::m_bRightShift = FALSE;
111+BOOL CXkeymacsDll::m_bRightControl = FALSE;
112+BOOL CXkeymacsDll::m_bRightAlt = FALSE;
113+TCHAR CXkeymacsDll::m_M_xTip[128] = "";
114+BYTE CXkeymacsDll::m_nOriginal[MAX_COMMAND_TYPE][MAX_KEY] = {'\0'};
115115 CList<CClipboardSnap *, CClipboardSnap *> CXkeymacsDll::m_oKillRing;
116116 int CXkeymacsDll::m_nKillRing = 0;
117117 KbdMacro* CXkeymacsDll::m_kbdMacro = NULL;
Show on old repository browser