This PR fixes the following issues with LV code generation from a .proto file:
The generated converter VIs for oneofs (i.e. FlatToRich and RichToFlat variants) were not getting saved as source only. Because of this, the VIs must be saved in the editor version rather honoring the source version specified in the project in which the VIs are being added. This then results in a mix of source versions for the generated VIs since all of the other VIs are marked as source only.
Library icons are not consistently applied to generated client VIs.
Implementation
Added new Set Source Only.vi for scripting. This is then used when creating new oneof conversion VIs from a template. I'm not certain why we don't have similar issues with creating new VIs from template using the New VI node. I suspect it might be a bug with using a .vim template rather than a .vi template.
Updated Save Library.vi so that it applies the library icon to all members before saving. This ensures newly created VIs during the generation process receive the icon as well. Without this, the members of the library were mixed in which ones displayed the icon and which ones didn't.
Updated all template VIs so that they are source only. This is the first thing I tried, but it didn't end up fixing the generated VIs not being marked as source only. Never the less, this seems like a good idea so I kept the changes.
Testing
I manually tested generation using proto files used by this repo which is where these issue were originally encountered.
Description
This PR fixes the following issues with LV code generation from a .proto file:
Implementation
Set Source Only.vi
for scripting. This is then used when creating new oneof conversion VIs from a template. I'm not certain why we don't have similar issues with creating new VIs from template using theNew VI
node. I suspect it might be a bug with using a .vim template rather than a .vi template.Save Library.vi
so that it applies the library icon to all members before saving. This ensures newly created VIs during the generation process receive the icon as well. Without this, the members of the library were mixed in which ones displayed the icon and which ones didn't.Testing
I manually tested generation using proto files used by this repo which is where these issue were originally encountered.