add special code to migrate tabs.persist_mode_on_change setting to tabs.mode_on_change.

This commit is contained in:
Marc Jauvin 2018-02-09 11:28:21 -05:00
parent a3ce03e0bd
commit 85dfe5c403

View File

@ -180,6 +180,14 @@ class YamlConfig(QObject):
log.config.debug("Removing {}".format(name))
del self._values[name]
persist = 'tabs.persist_mode_on_change'
if persist in self._values:
if self._values[persist]:
self._values['tabs.mode_on_change'] = 'persist'
else:
self._values['tabs.mode_on_change'] = 'normal'
del self._values[persist]
def _validate(self):
"""Make sure all settings exist."""
unknown = set(self._values) - set(configdata.DATA)