Modified: tapestry/tapestry4/trunk/src/site/xdoc/usersguide/state.xml
URL: 
http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/src/site/xdoc/usersguide/state.xml?view=diff&rev=475038&r1=475037&r2=475038
==============================================================================
--- tapestry/tapestry4/trunk/src/site/xdoc/usersguide/state.xml (original)
+++ tapestry/tapestry4/trunk/src/site/xdoc/usersguide/state.xml Tue Nov 14 
14:58:22 2006
@@ -298,7 +298,7 @@
 import org.apache.tapestry.html.BasePage;
        
 public abstract class MyPage extends <a
-                            
href="../tapestry-framework/apidocs/org/apache/tapestry/html/BasePage.html">BasePage</a>
+                            
href="../apidocs/org/apache/tapestry/html/BasePage.html">BasePage</a>
 {
     abstract public int getItemsPerPage();
        
@@ -524,7 +524,7 @@
                         &lt;create-instance&gt;. &lt;invoke-factory&gt; allows 
you to reference an
                         object or service that implements the
                         <a
-                            
href="../tapestry-framework/apidocs/org/apache/tapestry/engine/state/StateObjectFactory.html">
+                            
href="../apidocs/org/apache/tapestry/engine/state/StateObjectFactory.html">
                             StateObjectFactory
                         </a>
                         interface.
@@ -573,7 +573,7 @@
                         <strong>Warning:</strong>
                         <p>
                         The
-                        <a 
href="../tapestry-framework/apidocs/org/apache/tapestry/IPage.html">
+                        <a href="../apidocs/org/apache/tapestry/IPage.html">
                             IPage
                         </a>
                         interface defines two read-only properties:
@@ -617,7 +617,7 @@
                         <em>optionally</em>
                         implement the
                         <a
-                            
href="../tapestry-framework/apidocs/org/apache/tapestry/SessionStoreOptimized.html">
+                            
href="../apidocs/org/apache/tapestry/SessionStoreOptimized.html">
                             SessionStoreOptimized
                         </a>
                         interface. The method isStoreToSessionNeeded() will be 
checked; if it
@@ -636,7 +636,7 @@
                     <p>
                         A base class,
                         <a
-                            
href="../tapestry-framework/apidocs/org/apache/tapestry/BaseSessionStoreOptimized.html">
+                            
href="../apidocs/org/apache/tapestry/BaseSessionStoreOptimized.html">
                             BaseSessionStoreOptimized
                         </a>
                         , implements this behavior.

Modified: tapestry/tapestry4/trunk/src/site/xdoc/usersguide/template.xml
URL: 
http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/src/site/xdoc/usersguide/template.xml?view=diff&rev=475038&r1=475037&r2=475038
==============================================================================
--- tapestry/tapestry4/trunk/src/site/xdoc/usersguide/template.xml (original)
+++ tapestry/tapestry4/trunk/src/site/xdoc/usersguide/template.xml Tue Nov 14 
14:58:22 2006
@@ -431,7 +431,7 @@
                             additional attributes in the output markup. A 
special case is when the
                             value for an informal parameter is an
                             <a
-                                
href="../tapestry-framework/apidocs/org/apache/tapestry/IAsset.html">
+                                
href="../apidocs/org/apache/tapestry/IAsset.html">
                                 IAsset
                             </a>
                             (possibly specified with the "asset:" prefix), in 
which case the

Modified: tapestry/tapestry4/trunk/src/site/xdoc/usersguide/upgrade.xml
URL: 
http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/src/site/xdoc/usersguide/upgrade.xml?view=diff&rev=475038&r1=475037&r2=475038
==============================================================================
--- tapestry/tapestry4/trunk/src/site/xdoc/usersguide/upgrade.xml (original)
+++ tapestry/tapestry4/trunk/src/site/xdoc/usersguide/upgrade.xml Tue Nov 14 
14:58:22 2006
@@ -93,7 +93,7 @@
                 <p>
                     The
                     <a
-                        
href="../tapestry-framework/apidocs/org/apache/tapestry/engine/IEngineService.html">
+                        
href="../apidocs/org/apache/tapestry/engine/IEngineService.html">
                         IEngineService
                     </a>
                     interface has changed in non-backwards compatible ways. If 
your application
@@ -187,7 +187,7 @@
                         This may be of concern if your component used the 
custom parameter
                         direction. In Tapestry 3.0, direction custom meant 
that your code would
                         directly access the
-                        <a 
href="../tapestry-framework/apidocs/org/apache/tapestry/IBinding.html">
+                        <a href="../apidocs/org/apache/tapestry/IBinding.html">
                             IBinding
                         </a>
                         object for the parameter, and no property for the 
parameter would be
@@ -268,7 +268,7 @@
 
                     <p>
                         In Tapestry 3.0, it was possible to access a
-                        <a 
href="../tapestry-framework/apidocs/org/apache/tapestry/IBinding.html">
+                        <a href="../apidocs/org/apache/tapestry/IBinding.html">
                             IBinding
                         </a>
                         object for a parameter by defining an additional 
property in your
@@ -330,7 +330,7 @@
                     <p>
                         Tapestry 3.0 included an &lt;inherited-binding&gt; 
element, this was a way
                         to directly pass the
-                        <a 
href="../tapestry-framework/apidocs/org/apache/tapestry/IBinding.html">
+                        <a href="../apidocs/org/apache/tapestry/IBinding.html">
                             IBinding
                         </a>
                         object for a component parameter to a parameter of a 
nested component. This
@@ -445,7 +445,7 @@
                     word in JDK 1.5). With the loss of that dependency, so goes
                     org.apache.tapestry.form.EnumPropertySelectionModel, an
                     <a
-                        
href="../tapestry-framework/apidocs/org/apache/tapestry/form/IPropertySelectionModel.html">
+                        
href="../apidocs/org/apache/tapestry/form/IPropertySelectionModel.html">
                         IPropertySelectionModel
                     </a>
                     implementation.
@@ -464,7 +464,7 @@
                 <p>
                     The contract for
                     <a
-                        
href="../tapestry-framework/apidocs/org/apache/tapestry/resolver/ISpecificationResolverDelegate.html">
+                        
href="../apidocs/org/apache/tapestry/resolver/ISpecificationResolverDelegate.html">
                         ISpecificationResolverDelegate
                     </a>
                     has changed. The specifications returned by the delegate 
are now cached by

Modified: 
tapestry/tapestry4/trunk/tapestry-examples/TimeTracker/src/context/css/forms.css
URL: 
http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-examples/TimeTracker/src/context/css/forms.css?view=diff&rev=475038&r1=475037&r2=475038
==============================================================================
--- 
tapestry/tapestry4/trunk/tapestry-examples/TimeTracker/src/context/css/forms.css
 (original)
+++ 
tapestry/tapestry4/trunk/tapestry-examples/TimeTracker/src/context/css/forms.css
 Tue Nov 14 14:58:22 2006
@@ -55,7 +55,8 @@
 }
 
 .alertDialog {
-    width: 30em;
+    margin-left:26%;
+    margin-right:26%;
     border: 2px solid #ff660a;
     padding: 1em;
     background: #ffffff;
@@ -83,15 +84,14 @@
     padding-left:0.1em;
     padding-right:0.2em;
     margin: 0;
+    width: 26em;
 }
 
 .missingList {
-    width: 24em;
     border-top: 4px solid #bedef4;
 }
 
 .invalidList {
-    width: 24em;
     border-top: 4px solid #ffaf7e;
 }
 

Modified: 
tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/asset/AssetService.java
URL: 
http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/asset/AssetService.java?view=diff&rev=475038&r1=475037&r2=475038
==============================================================================
--- 
tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/asset/AssetService.java
 (original)
+++ 
tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/asset/AssetService.java
 Tue Nov 14 14:58:22 2006
@@ -96,6 +96,7 @@
         _mimeTypes.put("gif", "image/gif");
         _mimeTypes.put("jpg", "image/jpeg");
         _mimeTypes.put("jpeg", "image/jpeg");
+        _mimeTypes.put("png", "image/png");
         _mimeTypes.put("htm", "text/html");
         _mimeTypes.put("html", "text/html");
     }
@@ -104,6 +105,9 @@
 
     private static final DateFormat CACHED_FORMAT = new SimpleDateFormat("EEE, 
d MMM yyyy HH:mm:ss Z", Locale.ENGLISH);
     
+    /** Represents a month of time in seconds. */
+    private static final long MONTH_SECONDS = 60 * 60 * 24 * 30;
+    
     private Log _log;
     
     /** @since 4.0 */
@@ -213,7 +217,7 @@
 
         return result;
     }
-
+    
     /**
      * Retrieves a resource from the classpath and returns it to the client in 
a binary output
      * stream.
@@ -330,11 +334,12 @@
     boolean cachedResource(URL resourceURL)
     {
         File resource = new File(resourceURL.getFile());
+        
         if (!resource.exists()) 
             return false;
         
-        //even if it doesn't exist in header the value will be -1, 
-        //which means we need to write out the contents of the resource
+        // even if it doesn't exist in header the value will be -1, 
+        // which means we need to write out the contents of the resource
         
         String header = _request.getHeader("If-Modified-Since");
         long modify = -1;
@@ -349,6 +354,7 @@
             return false;
         
         _response.setStatus(HttpServletResponse.SC_NOT_MODIFIED);
+        
         return true;
     }
     
@@ -373,13 +379,23 @@
 
             _response.setDateHeader("Last-Modified", _startupTime);
             _response.setDateHeader("Expires", _expireTime);
-
+            
             // Set the content type. If the servlet container doesn't
             // provide it, try and guess it by the extension.
 
             if (contentType == null || contentType.length() == 0)
                 contentType = getMimeType(resourcePath);
-
+            
+            // force image caching when detected, esp helps with ie related 
things
+            // see 
http://mir.aculo.us/2005/08/28/internet-explorer-and-ajax-image-caching-woes
+            
+            if (contentType != null && "image".indexOf(contentType) > -1) {
+                
+                _response.setHeader("Cache-Control", "max-age=" + 
MONTH_SECONDS);
+                
+                _response.setHeader("ETag", 
String.valueOf(resourcePath.hashCode()));
+            }
+            
             OutputStream output = _response.getOutputStream(new 
ContentType(contentType));
 
             input = new 
BufferedInputStream(resourceConnection.getInputStream());


Reply via email to