From 638f70b640c605ae3661c1760f14347399e44fb4 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 7 Apr 2011 18:09:39 -0600 Subject: [PATCH] ... --- src/calibre/gui2/actions/__init__.py | 2 +- src/calibre/gui2/metadata/single_download.py | 12 +++++++----- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/src/calibre/gui2/actions/__init__.py b/src/calibre/gui2/actions/__init__.py index 589e14cff2..a68659864a 100644 --- a/src/calibre/gui2/actions/__init__.py +++ b/src/calibre/gui2/actions/__init__.py @@ -148,7 +148,7 @@ class InterfaceAction(QObject): def genesis(self): ''' Setup this plugin. Only called once during initialization. self.gui is - available. The action secified by :attr:`action_spec` is available as + available. The action specified by :attr:`action_spec` is available as ``self.qaction``. ''' pass diff --git a/src/calibre/gui2/metadata/single_download.py b/src/calibre/gui2/metadata/single_download.py index 94ee8f8a13..eb067e1211 100644 --- a/src/calibre/gui2/metadata/single_download.py +++ b/src/calibre/gui2/metadata/single_download.py @@ -71,15 +71,12 @@ class ResultsModel(QAbstractTableModel): return len(self.COLUMNS) def headerData(self, section, orientation, role): - if role != Qt.DisplayRole: - return NONE - if orientation == Qt.Horizontal: + if orientation == Qt.Horizontal and role == Qt.DisplayRole: try: return QVariant(self.COLUMNS[section]) except: return NONE - else: - return QVariant(unicode(section+1)) + return NONE def data_as_text(self, book, col): if col == 0: @@ -324,6 +321,11 @@ class IdentifyWidget(QWidget): # {{{ self.results_view.show_results(self.worker.results) + self.comments_view.show_data(''' +
Found %d results
+
To see details, click on any result
''' % + len(self.worker.results)) + def cancel(self): self.abort.set()