Tag Browser: Flatten the display of sub-groups when sort by is not set to 'name'. Fixes #1032746 (genres and search)

This commit is contained in:
Kovid Goyal 2012-08-05 12:12:03 +05:30
commit 959ec2c844

View File

@ -425,7 +425,8 @@ class TagsModel(QAbstractItemModel): # {{{
last_idx = -collapse last_idx = -collapse
category_is_hierarchical = not ( category_is_hierarchical = not (
key in ['authors', 'publisher', 'news', 'formats', 'rating'] or key in ['authors', 'publisher', 'news', 'formats', 'rating'] or
key not in self.db.prefs.get('categories_using_hierarchy', [])) key not in self.db.prefs.get('categories_using_hierarchy', []) or
config['sort_tags_by'] != 'name')
for idx,tag in enumerate(data[key]): for idx,tag in enumerate(data[key]):
components = None components = None