~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to ivle/webapp/base/xhtml.py

  • Committer: William Grant
  • Date: 2010-02-15 05:37:50 UTC
  • Revision ID: grantw@unimelb.edu.au-20100215053750-hihmegnp8e7dshc2
Ignore test coverage files.

Show diffs side-by-side

added added

removed removed

Lines of Context:
113
113
        crumber = Breadcrumber(req)
114
114
 
115
115
        ctx['breadcrumbs'] = []
116
 
        if not req.publicmode:
117
 
            for ancestor in ancestry:
118
 
                crumb = crumber.crumb(ancestor)
119
 
                if crumb is None:
120
 
                    continue
121
 
 
122
 
                if hasattr(crumb, 'extra_breadcrumbs_before'):
123
 
                    ctx['breadcrumbs'].extend(crumb.extra_breadcrumbs_before)
124
 
                ctx['breadcrumbs'].append(crumb)
125
 
                if hasattr(crumb, 'extra_breadcrumbs_after'):
126
 
                    ctx['breadcrumbs'].extend(crumb.extra_breadcrumbs_after)
127
 
 
128
 
            # If the view has specified text for a breadcrumb, add one.
129
 
            if self.breadcrumb_text:
130
 
                ctx['breadcrumbs'].append(ViewBreadcrumb(req, self))
131
 
 
132
 
            # Allow the view to add its own fake breadcrumbs.
133
 
            ctx['breadcrumbs'].extend(self.extra_breadcrumbs)
 
116
        for ancestor in ancestry:
 
117
            crumb = crumber.crumb(ancestor)
 
118
            if crumb is None:
 
119
                continue
 
120
 
 
121
            if hasattr(crumb, 'extra_breadcrumbs_before'):
 
122
                ctx['breadcrumbs'].extend(crumb.extra_breadcrumbs_before)
 
123
            ctx['breadcrumbs'].append(crumb)
 
124
            if hasattr(crumb, 'extra_breadcrumbs_after'):
 
125
                ctx['breadcrumbs'].extend(crumb.extra_breadcrumbs_after)
 
126
 
 
127
        # If the view has specified text for a breadcrumb, add one.
 
128
        if self.breadcrumb_text:
 
129
            ctx['breadcrumbs'].append(ViewBreadcrumb(req, self))
 
130
 
 
131
        # Allow the view to add its own fake breadcrumbs.
 
132
        ctx['breadcrumbs'].extend(self.extra_breadcrumbs)
134
133
 
135
134
        self.populate_headings(req, ctx)
136
135
        tmpl = loader.load(os.path.join(os.path.dirname(__file__),