svn commit: r742133 - in /lenya/trunk: ./ org.apache.lenya.core.api/src/main/resources/META-INF/cocoon/avalon/ org.apache.lenya.core.gui/src/main/resources/COB-INF/ org.apache.lenya.core.gui/src/main/resources/COB-INF/resources/ org.apache.lenya.core.g...

[email protected]
Newsgroups gmane.comp.cms.lenya.cvs
Message-ID <[email protected]>
Author: andreas
Date: Sun Feb  8 17:43:15 2009
New Revision: 742133

URL: http://svn.apache.org/viewvc?rev=742133&view=rev
Log:
Adding GUI module resources, reference it from welcome block.

Added:
    lenya/trunk/org.apache.lenya.core.gui/src/main/resources/COB-INF/resources/
      - copied from r742130, lenya/branches/BRANCH_2_0_X/src/modules-core/gui/resources/
    lenya/trunk/org.apache.lenya.core.gui/src/main/resources/COB-INF/sitemap.xmap
Modified:
    lenya/trunk/org.apache.lenya.core.api/src/main/resources/META-INF/cocoon/avalon/lenya-core-sitemap.xconf
    lenya/trunk/org.apache.lenya.core.gui/src/main/resources/META-INF/cocoon/spring/lenya-core-gui-blockServlet.xml
    lenya/trunk/org.apache.lenya.parent/pom.xml
    lenya/trunk/org.apache.lenya.webapp/rcl.properties
    lenya/trunk/org.apache.lenya.welcome/src/main/resources/COB-INF/global-sitemap.xmap
    lenya/trunk/org.apache.lenya.welcome/src/main/resources/COB-INF/lenya/xslt/util/page2xhtml.xsl
    lenya/trunk/org.apache.lenya.welcome/src/main/resources/META-INF/cocoon/spring/lenya-welcome-blockServlet.xml
    lenya/trunk/pom.xml

Modified: lenya/trunk/org.apache.lenya.core.api/src/main/resources/META-INF/cocoon/avalon/lenya-core-sitemap.xconf
URL: http://svn.apache.org/viewvc/lenya/trunk/org.apache.lenya.core.api/src/main/resources/META-INF/cocoon/avalon/lenya-core-sitemap.xconf?rev=742133&r1=742132&r2=742133&view=diff
==============================================================================
--- lenya/trunk/org.apache.lenya.core.api/src/main/resources/META-INF/cocoon/avalon/lenya-core-sitemap.xconf (original)
+++ lenya/trunk/org.apache.lenya.core.api/src/main/resources/META-INF/cocoon/avalon/lenya-core-sitemap.xconf Sun Feb  8 17:43:15 2009
@@ -26,6 +26,17 @@
       <parameter name="localizable" value="true"/>
     </map:generator>
   </map:generators>
+  
+  
+  <transformers>
+    <map:transformer name="servletLinkRewriter-xhtml"
+      src="org.apache.cocoon.transformation.LinkRewriterTransformer">
+      <namespace-uri>http://www.w3.org/1999/xhtml</namespace-uri>
+      <schemes>servlet</schemes>
+      <link-attrs>href src</link-attrs>
+      <input-module name="servlet"/>
+    </map:transformer>
+  </transformers>
 
 
   <!-- Serializers -->

Added: lenya/trunk/org.apache.lenya.core.gui/src/main/resources/COB-INF/sitemap.xmap
URL: http://svn.apache.org/viewvc/lenya/trunk/org.apache.lenya.core.gui/src/main/resources/COB-INF/sitemap.xmap?rev=742133&view=auto
==============================================================================
--- lenya/trunk/org.apache.lenya.core.gui/src/main/resources/COB-INF/sitemap.xmap (added)
+++ lenya/trunk/org.apache.lenya.core.gui/src/main/resources/COB-INF/sitemap.xmap Sun Feb  8 17:43:15 2009
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+
+<!--
+  - Samples Style block sitemap
+  -
+  - $Id: sitemap.xmap 606212 2007-12-21 14:57:11Z vgritsenko $
+  -->
+<map:sitemap xmlns:map="http://apache.org/cocoon/sitemap/1.0">
+
+  <map:pipelines>
+    <map:pipeline id="services">
+      <!--
+        - These matchers are intended to be called
+        - when making use of servlet services from other blocks
+        -->
+
+<!--
+      <map:match pattern="service/blocks/*">
+        <map:generate src="service-consumer:"/>
+        <map:transform src="blocks/{1}.xsl"/>
+        <map:transform type="servletLinkRewriter"/>
+        <map:serialize type="html"/>
+      </map:match>
+-->
+    </map:pipeline>
+
+    <map:pipeline id="resources">
+      <map:match pattern="**.gif">
+        <map:read src="resources/{1}.gif"/>
+      </map:match>
+      <map:match pattern="**.jpg">
+        <map:read src="resources/{1}.jpg"/>
+      </map:match>
+      <map:match pattern="**.ico">
+        <map:read src="resources/{1}.ico"/>
+      </map:match>
+
+      <map:match pattern="**.css">
+        <map:read type="servletLinkRewriter" src="resources/{1}.css"/>
+      </map:match>
+      <map:match pattern="**.js">
+        <map:read type="servletLinkRewriter" src="resources/{1}.js"/>
+      </map:match>
+      <map:match pattern="**">
+        <map:read type="servletLinkRewriter" src="{1}"/>
+      </map:match>
+    </map:pipeline>
+  </map:pipelines>
+
+</map:sitemap>

Modified: lenya/trunk/org.apache.lenya.core.gui/src/main/resources/META-INF/cocoon/spring/lenya-core-gui-blockServlet.xml
URL: http://svn.apache.org/viewvc/lenya/trunk/org.apache.lenya.core.gui/src/main/resources/META-INF/cocoon/spring/lenya-core-gui-blockServlet.xml?rev=742133&r1=742132&r2=742133&view=diff
==============================================================================
--- lenya/trunk/org.apache.lenya.core.gui/src/main/resources/META-INF/cocoon/spring/lenya-core-gui-blockServlet.xml (original)
+++ lenya/trunk/org.apache.lenya.core.gui/src/main/resources/META-INF/cocoon/spring/lenya-core-gui-blockServlet.xml Sun Feb  8 17:43:15 2009
@@ -25,10 +25,6 @@
                            http://cocoon.apache.org/schema/servlet http://cocoon.apache.org/schema/servlet/cocoon-servlet-1.0.xsd">
 
   <bean name="org.apache.lenya.core.gui.block" class="org.apache.cocoon.sitemap.SitemapServlet">
-    <servlet:context mount-path="/gui" context-path="blockcontext:/lenya-core-gui-2.2.0-SNAPSHOT/">
-      <servlet:connections>
-        <entry key="prettyprinting" value-ref="org.apache.lenya.core.gui.block"/>
-      </servlet:connections>
-    </servlet:context>
+    <servlet:context mount-path="/gui" context-path="blockcontext:/lenya-core-gui-2.2.0-SNAPSHOT/"/>
   </bean>
 </beans>

Modified: lenya/trunk/org.apache.lenya.parent/pom.xml
URL: http://svn.apache.org/viewvc/lenya/trunk/org.apache.lenya.parent/pom.xml?rev=742133&r1=742132&r2=742133&view=diff
==============================================================================
--- lenya/trunk/org.apache.lenya.parent/pom.xml (original)
+++ lenya/trunk/org.apache.lenya.parent/pom.xml Sun Feb  8 17:43:15 2009
@@ -294,6 +294,11 @@
       </dependency>
       <dependency>
         <groupId>org.apache.lenya</groupId>
+        <artifactId>lenya-core-gui</artifactId>
+        <version>${project.version}</version>
+      </dependency>
+      <dependency>
+        <groupId>org.apache.lenya</groupId>
         <artifactId>lenya-core-i18n</artifactId>
         <version>${project.version}</version>
       </dependency>

Modified: lenya/trunk/org.apache.lenya.webapp/rcl.properties
URL: http://svn.apache.org/viewvc/lenya/trunk/org.apache.lenya.webapp/rcl.properties?rev=742133&r1=742132&r2=742133&view=diff
==============================================================================
--- lenya/trunk/org.apache.lenya.webapp/rcl.properties (original)
+++ lenya/trunk/org.apache.lenya.webapp/rcl.properties Sun Feb  8 17:43:15 2009
@@ -14,5 +14,6 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 #
-org.apache.lenya.welcome.block%classes-dir=../org.apache.lenya.welcome/target/classes
+org.apache.lenya.core.gui.block%classes-dir=../org.apache.lenya.core.gui/target/classes
 org.apache.lenya.module.prettyprinting.block%classes-dir=../org.apache.lenya.module.prettyprinting/target/classes
+org.apache.lenya.welcome.block%classes-dir=../org.apache.lenya.welcome/target/classes

Modified: lenya/trunk/org.apache.lenya.welcome/src/main/resources/COB-INF/global-sitemap.xmap
URL: http://svn.apache.org/viewvc/lenya/trunk/org.apache.lenya.welcome/src/main/resources/COB-INF/global-sitemap.xmap?rev=742133&r1=742132&r2=742133&view=diff
==============================================================================
--- lenya/trunk/org.apache.lenya.welcome/src/main/resources/COB-INF/global-sitemap.xmap (original)
+++ lenya/trunk/org.apache.lenya.welcome/src/main/resources/COB-INF/global-sitemap.xmap Sun Feb  8 17:43:15 2009
@@ -25,6 +25,7 @@
         <map:parameter name="locale" value="{request:locale}"/>
       </map:transform>
       <map:transform src="lenya/xslt/util/page2xhtml.xsl"/>
+      <map:transform type="servletLinkRewriter-xhtml"/>
       <map:transform type="proxy-xhtml"/>
       <map:transform src="lenya/xslt/util/strip_namespaces.xsl"/>
       <map:transform type="servletService">

Modified: lenya/trunk/org.apache.lenya.welcome/src/main/resources/COB-INF/lenya/xslt/util/page2xhtml.xsl
URL: http://svn.apache.org/viewvc/lenya/trunk/org.apache.lenya.welcome/src/main/resources/COB-INF/lenya/xslt/util/page2xhtml.xsl?rev=742133&r1=742132&r2=742133&view=diff
==============================================================================
--- lenya/trunk/org.apache.lenya.welcome/src/main/resources/COB-INF/lenya/xslt/util/page2xhtml.xsl (original)
+++ lenya/trunk/org.apache.lenya.welcome/src/main/resources/COB-INF/lenya/xslt/util/page2xhtml.xsl Sun Feb  8 17:43:15 2009
@@ -33,7 +33,7 @@
     <html>
       <head>
         <title><xsl:apply-templates select="page:title/node()" mode="htmlTitle"/></title>
-        <link rel="stylesheet" type="text/css" href="/modules/gui/css/default.css" title="default css"/>
+        <link rel="stylesheet" type="text/css" href="servlet:gui:/css/default.css" title="default css"/>
         <xsl:comment>[if IE 6]<![CDATA[>]]>&lt;link rel="stylesheet" type="text/css" href="/modules/gui/css/ie6hacksonly.css" /><![CDATA[<![endif]]]></xsl:comment>
         <link rel="icon" href="/favicon.ico" type="image/ico"/>
         <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8"/>

Modified: lenya/trunk/org.apache.lenya.welcome/src/main/resources/META-INF/cocoon/spring/lenya-welcome-blockServlet.xml
URL: http://svn.apache.org/viewvc/lenya/trunk/org.apache.lenya.welcome/src/main/resources/META-INF/cocoon/spring/lenya-welcome-blockServlet.xml?rev=742133&r1=742132&r2=742133&view=diff
==============================================================================
--- lenya/trunk/org.apache.lenya.welcome/src/main/resources/META-INF/cocoon/spring/lenya-welcome-blockServlet.xml (original)
+++ lenya/trunk/org.apache.lenya.welcome/src/main/resources/META-INF/cocoon/spring/lenya-welcome-blockServlet.xml Sun Feb  8 17:43:15 2009
@@ -27,6 +27,7 @@
   <bean name="org.apache.lenya.welcome.block" class="org.apache.cocoon.sitemap.SitemapServlet">
     <servlet:context mount-path="/" context-path="blockcontext:/lenya-welcome-2.2.0-SNAPSHOT/">
       <servlet:connections>
+        <entry key="gui" value-ref="org.apache.lenya.core.gui.block"/>
         <entry key="prettyprinting" value-ref="org.apache.lenya.module.prettyprinting.block"/>
       </servlet:connections>
     </servlet:context>

Modified: lenya/trunk/pom.xml
URL: http://svn.apache.org/viewvc/lenya/trunk/pom.xml?rev=742133&r1=742132&r2=742133&view=diff
==============================================================================
--- lenya/trunk/pom.xml (original)
+++ lenya/trunk/pom.xml Sun Feb  8 17:43:15 2009
@@ -39,6 +39,7 @@
     <module>org.apache.lenya.core.administration</module>
     <module>org.apache.lenya.core.api</module>
     <module>org.apache.lenya.core.cache</module>
+    <module>org.apache.lenya.core.gui</module>
     <module>org.apache.lenya.core.i18n</module>
     <module>org.apache.lenya.core.impl</module>
     <module>org.apache.lenya.core.janitor</module>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.