On Saturday 24 April 2010, Thorsten Alteholz wrote: > In case of a missing audio file QFileDialog::getExistingDirectory() will > be called to get a new path to this audio file. The starting directory of > this dialog is always /home. Wouldn't it be better to start in the current > audioPath (if you sort your stuff, you wouldn't move it far away, would > you) or at least start in $HOME?
If the current audio path is /home/joebob/Documents/rosegarden or something like that and the audio for an older file the user hasn't worked with in years is sitting in /home/joebob/rosegarden, then starting at the audio path would never find the files. (I'm thinking of how newer distros are wanting to keep dumping everything in ~/Documents instead of ~ here, though this is a made up scenario.) Starting at /home seems a little odd, since most users don't typically have personal files stored in locations under /home outside of their own personal directory. Depending on how the system is set up, if users can see into each other's directories (the default on most Linux distros these days) then the search could take forever on a multi-user system. I suggest using $HOME, or better yet, QDesktopServices. Code snippet: QString home = QUrl::fromLocalFile(QDesktopServices::storageLocation(QDesktopServices::HomeLocation)).path(); -- D. Michael McIntyre ------------------------------------------------------------------------------ _______________________________________________ Rosegarden-devel mailing list [email protected] - use the link below to unsubscribe https://lists.sourceforge.net/lists/listinfo/rosegarden-devel
