1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-06-15 23:59:37 +02:00

Further work on bug 137. Accidental click OK on prev commit, so here are comments for it and this one:

* Make progress messages not have ellipsis at end, as convention in other cases.

* Reword "Continue without deleting" radio button about orphan files.

* Fix the removal of empty dirs at the end of DirManager::ProjectFSCK() which previously did nothing because it passed a hardcoded zero count for the file list, to what is now RecursivelyRemove(). Added RecursivelyCountSubdirs() so progress dialog has correct maximum (directory count, not blockCount as previously). Added RecursivelyRemoveEmptyDirs().

* Found that Windows SDK functions sometimes do not remove empty directories and added code to help it in some cases.
This commit is contained in:
v.audacity 2010-07-09 03:52:51 +00:00
parent afe904e0c5
commit cf3ba227f7

View File

@ -304,10 +304,10 @@ static int RecursivelyRemoveEmptyDirs(wxString dirPath,
// and RemoveDirectory), and they all give same results.
// I noticed dirs get deleted in RecursivelyRemove, maybe because it doesn't
// consider whether the path is a directory or a file and wxRemoveFile()'s it first.
// Tried it here, but no joy!
// #ifdef __WXMSW__
// ::wxRemoveFile(dirPath);
// #endif
// Tried it here on WinXP, but no joy. Leave the code in case it works on other Win systems.
#ifdef __WXMSW__
::wxRemoveFile(dirPath);
#endif
::wxRmdir(dirPath);
}
nCount++; // Count dirPath in progress.