| 240 | } |
| 241 | |
| 242 | void SpawnListManager::SetUpPluginsDropdown() |
| 243 | { |
| 244 | std::vector<ModuleFactory::Spawnable> list; |
| 245 | |
| 246 | ModuleFactory::Spawnable scanDummy; |
| 247 | scanDummy.mLabel = kManagePluginsLabel; |
| 248 | list.push_back(scanDummy); |
| 249 | |
| 250 | std::vector<juce::PluginDescription> recentPlugins; |
| 251 | VSTLookup::GetRecentPlugins(recentPlugins, 8); |
| 252 | for (auto& pluginDesc : recentPlugins) |
| 253 | { |
| 254 | ModuleFactory::Spawnable spawnable{}; |
| 255 | spawnable.mLabel = pluginDesc.name.toStdString(); |
| 256 | spawnable.mDecorator = "[" + ModuleFactory::Spawnable::GetPluginLabel(pluginDesc) + "]"; |
| 257 | spawnable.mPluginDesc = pluginDesc; |
| 258 | spawnable.mSpawnMethod = ModuleFactory::SpawnMethod::Plugin; |
| 259 | list.push_back(spawnable); |
| 260 | } |
| 261 | |
| 262 | std::vector<juce::PluginDescription> vsts; |
| 263 | VSTLookup::GetAvailableVSTs(vsts); |
| 264 | for (auto& pluginDesc : vsts) |
| 265 | { |
| 266 | ModuleFactory::Spawnable spawnable{}; |
| 267 | spawnable.mLabel = pluginDesc.name.toStdString(); |
| 268 | spawnable.mDecorator = "[" + ModuleFactory::Spawnable::GetPluginLabel(pluginDesc) + "]"; |
| 269 | spawnable.mPluginDesc = pluginDesc; |
| 270 | spawnable.mSpawnMethod = ModuleFactory::SpawnMethod::Plugin; |
| 271 | list.push_back(spawnable); |
| 272 | } |
| 273 | |
| 274 | mPlugins.SetList(list); |
| 275 | mPlugins.GetList()->ClearSeparators(); |
| 276 | mPlugins.GetList()->AddSeparator(1); |
| 277 | if (!recentPlugins.empty()) |
| 278 | mPlugins.GetList()->AddSeparator((int)recentPlugins.size() + 1); |
| 279 | } |
| 280 | |
| 281 | void TitleBar::ListLayouts() |
| 282 | { |
no test coverage detected