Small fixes

This commit is contained in:
Natsumi
2024-03-17 03:06:45 +13:00
parent 3479746c8c
commit e05bd168a7
4 changed files with 7 additions and 4 deletions

View File

@@ -157,6 +157,7 @@ namespace VRCX
/// <param name="isFolder">Whether the specified path is a folder or not. Defaults to false.</param>
public void OpenFolderAndSelectItem(string path, bool isFolder = false)
{
path = Path.GetFullPath(path);
// I don't think it's quite meant for it, but SHOpenFolderAndSelectItems can open folders by passing the folder path as the item to select, as a child to itself, somehow. So we'll check to see if 'path' is a folder as well.
if (!File.Exists(path) && !Directory.Exists(path))
return;