don't check for SHGetSpecialFolderPathA in shfolder.dll (cause it won't be there) and load the 'ansi' proc name from shell32.dll, bug 204246, r+sr=dougt, a=asa

This commit is contained in:
jrgm%netscape.com 2003-05-08 20:41:20 +00:00
Родитель 1df4c907ed
Коммит cf01c9d921
3 изменённых файлов: 9 добавлений и 48 удалений

Просмотреть файл

@ -110,26 +110,13 @@ NS_COM void StartupSpecialSystemDirectory()
startup. Replacing these older calls with a single call to SHGetSpecialFolderPath
effectively removes these calls from the performace radar. We need to
support the older way of file location lookup on systems that do not have
IE4.
IE4. (Note: gets the ansi version: SHGetSpecialFolderPathA).
*/
gShell32DLLInst = LoadLibrary("shfolder.dll");
gShell32DLLInst = LoadLibrary("Shell32.dll");
if(gShell32DLLInst)
{
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
"SHGetSpecialFolderPath");
}
if (!gGetSpecialPathProc)
{
if (gShell32DLLInst)
FreeLibrary(gShell32DLLInst);
gShell32DLLInst = LoadLibrary("Shell32.dll");
if(gShell32DLLInst)
{
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
"SHGetSpecialFolderPath");
}
"SHGetSpecialFolderPathA");
}
#endif
}

Просмотреть файл

@ -133,26 +133,13 @@ NS_COM void StartupSpecialSystemDirectory()
startup. Replacing these older calls with a single call to SHGetSpecialFolderPath
effectively removes these calls from the performace radar. We need to
support the older way of file location lookup on systems that do not have
IE4.
IE4. (Note: gets the ansi version: SHGetSpecialFolderPathA).
*/
gShell32DLLInst = LoadLibrary("shfolder.dll");
gShell32DLLInst = LoadLibrary("Shell32.dll");
if(gShell32DLLInst)
{
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
"SHGetSpecialFolderPath");
}
if (!gGetSpecialPathProc)
{
if (gShell32DLLInst)
FreeLibrary(gShell32DLLInst);
gShell32DLLInst = LoadLibrary("Shell32.dll");
if(gShell32DLLInst)
{
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
"SHGetSpecialFolderPath");
}
"SHGetSpecialFolderPathA");
}
#endif
}

Просмотреть файл

@ -133,26 +133,13 @@ NS_COM void StartupSpecialSystemDirectory()
startup. Replacing these older calls with a single call to SHGetSpecialFolderPath
effectively removes these calls from the performace radar. We need to
support the older way of file location lookup on systems that do not have
IE4.
IE4. (Note: gets the ansi version: SHGetSpecialFolderPathA).
*/
gShell32DLLInst = LoadLibrary("shfolder.dll");
gShell32DLLInst = LoadLibrary("Shell32.dll");
if(gShell32DLLInst)
{
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
"SHGetSpecialFolderPath");
}
if (!gGetSpecialPathProc)
{
if (gShell32DLLInst)
FreeLibrary(gShell32DLLInst);
gShell32DLLInst = LoadLibrary("Shell32.dll");
if(gShell32DLLInst)
{
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
"SHGetSpecialFolderPath");
}
"SHGetSpecialFolderPathA");
}
#endif
}