From 4a73a9a6f0ae5c8cf0631c658c08700b2d0bd783 Mon Sep 17 00:00:00 2001 From: ed Date: Tue, 17 Apr 2018 09:43:53 +0100 Subject: [PATCH] Projucer: When writing the VST3 category string prioritise "Fx" > "Instrument" > everything else. Added missing "Dynamics" category --- extras/Projucer/Source/Project/jucer_Project.cpp | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/extras/Projucer/Source/Project/jucer_Project.cpp b/extras/Projucer/Source/Project/jucer_Project.cpp index 13d36d7e15..c3b3dd351e 100644 --- a/extras/Projucer/Source/Project/jucer_Project.cpp +++ b/extras/Projucer/Source/Project/jucer_Project.cpp @@ -1620,6 +1620,13 @@ static String getVST3CategoryStringFromSelection (Array selected) noexcept for (auto& category : selected) categories.add (category); + // "Fx" and "Instrument" should come first and if both are present prioritise "Fx" + if (categories.contains ("Instrument")) + categories.move (categories.indexOf ("Instrument"), 0); + + if (categories.contains ("Fx")) + categories.move (categories.indexOf ("Fx"), 0); + return categories.joinIntoString ("|"); } @@ -1754,9 +1761,9 @@ Array Project::getDefaultVSTCategories() const noexcept StringArray Project::getAllVST3CategoryStrings() noexcept { - static StringArray vst3CategoryStrings { "Fx", "Instrument", "Spatial", "Analyzer", "Delay", "Distortion", "EQ", "Filter", "Generator", "Mastering", - "Modulation", "Pitch Shift", "Restoration", "Reverb", "Surround", "Tools", "Network", "Drum", "Sampler", - "Synth", "External", "OnlyRT", "OnlyOfflineProcess", "NoOfflineProcess", "Up-Downmix" }; + static StringArray vst3CategoryStrings { "Fx", "Instrument", "Analyzer", "Delay", "Distortion", "Drum", "Dynamics", "EQ", "External", "Filter", + "Generator", "Mastering", "Modulation", "Mono", "Network", "NoOfflineProcess", "OnlyOfflineProcess", "OnlyRT", + "Pitch Shift", "Restoration", "Reverb", "Sampler", "Spatial", "Stereo", "Surround", "Synth", "Tools", "Up-Downmix" }; return vst3CategoryStrings; }