如果Visual Studio 2010基于WPF,为什么我无法用反射器打开它?

发布于 2024-08-29 19:06:40 字数 97 浏览 3 评论 0原文

如果Visual Studio 2010基于WPF,为什么我无法用反射器打开它?

换句话说,devenv.exe 似乎是本机程序集,那么 WPF UI 代码在哪里?

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

In other words, devenv.exe seems to be native assembly, so where is the WPF UI code?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

2024-09-05 19:06:40

Visual Studio devenv.exe 可执行文件确实是一个本机程序。但是,本机程序可以加载 .NET 运行时,从而托管 Windows 窗体和 WPF 组件。事实上,Visual Studio 一直都是这么做的。甚至在 VS2010 采用 WPF 作为其编辑器和 shell 之前,各种 Visual Studio 设计器都是在 Windows 窗体中实现的。如果您进入 Common7\IDECommon7\IDE\PrivateAssemblies 目录,您会发现许多可以在 Reflector 中查看的设计器 DLL(例如 Microsoft .VisualStudio.ORDesigner.Dsl.dll 是 LINQ to SQL 设计器)。

因此,Visual Studio 的新 WPF 位只是本机可执行文件中托管的另一组托管程序集。我不确定哪些特定程序集托管 WPF 位 - 老实说可能有几十个。但是查看调试器中的 VS 进程,我会说 Microsoft.VisualStudio.Editor.dll(位于 GAC 中,而不是 VS 安装目录中)将是一个不错的起点。

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.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文