开发者

If Visual Studio 2010 based on WPF, why I cannot open it with reflector?

开发者 https://www.devze.com 2022-12-27 19:27 出处:网络
If Visual Studio 2010 based on WPF, why I cannot open it with reflector? In other words, devenv.exe se开发者_运维技巧ems to be native assembly, so where is the WPF UI code?The Visual Studio devenv.ex

If Visual Studio 2010 based on WPF, why I cannot open it with reflector?

In other words, devenv.exe se开发者_运维技巧ems to be native assembly, so where is the WPF UI code?


The Visual Studio devenv.exe executable is indeed a native program. However, native programs can load the .NET runtime and thereby host Windows Forms and WPF components. In fact, Visual Studio has always done this. Even before VS2010 adopted WPF for its editor and shell, the various Visual Studio designers were implemented in Windows Forms. If you go into the Common7\IDE and Common7\IDE\PrivateAssemblies directories, you'll find lots of designer DLLs that you can view in Reflector (e.g. Microsoft.VisualStudio.ORDesigner.Dsl.dll is the LINQ to SQL designer).

So the new WPF bits of Visual Studio are just another set of managed assemblies hosted in the native executable. I'm not sure which particular assemblies host the WPF bits -- and to be honest there are probably dozens. But looking at the VS process in the debugger, I'd say Microsoft.VisualStudio.Editor.dll (which lives in the GAC, not in the VS install directory) would be a good place to start.

0

精彩评论

暂无评论...
验证码 换一张
取 消