You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lo...@apache.org on 2012/10/16 15:05:59 UTC

svn commit: r1398776 - /myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js

Author: lofwyr
Date: Tue Oct 16 13:05:59 2012
New Revision: 1398776

URL: http://svn.apache.org/viewvc?rev=1398776&view=rev
Log:
undo the codi stuff

Modified:
    myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js

Modified: myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js?rev=1398776&r1=1398775&r2=1398776&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js (original)
+++ myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js Tue Oct 16 13:05:59 2012
@@ -2869,52 +2869,4 @@ Tobago.registerListener(Tobago.File.init
 
 // ////////////////////////////////////////////////////////////////////////////////////////////////////////////////
 
-Tobago.Codi = {};
-
-/**
- * If the window has no name set we set the name and request a new view with unset windowId, so that the
- * server will generate a new one for us.
- */
-Tobago.Codi.init = function() {
-
-  var form = document.forms[0];
-  var windowIdEnabled = Tobago.Codi.hasUrlWindowId(form.action);
-  if (windowIdEnabled && window.name == "") {
-    form.action = Tobago.Codi.urlWithoutWindowId(form.action);
-    window.name = "window";
-    Tobago.submitAction();
-  }
-};
-
-Tobago.Codi.hasUrlWindowId = function(base) {
-  return base.indexOf("?windowId=") || base.indexOf("&windowId=");
-};
-
-/**
- * taken from myfaces-extcdi (Codi)
- */
-Tobago.Codi.urlWithoutWindowId = function(base) {
-    var query = base;
-    var vars = query.split(/&|\?/g);
-    var newQuery = "";
-    var iParam = 0;
-    for (var i=0; vars != null && i < vars.length; i++) {
-        var pair = vars[i].split("=");
-        if (pair.length == 1) {
-            newQuery = pair[0];
-        }
-        else {
-            if (pair[0] != "windowId") {
-                var amp = iParam++ > 0 ? "&" : "?";
-                newQuery =  newQuery + amp + pair[0] + "=" + pair[1];
-            }
-        }
-    }
-    return newQuery;
-};
-
-Tobago.registerListener(Tobago.Codi.init, Tobago.Phase.DOCUMENT_READY);
-
-// ////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-
 TbgTimer.endTbgJs = new Date(); // @DEV_ONLY