Fixed a formerly unnoticed crash bug. If user selected a subset of the dependency files list, then clicked "Copy Selected Audio Into Project", it removed the selected dependency/dependencies, but then crashed on bad reference trying to delete the non-selected dependency/dependencies. This was due to a consistent misuse of wxHashMap::operator[] to check for the existence of a hash element. If you call it with a key that's not in the hash map, yes it returns NULL, the first time, but it creates an entry for that key. So if you test it again with the same key it returns a bad entry. Replaced it with a correct call to wxHashMap::count(). Leland had fixed one of these, but there were 4 more.
RemoveDependencies() always returned true, and was never checked, so made it return nothing.
More readability improvements.
Update header block.
Move declarations that aren't used elsewhere, from .h file. No need to expose them there, used only in this file.
Working on first part of bug 113 where moved/deleted file is allowed to be copied into project:
* Made class AliasedFile know whether its original file exists in specified location.
* Dependency dialog:
** Updated so message states some original files were moved/deleted, and what to do about it.
** Missing dependencies shown in red, italic text.
** Missing dependencies cannot be selected for copying into project.
* Fixed bug where deselecting all items did not disable "Copy Selected..." button.
FindDependencies always returns true, so removed return value and its handling.
Sundry readability improvements: var names, {} brackets usage consistency, indenting, clearer names, etc.
Get rid of vim/emacs declarations. Matt said they're unnecessary, ages ago.
Update header block.
Move declarations that aren't used elsewhere, into cpp file. No need to expose them here.
Get rid of vim/emacs declarations. Matt said they're unnecessary, ages ago.
* 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.
(still in progress, per "//vvvvv" comments):
Update credits and copyright.
Fix some grammar and remove obvious comments.
(For example, stack vars are always destroyed when
"out of context" (i.e, scope, when stack popped),
so no need to comment on it).
Remove wxWidgets error squelching.
"rm_dash_rf*" static functions
Rename all the "rm_dash_rf*" static functions to better
reflect what they actually do (per "finally
misnomer" comment). Not very mnemonic to
name functions on *nix-specific shell command
"rm- rf" that they do not emulate. Only 1 of the 4
so-named actually removed anything.
Remove one unnecessary function (originally
"rm_dash_rf_enumerate"), replaced by
parameter defaults on main recursive function
(originally rm_dash_rf_enumerate_i").
Remove unused parameter "prompt" from
rm_dash_rf_enumerate_i (now RecursivelyEnumerate).
The files_p and dirs_p ints were actually used only
as bools, so make them bools bFiles and bDirs.
Rename "prompt" vars to match ProgressDialog
"message" arg. They do not prompt user to do
anything, they're informational.
files_p and dirs_p were int but used only as bools,
so make them bool for better readability.
Also some minor refactoring.
This feature works with mp3 right now - may work on other formats, but that will be a seperate commit.
It is not enabled so most of the changes won't even be compiled, and those that do won't be run.
To enable it uncommment the EXPERIMENTAL_ODFFMPEG def in Experimental.h
Remove double-click to rename, for keyboard users.
Added 'Names' to controls in the hope that screen readers will be helped.
Resizing works better.
Various tidy-up, inc. adding a few comments!