cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r888229 - in /cxf/branches/2.2.x-fixes: ./ rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/AbstractServletController.java rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java
Date Tue, 08 Dec 2009 02:30:33 GMT
Author: dkulp
Date: Tue Dec  8 02:30:33 2009
New Revision: 888229

URL: http://svn.apache.org/viewvc?rev=888229&view=rev
Log:
Merged revisions 888195 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r888195 | dkulp | 2009-12-07 18:47:02 -0500 (Mon, 07 Dec 2009) | 2 lines
  
  [CXF-2562] Add ability to change service list title.
  Patch from R?\195?\169mi Flament applied.
........

Modified:
    cxf/branches/2.2.x-fixes/   (props changed)
    cxf/branches/2.2.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/AbstractServletController.java
    cxf/branches/2.2.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java

Propchange: cxf/branches/2.2.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.2.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/AbstractServletController.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.2.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/AbstractServletController.java?rev=888229&r1=888228&r2=888229&view=diff
==============================================================================
--- cxf/branches/2.2.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/AbstractServletController.java
(original)
+++ cxf/branches/2.2.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/AbstractServletController.java
Tue Dec  8 02:30:33 2009
@@ -31,6 +31,7 @@
     protected boolean disableAddressUpdates;
     protected String forcedBaseAddress;
     protected String serviceListStyleSheet;
+    protected String title;
     protected String serviceListRelativePath = DEFAULT_LISTINGS_CLASSIFIER;
     
     protected AbstractServletController() {
@@ -58,6 +59,9 @@
     public void setServiceListStyleSheet(String serviceListStyleSheet) {
         this.serviceListStyleSheet = serviceListStyleSheet;
     }
+    public void setTitle(String t) {
+        title = t;
+    }
     
     private void init(ServletConfig servletConfig) {
         if (servletConfig == null) {
@@ -84,6 +88,10 @@
         if (serviceListPath != null) {
             serviceListRelativePath = serviceListPath;
         }
+        String configTitle = servletConfig.getInitParameter("service-list-title");
+        if (configTitle != null) {
+            title = configTitle;
+        }
     }
     
     protected String getBaseURL(HttpServletRequest request) {

Modified: cxf/branches/2.2.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.2.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java?rev=888229&r1=888228&r2=888229&view=diff
==============================================================================
--- cxf/branches/2.2.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java
(original)
+++ cxf/branches/2.2.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java
Tue Dec  8 02:30:33 2009
@@ -217,7 +217,11 @@
                                        + request.getRequestURI() + "/?stylesheet=1\">");
           
         }
         response.getWriter().write("<meta http-equiv=content-type content=\"text/html;
charset=UTF-8\">");
-        response.getWriter().write("<title>CXF - Service list</title>");
+        if (title != null) {
+            response.getWriter().write("<title>" + title + "</title>");
+        } else {
+            response.getWriter().write("<title>CXF - Service list</title>");
+        }
         response.getWriter().write("</head><body>");
         
         List<ServletDestination> destinations = getServletDestinations();



Mime
View raw message