mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-11 23:54:18 +00:00
Projucer: Source code files for browsing are now added to the individual VS projects instead of the VS solution
This commit is contained in:
parent
f8d1b70159
commit
14d7675c48
2 changed files with 173 additions and 103 deletions
|
|
@ -563,20 +563,22 @@ void LibraryModule::addBrowseableCode (ProjectExporter& exporter, const Array<Fi
|
|||
|
||||
const RelativePath moduleFromProject (exporter.getModuleFolderRelativeToProject (getID()));
|
||||
|
||||
auto moduleHeader = moduleInfo.getHeader();
|
||||
|
||||
for (auto& sourceFile : sourceFiles)
|
||||
{
|
||||
auto pathWithinModule = FileHelpers::getRelativePathFrom (sourceFile, localModuleFolder);
|
||||
|
||||
// (Note: in exporters like MSVC we have to avoid adding the same file twice, even if one of those instances
|
||||
// is flagged as being excluded from the build, because this overrides the other and it fails to compile)
|
||||
if (exporter.canCopeWithDuplicateFiles() || ! compiled.contains (sourceFile))
|
||||
if ((exporter.canCopeWithDuplicateFiles() || ! compiled.contains (sourceFile)) && sourceFile != moduleHeader)
|
||||
addFileWithGroups (sourceGroup,
|
||||
moduleFromProject.getChildFile (pathWithinModule),
|
||||
pathWithinModule);
|
||||
}
|
||||
|
||||
sourceGroup.sortAlphabetically (true, true);
|
||||
sourceGroup.addFileAtIndex (moduleInfo.getHeader(), -1, false);
|
||||
sourceGroup.addFileAtIndex (moduleHeader, -1, false);
|
||||
|
||||
exporter.getModulesGroup().state.addChild (sourceGroup.state.createCopy(), -1, nullptr);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue