platypus: make LCActionFlowable the bad ones
authorrgbecker
Thu, 03 Feb 2005 17:14:58 +0000
changeset 2450 f2ae0122a66a
parent 2449 47b15f941325
child 2451 19bf750c3c26
platypus: make LCActionFlowable the bad ones
reportlab/platypus/doctemplate.py
reportlab/platypus/flowables.py
--- a/reportlab/platypus/doctemplate.py	Thu Feb 03 11:30:21 2005 +0000
+++ b/reportlab/platypus/doctemplate.py	Thu Feb 03 17:14:58 2005 +0000
@@ -81,13 +81,6 @@
             action = (action,)
         self.action = tuple(action)
 
-    def wrap(self, availWidth, availHeight):
-        '''Should never be called.'''
-        raise NotImplementedError
-
-    def draw(self):
-        '''Should never be called.'''
-        raise NotImplementedError
 
     def apply(self,doc):
         '''
@@ -117,6 +110,14 @@
 class LCActionFlowable(ActionFlowable):
     locChanger = 1                  #we cause a frame or page change
 
+    def wrap(self, availWidth, availHeight):
+        '''Should never be called.'''
+        raise NotImplementedError
+
+    def draw(self):
+        '''Should never be called.'''
+        raise NotImplementedError
+
 class NextFrameFlowable(ActionFlowable):
     def __init__(self,ix,resume=0):
         ActionFlowable.__init__(self,('nextFrame',ix,resume))
--- a/reportlab/platypus/flowables.py	Thu Feb 03 11:30:21 2005 +0000
+++ b/reportlab/platypus/flowables.py	Thu Feb 03 17:14:58 2005 +0000
@@ -448,8 +448,8 @@
 def _flowableSublist(V):
     "if it isn't a list or tuple, wrap it in a list"
     if type(V) not in (ListType, TupleType): V = V is not None and [V] or []
-    from doctemplate import  ActionFlowable
-    assert not filter(lambda x: isinstance(x,ActionFlowable),V),'Action flowables not allowed in sublists'
+    from doctemplate import LCActionFlowable
+    assert not filter(lambda x: isinstance(x,LCActionFlowable),V),'LCActionFlowables not allowed in sublists'
     return V
 
 class KeepTogether(Flowable):