This PR adds the user application data directory to the list of paths to search for when loading JSON models as dropdown choices, with the goal of addressing #3. Specifically, the plugin will search for <userAppDataDirectory>/GuitarML/SmartPedal, based on the plugin manufacturer and plugin name set in the project .jucer.
The plugin will automatically create (and delete) a temp file in the directory if it doesn't exist yet, so that users don't have to manually create the directory -- however, users will have to reinstantiate the plugin after adding model files to the directory for those models to show up in the dropdown.
SmartPedalAudioProcessorEditor::modelSelectChanged() has also been adjusted to use selectedItemIndex instead of selectedText, in order to work with paths that aren't in the current working directory.
Potential further TODOs:
Add File::commonDocumentsDirectory as a path as well
Add a "Re-scan models" button so users don't have to restart the plugin after copying a model over
Create an installer and have that do the directory setup (instead of doing it in the plugin processor constructor)
This PR adds the user application data directory to the list of paths to search for when loading JSON models as dropdown choices, with the goal of addressing #3. Specifically, the plugin will search for
<userAppDataDirectory>/GuitarML/SmartPedal
, based on the plugin manufacturer and plugin name set in the project .jucer.The plugin will automatically create (and delete) a temp file in the directory if it doesn't exist yet, so that users don't have to manually create the directory -- however, users will have to reinstantiate the plugin after adding model files to the directory for those models to show up in the dropdown.
SmartPedalAudioProcessorEditor::modelSelectChanged()
has also been adjusted to useselectedItemIndex
instead ofselectedText
, in order to work with paths that aren't in the current working directory.Potential further TODOs:
File::commonDocumentsDirectory
as a path as well