diff options
author | George Hazan <ghazan@miranda.im> | 2020-09-08 13:21:50 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2020-09-08 13:21:50 +0300 |
commit | 5d0dff54982b174d382aca8da00393273bc7b3e5 (patch) | |
tree | b18df845cd408a8f4d32fe02e9e65109e01c58c0 /plugins/PackUpdater/Src/Events.cpp | |
parent | 7997d0ec5810ad7699d0de6417510ab756be320d (diff) |
DeleteDirectoryTreeW - new function that deletes a folder with all subfolders (recursively)
Diffstat (limited to 'plugins/PackUpdater/Src/Events.cpp')
-rw-r--r-- | plugins/PackUpdater/Src/Events.cpp | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/plugins/PackUpdater/Src/Events.cpp b/plugins/PackUpdater/Src/Events.cpp index 3745f37732..0a59c5b14a 100644 --- a/plugins/PackUpdater/Src/Events.cpp +++ b/plugins/PackUpdater/Src/Events.cpp @@ -51,21 +51,9 @@ INT_PTR MenuCommand(WPARAM, LPARAM) return 0;
}
-INT_PTR EmptyFolder(WPARAM, LPARAM lParam)
+INT_PTR EmptyFolder(WPARAM, LPARAM)
{
- SHFILEOPSTRUCT file_op = {
- nullptr,
- FO_DELETE,
- tszRoot,
- L"",
- FOF_NOERRORUI |
- FOF_SILENT,
- false,
- nullptr,
- L"" };
- if (lParam)
- file_op.fFlags |= FOF_NOCONFIRMATION;
- SHFileOperation(&file_op);
+ DeleteDirectoryTreeW(tszRoot);
return 0;
}
|