Template Var in ViewModel & Settings Save in ViewModel


I've been working away at a plugin. To make two additional features work I need to bind a custom viewModel to the settings pane. However, when I do so I run into those issues:

  1. I have template vars defined in __init__.py (using get_template_vars). I loose access to those when activating the custom ViewModel. I cannot see a way to get them into the ViewModel. Am I missing something, or is there none? If not, how can I get calculated values from __init__.py into my ViewModel?

  2. When I activate my custom ViewModel I can no longer save my plugins setting pane. Other settings save just fine, just not the ones inside my ViewModel. Is that supposed to be, and if so, is there an example on how to save using my own method?



Seeing your code would help to understand what you mean and see how you are doing your bindings.