mirror of
https://mirror.ghproxy.com/https://github.com/dexyfex/CodeWalker
synced 2024-08-20 00:49:25 +08:00
Fix for RPF Explorer crash when previously opened folder was deleted
This commit is contained in:
parent
66b1d619fe
commit
2b8ac5bb65
@ -686,11 +686,26 @@ namespace CodeWalker
|
|||||||
RefreshMainTreeViewRoot(root);
|
RefreshMainTreeViewRoot(root);
|
||||||
|
|
||||||
|
|
||||||
|
var remFolders = new List<MainTreeFolder>();
|
||||||
|
|
||||||
foreach (var extraroot in ExtraRootFolders)
|
foreach (var extraroot in ExtraRootFolders)
|
||||||
{
|
{
|
||||||
extraroot.Clear();
|
extraroot.Clear();
|
||||||
|
|
||||||
|
if (Directory.Exists(extraroot.FullPath))
|
||||||
|
{
|
||||||
RefreshMainTreeViewRoot(extraroot);
|
RefreshMainTreeViewRoot(extraroot);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
remFolders.Add(extraroot);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach (var remFolder in remFolders)
|
||||||
|
{
|
||||||
|
ExtraRootFolders.Remove(remFolder);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
Ready = true;
|
Ready = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user