Re: [Audacity-devel] Central Audacity additional files storage
A free multi-track audio editor and recorder
Brought to you by:
aosiniao
From: James.Crook <cr...@in...> - 2006-07-11 14:46:17
|
Markus, Your new function PlatformCompatibility::GetUserDataDir() is duplicating a function that already exists in our class FileNames, wxString FileNames::DataDir(). I've no problem with you having FileNames::DataDir call GetUserDataDir, if you think that's better structure. Please also compare the two versions. There is a slight difference, and I suspect Leland's version gets it right for wxMac too. Also do look at the general approach taken in Filenames.cpp and see what you think. You may not have seen this file before because it is relatively new. Do you think filenames like "EQCurves.xml" should be handled in the code in the same way as Filenames.cpp does for files like "ImageCache.htm"? This is not meant as a criticism at all. I think it's quite clear that getting the directories/files better organised is an idea who's time has come. It is also coming in from Jeroen's discussion of export/import-handlers. I'd like in time to have registration of file extensions and of file-data-types in Filenames.cpp, or at any rate in a class of similar kind. --James. Markus Meyer wrote: > Hi, > > there used to be confusion about where Audacity stored additional > settings that were not suitable for storage in the standard preferences > file / registry. Some pieces (like the CleanSpeech code and FTP code) > used the current directory for them, which generally is a bad idea > (e.g., there might be insufficient permissions to access the current > directory). I changed those occurences to use the > .audacity-data-Directory in the user's home directory like the > Equalization dialog already does for the EQ curves. CleanSpeech will > still find its old CleanSpeech presets because the location of the > preset directory, once created, is stored in the preferences. > > For new code, please use the function > PlatformCompatibility::GetUserDataDir(). This will return a path where > you can write additional per-user data files into. Please also use > wxFileName for new code, to automate generation of slashes vs. > backslashes in filenames. > > > Markus |