added GetOSLibraryPath function.

This commit is contained in:
hyzboy 2022-03-31 18:14:43 +08:00
parent ad3fb8d380
commit 081778e12c

View File

@ -6,6 +6,20 @@ namespace hgl
{ {
namespace filesystem namespace filesystem
{ {
bool GetOSLibararyPath(OSString &result)
{
wchar_t dllfn[MAX_PATH];
UINT size;
size=::GetSystemDirectoryW(dllfn,MAX_PATH);
if(size==0)
return(false);
result.SetString(dllfn,size);
return(true);
}
bool GetLocalAppdataPath(OSString &result) bool GetLocalAppdataPath(OSString &result)
{ {
os_char fn[HGL_MAX_PATH]; os_char fn[HGL_MAX_PATH];