Commit d8fa2d83 authored by Jacek Sowiński's avatar Jacek Sowiński

Properly unmark items when resetting state

After introducing cache for TodoWidget objects, widgets highlighted with
'mark' action were not unmarked after 'reset' action and they reappeared
highlighted ("marked") after reverting `do` or `delete` commands.
parent 0774ad55
...@@ -301,6 +301,8 @@ class UIApplication(CLIApplicationBase): ...@@ -301,6 +301,8 @@ class UIApplication(CLIApplicationBase):
self._output if verbosity else lambda _: None) self._output if verbosity else lambda _: None)
def _reset_state(self): def _reset_state(self):
for widget in TodoWidget.cache.values():
widget.unmark()
self.marked_todos = [] self.marked_todos = []
self._update_all_columns() self._update_all_columns()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment