commit-gnue
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

gnue/reports/src GRLayout.py


From: Jason Cater
Subject: gnue/reports/src GRLayout.py
Date: Tue, 09 Apr 2002 00:30:58 -0400

CVSROOT:        /home/cvs
Module name:    gnue
Changes by:     Jason Cater <address@hidden>    02/04/09 00:30:57

Modified files:
        reports/src    : GRLayout.py 

Log message:
        finally whipped section firstRow support into shape

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/reports/src/GRLayout.py.diff?cvsroot=OldCVS&tr1=1.23&tr2=1.24&r1=text&r2=text

Patches:
Index: gnue/reports/src/GRLayout.py
diff -c gnue/reports/src/GRLayout.py:1.23 gnue/reports/src/GRLayout.py:1.24
*** gnue/reports/src/GRLayout.py:1.23   Mon Apr  8 22:41:02 2002
--- gnue/reports/src/GRLayout.py        Tue Apr  9 00:30:57 2002
***************
*** 221,234 ****
  class ContainerElement (GRLayoutElement):
    def __init__(self, parent=None, type='GRContainerElement'):
      GRLayoutElement.__init__(self, parent, type=type)
!     self._name = None
  
  
    # Process all children, handling GRSections properly
    def processChildren(self, dest, mapper,
                        isfirst, islast, firstSection, nextSection):
  
!     first = 1 # isfirst or firstSection == self
      while 1:
        for child in self._children:
          if child._type == "_content_":
--- 221,236 ----
  class ContainerElement (GRLayoutElement):
    def __init__(self, parent=None, type='GRContainerElement'):
      GRLayoutElement.__init__(self, parent, type=type)
!     # TODO: remove.. this is for debugging
!     self._name = "untitled"
  
  
    # Process all children, handling GRSections properly
    def processChildren(self, dest, mapper,
                        isfirst, islast, firstSection, nextSection):
  
!     first = isfirst or isinstance(self, GRSection)
! 
      while 1:
        for child in self._children:
          if child._type == "_content_":
***************
*** 240,246 ****
                child.processAsController(dest, mapper)
              else:
                nextSection = child.process(dest, mapper,
!                  isfirst=first,
                   islast=(nextSection == None) or \
                      (nextSection._name not in (child._childSections)),
                   firstSection=firstSection,
--- 242,248 ----
                child.processAsController(dest, mapper)
              else:
                nextSection = child.process(dest, mapper,
!                  isfirst=1,
                   islast=(nextSection == None) or \
                      (nextSection._name not in (child._childSections)),
                   firstSection=firstSection,
***************
*** 254,260 ****
  
        if nextSection == self:
          firstSection, nextSection = self.getGotos(mapper)
-         #print "grabbing next one %s" % self._name
          islast = (nextSection == None)
        else:
          break
--- 256,261 ----
***************
*** 321,347 ****
          firstSection, nextSection = self.getGotos(mapper,1)
  
          self.process(dest, mapper, 1, nextSection == None, self, nextSection)
- #
- #        oldSection = None
- #
- #
- #        while goto:
- #
- #          section = mapper.sectionMap[goto]._object
- #          if gotoNext:
- #            nextSection = mapper.sectionMap[gotoNext]._object._name
- #          else:
- #            nextSection = None
- #
- #          # Process the current data row starting at correct section
- #          section.process(dest, mapper, (oldSection in 
section._childSections),
- #                        firstSection, nextSection)
- #
- #          (goto, gotoNext) = mapper.getNextRecord(self._source)
- #          GDebug.printMesg (10, "Goto is '%s'; next is '%s'" % (goto, 
gotoNext))
- #
- #          oldSection = section._name
- #
  
        else:
          # This is a data-bound section and there
--- 322,327 ----



reply via email to

[Prev in Thread] Current Thread [Next in Thread]