mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Make coloring work across change_libraries
This commit is contained in:
parent
ca5dc817c2
commit
1a4768a539
@ -65,7 +65,6 @@ class LibraryViewMixin(object): # {{{
|
||||
|
||||
self.build_context_menus()
|
||||
self.library_view.model().set_highlight_only(config['highlight_search_matches'])
|
||||
self.library_view.model().set_color_templates()
|
||||
|
||||
def build_context_menus(self):
|
||||
lm = QMenu(self)
|
||||
|
@ -157,6 +157,7 @@ class BooksModel(QAbstractTableModel): # {{{
|
||||
self.database_changed.emit(db)
|
||||
self.stop_metadata_backup()
|
||||
self.start_metadata_backup()
|
||||
self.set_color_templates()
|
||||
|
||||
def start_metadata_backup(self):
|
||||
self.metadata_backup = MetadataBackup(self.db)
|
||||
@ -535,6 +536,7 @@ class BooksModel(QAbstractTableModel): # {{{
|
||||
return img
|
||||
|
||||
def set_color_templates(self):
|
||||
print 'here'
|
||||
self.column_color_map = {}
|
||||
for i in range(1,self.db.column_color_count+1):
|
||||
name = self.db.prefs.get('column_color_name_'+str(i))
|
||||
|
Loading…
x
Reference in New Issue
Block a user