Comment 5 for bug 723028

Revision history for this message
Be (be.ing) wrote :

> It is reasonable to expect the user to unarchive downloaded presets first, because often the compression format and/or the folder hierarchy inside the archive varies.

Not really. Most of the presets on the forum that require multiple files are in ZIP archives. If this import button is added to Mixxx and it supports a given archive format and the controller mapping documentation on the wiki is updated to reflect that, people will post mappings in that archive format. I think it should be as easy as possible for people to use mappings. While it is reasonable to expect most users to know how to extract a ZIP file, one shouldn't need to know how to extract a ZIP file to DJ and it's inconvenient for those that do.

So I think the file selection dialog should filter for XML and ZIP files. If an XML file is selected, follow the outline proposed above by Pegasus. If a ZIP file is selected:
1. Extract archive without copying any files into user's settings yet
2. Look for XML file and parse if found. If no XML file is found, show an error.
3. Look in the archive for JS files specified by the XML file. If they are not found, show an error.
4. Copy XML & JS files to user's settings directory.