using Visual Studio 2017 I noticed today that when Visual Studio reloads the cmake-generated project (because cmake was rerun when building one of the targets), it closes the open files which are not part of the project.
Is this normal ? Can I do something against this ?
This is especially annoying when editing some of the used cmake files, those which did not end up in the generated project (even though they are include()ed, see my other post).
The other set of files are the .h files, which I did not add as sources to the targets. Now they are closed when the project is reloaded. Should I add them for this purpose to the project ?
I have only that version available.
I just reproduced it again.
When reloading a project, sometimes non-project files stay open, sometimes they are closed. That’s a bit annoying when editing one of the include()d cmakefiles, so the project will be reloaded, and then this file is closed.
I haven’t found out yet what the exact conditions are.
It seems the non-project files stay open if I edit one of the CMakeLists.txt, and they are closed when I edit one of the include()d cmake files.
I’ll try with a small example project tomorrow.
Haven’t tried with another project yet, but, if I add the included cmake file to the sources of a target, it stays open when the project is reloaded, if I remove it again from the list of source files, it is closed.