Turn off Visual Studio popups
Asked Answered
O

3

6

I have a large project that I have to load and work on. Nothing I can do about it - just load the solution and all projects within it.

Problem is that first several minutes VS loads project one by one and it constantly inform me about it by constantly displaying some "Loading project is required..." window. Sure, I know it is required, but cannot it be somehow done in the background? I would be content if I could just open some text editor and tune configs or read documentation without popups stealing the focus.

It happens on all project regeneration (we use GYP) - since VS solution and projects are generated each time I have to work on new C++ defines/flags/dependencies settings I have to sit and watch VS spamming those little windows.

It has another drawback - if right after project regeneration I'll try to build it VS will "block" - it will complain that it cannot close the project when build is running and I have to terminate the build in order to "close" the project. I understand that what it really does is close and reopen it in order to update settings... but popup that locks whole IDE certainly makes it more annoying.

I know that I can disable automatic reload of source file when it was edited outside by e.g. Sublime Text. Are there some solutions that would allow me to do the same for projects? Some settings, plugins or register entries that would prevent those windows from spamming or which would reload project when it suits me? It's really annoying when I have to switch to ST each time I regenerate and build projects because Visual Studio will stay locked until the build is finished.

Ossetia answered 21/1, 2015 at 11:20 Comment(4)
You're talking about generation - are you using CMake?Cottrill
Unfortunately it's GYP. I wish it was CMake since CMake is supported by JetBrains' CLion. GYP generates ninja and VS solution at the same time. For some reason recently running ninja from command line stopped working for me and I can only build it from VS, thus blocked IDE issue became much more disturbing than ever before.Ossetia
Still, you should definitely edit the question to add that info in. gyp even has a tag, add it.Cottrill
You're right, I've added that information to the question.Ossetia
C
5

I have a similar issue with CMake-generated Visual Studio solutions. While I don't have a solution, I've found a workaround which works just fine for me - close the solution before re-running the generator, and open it again when the re-run's finished. Under normal keymappings, it's Alt+FT to close, and Alt+FJ1 to open again.

Cottrill answered 21/1, 2015 at 12:15 Comment(5)
I was advised to do this and I will do that as a last resort solution. Problem with that approach is that those popups will appear again, just not right when I rebuild project but when I'll try to load back solution.Ossetia
@maddening Then maybe I misunderstand something. They don't appear for me. It just loads the solution as normal. Perhaps GYP is generating some weird dependencies there?Cottrill
I guess there are dependencies from one project to another. I've never managed to open just one project - when I tried it automatically opened all 600+ projects withing solution. And then it started to load them one after another.Ossetia
@maddening The thing is, I always open the entire solution, not just a project. So it loads them all, but silently.Cottrill
@maddening You might want to unaccept the answer, at least for a few days. That might increase the chance that somebody who actually has a solution instead of just a workaround will happen upon the question.Cottrill
J
3

Disable Intellisense, Visual Studio usually takes a great deal of time during project load parsing headers and building up its intellisense database. Disable that and see if your load times improve.

Might not be applicable if you can't change your solution, but I'd try to move less important modules/projects to DLL or prebuilt libraries. Candidates for this are 3rd party / external libraries that you don't plan on changing or potentially really stable sections of your code base.

Good luck.

Jago answered 4/2, 2015 at 6:23 Comment(0)
P
2

The VS system records the last solution associated with each project in the .SUO files. If you delete the .SUO files, you will then be able to open the project files individually, and then save a solution containing just the projects you want to open.

Photophobia answered 3/2, 2015 at 23:47 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.