mirror of
https://github.com/Kitware/CMake.git
synced 2026-02-22 06:59:01 -06:00
VS10: Simplify vcxproj.filter file generation
Remove the duplicate source file classification logic used to generate the filter files. Instead record during the main vcxproj file generation the source files generated for each tool. Also record whether or not each source file is converted to a relative path. Use the recorded result during filter generation to ensure consistency between the project file and filter file.
This commit is contained in:
@@ -43,6 +43,13 @@ public:
|
||||
);
|
||||
|
||||
private:
|
||||
struct ToolSource
|
||||
{
|
||||
cmSourceFile* SourceFile;
|
||||
bool RelativePath;
|
||||
};
|
||||
struct ToolSources: public std::vector<ToolSource> {};
|
||||
|
||||
void ConvertToWindowsSlash(std::string& s);
|
||||
void WriteString(const char* line, int indentLevel);
|
||||
void WriteProjectConfigurations();
|
||||
@@ -77,8 +84,7 @@ private:
|
||||
void WriteEvents(std::string const& configName);
|
||||
void WriteEvent(const char* name, std::vector<cmCustomCommand> & commands,
|
||||
std::string const& configName);
|
||||
void WriteGroupSources(const char* name,
|
||||
std::vector<cmSourceFile*> const& sources,
|
||||
void WriteGroupSources(const char* name, ToolSources const& sources,
|
||||
std::vector<cmSourceGroup>& );
|
||||
void AddMissingSourceGroups(std::set<cmSourceGroup*>& groupsUsed,
|
||||
const std::vector<cmSourceGroup>& allGroups);
|
||||
@@ -99,6 +105,9 @@ private:
|
||||
cmGeneratedFileStream* BuildFileStream;
|
||||
cmLocalVisualStudio7Generator* LocalGenerator;
|
||||
std::set<cmSourceFile*> SourcesVisited;
|
||||
|
||||
typedef std::map<cmStdString, ToolSources> ToolSourceMap;
|
||||
ToolSourceMap Tools;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user