This commit is contained in:
Kovid Goyal 2013-08-19 10:21:13 +05:30
parent 079c685f1a
commit 6690397d1a

View File

@ -1089,7 +1089,7 @@ class TagsModel(QAbstractItemModel): # {{{
fm = self.db.metadata_for_field(node.tag.category)
if node.tag.category in \
('tags', 'series', 'authors', 'rating', 'publisher') or \
(fm['is_custom'] and \
(fm['is_custom'] and
fm['datatype'] in ['text', 'rating', 'series', 'enumeration']):
ans |= Qt.ItemIsDropEnabled
else:
@ -1193,7 +1193,8 @@ class TagsModel(QAbstractItemModel): # {{{
exclusive: clear all states before applying this one
set_to: None => advance the state, otherwise a value from TAG_SEARCH_STATES
'''
if not index.isValid(): return False
if not index.isValid():
return False
item = self.get_node(index)
item.toggle(set_to=set_to)
if exclusive: