本文整理汇总了C#中Filter.AddFile方法的典型用法代码示例。如果您正苦于以下问题:C# Filter.AddFile方法的具体用法?C# Filter.AddFile怎么用?C# Filter.AddFile使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Filter
的用法示例。
在下文中一共展示了Filter.AddFile方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: OutputSolution
//.........这里部分代码省略.........
confs.Add(new ProjectConfiguration("SharpDX", true, "GRAPHICS_SHARPDX", slnRelDir + "..\\SharpDX\\Bin\\DirectX11-net40"));
confs.Add(new ProjectConfiguration("SharpDX", false, "GRAPHICS_SHARPDX", slnRelDir + "..\\SharpDX\\Bin\\DirectX11-net40"));
confs.Add(new ProjectConfiguration("SharpDX Signed", true, "GRAPHICS_SHARPDX", slnRelDir + "..\\SharpDX\\Bin\\DirectX11-Signed-net40"));
confs.Add(new ProjectConfiguration("SharpDX Signed", false, "GRAPHICS_SHARPDX", slnRelDir + "..\\SharpDX\\Bin\\DirectX11-Signed-net40"));
confs.Add(new ProjectConfiguration("SlimDX", true, "GRAPHICS_SLIMDX", "$(PROGRAMFILES)\\SlimDX SDK (January 2012)\\Bin\\net40\\;$(PROGRAMFILES(x86))\\SlimDX SDK (June 2010)\\Bin\\net40\\"));
confs.Add(new ProjectConfiguration("SlimDX", false, "GRAPHICS_SLIMDX", "$(PROGRAMFILES)\\SlimDX SDK (January 2012)\\Bin\\net40\\;$(PROGRAMFILES(x86))\\SlimDX SDK (June 2010)\\Bin\\net40\\"));
}
//confs.Add(new ProjectConfiguration("SlimMath", true, "GRAPHICS_SLIMMATH", slnRelDir + "..\\SlimMath\\SlimMath\\bin\\Release"));
//confs.Add(new ProjectConfiguration("SlimMath", false, "GRAPHICS_SLIMMATH", slnRelDir + "..\\SlimMath\\SlimMath\\bin\\Debug"));
if (targetVS != TargetVS.VS2008)
{
confs.Add(new ProjectConfiguration("Windows API Code Pack", true, "GRAPHICS_WAPICODEPACK", slnRelDir + "..\\Windows API Code Pack 1.1\\binaries\\DirectX"));
confs.Add(new ProjectConfiguration("Windows API Code Pack", false, "GRAPHICS_WAPICODEPACK", slnRelDir + "..\\Windows API Code Pack 1.1\\binaries\\DirectX"));
}
/*
confs.Add(new ProjectConfiguration("XNA 3.1", true, "GRAPHICS_XNA31", "$(ProgramFiles)\\Microsoft XNA\\XNA Game Studio\\v3.1\\References\\Windows\\x86\\;$(ProgramFiles(x86))\\Microsoft XNA\\XNA Game Studio\\v3.1\\References\\Windows\\x86\\"));
confs.Add(new ProjectConfiguration("XNA 3.1", false, "GRAPHICS_XNA31", "$(ProgramFiles)\\Microsoft XNA\\XNA Game Studio\\v3.1\\References\\Windows\\x86\\;$(ProgramFiles(x86))\\Microsoft XNA\\XNA Game Studio\\v3.1\\References\\Windows\\x86\\"));
if (targetVS != TargetVS.VS2008)
{
confs.Add(new ProjectConfiguration("XNA 4.0", true, "GRAPHICS_XNA40", "$(ProgramFiles)\\Microsoft XNA\\XNA Game Studio\\v4.0\\References\\Windows\\x86\\;$(ProgramFiles(x86))\\Microsoft XNA\\XNA Game Studio\\v4.0\\References\\Windows\\x86\\"));
confs.Add(new ProjectConfiguration("XNA 4.0", false, "GRAPHICS_XNA40", "$(ProgramFiles)\\Microsoft XNA\\XNA Game Studio\\v4.0\\References\\Windows\\x86\\;$(ProgramFiles(x86))\\Microsoft XNA\\XNA Game Studio\\v4.0\\References\\Windows\\x86\\"));
}
*/
var project = parser.Project;
var filterWriter = new FilterWriter(project.NamespaceName);
var sourceFilter = new Filter("Source Files", "4FC737F1-C7A5-4376-A066-2A32D752A2FF", "cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx");
var headerFilter = new Filter("Header Files", "93995380-89BD-4b04-88EB-625FBE52EBFB", "h;hh;hpp;hxx;hm;inl;inc;xsd");
var resourceFilter = new Filter("Resource Files", "67DA6AB6-F800-4c08-8B7A-83BB121AAD01", "rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms");
filterWriter.RootFilter.Add(sourceFilter);
filterWriter.RootFilter.Add(headerFilter);
filterWriter.RootFilter.Add(resourceFilter);
sourceFilter.AddFile("", rootFolder + "Stdafx");
sourceFilter.AddFile("", rootFolder + "AssemblyInfo");
sourceFilter.AddFile("", rootFolder + "Collections");
sourceFilter.AddFile("", rootFolder + "Math");
sourceFilter.AddFile("", rootFolder + "StringConv");
sourceFilter.AddFile("", rootFolder + "DataStream");
sourceFilter.AddFile("", rootFolder + "Matrix");
sourceFilter.AddFile("", rootFolder + "Quaternion");
sourceFilter.AddFile("", rootFolder + "Utilities");
sourceFilter.AddFile("", rootFolder + "Vector3");
sourceFilter.AddFile("", rootFolder + "Vector4");
headerFilter.AddFile("", rootFolder + "Stdafx");
headerFilter.AddFile("", rootFolder + "Collections");
headerFilter.AddFile("", rootFolder + "Enums");
headerFilter.AddFile("", rootFolder + "ITrackingDisposable");
headerFilter.AddFile("", rootFolder + "Math");
headerFilter.AddFile("", rootFolder + "StringConv");
headerFilter.AddFile("", rootFolder + "Version");
headerFilter.AddFile("", rootFolder + "DataStream");
headerFilter.AddFile("", rootFolder + "Matrix");
headerFilter.AddFile("", rootFolder + "Quaternion");
headerFilter.AddFile("", rootFolder + "Utilities");
headerFilter.AddFile("", rootFolder + "Vector3");
headerFilter.AddFile("", rootFolder + "Vector4");
foreach (ManagedHeader header in parser.Headers.Values)
{
if (header.Classes.Count == 0) continue;
sourceFilter.AddFile(header.Native.Filename, rootFolder + header.Name);
headerFilter.AddFile(header.Native.Filename, rootFolder + header.Name);
}