static
| 745 | |
| 746 | //static |
| 747 | void ModuleFactory::GetPrefabs(std::vector<ModuleFactory::Spawnable>& prefabs) |
| 748 | { |
| 749 | using namespace juce; |
| 750 | File dir(ofToDataPath("prefabs")); |
| 751 | Array<File> files; |
| 752 | dir.findChildFiles(files, File::findFiles, false); |
| 753 | for (auto file : files) |
| 754 | { |
| 755 | if (file.getFileExtension() == ".pfb") |
| 756 | { |
| 757 | ModuleFactory::Spawnable spawnable; |
| 758 | spawnable.mLabel = file.getFileName().toStdString(); |
| 759 | spawnable.mDecorator = kPrefabSuffix; |
| 760 | spawnable.mSpawnMethod = SpawnMethod::Prefab; |
| 761 | prefabs.push_back(spawnable); |
| 762 | } |
| 763 | } |
| 764 | } |
| 765 | |
| 766 | //static |
| 767 | void ModuleFactory::GetPresets(std::vector<ModuleFactory::Spawnable>& presets) |
nothing calls this directly
no test coverage detected