You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bloodhound.apache.org by gj...@apache.org on 2012/12/10 12:42:12 UTC
svn commit: r1419352 -
/incubator/bloodhound/trunk/bloodhound_theme/bhtheme/theme.py
Author: gjm
Date: Mon Dec 10 11:42:11 2012
New Revision: 1419352
URL: http://svn.apache.org/viewvc?rev=1419352&view=rev
Log:
move footer whitelabelling code from pre_process_request to post_process_request - for #294
Modified:
incubator/bloodhound/trunk/bloodhound_theme/bhtheme/theme.py
Modified: incubator/bloodhound/trunk/bloodhound_theme/bhtheme/theme.py
URL: http://svn.apache.org/viewvc/incubator/bloodhound/trunk/bloodhound_theme/bhtheme/theme.py?rev=1419352&r1=1419351&r2=1419352&view=diff
==============================================================================
--- incubator/bloodhound/trunk/bloodhound_theme/bhtheme/theme.py (original)
+++ incubator/bloodhound/trunk/bloodhound_theme/bhtheme/theme.py Mon Dec 10 11:42:11 2012
@@ -161,20 +161,6 @@ class BloodhoundTheme(ThemeBase):
def pre_process_request(self, req, handler):
"""Pre process request filter"""
- c = self.env.config
- req.chrome['labels'] = dict(
- application_short = c.get(
- 'labels', 'application_short', "Bloodhound"),
- application_full = c.get(
- 'labels', 'application_full', "Apache Bloodhound"),
- footer_left_prefix = c.get(
- 'labels', 'footer_left_prefix', ""),
- footer_left_postfix = c.get(
- 'labels', 'footer_left_postfix', ""),
- footer_right = c.get(
- 'labels', 'footer_right', ""),
- application_version = ".".join(map(str, application_version)))
-
def hwiki(*args, **kw):
def new_name(name):
@@ -205,6 +191,20 @@ class BloodhoundTheme(ThemeBase):
is_active = active_theme['name'] == this_theme_name
return is_active
+ c = self.env.config
+ req.chrome['labels'] = dict(
+ application_short = c.get(
+ 'labels', 'application_short', "Bloodhound"),
+ application_full = c.get(
+ 'labels', 'application_full', "Apache Bloodhound"),
+ footer_left_prefix = c.get(
+ 'labels', 'footer_left_prefix', ""),
+ footer_left_postfix = c.get(
+ 'labels', 'footer_left_postfix', ""),
+ footer_right = c.get(
+ 'labels', 'footer_right', ""),
+ application_version = ".".join(map(str, application_version)))
+
links = req.chrome.get('links',{})
# replace favicon if appropriate
if self.env.project_icon == 'common/trac.ico':