Core: Win XP compatibility fix

git-svn-id: svn://ultimatepp.org/upp/trunk@10635 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2017-01-03 13:51:02 +00:00
parent cc392cf740
commit 2bd17d1612
2 changed files with 5 additions and 24 deletions

View file

@ -147,7 +147,11 @@ void DeleteWinReg(const String& key, HKEY base, dword wow) {
RegCloseKey(hkey);
while(!subkeys.IsEmpty())
DeleteWinReg(key + '\\' + subkeys.Pop(), base);
if(wow)
static LONG (WINAPI *RegDeleteKeyEx)(HKEY, LPCTSTR, REGSAM, DWORD);
DllFn(RegDeleteKeyEx, "Advapi32.dll", "RegDeleteKeyExA");
if(wow && RegDeleteKeyEx)
RegDeleteKeyEx(base, key, wow, 0);
else
RegDeleteKey(base, key);

View file

@ -92,29 +92,6 @@ void InstantSetup()
{
DirFinder df;
#if 0
Array<FileSystemInfo::FileInfo> root = StdFileSystemInfo().Find(Null);
for(int i = 0; i < root.GetCount(); i++) {
if(root[i].root_style == FileSystemInfo::ROOT_FIXED) {
int drive = *root[i].filename;
String pf = GetProgramsFolderX86();
pf.Set(0, drive);
df.Dir(pf + "/microsoft visual studio 14.0/vc/bin");
df.Dir(pf + "/windows kits/10");
df.Dir(pf + "/windows kits/8.1");
df.Dir(pf + "/windows kits");
df.Dir(pf + "/microsoft visual studio 14.0");
df.Dir(pf);
pf = GetProgramsFolder();
pf.Set(0, drive);
df.Dir(pf);
}
}
for(int i = 0; i < root.GetCount(); i++)
if(root[i].root_style == FileSystemInfo::ROOT_FIXED)
df.Dir(root[i].filename);
#endif
String default_method;
bool dirty = false;