Disable expanding file contents in Visual Studio 2012 Solution Explorer
In Visual Studio 2012, the files in Solution Explorer are expandable, allowing the user to navigate to the symbols they contain:
While this can be convenient, I personally never use the Solution Explorer to navigate the code symbols: I prefer using Resharper Go To Type/Symbol and the File Structure Window, or Visual Studio Navigate To and VS Code Map. When using the Solution Explorer, I usually want to rename, delete or create a new file. Having expandable files makes the folders and projects harder to distinguish, so I searched for a way to disable this feature.
After Googling to no avail, I finally found an hidden setting that can be set in the registry.
Go to HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\11.0 and add a new dword value named UseSolutionNavigatorGraphProvider with a value of 0. Restart Visual Studio and enjoy your old-school Solution Explorer:
You can also directly apply this registry file: VS2012NoFileExpand