如何将自定义“项目项节点”添加到Visual Studio Flavored Project

时间:2023-01-16 15:52:45

I have written a simple flavoured project for Visual Studio 2008, and I want to add a custom 'folder' item to the solution explorer, similar to the 'references' folder. This folder will contain more 'custom' nodes, which dont actually represent files, but in-memory objects. How do I hook into what is displayed in the solution explorer? I cant seem to find any simple code examples.

我为Visual Studio 2008编写了一个简单的项目,我想在解决方案资源管理器中添加一个自定义的'文件夹'项,类似于'references'文件夹。此文件夹将包含更多“自定义”节点,这些节点实际上不代表文件,而是内存中的对象。如何挂钩解决方案资源管理器中显示的内容?我似乎无法找到任何简单的代码示例。

Thanks

1 个解决方案

#1


You should edit your .vcproj file. Google Mock does this to have a fake "Public header files" and a "Private header files" filter.

您应该编辑.vcproj文件。谷歌模拟这样做有一个假的“公共头文件”和一个“私人头文件”过滤器。

http://code.google.com/p/googlemock/source/browse/trunk/msvc/gmock.vcproj#199

#1


You should edit your .vcproj file. Google Mock does this to have a fake "Public header files" and a "Private header files" filter.

您应该编辑.vcproj文件。谷歌模拟这样做有一个假的“公共头文件”和一个“私人头文件”过滤器。

http://code.google.com/p/googlemock/source/browse/trunk/msvc/gmock.vcproj#199