GTKUI: Fix Show Zero Hits to only apply to state, owner and tracker_host

There is an issue with the Label plugin where a new label would 'disappear'
and you could not change the options for the new label with zero hits hidden.
This commit is contained in:
Calum Lind 2013-05-20 15:41:16 +01:00
parent f8fbda97cd
commit 85f9247fd7
1 changed files with 3 additions and 2 deletions

View File

@ -223,8 +223,9 @@ class FilterManager(component.Component):
items["tracker_host"]["Error"] = len(tracker_error_filter(torrent_ids, ("Error",))) items["tracker_host"]["Error"] = len(tracker_error_filter(torrent_ids, ("Error",)))
if not show_zero_hits: if not show_zero_hits:
for cat in tree_keys: for cat in ["state", "owner", "tracker_host"]:
self._hide_state_items(items[cat]) if cat in tree_keys:
self._hide_state_items(items[cat])
# Return a dict of tuples: # Return a dict of tuples:
sorted_items = {} sorted_items = {}