PR: A fix for the two most annoying issues in the ProJucer

I mainly work on macOS, but every time I go to my Windows machine there are two things that drive me insane.

  1. If you click “Save and Open in IDE” button and you have multiple version of Visual Studio installed, often the incorrect VS version will launch.
  2. If you already have the solution open in VS and then you go back to ProJucer and make a few changes and press “Save and Open in IDE” again, it launches a second copy of VS with solution, unlike on macOS where it just resaves the project and Xcode then reloads it.

The follow PR fixes these issues by checking if the solution is already open before launching and using vswhere.exe to find the correct version of Visual Studio. vswhere.exe is installed with VS 2017 and later.

The 3rd annoyance is that is the ProJucer drops support for your VS Exporter it just silently drops it from the project. There should be an upgrade path where it optionally upgrades it to the latest VS version. There should be an upgrade path for exporters on old VS versions as well. I don’t have a fix for this, but I probably will the next time I need to upgrade the VS version of the plugin pack I work on.

8 Likes

Thank you!

I agree this is annoying but you know you can just save the project (ctrl + p?) and it should reload?

The Projucer will just use whatever default app is configured on the OS when launching a project. To make it use the VS version selector automatically, without making any changes to the program, just right-click on a .sln file, choose “open with” → “choose another app”, then select “Visual Studio Version Selector” and click the “Always” button.