1 // TortoiseGit - a Windows shell extension for easy version control
3 // Copyright (C) 2012-2014 - TortoiseGit
4 // Copyright (C) 2003-2008 - Stefan Kueng
6 // This program is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU General Public License
8 // as published by the Free Software Foundation; either version 2
9 // of the License, or (at your option) any later version.
11 // This program is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
16 // You should have received a copy of the GNU General Public License
17 // along with this program; if not, write to the Free Software Foundation,
18 // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
23 #include "GitAdminDir.h"
26 #define REGISTRYTIMEOUT 2000
27 #define EXCLUDELISTTIMEOUT 5000
28 #define ADMINDIRTIMEOUT 10000
29 #define DRIVETYPETIMEOUT 300000 // 5 min
30 #define MENUTIMEOUT 100
32 #define DEFAULTMENUTOPENTRIES MENUSYNC|MENUCREATEREPOS|MENUCLONE|MENUCOMMIT
33 #define DEFAULTMENUEXTENTRIES MENUSVNIGNORE|MENUREFLOG|MENUREFBROWSE|MENUSTASHAPPLY|MENUSUBSYNC
35 typedef CComCritSecLock
<CComCriticalSection
> Locker
;
38 * \ingroup TortoiseShell
39 * Helper class which caches access to the registry. Also provides helper methods
40 * for checks against the settings stored in the registry.
50 dllFull
,// same as dll except it uses commandline git tool with all status modes supported
54 cachetype
= CRegStdDWORD(_T("Software\\TortoiseGit\\CacheType"), GetSystemMetrics(SM_REMOTESESSION
) ? dll
: exe
);
55 showrecursive
= CRegStdDWORD(_T("Software\\TortoiseGit\\RecursiveOverlay"), TRUE
);
56 folderoverlay
= CRegStdDWORD(_T("Software\\TortoiseGit\\FolderOverlay"), TRUE
);
57 driveremote
= CRegStdDWORD(_T("Software\\TortoiseGit\\DriveMaskRemote"));
58 drivefixed
= CRegStdDWORD(_T("Software\\TortoiseGit\\DriveMaskFixed"), TRUE
);
59 drivecdrom
= CRegStdDWORD(_T("Software\\TortoiseGit\\DriveMaskCDROM"));
60 driveremove
= CRegStdDWORD(_T("Software\\TortoiseGit\\DriveMaskRemovable"));
61 drivefloppy
= CRegStdDWORD(_T("Software\\TortoiseGit\\DriveMaskFloppy"));
62 driveram
= CRegStdDWORD(_T("Software\\TortoiseGit\\DriveMaskRAM"));
63 driveunknown
= CRegStdDWORD(_T("Software\\TortoiseGit\\DriveMaskUnknown"));
64 shellmenuaccelerators
= CRegStdDWORD(_T("Software\\TortoiseGit\\ShellMenuAccelerators"), TRUE
);
65 excludelist
= CRegStdString(_T("Software\\TortoiseGit\\OverlayExcludeList"));
66 includelist
= CRegStdString(_T("Software\\TortoiseGit\\OverlayIncludeList"));
67 simplecontext
= CRegStdDWORD(_T("Software\\TortoiseGit\\SimpleContext"), FALSE
);
68 unversionedasmodified
= CRegStdDWORD(_T("Software\\TortoiseGit\\UnversionedAsModified"), FALSE
);
69 recursesubmodules
= CRegStdDWORD(_T("Software\\TortoiseGit\\TGitCacheRecurseSubmodules"), FALSE
);
70 hidemenusforunversioneditems
= CRegStdDWORD(_T("Software\\TortoiseGit\\HideMenusForUnversionedItems"), FALSE
);
71 showunversionedoverlay
= CRegStdDWORD(_T("Software\\TortoiseGit\\ShowUnversionedOverlay"), TRUE
);
72 showignoredoverlay
= CRegStdDWORD(_T("Software\\TortoiseGit\\ShowIgnoredOverlay"), TRUE
);
73 getlocktop
= CRegStdDWORD(_T("Software\\TortoiseGit\\GetLockTop"), TRUE
);
74 excludedasnormal
= CRegStdDWORD(_T("Software\\TortoiseGit\\ShowExcludedAsNormal"), TRUE
);
75 cachetypeticker
= GetTickCount();
76 recursiveticker
= cachetypeticker
;
77 folderoverlayticker
= cachetypeticker
;
78 driveticker
= cachetypeticker
;
79 drivetypeticker
= cachetypeticker
;
80 langticker
= cachetypeticker
;
81 excludelistticker
= cachetypeticker
;
82 includelistticker
= cachetypeticker
;
83 simplecontextticker
= cachetypeticker
;
84 shellmenuacceleratorsticker
= cachetypeticker
;
85 unversionedasmodifiedticker
= cachetypeticker
;
86 recursesubmodulesticker
= cachetypeticker
;
87 showunversionedoverlayticker
= cachetypeticker
;
88 showignoredoverlayticker
= cachetypeticker
;
89 admindirticker
= cachetypeticker
;
90 getlocktopticker
= cachetypeticker
;
91 excludedasnormalticker
= cachetypeticker
;
92 hidemenusforunversioneditemsticker
= cachetypeticker
;
93 excontextticker
= cachetypeticker
;
95 unsigned __int64 entries
= (DEFAULTMENUTOPENTRIES
);
96 menulayoutlow
= CRegStdDWORD(_T("Software\\TortoiseGit\\ContextMenuEntries"), entries
&0xFFFFFFFF);
97 menulayouthigh
= CRegStdDWORD(_T("Software\\TortoiseGit\\ContextMenuEntrieshigh"), entries
>>32);
98 layoutticker
= cachetypeticker
;
100 unsigned __int64 ext
= (DEFAULTMENUEXTENTRIES
);
101 menuextlow
= CRegStdDWORD(_T("Software\\TortoiseGit\\ContextMenuExtEntriesLow"), ext
&0xFFFFFFFF );
102 menuexthigh
= CRegStdDWORD(_T("Software\\TortoiseGit\\ContextMenuExtEntriesHigh"), ext
>>32 );
103 exticker
= cachetypeticker
;
105 menumasklow_lm
= CRegStdDWORD(_T("Software\\TortoiseGit\\ContextMenuEntriesMaskLow"), 0, FALSE
, HKEY_LOCAL_MACHINE
);
106 menumaskhigh_lm
= CRegStdDWORD(_T("Software\\TortoiseGit\\ContextMenuEntriesMaskHigh"), 0, FALSE
, HKEY_LOCAL_MACHINE
);
107 menumasklow_cu
= CRegStdDWORD(_T("Software\\TortoiseGit\\ContextMenuEntriesMaskLow"), 0);
108 menumaskhigh_cu
= CRegStdDWORD(_T("Software\\TortoiseGit\\ContextMenuEntriesMaskHigh"), 0);
109 menumaskticker
= cachetypeticker
;
110 langid
= CRegStdDWORD(_T("Software\\TortoiseGit\\LanguageID"), 1033);
111 blockstatus
= CRegStdDWORD(_T("Software\\TortoiseGit\\BlockStatus"), 0);
112 blockstatusticker
= cachetypeticker
;
113 for (int i
= 0; i
< 27; ++i
)
115 drivetypecache
[i
] = (UINT
)-1;
117 // A: and B: are floppy disks
118 drivetypecache
[0] = DRIVE_REMOVABLE
;
119 drivetypecache
[1] = DRIVE_REMOVABLE
;
120 drivetypepathcache
[0] = 0;
121 sAdminDirCacheKey
.reserve(MAX_PATH
); // MAX_PATH as buffer reservation ok.
122 nocontextpaths
= CRegStdString(_T("Software\\TortoiseGit\\NoContextPaths"), _T(""));
128 showrecursive
.read();
129 folderoverlay
.read();
139 simplecontext
.read();
140 shellmenuaccelerators
.read();
141 unversionedasmodified
.read();
142 recursesubmodules
.read();
143 showunversionedoverlay
.read();
144 showignoredoverlay
.read();
145 excludedasnormal
.read();
146 hidemenusforunversioneditems
.read();
147 menulayoutlow
.read();
148 menulayouthigh
.read();
152 menumasklow_lm
.read();
153 menumaskhigh_lm
.read();
154 menumasklow_cu
.read();
155 menumaskhigh_cu
.read();
156 nocontextpaths
.read();
158 CacheType
GetCacheType()
160 if ((GetTickCount() - REGISTRYTIMEOUT
) > cachetypeticker
)
162 cachetypeticker
= GetTickCount();
165 return CacheType(DWORD((cachetype
)));
169 if ((GetTickCount() - REGISTRYTIMEOUT
) > blockstatusticker
)
171 blockstatusticker
= GetTickCount();
174 return (blockstatus
);
176 unsigned __int64
GetMenuLayout()
178 if ((GetTickCount() - REGISTRYTIMEOUT
) > layoutticker
)
180 layoutticker
= GetTickCount();
181 menulayoutlow
.read();
182 menulayouthigh
.read();
184 unsigned __int64 temp
= unsigned __int64(DWORD(menulayouthigh
))<<32;
185 temp
|= unsigned __int64(DWORD(menulayoutlow
));
189 unsigned __int64
GetMenuExt()
191 if ((GetTickCount() - REGISTRYTIMEOUT
) > exticker
)
193 exticker
= GetTickCount();
197 unsigned __int64 temp
= unsigned __int64(DWORD(menuexthigh
))<<32;
198 temp
|= unsigned __int64(DWORD(menuextlow
));
202 unsigned __int64
GetMenuMask()
204 if ((GetTickCount() - REGISTRYTIMEOUT
) > menumaskticker
)
206 menumaskticker
= GetTickCount();
207 menumasklow_lm
.read();
208 menumaskhigh_lm
.read();
209 menumasklow_cu
.read();
210 menumaskhigh_cu
.read();
212 DWORD low
= (DWORD
)menumasklow_lm
| (DWORD
)menumasklow_cu
;
213 DWORD high
= (DWORD
)menumaskhigh_lm
| (DWORD
)menumaskhigh_cu
;
214 unsigned __int64 temp
= unsigned __int64(high
)<<32;
215 temp
|= unsigned __int64(low
);
220 if ((GetTickCount() - REGISTRYTIMEOUT
)>recursiveticker
)
222 recursiveticker
= GetTickCount();
223 showrecursive
.read();
225 return (showrecursive
);
227 BOOL
IsFolderOverlay()
229 if ((GetTickCount() - REGISTRYTIMEOUT
)>folderoverlayticker
)
231 folderoverlayticker
= GetTickCount();
232 folderoverlay
.read();
234 return (folderoverlay
);
236 BOOL
IsSimpleContext()
238 if ((GetTickCount() - REGISTRYTIMEOUT
)>simplecontextticker
)
240 simplecontextticker
= GetTickCount();
241 simplecontext
.read();
243 return (simplecontext
!=0);
245 BOOL
HasShellMenuAccelerators()
247 if ((GetTickCount() - shellmenuacceleratorsticker
)>REGISTRYTIMEOUT
)
249 shellmenuacceleratorsticker
= GetTickCount();
250 shellmenuaccelerators
.read();
252 return (shellmenuaccelerators
!=0);
254 BOOL
IsUnversionedAsModified()
256 if ((GetTickCount() - REGISTRYTIMEOUT
)>unversionedasmodifiedticker
)
258 unversionedasmodifiedticker
= GetTickCount();
259 unversionedasmodified
.read();
261 return (unversionedasmodified
);
263 BOOL
IsRecurseSubmodules()
265 if ((GetTickCount() - REGISTRYTIMEOUT
) > recursesubmodulesticker
)
267 recursesubmodulesticker
= GetTickCount();
268 recursesubmodules
.read();
270 return (recursesubmodules
);
272 BOOL
ShowUnversionedOverlay()
274 if ((GetTickCount() - REGISTRYTIMEOUT
)>showunversionedoverlayticker
)
276 showunversionedoverlayticker
= GetTickCount();
277 showunversionedoverlay
.read();
279 return (showunversionedoverlay
);
281 BOOL
ShowIgnoredOverlay()
283 if ((GetTickCount() - REGISTRYTIMEOUT
)>showignoredoverlayticker
)
285 showignoredoverlayticker
= GetTickCount();
286 showignoredoverlay
.read();
288 return (showignoredoverlay
);
292 if ((GetTickCount() - REGISTRYTIMEOUT
)>getlocktopticker
)
294 getlocktopticker
= GetTickCount();
299 BOOL
ShowExcludedAsNormal()
301 if ((GetTickCount() - REGISTRYTIMEOUT
)>excludedasnormalticker
)
303 excludedasnormalticker
= GetTickCount();
304 excludedasnormal
.read();
306 return (excludedasnormal
);
308 BOOL
HideMenusForUnversionedItems()
310 if ((GetTickCount() - hidemenusforunversioneditemsticker
)>REGISTRYTIMEOUT
)
312 hidemenusforunversioneditemsticker
= GetTickCount();
313 hidemenusforunversioneditems
.read();
315 return (hidemenusforunversioneditems
);
320 return (driveremote
);
335 return (driveremove
);
345 return (driveunknown
);
347 BOOL
IsContextPathAllowed(LPCTSTR path
)
349 Locker
lock(m_critSec
);
350 ExcludeContextValid();
351 for (std::vector
<stdstring
>::iterator I
= excontextvector
.begin(); I
!= excontextvector
.end(); ++I
)
355 if (!I
->empty() && I
->at(I
->size()-1)=='*')
357 stdstring str
= I
->substr(0, I
->size()-1);
358 if (_tcsnicmp(str
.c_str(), path
, str
.size())==0)
361 else if (_tcsicmp(I
->c_str(), path
)==0)
366 BOOL
IsPathAllowed(LPCTSTR path
)
368 Locker
lock(m_critSec
);
370 for (std::vector
<stdstring
>::iterator I
= invector
.begin(); I
!= invector
.end(); ++I
)
374 if (I
->at(I
->size()-1)=='*')
376 stdstring str
= I
->substr(0, I
->size()-1);
377 if (_tcsnicmp(str
.c_str(), path
, str
.size())==0)
379 if (!str
.empty() && (str
.at(str
.size()-1) == '\\') && (_tcsnicmp(str
.c_str(), path
, str
.size()-1)==0))
382 else if (_tcsicmp(I
->c_str(), path
)==0)
384 else if ((I
->at(I
->size()-1) == '\\') &&
385 ((_tcsnicmp(I
->c_str(), path
, I
->size())==0) || (_tcsicmp(I
->c_str(), path
)==0)) )
390 int drivenumber
= PathGetDriveNumber(path
);
391 if ((drivenumber
>=0)&&(drivenumber
< 25))
393 drivetype
= drivetypecache
[drivenumber
];
394 if ((drivetype
== -1)||((GetTickCount() - DRIVETYPETIMEOUT
)>drivetypeticker
))
396 if ((drivenumber
== 0)||(drivenumber
== 1))
397 drivetypecache
[drivenumber
] = DRIVE_REMOVABLE
;
400 drivetypeticker
= GetTickCount();
401 TCHAR pathbuf
[MAX_PATH
+4] = {0}; // MAX_PATH ok here. PathStripToRoot works with partial paths too.
402 _tcsncpy_s(pathbuf
, MAX_PATH
+4, path
, MAX_PATH
+3);
403 PathStripToRoot(pathbuf
);
404 PathAddBackslash(pathbuf
);
405 CTraceToOutputDebugString::Instance()(_T(__FUNCTION__
) _T(": GetDriveType for %s, Drive %d\n"), pathbuf
, drivenumber
);
406 drivetype
= GetDriveType(pathbuf
);
407 drivetypecache
[drivenumber
] = drivetype
;
413 TCHAR pathbuf
[MAX_PATH
+4] = {0}; // MAX_PATH ok here. PathIsUNCServer works with partial paths too.
414 _tcsncpy_s(pathbuf
, MAX_PATH
+4, path
, MAX_PATH
+3);
415 if (PathIsUNCServer(pathbuf
))
416 drivetype
= DRIVE_REMOTE
;
419 PathStripToRoot(pathbuf
);
420 PathAddBackslash(pathbuf
);
421 if (_tcsncmp(pathbuf
, drivetypepathcache
, MAX_PATH
-1)==0) // MAX_PATH ok.
422 drivetype
= drivetypecache
[26];
425 CTraceToOutputDebugString::Instance()(_T(__FUNCTION__
) _T("GetDriveType for %s\n"), pathbuf
);
426 drivetype
= GetDriveType(pathbuf
);
427 drivetypecache
[26] = drivetype
;
428 _tcsncpy_s(drivetypepathcache
, MAX_PATH
, pathbuf
, MAX_PATH
); // MAX_PATH ok.
432 if ((drivetype
== DRIVE_REMOVABLE
)&&(!IsRemovable()))
434 if ((drivetype
== DRIVE_REMOVABLE
)&&(drivefloppy
== 0)&&((drivenumber
==0)||(drivenumber
==1)))
436 if ((drivetype
== DRIVE_FIXED
)&&(!IsFixed()))
438 if (((drivetype
== DRIVE_REMOTE
)||(drivetype
== DRIVE_NO_ROOT_DIR
))&&(!IsRemote()))
440 if ((drivetype
== DRIVE_CDROM
)&&(!IsCDRom()))
442 if ((drivetype
== DRIVE_RAMDISK
)&&(!IsRAM()))
444 if ((drivetype
== DRIVE_UNKNOWN
)&&(IsUnknown()))
448 for (std::vector
<stdstring
>::iterator I
= exvector
.begin(); I
!= exvector
.end(); ++I
)
452 if (I
->size() && I
->at(I
->size()-1)=='*')
454 stdstring str
= I
->substr(0, I
->size()-1);
455 if (_tcsnicmp(str
.c_str(), path
, str
.size())==0)
458 else if (_tcsicmp(I
->c_str(), path
)==0)
465 if ((GetTickCount() - REGISTRYTIMEOUT
) > langticker
)
467 langticker
= GetTickCount();
472 BOOL
HasGITAdminDir(LPCTSTR path
, BOOL bIsDir
, CString
*ProjectTopDir
= NULL
)
474 size_t len
= _tcslen(path
);
475 std::unique_ptr
<TCHAR
[]> buf(new TCHAR
[len
+ 1]);
476 _tcscpy_s(buf
.get(), len
+ 1, path
);
479 TCHAR
* ptr
= _tcsrchr(buf
.get(), '\\');
485 if ((GetTickCount() - ADMINDIRTIMEOUT
) < admindirticker
)
487 std::map
<stdstring
, AdminDir_s
>::iterator iter
;
488 sAdminDirCacheKey
.assign(buf
.get());
489 if ((iter
= admindircache
.find(sAdminDirCacheKey
)) != admindircache
.end())
491 if (ProjectTopDir
&& iter
->second
.bHasAdminDir
)
492 *ProjectTopDir
= iter
->second
.sProjectRoot
.c_str();
493 return iter
->second
.bHasAdminDir
;
496 CString sProjectRoot
;
497 BOOL hasAdminDir
= g_GitAdminDir
.HasAdminDir(buf
.get(), true, &sProjectRoot
);
498 admindirticker
= GetTickCount();
499 Locker
lock(m_critSec
);
501 AdminDir_s
&ad
= admindircache
[buf
.get()];
502 ad
.bHasAdminDir
= hasAdminDir
;
505 ad
.sProjectRoot
.assign(sProjectRoot
);
508 *ProjectTopDir
= sProjectRoot
;
516 if ((GetTickCount() - REGISTRYTIMEOUT
)>driveticker
)
518 driveticker
= GetTickCount();
526 void ExcludeContextValid()
528 if ((GetTickCount() - EXCLUDELISTTIMEOUT
)>excontextticker
)
530 Locker
lock(m_critSec
);
531 excontextticker
= GetTickCount();
532 nocontextpaths
.read();
533 if (excludecontextstr
.compare((stdstring
)nocontextpaths
)==0)
535 excludecontextstr
= (stdstring
)nocontextpaths
;
536 excontextvector
.clear();
537 size_t pos
= 0, pos_ant
= 0;
538 pos
= excludecontextstr
.find(_T("\n"), pos_ant
);
539 while (pos
!= stdstring::npos
)
541 stdstring token
= excludecontextstr
.substr(pos_ant
, pos
-pos_ant
);
542 excontextvector
.push_back(token
);
544 pos
= excludecontextstr
.find(_T("\n"), pos_ant
);
546 if (!excludecontextstr
.empty())
548 excontextvector
.push_back(excludecontextstr
.substr(pos_ant
, excludecontextstr
.size()-1));
550 excludecontextstr
= (stdstring
)nocontextpaths
;
553 void ExcludeListValid()
555 if ((GetTickCount() - EXCLUDELISTTIMEOUT
)>excludelistticker
)
557 Locker
lock(m_critSec
);
558 excludelistticker
= GetTickCount();
560 if (excludeliststr
.compare((stdstring
)excludelist
)==0)
562 excludeliststr
= (stdstring
)excludelist
;
564 size_t pos
= 0, pos_ant
= 0;
565 pos
= excludeliststr
.find(_T("\n"), pos_ant
);
566 while (pos
!= stdstring::npos
)
568 stdstring token
= excludeliststr
.substr(pos_ant
, pos
-pos_ant
);
569 exvector
.push_back(token
);
571 pos
= excludeliststr
.find(_T("\n"), pos_ant
);
573 if (!excludeliststr
.empty())
575 exvector
.push_back(excludeliststr
.substr(pos_ant
, excludeliststr
.size()-1));
577 excludeliststr
= (stdstring
)excludelist
;
580 void IncludeListValid()
582 if ((GetTickCount() - EXCLUDELISTTIMEOUT
)>includelistticker
)
584 Locker
lock(m_critSec
);
585 includelistticker
= GetTickCount();
587 if (includeliststr
.compare((stdstring
)includelist
)==0)
589 includeliststr
= (stdstring
)includelist
;
591 size_t pos
= 0, pos_ant
= 0;
592 pos
= includeliststr
.find(_T("\n"), pos_ant
);
593 while (pos
!= stdstring::npos
)
595 stdstring token
= includeliststr
.substr(pos_ant
, pos
-pos_ant
);
596 invector
.push_back(token
);
598 pos
= includeliststr
.find(_T("\n"), pos_ant
);
600 if (!includeliststr
.empty())
602 invector
.push_back(includeliststr
.substr(pos_ant
, includeliststr
.size()-1));
604 includeliststr
= (stdstring
)includelist
;
611 stdstring sProjectRoot
;
614 CRegStdDWORD cachetype
;
615 CRegStdDWORD blockstatus
;
617 CRegStdDWORD showrecursive
;
618 CRegStdDWORD folderoverlay
;
619 CRegStdDWORD getlocktop
;
620 CRegStdDWORD driveremote
;
621 CRegStdDWORD drivefixed
;
622 CRegStdDWORD drivecdrom
;
623 CRegStdDWORD driveremove
;
624 CRegStdDWORD drivefloppy
;
625 CRegStdDWORD driveram
;
626 CRegStdDWORD driveunknown
;
627 CRegStdDWORD menulayoutlow
; /* Fist level mask */
628 CRegStdDWORD menulayouthigh
;
629 CRegStdDWORD shellmenuaccelerators
;
630 CRegStdDWORD menuextlow
; /* ext menu mask */
631 CRegStdDWORD menuexthigh
;
632 CRegStdDWORD simplecontext
;
633 CRegStdDWORD menumasklow_lm
;
634 CRegStdDWORD menumaskhigh_lm
;
635 CRegStdDWORD menumasklow_cu
;
636 CRegStdDWORD menumaskhigh_cu
;
637 CRegStdDWORD unversionedasmodified
;
638 CRegStdDWORD recursesubmodules
;
639 CRegStdDWORD showunversionedoverlay
;
640 CRegStdDWORD showignoredoverlay
;
641 CRegStdDWORD excludedasnormal
;
642 CRegStdString excludelist
;
643 CRegStdDWORD hidemenusforunversioneditems
;
644 stdstring excludeliststr
;
645 std::vector
<stdstring
> exvector
;
646 CRegStdString includelist
;
647 stdstring includeliststr
;
648 std::vector
<stdstring
> invector
;
649 DWORD cachetypeticker
;
650 DWORD recursiveticker
;
651 DWORD folderoverlayticker
;
652 DWORD getlocktopticker
;
654 DWORD drivetypeticker
;
657 DWORD menumaskticker
;
659 DWORD blockstatusticker
;
660 DWORD excludelistticker
;
661 DWORD includelistticker
;
662 DWORD simplecontextticker
;
663 DWORD shellmenuacceleratorsticker
;
664 DWORD unversionedasmodifiedticker
;
665 DWORD recursesubmodulesticker
;
666 DWORD showunversionedoverlayticker
;
667 DWORD showignoredoverlayticker
;
668 DWORD excludedasnormalticker
;
669 DWORD hidemenusforunversioneditemsticker
;
670 UINT drivetypecache
[27];
671 TCHAR drivetypepathcache
[MAX_PATH
]; // MAX_PATH ok.
673 TCHAR szThousandsSep
[5];
674 std::map
<stdstring
, AdminDir_s
> admindircache
;
675 stdstring sAdminDirCacheKey
;
676 CRegStdString nocontextpaths
;
677 stdstring excludecontextstr
;
678 std::vector
<stdstring
> excontextvector
;
679 DWORD excontextticker
;
680 DWORD admindirticker
;
681 CComCriticalSection m_critSec
;