mirror of
https://github.com/aharabada/glitchy-engine-beef.git
synced 2026-09-06 05:01:53 +00:00
Start of project system
+ added Directory.IsEmpty
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
namespace System.IO;
|
||||
|
||||
extension Directory
|
||||
{
|
||||
[Import("Shlwapi.lib"), CLink, CallingConvention(.Stdcall)]
|
||||
private static extern System.Windows.IntBool PathIsDirectoryEmptyW(char16* pszPath);
|
||||
|
||||
public static bool IsEmpty(StringView fileName)
|
||||
{
|
||||
// TODO: This is obviously windows only
|
||||
return PathIsDirectoryEmptyW(fileName.ToScopedNativeWChar!());
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user