Add "Import" button to the Midi Preferences dialog

Bug #723028 reported by jus
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mixxx
Confirmed
Wishlist
Unassigned

Bug Description

Wishlist: While we have an "Export" buttons to save modified Midi Bindings we do not have an "Import" button.

This Import button should
* allow multiple file selection (for *.js. and *.xml)
* put the imported files in the appropriate place depending on OS

This would simplify the use of new/changed community supported mappings , avoid messing with the filesystem and reduce support requests.

RJ Skerry-Ryan (rryan)
Changed in mixxx:
status: New → Confirmed
tags: added: midi usability
RJ Skerry-Ryan (rryan)
Changed in mixxx:
importance: Undecided → Wishlist
Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

This should be pretty easy. I would say we should just let you specify the XML and then parse the XML to figure out what JS files it needs and copy those too.

tags: added: polish
tags: added: easy
RJ Skerry-Ryan (rryan)
tags: added: controllers
Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

Jus, what do you think about just selecting the XML and then reading the scripts needed from that XML and automatically copying them over?

Changed in mixxx:
assignee: nobody → RJ Ryan (rryan)
Revision history for this message
jus (jus) wrote :

Thanks for working on it.
I`m for anything that simplifies the process of adding downloaded controller presets. Your idea sounds good.

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.

Just a thought: Maybe add some kind of suffix so that one can differentiate if a presets was copied over or build-in.

Revision history for this message
Sean M. Pappalardo (pegasus-renegadetech) wrote :

If someone else beats me to implementing this, I think the order should be:
1) Ask for XML file
2) Parse XML, look for the JS files in the same directory.
3) If not found, look in the Mixxx /controllers directory tree.
4) If still not found, ask the user for the file location.

The only problem I can see with this is step 3: if the JS in the Mixxx directory doesn't correspond to what the XML file expects, weird stuff could happen. So should this step be omitted to avoid such problems since 99% of the time the JS will be in the same directory as the XML? (And if it isn't, the user most likely forgot to download it as well.) The only exception is if the XML references a common script file that is shipped with Mixxx. (Maybe we should start versioning those.)

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.

Revision history for this message
Daniel Schürmann (daschuer) wrote :

Sounds good. What about supporting zip files in the controllers folder? This will help keeping the xml and js file together.

RJ Skerry-Ryan (rryan)
Changed in mixxx:
assignee: RJ Ryan (rryan) → nobody
Revision history for this message
ronso0 (ronso0) wrote :

setting to Won't Fix because of the new controller system about to be designed.
https://mixxx.zulipchat.com/#narrow/stream/113295-controller-mapping/topic/C.2B.2B.20controller.20system.20refactoring

Changed in mixxx:
status: Confirmed → Won't Fix
Revision history for this message
Be (be.ing) wrote :

I think this would be a nice feature to add to the new system.

Changed in mixxx:
status: Won't Fix → Confirmed
Revision history for this message
Swiftb0y (swiftb0y) wrote :

Mixxx now uses GitHub for bug tracking. This bug has been migrated to:
https://github.com/mixxxdj/mixxx/issues/5785

lock status: Metadata changes locked and limited to project staff
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.