Author: crossley
Date: Wed Oct 4 01:39:32 2006
New Revision: 452796
URL: http://svn.apache.org/viewvc?view=rev&rev=452796
Log:
i18n: Add LocaleAction action wrapper, and use the locale provided by it.
Issue: FOR-935
Contributed by: Sjur Moshagen
Modified:
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/internal.xmap
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/status.xml
Modified:
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/internal.xmap
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/internal.xmap?view=diff&rev=452796&r1=452795&r2=452796
==============================================================================
---
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/internal.xmap
(original)
+++
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/internal.xmap
Wed Oct 4 01:39:32 2006
@@ -92,6 +92,7 @@
prepares and transforms the requested contracts (themes) and populate
them with the content (businessHelper).
-->
<map:pipeline>
+ <map:act type="locale" >
<map:match pattern="resolve.structurer.**">
<map:generate src="lm://resolve.structurer.{1}" />
<map:serialize />
@@ -99,10 +100,11 @@
<map:match pattern="resolve.contract.*.**">
<map:generate src="{lm:resolve.contract.{1}.{2}}" />
<map:transform type="i18n">
- <map:parameter name="locale" value="{request:locale}" />
+ <map:parameter name="locale" value="{../locale}" />
</map:transform>
<map:serialize />
</map:match>
+ </map:act>
</map:pipeline>
<!-- prepare the xsl:templates of the requested contract.
@@ -112,14 +114,16 @@
<xsl:include
href="cocoon://prepare.contract.html.NameOfTheContract"/>
Warning - At the moment, the contracts do not manage formats anymore...
-->
<map:pipeline>
+ <map:act type="locale" >
<map:match pattern="prepare.contract.*.**">
<map:generate src="{lm:resolve.contract.{1}.{2}}" />
<map:transform src="{lm:contract-strip-xsl.xsl}"/>
<map:transform type="i18n">
- <map:parameter name="locale" value="{request:locale}" />
+ <map:parameter name="locale" value="{../locale}" />
</map:transform>
<map:serialize />
</map:match>
+ </map:act>
</map:pipeline>
<!-- You can group elements to a template and call it from any view.
Modified:
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/status.xml
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/status.xml?view=diff&rev=452796&r1=452795&r2=452796
==============================================================================
---
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/status.xml
(original)
+++
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.dispatcher/status.xml
Wed Oct 4 01:39:32 2006
@@ -18,7 +18,9 @@
<status>
<developers>
+ <person name="David Crossley" email="[EMAIL PROTECTED]" id="DC" />
<person name="Ross Gardler" email="[EMAIL PROTECTED]" id="RDG" />
+ <person name="Thorsten Scherler" email="[EMAIL PROTECTED]" id="TS" />
<person name="Volunteer needed" email="[email protected]" id="open"/>
</developers>
@@ -37,6 +39,11 @@
<changes>
<!-- Add new releases here -->
<release version="0.1" date="unreleased">
+ <action context="code" type="update" dev="DC" fixes-bug="FOR-935"
+ due-to="Sjur Moshagen">
+ i18n: Add LocaleAction action wrapper, and use the locale provided by
it.
+ Was taking the locale directly from the request instead of using the
standard method in Forrest: LocaleAction.
+ </action>
<action dev="TS" type="add" context="docs">
Adding the "how tos" from the site-author to this plugin.
</action>