| OLD | NEW |
| 1 # This file is part of Buildbot. Buildbot is free software: you can | 1 # This file is part of Buildbot. Buildbot is free software: you can |
| 2 # redistribute it and/or modify it under the terms of the GNU General Public | 2 # redistribute it and/or modify it under the terms of the GNU General Public |
| 3 # License as published by the Free Software Foundation, version 2. | 3 # License as published by the Free Software Foundation, version 2. |
| 4 # | 4 # |
| 5 # This program is distributed in the hope that it will be useful, but WITHOUT | 5 # This program is distributed in the hope that it will be useful, but WITHOUT |
| 6 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS | 6 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS |
| 7 # FOR A PARTICULAR PURPOSE. See the GNU General Public License for more | 7 # FOR A PARTICULAR PURPOSE. See the GNU General Public License for more |
| 8 # details. | 8 # details. |
| 9 # | 9 # |
| 10 # You should have received a copy of the GNU General Public License along with | 10 # You should have received a copy of the GNU General Public License along with |
| (...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 202 stylesheet = rootpath + 'default.css', | 202 stylesheet = rootpath + 'default.css', |
| 203 path_to_root = rootpath, | 203 path_to_root = rootpath, |
| 204 version = version, | 204 version = version, |
| 205 time = time.strftime("%a %d %b %Y %H:%M:%S", | 205 time = time.strftime("%a %d %b %Y %H:%M:%S", |
| 206 time.localtime(util.now())), | 206 time.localtime(util.now())), |
| 207 tz = locale_tz, | 207 tz = locale_tz, |
| 208 metatags = [], | 208 metatags = [], |
| 209 pageTitle = self.getPageTitle(request), | 209 pageTitle = self.getPageTitle(request), |
| 210 welcomeurl = rootpath, | 210 welcomeurl = rootpath, |
| 211 authz = self.getAuthz(request), | 211 authz = self.getAuthz(request), |
| 212 mastername = self.getBuildmaster(request), |
| 212 ) | 213 ) |
| 213 | 214 |
| 214 | 215 |
| 215 class ActionResource(resource.Resource, AccessorMixin): | 216 class ActionResource(resource.Resource, AccessorMixin): |
| 216 """A resource that performs some action, then redirects to a new URL.""" | 217 """A resource that performs some action, then redirects to a new URL.""" |
| 217 | 218 |
| 218 isLeaf = 1 | 219 isLeaf = 1 |
| 219 | 220 |
| 220 def getChild(self, name, request): | 221 def getChild(self, name, request): |
| 221 return self | 222 return self |
| (...skipping 542 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 764 return filter | 765 return filter |
| 765 | 766 |
| 766 class AlmostStrictUndefined(jinja2.StrictUndefined): | 767 class AlmostStrictUndefined(jinja2.StrictUndefined): |
| 767 ''' An undefined that allows boolean testing but | 768 ''' An undefined that allows boolean testing but |
| 768 fails properly on every other use. | 769 fails properly on every other use. |
| 769 | 770 |
| 770 Much better than the default Undefined, but not | 771 Much better than the default Undefined, but not |
| 771 fully as strict as StrictUndefined ''' | 772 fully as strict as StrictUndefined ''' |
| 772 def __nonzero__(self): | 773 def __nonzero__(self): |
| 773 return False | 774 return False |
| OLD | NEW |