You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by st...@apache.org on 2012/05/14 12:57:21 UTC

svn commit: r1338150 - /myfaces/extensions/cdi/trunk/core/api/src/main/java/org/apache/myfaces/extensions/cdi/core/api/scope/conversation/config/WindowContextConfig.java

Author: struberg
Date: Mon May 14 10:57:21 2012
New Revision: 1338150

URL: http://svn.apache.org/viewvc?rev=1338150&view=rev
Log:
EXTCDI-288 set isUnknownWindowIdsAllowed to true as default

Modified:
    myfaces/extensions/cdi/trunk/core/api/src/main/java/org/apache/myfaces/extensions/cdi/core/api/scope/conversation/config/WindowContextConfig.java

Modified: myfaces/extensions/cdi/trunk/core/api/src/main/java/org/apache/myfaces/extensions/cdi/core/api/scope/conversation/config/WindowContextConfig.java
URL: http://svn.apache.org/viewvc/myfaces/extensions/cdi/trunk/core/api/src/main/java/org/apache/myfaces/extensions/cdi/core/api/scope/conversation/config/WindowContextConfig.java?rev=1338150&r1=1338149&r2=1338150&view=diff
==============================================================================
--- myfaces/extensions/cdi/trunk/core/api/src/main/java/org/apache/myfaces/extensions/cdi/core/api/scope/conversation/config/WindowContextConfig.java (original)
+++ myfaces/extensions/cdi/trunk/core/api/src/main/java/org/apache/myfaces/extensions/cdi/core/api/scope/conversation/config/WindowContextConfig.java Mon May 14 10:57:21 2012
@@ -52,17 +52,29 @@ public class WindowContextConfig extends
 
     /**
      * Allows to restrict window-ids.
-     * With the default window handler (esp. for JSF 1.2), URLs have to contain the window-id.
+     * <p>With the default window handler (esp. for JSF 1.2), URLs have to contain the window-id.
      * If users bookmark these links, they could open 2-n tabs (with the bookmark) which have the same window-id.
-     * It isn't possible to prevent it if the session is still active, but it's possible to prevent it as soon as the
-     * session gets closed.
+     * It is only possible to prevent it if the ClientSideWindowHandler is used.
+     * </p>
      *
-     * @return true to allow window-ids which aren't generated by CODI, false otherwise
+     * <p><b>ATTENTION:</b> Since CODI-1.0.6 this is set to <code>true</code> as defalt!</p>
+     *
+     * <p>
+     * This must be enabled to
+     * <ul>
+     *     <li>allow <i>target</i> attributes in a href</li>
+     *     <li>support multiple webapps in an EAR scenario. Since each webapp has it's own session,
+     *     they would otherwise trash their windowIds each time you link from one webapp to another one</li>
+     *     <li>play nicely with other frameworks which use the window.name for browser tab detection</li>
+     * </ul>
+     * </p>
+     * @return <code>true</code> to allow all windowIds already present in window.name.
+     *         <code>false</code> to only allow window-ids which are generated by CODI
      */
     @ConfigEntry
     public boolean isUnknownWindowIdsAllowed()
     {
-        return false;
+        return true;
     }
 
     /**