Merge 'upstream/develop' into new-plugin-system

This commit is contained in:
David Pierron
2020-10-20 22:10:08 +02:00
47 changed files with 783 additions and 415 deletions

View File

@@ -45,4 +45,15 @@ class Settings:
plugin.setSettings(self)
# Cheating
self.show_red_ato = False
def __setstate__(self, state) -> None:
# __setstate__ is called with the dict of the object being unpickled. We
# can provide save compatibility for new settings options (which
# normally would not be present in the unpickled object) by creating a
# new settings object, updating it with the unpickled state, and
# updating our dict with that.
new_state = Settings().__dict__
new_state.update(state)
self.__dict__.update(new_state)