Skip to content

Commit

Permalink
Correctly remember tag unselection
Browse files Browse the repository at this point in the history
The config is now updated both when a tag is selected and when
tags are unselected.

This fixes GitHub issue #1130
  • Loading branch information
gycsaba96 authored and diegogangl committed Jan 13, 2025
1 parent 6ea94b9 commit 6ac3c7e
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions GTG/gtk/browser/sidebar.py
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,7 @@ def tags_unbind_cb(self, signallistitem, listitem, user_data=None) -> None:

def unselect_tags(self) -> None:
"""Clear tags selection"""
self.browser.config.set("selected_tag", '')

with signal_block(self.tag_selection, self.tag_handle):
self.tag_selection.unselect_all()
Expand Down Expand Up @@ -492,8 +493,6 @@ def on_tag_selected(self, model, position, n_items, user_data=None):

if tags:
self.browser.config.set("selected_tag", tags[0])
else:
self.browser.config.set("selected_tag", '')

self.emit('selection_changed')

Expand Down

0 comments on commit 6ac3c7e

Please sign in to comment.