From a08213182314490b90adf2fdcd644651640774a2 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Fri, 15 Jun 2007 17:25:13 +0000 Subject: [PATCH] Fix #106 --- src/libprs500/__init__.py | 2 +- src/libprs500/ebooks/lrf/pylrs/pylrs.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/libprs500/__init__.py b/src/libprs500/__init__.py index cd2a3f1dae..ebac7179d9 100644 --- a/src/libprs500/__init__.py +++ b/src/libprs500/__init__.py @@ -13,7 +13,7 @@ ## with this program; if not, write to the Free Software Foundation, Inc., ## 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. ''' E-book management software''' -__version__ = "0.3.51" +__version__ = "0.3.52" __docformat__ = "epytext" __author__ = "Kovid Goyal " __appname__ = 'libprs500' diff --git a/src/libprs500/ebooks/lrf/pylrs/pylrs.py b/src/libprs500/ebooks/lrf/pylrs/pylrs.py index 1f6865f328..a298c2ed84 100644 --- a/src/libprs500/ebooks/lrf/pylrs/pylrs.py +++ b/src/libprs500/ebooks/lrf/pylrs/pylrs.py @@ -643,8 +643,8 @@ class TableOfContents(object): def addTocEntry(self, tocLabel, textBlock): - if not isinstance(textBlock, (TextBlock, ImageBlock, RuledLine)): - raise LrsError, "TOC destination must be a TextBlock, ImageBlock or RuledLine"+\ + if not isinstance(textBlock, (Canvas, TextBlock, ImageBlock, RuledLine)): + raise LrsError, "TOC destination must be a Canvas, TextBlock, ImageBlock or RuledLine"+\ " not a " + str(type(textBlock)) if textBlock.parent is None: