Package list lightdm-gtk-greeter-settings / 6c76098
Config.__setitem__ logic changed Andrew P. 7 years ago
2 changed file(s) with 4 addition(s) and 4 deletion(s). Raw diff Collapse all Expand all
5353 return
5454
5555 if values and values[-1][0] == self._config._output_path:
56 if default is not None and value == default and len(values) == 1:
56 if len(values) > 1 and values[-2][1] == value:
57 del values[-1]
58 elif default is not None and value == default and len(values) == 1:
5759 values.clear()
5860 else:
5961 values[-1] = (self._config._output_path, value)
112112 for key, entry in self._entries.items():
113113 if changed and not changed(entry):
114114 continue
115 del config[self._name, key]
116 if entry.enabled:
117 config[self._name, key] = entry.value, self._get_default(key)
115 config[self._name, key] = entry.value if entry.enabled else None, self._get_default(key)
118116
119117 def _get_entry(self, key):
120118 return self._entries.get(key)