tapestry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jkuhn...@apache.org
Subject svn commit: r498423 [12/30] - in /tapestry/tapestry4/trunk: .settings/ eclipse/ tapestry-examples/TimeTracker/src/context/WEB-INF/ tapestry-examples/TimeTracker/src/java/org/apache/tapestry/timetracker/dao/ tapestry-examples/TimeTracker/src/java/org/ap...
Date Sun, 21 Jan 2007 18:26:26 GMT
Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_browser.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_browser.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_browser.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_browser.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,70 @@
+
+if(typeof window != 'undefined'){(function(){if(djConfig.allowQueryConfig){var baseUrl = document.location.toString();var params = baseUrl.split("?", 2);if(params.length > 1){var paramStr = params[1];var pairs = paramStr.split("&");for(var x in pairs){var sp = pairs[x].split("=");if((sp[0].length > 9)&&(sp[0].substr(0, 9) == "djConfig.")){var opt = sp[0].substr(9);try{djConfig[opt]=eval(sp[1]);}catch(e){djConfig[opt]=sp[1];}}
+}}
+}
+if(
+((djConfig["baseScriptUri"] == "")||(djConfig["baseRelativePath"] == "")) &&
+(document && document.getElementsByTagName)
+){var scripts = document.getElementsByTagName("script");var rePkg = /(__package__|dojo|bootstrap1)\.js([\?\.]|$)/i;for(var i = 0; i < scripts.length; i++) {var src = scripts[i].getAttribute("src");if(!src) { continue; }
+var m = src.match(rePkg);if(m) {var root = src.substring(0, m.index);if(src.indexOf("bootstrap1") > -1) { root += "../"; }
+if(!this["djConfig"]) { djConfig = {}; }
+if(djConfig["baseScriptUri"] == "") { djConfig["baseScriptUri"] = root; }
+if(djConfig["baseRelativePath"] == "") { djConfig["baseRelativePath"] = root; }
+break;}}
+}
+var dr = dojo.render;var drh = dojo.render.html;var drs = dojo.render.svg;var dua = (drh.UA = navigator.userAgent);var dav = (drh.AV = navigator.appVersion);var t = true;var f = false;drh.capable = t;drh.support.builtin = t;dr.ver = parseFloat(drh.AV);dr.os.mac = dav.indexOf("Macintosh") >= 0;dr.os.win = dav.indexOf("Windows") >= 0;dr.os.linux = dav.indexOf("X11") >= 0;drh.opera = dua.indexOf("Opera") >= 0;drh.khtml = (dav.indexOf("Konqueror") >= 0)||(dav.indexOf("Safari") >= 0);drh.safari = dav.indexOf("Safari") >= 0;var geckoPos = dua.indexOf("Gecko");drh.mozilla = drh.moz = (geckoPos >= 0)&&(!drh.khtml);if (drh.mozilla) {drh.geckoVersion = dua.substring(geckoPos + 6, geckoPos + 14);}
+drh.ie = (document.all)&&(!drh.opera);drh.ie50 = drh.ie && dav.indexOf("MSIE 5.0")>=0;drh.ie55 = drh.ie && dav.indexOf("MSIE 5.5")>=0;drh.ie60 = drh.ie && dav.indexOf("MSIE 6.0")>=0;drh.ie70 = drh.ie && dav.indexOf("MSIE 7.0")>=0;var cm = document["compatMode"];drh.quirks = (cm == "BackCompat")||(cm == "QuirksMode")||drh.ie55||drh.ie50;dojo.locale = dojo.locale || (drh.ie ? navigator.userLanguage : navigator.language).toLowerCase();dr.vml.capable=drh.ie;drs.capable = f;drs.support.plugin = f;drs.support.builtin = f;var tdoc = window["document"];var tdi = tdoc["implementation"];if((tdi)&&(tdi["hasFeature"])&&(tdi.hasFeature("org.w3c.dom.svg", "1.0"))){drs.capable = t;drs.support.builtin = t;drs.support.plugin = f;}
+if(drh.safari){var tmp = dua.split("AppleWebKit/")[1];var ver = parseFloat(tmp.split(" ")[0]);if(ver >= 420){drs.capable = t;drs.support.builtin = t;drs.support.plugin = f;}}else{}})();dojo.hostenv.startPackage("dojo.hostenv");dojo.render.name = dojo.hostenv.name_ = 'browser';dojo.hostenv.searchIds = [];dojo.hostenv._XMLHTTP_PROGIDS = ['Msxml2.XMLHTTP', 'Microsoft.XMLHTTP', 'Msxml2.XMLHTTP.4.0'];dojo.hostenv.getXmlhttpObject = function(){var http = null;var last_e = null;try{ http = new XMLHttpRequest(); }catch(e){}
+if(!http){for(var i=0; i<3; ++i){var progid = dojo.hostenv._XMLHTTP_PROGIDS[i];try{http = new ActiveXObject(progid);}catch(e){last_e = e;}
+if(http){dojo.hostenv._XMLHTTP_PROGIDS = [progid];break;}}
+}
+if(!http){return dojo.raise("XMLHTTP not available", last_e);}
+return http;}
+dojo.hostenv._blockAsync = false;dojo.hostenv.getText = function(uri, async_cb, fail_ok){if(!async_cb){ this._blockAsync = true; }
+var http = this.getXmlhttpObject();function isDocumentOk(http){var stat = http["status"];return Boolean((!stat)||((200 <= stat)&&(300 > stat))||(stat==304));}
+if(async_cb){var _this = this, timer = null, gbl = dojo.global();var xhr = dojo.getObject("dojo.io.XMLHTTPTransport");http.onreadystatechange = function(){if(timer){ gbl.clearTimeout(timer); timer = null; }
+if(_this._blockAsync || (xhr && xhr._blockAsync)){timer = gbl.setTimeout(function () { http.onreadystatechange.apply(this); }, 10);}else{if(4==http.readyState){if(isDocumentOk(http)){async_cb(http.responseText);}}
+}}
+}
+http.open('GET', uri, async_cb ? true : false);try{http.send(null);if(async_cb){return null;}
+if(!isDocumentOk(http)){var err = Error("Unable to load "+uri+" status:"+ http.status);err.status = http.status;err.responseText = http.responseText;throw err;}}catch(e){this._blockAsync = false;if((fail_ok)&&(!async_cb)){return null;}else{throw e;}}
+this._blockAsync = false;return http.responseText;}
+dojo.hostenv.defaultDebugContainerId = 'dojoDebug';dojo.hostenv._println_buffer = [];dojo.hostenv._println_safe = false;dojo.hostenv.println = function(line){if(!dojo.hostenv._println_safe){dojo.hostenv._println_buffer.push(line);}else{try {var console = document.getElementById(djConfig.debugContainerId ?
+djConfig.debugContainerId : dojo.hostenv.defaultDebugContainerId);if(!console) { console = dojo.body(); }
+var div = document.createElement("div");div.appendChild(document.createTextNode(line));console.appendChild(div);} catch (e) {try{document.write("<div>" + line + "</div>");}catch(e2){window.status = line;}}
+}}
+dojo.addOnLoad(function(){dojo.hostenv._println_safe = true;while(dojo.hostenv._println_buffer.length > 0){dojo.hostenv.println(dojo.hostenv._println_buffer.shift());}});function dj_addNodeEvtHdlr(node, evtName, fp){var oldHandler = node["on"+evtName] || function(){};node["on"+evtName] = function(){fp.apply(node, arguments);oldHandler.apply(node, arguments);}
+return true;}
+function dj_load_init(e){var type = (e && e.type) ? e.type.toLowerCase() : "load";if(arguments.callee.initialized || (type!="domcontentloaded" && type!="load")){ return; }
+arguments.callee.initialized = true;if(typeof(_timer) != 'undefined'){clearInterval(_timer);delete _timer;}
+var initFunc = function(){if(dojo.render.html.ie){dojo.hostenv.makeWidgets();}};if(dojo.hostenv.inFlightCount == 0){initFunc();dojo.hostenv.modulesLoaded();}else{dojo.hostenv.modulesLoadedListeners.unshift(initFunc);}}
+if(document.addEventListener){if(dojo.render.html.opera || (dojo.render.html.moz && (djConfig["enableMozDomContentLoaded"] === true))){document.addEventListener("DOMContentLoaded", dj_load_init, null);}
+window.addEventListener("load", dj_load_init, null);}
+if(dojo.render.html.ie && dojo.render.os.win){document.write('<scr'+'ipt defer src="//:" '
++ 'onreadystatechange="if(this.readyState==\'complete\'){dj_load_init();}">'
++ '</scr'+'ipt>'
+);}
+if (/(WebKit|khtml)/i.test(navigator.userAgent)) {var _timer = setInterval(function() {if (/loaded|complete/.test(document.readyState)) {dj_load_init();}}, 10);}
+if(dojo.render.html.ie){dj_addNodeEvtHdlr(window, "beforeunload", function(){dojo.hostenv._unloading = true;window.setTimeout(function() {dojo.hostenv._unloading = false;}, 0);});}
+dj_addNodeEvtHdlr(window, "unload", function(){if((!dojo.render.html.ie)||(dojo.render.html.ie && dojo.hostenv._unloading)){dojo.hostenv.unloaded();}});dojo.hostenv.makeWidgets = function(){var sids = [];if(djConfig.searchIds && djConfig.searchIds.length > 0) {sids = sids.concat(djConfig.searchIds);}
+if(dojo.hostenv.searchIds && dojo.hostenv.searchIds.length > 0) {sids = sids.concat(dojo.hostenv.searchIds);}
+if((djConfig.parseWidgets)||(sids.length > 0)){if(dojo.getObject("dojo.widget.Parse")){var parser = new dojo.xml.Parse();if(sids.length > 0){for(var x=0; x<sids.length; x++){var tmpNode = document.getElementById(sids[x]);if(!tmpNode){ continue; }
+var frag = parser.parseElement(tmpNode, null, true);dojo.widget.getParser().createComponents(frag);}}else if(djConfig.parseWidgets){var frag  = parser.parseElement(dojo.body(), null, true);dojo.widget.getParser().createComponents(frag);}}
+}}
+dojo.addOnLoad(function(){if(!dojo.render.html.ie) {dojo.hostenv.makeWidgets();}});try{if(dojo.render.html.ie){document.namespaces.add("v","urn:schemas-microsoft-com:vml");document.createStyleSheet().addRule("v\\:*", "behavior:url(#default#VML)");}}catch(e){ }
+dojo.hostenv.writeIncludes = function(){}
+if(!dj_undef("document", this)){dj_currentDocument = this.document;}
+dojo.doc = function(){return dj_currentDocument;}
+dojo.body = function(){return dojo.doc().body || dojo.doc().getElementsByTagName("body")[0];}
+dojo.byId = function(id, doc){if((id)&&((typeof id == "string")||(id instanceof String))){if(!doc){ doc = dj_currentDocument; }
+var ele = doc.getElementById(id);if(ele && (ele.id != id) && doc.all){ele = null;eles = doc.all[id];if(eles){if(eles.length){for(var i=0; i<eles.length; i++){if(eles[i].id == id){ele = eles[i];break;}}
+}else{ele = eles;}}
+}
+return ele;}
+return id;}
+dojo.setContext = function(globalObject, globalDocument){dj_currentContext = globalObject;dj_currentDocument = globalDocument;};dojo._fireCallback = function(callback, context, cbArguments){if((context)&&((typeof callback == "string")||(callback instanceof String))){callback=context[callback];}
+return (context ? callback.apply(context, cbArguments || [ ]) : callback());}
+dojo.withGlobal = function(globalObject, callback, thisObject, cbArguments){var rval;var oldGlob = dj_currentContext;var oldDoc = dj_currentDocument;try{dojo.setContext(globalObject, globalObject.document);rval = dojo._fireCallback(callback, thisObject, cbArguments);}finally{dojo.setContext(oldGlob, oldDoc);}
+return rval;}
+dojo.withDoc = function (documentObject, callback, thisObject, cbArguments) {var rval;var oldDoc = dj_currentDocument;try{dj_currentDocument = documentObject;rval = dojo._fireCallback(callback, thisObject, cbArguments);}finally{dj_currentDocument = oldDoc;}
+return rval;}}

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_browser.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_dashboard.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_dashboard.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_dashboard.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_dashboard.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,29 @@
+
+dojo.render.name = dojo.hostenv.name_ = "dashboard";dojo.hostenv.println = function( message){return alert(message);}
+dojo.hostenv.getXmlhttpObject = function( kwArgs){if(widget.system && kwArgs){if((kwArgs.contentType && kwArgs.contentType.indexOf("text/") != 0) || (kwArgs.headers && kwArgs.headers["content-type"] && kwArgs.headers["content-type"].indexOf("text/") != 0)){var curl = new dojo.hostenv.CurlRequest;curl._save = true;return curl;}else if(kwArgs.method && kwArgs.method.toUpperCase() == "HEAD"){return new dojo.hostenv.CurlRequest;}else if(kwArgs.headers && kwArgs.header.referer){return new dojo.hostenv.CurlRequest;}}
+return new XMLHttpRequest;}
+dojo.hostenv.CurlRequest = function(){this.onreadystatechange = null;this.readyState = 0;this.responseText = "";this.responseXML = null;this.status = 0;this.statusText = "";this._method = "";this._url = "";this._async = true;this._referrer = "";this._headers = [];this._save = false;this._responseHeader = "";this._responseHeaders = {};this._fileName = "";this._username = "";this._password = "";}
+dojo.hostenv.CurlRequest.prototype.open = function( method,  url,  async,  username,  password){this._method = method;this._url = url;if(async){this._async = async;}
+if(username){this._username = username;}
+if(password){this._password = password;}}
+dojo.hostenv.CurlRequest.prototype.setRequestHeader = function( label,  value){switch(label){case "Referer":
+this._referrer = value;break;case "content-type":
+break;default:
+this._headers.push(label + "=" + value);break;}}
+dojo.hostenv.CurlRequest.prototype.getAllResponseHeaders = function(){return this._responseHeader;}
+dojo.hostenv.CurlRequest.prototype.getResponseHeader = function( headerLabel){return this._responseHeaders[headerLabel];}
+dojo.hostenv.CurlRequest.prototype.send = function( content){this.readyState = 1;if(this.onreadystatechange){this.onreadystatechange.call(this);}
+var query = {sS: ""};if(this._referrer){query.e = this._referrer;}
+if(this._headers.length){query.H = this._headers.join("&");}
+if(this._username){if(this._password){query.u = this._username + ":" + this._password;}else{query.u = this._username;}}
+if(content){query.d = this.content;if(this._method != "POST"){query.G = "";}}
+if(this._method == "HEAD"){query.I = "";}else{if(this._save){query.I = "";}else{query.i = "";}}
+var system = widget.system(dojo.hostenv.CurlRequest._formatCall(query, this._url), null);this.readyState = 2;if(this.onreadystatechange){this.onreadystatechange.call(this);}
+if(system.errorString){this.responseText = system.errorString;this.status = 0;}else{if(this._save){this._responseHeader = system.outputString;}else{var split = system.outputString.replace(/\r/g, "").split("\n\n", 2);this._responseHeader = split[0];this.responseText = split[1];}
+split = this._responseHeader.split("\n");this.statusText = split.shift();this.status = this.statusText.split(" ")[1];for(var i = 0, header; header = split[i]; i++){var header_split = header.split(": ", 2);this._responseHeaders[header_split[0]] = header_split[1];}
+if(this._save){widget.system("/bin/mkdir cache", null);this._fileName = this._url.split("/").pop().replace(/\W/g, "");this._fileName += "." + this._responseHeaders["Content-Type"].replace(/[\r\n]/g, "").split("/").pop()
+delete query.I;query.o = "cache/" + this._fileName;system = widget.system(dojo.hostenv.CurlRequest._formatCall(query, this._url), null);if(!system.errorString){this.responseText = "cache/" + this._fileName;}}else if(this._method == "HEAD"){this.responseText = this._responseHeader;}}
+this.readyState = 4;if(this.onreadystatechange){this.onreadystatechange.call(this);}}
+dojo.hostenv.CurlRequest._formatCall = function(query, url){var call = ["/usr/bin/curl"];for(var key in query){if(query[key] != ""){call.push("-" + key + " '" + query[key].replace(/'/g, "\'") + "'");}else{call.push("-" + key);}}
+call.push("'" + url.replace(/'/g, "\'") + "'");return call.join(" ");}
+dojo.hostenv.exit = function(){if(widget.system){widget.system("/bin/rm -rf cache/*", null);}}

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_dashboard.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_jsc.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_jsc.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_jsc.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_jsc.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,8 @@
+
+dojo.hostenv.name_ = 'jsc';if((typeof ScriptEngineMajorVersion != 'function')||(ScriptEngineMajorVersion() < 7)){dojo.raise("attempt to use JScript .NET host environment with inappropriate ScriptEngine");}
+import System;dojo.hostenv.getText = function(uri){if(!System.IO.File.Exists(uri)){return 0;}
+var reader = new System.IO.StreamReader(uri);var contents : String = reader.ReadToEnd();return contents;}
+dojo.hostenv.loadUri = function(uri){var contents = this.getText(uri);if(!contents){dojo.raise("got no back contents from uri '" + uri + "': " + contents);}
+var value = dj_eval(contents);dojo.debug("jsc eval of contents returned: ", value);return 1;}
+dojo.hostenv.println = function(s){print(s);}
+dojo.hostenv.getLibraryScriptUri = function(){return System.Environment.GetCommandLineArgs()[0];}

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_jsc.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_rhino.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_rhino.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_rhino.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_rhino.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,26 @@
+
+dojo.hostenv.println=function(line){if(arguments.length > 0){print(arguments[0]);for(var i=1; i<arguments.length; i++){var valid=false;for (var p in arguments[i]){valid=true;break;}
+if(valid){dojo.debugShallow(arguments[i]);}}
+} else {print(line);}}
+dojo.locale = dojo.locale || java.util.Locale.getDefault().toString().replace('_','-').toLowerCase();dojo.render.name = dojo.hostenv.name_ = 'rhino';dojo.hostenv.getVersion = function() {return version();};if (dj_undef("byId")) {dojo.byId = function(id, doc){if(id && (typeof id == "string" || id instanceof String)){if(!doc){ doc = document; }
+return doc.getElementById(id);}
+return id;}}
+dojo.hostenv.loadUri = function(uri, cb){try{var local = (new java.io.File(uri)).exists();if(!local){try{var stream = (new java.net.URL(uri)).openStream();stream.close();}catch(e){return false;}}
+if(cb){var contents = (local ? readText : readUri)(uri, "UTF-8");cb(eval('('+contents+')'));}else{load(uri);}
+return true;}catch(e){dojo.debug("rhino load('" + uri + "') failed. Exception: " + e);return false;}}
+dojo.hostenv.exit = function(exitcode){quit(exitcode);}
+function dj_rhino_current_script_via_java(depth) {var optLevel = Packages.org.mozilla.javascript.Context.getCurrentContext().getOptimizationLevel();var caw = new java.io.CharArrayWriter();var pw = new java.io.PrintWriter(caw);var exc = new java.lang.Exception();var s = caw.toString();var matches = s.match(/[^\(]*\.js\)/gi);if(!matches){throw Error("cannot parse printStackTrace output: " + s);}
+var fname = ((typeof depth != 'undefined')&&(depth)) ? matches[depth + 1] : matches[matches.length - 1];var fname = matches[3];if(!fname){ fname = matches[1]; }
+if (!fname){ throw Error("could not find js file in printStackTrace output: " + s); }
+return fname;}
+function readText(path, encoding){encoding = encoding || "utf-8";var jf = new java.io.File(path);var is = new java.io.FileInputStream(jf);return dj_readInputStream(is, encoding);}
+function readUri(uri, encoding){var conn = (new java.net.URL(uri)).openConnection();encoding = encoding || conn.getContentEncoding() || "utf-8";var is = conn.getInputStream();return dj_readInputStream(is, encoding);}
+function dj_readInputStream(is, encoding){var input = new java.io.BufferedReader(new java.io.InputStreamReader(is, encoding));try {var sb = new java.lang.StringBuffer();var line = "";while((line = input.readLine()) !== null){sb.append(line);sb.append(java.lang.System.getProperty("line.separator"));}
+return sb.toString();} finally {input.close();}}
+if(!djConfig.libraryScriptUri.length){try{djConfig.libraryScriptUri = dj_rhino_current_script_via_java(1);}catch(e){if(djConfig["isDebug"]){print("\n");print("we have no idea where Dojo is located.");print("Please try loading rhino in a non-interpreted mode or set a");print("\n\tdjConfig.libraryScriptUri\n");print("Setting the dojo path to './'");print("This is probably wrong!");print("\n");print("Dojo will try to load anyway");}
+djConfig.libraryScriptUri = "./";}}
+dojo.doc = function(){return document;}
+dojo.body = function(){return document.body;}
+function setTimeout(func, delay){var def={sleepTime:delay,hasSlept:false,run:function(){if (!this.hasSlept){this.hasSlept=true;java.lang.Thread.currentThread().sleep(this.sleepTime);}
+try {func();} catch(e){dojo.debug("Error running setTimeout thread:" + e);}}
+};var runnable=new java.lang.Runnable(def);var thread=new java.lang.Thread(runnable);thread.start();}

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_rhino.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_spidermonkey.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_spidermonkey.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_spidermonkey.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_spidermonkey.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,10 @@
+
+dojo.hostenv.name_ = 'spidermonkey';dojo.hostenv.println = print;dojo.hostenv.exit = function(exitcode){quit(exitcode);}
+dojo.hostenv.getVersion = function(){ return version(); }
+if(typeof line2pc == 'undefined'){dojo.raise("attempt to use SpiderMonkey host environment when no 'line2pc' global");}
+function dj_spidermonkey_current_file(depth){var s = '';try{throw Error("whatever");}catch(e){s = e.stack;}
+var matches = s.match(/[^@]*\.js/gi);if(!matches){dojo.raise("could not parse stack string: '" + s + "'");}
+var fname = (typeof depth != 'undefined' && depth) ? matches[depth + 1] : matches[matches.length - 1];if(!fname){dojo.raise("could not find file name in stack string '" + s + "'");}
+return fname;}
+if(!dojo.hostenv.library_script_uri_){dojo.hostenv.library_script_uri_ = dj_spidermonkey_current_file(0);}
+dojo.hostenv.loadUri = function(uri){var ok = load(uri);return 1;}

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_spidermonkey.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_svg.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_svg.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_svg.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_svg.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,25 @@
+
+if(typeof window == 'undefined'){dojo.raise("attempt to use adobe svg hostenv when no window object");}
+dojo.debug = function(){if (!djConfig.isDebug) { return; }
+var args = arguments;var isJUM = dj_global["jum"];var s = isJUM ? "": "DEBUG: ";for (var i = 0; i < args.length; ++i){ s += args[i]; }
+if (isJUM){jum.debug(s);} else{dojo.hostenv.println(s);}};dojo.render.name = navigator.appName;dojo.render.ver = parseFloat(navigator.appVersion, 10);switch(navigator.platform){case "MacOS":
+dojo.render.os.osx =  true;break;case "Linux":
+dojo.render.os.linux =  true;break;case "Windows":
+dojo.render.os.win =  true;break;default:
+dojo.render.os.linux = true;break;};dojo.render.svg.capable = true;dojo.render.svg.support.builtin = true;dojo.render.svg.moz = ((navigator.userAgent.indexOf("Gecko") >= 0) && (!((navigator.appVersion.indexOf("Konqueror") >= 0) || (navigator.appVersion.indexOf("Safari") >= 0))));dojo.render.svg.adobe = (window.parseXML != null);dojo.hostenv.startPackage("dojo.hostenv");dojo.hostenv.println = function(s){try {var ti = document.createElement("text");ti.setAttribute("x","50");ti.setAttribute("y", (25 + 15 * document.getElementsByTagName("text").length));ti.appendChild(document.createTextNode(s));document.documentElement.appendChild(ti);} catch(e){ }};dojo.hostenv.name_ = "svg";dojo.hostenv.registerModulePath = function(module, prefix){ };dojo.hostenv.getModulePrefix = function(module){ };dojo.hostenv.getTextStack = [];dojo.hostenv.loadUriStack = [];dojo.hostenv.loadedUris = [];dojo.hostenv.modules_ = {};dojo.hostenv.modulesLoadedFired = false;dojo.hostenv.modulesLoadedListeners
  = [];dojo.hostenv.getText = function(uri, cb, data){if (!cb) var cb = function(result){ window.alert(result); };if (!data) {window.getUrl(uri, cb);} else {window.postUrl(uri, data, cb);}};dojo.hostenv.getLibaryScriptUri = function(){ };dojo.hostenv.loadUri = function(uri){ };dojo.hostenv.loadUriAndCheck = function(uri, module){ };dojo.hostenv.loadModule = function(moduleName){var a = moduleName.split(".");var currentObj = window;var s = [];for (var i = 0; i < a.length; i++){if (a[i] == "*") continue;s.push(a[i]);if (!currentObj[a[i]]){dojo.raise("dojo.require('" + moduleName + "'): module does not exist.");} else currentObj = currentObj[a[i]];}
+return;};dojo.hostenv.startPackage = function(moduleName){var a = moduleName.split(".");var currentObj = window;var s = [];for (var i = 0; i < a.length; i++){if (a[i] == "*") continue;s.push(a[i]);if (!currentObj[a[i]]) currentObj[a[i]] = {};currentObj = currentObj[a[i]];}
+return;};if (window.parseXML){window.XMLSerialzer = function(){function nodeToString(n, a) {function fixText(s) { return String(s).replace(/\&/g, "&amp;").replace(/>/g, "&gt;").replace(/</g, "&lt;"); }
+function fixAttribute(s) { return fixText(s).replace(/\"/g, "&quot;"); }
+switch (n.nodeType) {case 1:{var name = n.nodeName;a.push("<" + name);for (var i = 0; i < n.attributes.length; i++) {if (n.attributes.item(i).specified) {a.push(" " + n.attributes.item(i).nodeName.toLowerCase() + "=\"" + fixAttribute(n.attributes.item(i).nodeValue) + "\"");}}
+if (n.canHaveChildren || n.hasChildNodes()) {a.push(">");for (var i = 0; i < n.childNodes.length; i++) nodeToString(n.childNodes.item(i), a);a.push("</" + name + ">\n");} else a.push(" />\n");break;}
+case 3: {a.push(fixText(n.nodeValue));break;}
+case 4: {a.push("<![CDA" + "TA[\n" + n.nodeValue + "\n]" + "]>");break;}
+case 7:{a.push(n.nodeValue);if (/(^<\?xml)|(^<\!DOCTYPE)/.test(n.nodeValue)) a.push("\n");break;}
+case 8:{a.push("<!-- " + n.nodeValue + " -->\n");break;}
+case 9:
+case 11:{for (var i = 0; i < n.childNodes.length; i++) nodeToString(n.childNodes.item(i), a);break;}
+default:{a.push("<!--\nNot Supported:\n\n" + "nodeType: " + n.nodeType + "\nnodeName: " + n.nodeName + "\n-->");}}
+}
+this.serializeToString = function(node){var a = [];nodeToString(node, a);return a.join("");};};window.DOMParser = function(){this.parseFromString = function(s){return parseXML(s, window.document);}};window.XMLHttpRequest = function(){var uri = null;var method = "POST";var isAsync = true;var cb = function(d){this.responseText = d.content;try {this.responseXML = parseXML(this.responseText, window.document);} catch(e){}
+this.status = "200";this.statusText = "OK";if (!d.success) {this.status = "500";this.statusText = "Internal Server Error";}
+this.onload();this.onreadystatechange();};this.onload = function(){};this.readyState = 4;this.onreadystatechange = function(){};this.status = 0;this.statusText = "";this.responseBody = null;this.responseStream = null;this.responseXML = null;this.responseText = null;this.abort = function(){ return; };this.getAllResponseHeaders = function(){ return []; };this.getResponseHeader = function(n){ return null; };this.setRequestHeader = function(nm, val){ };this.open = function(meth, url, async){method = meth;uri = url;};this.send = function(data){var d = data || null;if (method == "GET") getURL(uri, cb);else postURL(uri, data, cb);};};}

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_svg.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_wsh.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_wsh.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_wsh.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_wsh.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,6 @@
+
+dojo.hostenv.name_ = 'wsh';if(typeof WScript == 'undefined'){dojo.raise("attempt to use WSH host environment when no WScript global");}
+dojo.hostenv.println = WScript.Echo;dojo.hostenv.getCurrentScriptUri = function(){return WScript.ScriptFullName();}
+dojo.hostenv.getText = function(fpath){var fso = new ActiveXObject("Scripting.FileSystemObject");var istream = fso.OpenTextFile(fpath, 1);if(!istream){return null;}
+var contents = istream.ReadAll();istream.Close();return contents;}
+dojo.hostenv.exit = function(exitcode){ WScript.Quit(exitcode); }

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/hostenv_wsh.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/__package__.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/__package__.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/__package__.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/__package__.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,3 @@
+
+dojo.kwCompoundRequire({common: [ "dojo.html.common","dojo.html.style" ]
+});dojo.provide("dojo.html.*");
\ No newline at end of file

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/__package__.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/color.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/color.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/color.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/color.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,5 @@
+
+dojo.require("dojo.html.style");dojo.provide("dojo.html.color");dojo.require("dojo.gfx.color");dojo.require("dojo.lang.common");dojo.html.getBackgroundColor = function(node){node = dojo.byId(node);var color;do{color = dojo.html.getStyle(node, "background-color");if(color.toLowerCase() == "rgba(0, 0, 0, 0)") { color = "transparent"; }
+if(node == document.getElementsByTagName("body")[0]) { node = null; break; }
+node = node.parentNode;}while(node && dojo.lang.inArray(["transparent", ""], color));if(color == "transparent"){color = [255, 255, 255, 0];}else{color = dojo.gfx.color.extractRGB(color);}
+return color;}

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/color.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/common.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/common.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/common.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/common.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,22 @@
+
+dojo.provide("dojo.html.common");dojo.require("dojo.lang.common");dojo.require("dojo.dom");dojo.lang.mixin(dojo.html, dojo.dom);dojo.html.getEventTarget = function(evt){if(!evt) { evt = dojo.global().event || {}};var t = (evt.srcElement ? evt.srcElement : (evt.target ? evt.target : null));while((t)&&(t.nodeType!=1)){ t = t.parentNode; }
+return t;}
+dojo.html.getViewport = function(){var _window = dojo.global();var _document = dojo.doc();var w = 0;var h = 0;if(dojo.render.html.mozilla){w = _document.documentElement.clientWidth;h = _window.innerHeight;}else if(!dojo.render.html.opera && _window.innerWidth){w = _window.innerWidth;h = _window.innerHeight;}else if (!dojo.render.html.opera && dojo.exists("documentElement.clientWidth", _document)){var w2 = _document.documentElement.clientWidth;if(!w || w2 && w2 < w) {w = w2;}
+h = _document.documentElement.clientHeight;}else if (dojo.body().clientWidth){w = dojo.body().clientWidth;h = dojo.body().clientHeight;}
+return { width: w, height: h };}
+dojo.html.getScroll = function(){var _window = dojo.global();var _document = dojo.doc();var top = _window.pageYOffset || _document.documentElement.scrollTop || dojo.body().scrollTop || 0;var left = _window.pageXOffset || _document.documentElement.scrollLeft || dojo.body().scrollLeft || 0;return {top: top,left: left,offset:{ x: left, y: top }};}
+dojo.html.getParentByType = function(node, type) {var _document = dojo.doc();var parent = dojo.byId(node);type = type.toLowerCase();while((parent)&&(parent.nodeName.toLowerCase()!=type)){if(parent==(_document["body"]||_document["documentElement"])){return null;}
+parent = parent.parentNode;}
+return parent;}
+dojo.html.getAttribute = function(node, attr){node = dojo.byId(node);if((!node)||(!node.getAttribute)){return null;}
+var ta = typeof attr == 'string' ? attr : new String(attr);var v = node.getAttribute(ta.toUpperCase());if((v)&&(typeof v == 'string')&&(v!="")){return v;}
+if(v && v.value){return v.value;}
+if((node.getAttributeNode)&&(node.getAttributeNode(ta))){return (node.getAttributeNode(ta)).value;}else if(node.getAttribute(ta)){return node.getAttribute(ta);}else if(node.getAttribute(ta.toLowerCase())){return node.getAttribute(ta.toLowerCase());}
+return null;}
+dojo.html.hasAttribute = function(node, attr){return dojo.html.getAttribute(dojo.byId(node), attr) ? true : false;}
+dojo.html.getCursorPosition = function(e){e = e || dojo.global().event;var cursor = {x:0, y:0};if(e.pageX || e.pageY){cursor.x = e.pageX;cursor.y = e.pageY;}else{var de = dojo.doc().documentElement;var db = dojo.body();cursor.x = e.clientX + ((de||db)["scrollLeft"]) - ((de||db)["clientLeft"]);cursor.y = e.clientY + ((de||db)["scrollTop"]) - ((de||db)["clientTop"]);}
+return cursor;}
+dojo.html.isTag = function(node) {node = dojo.byId(node);if(node && node.tagName) {for (var i=1; i<arguments.length; i++){if (node.tagName.toLowerCase()==String(arguments[i]).toLowerCase()){return String(arguments[i]).toLowerCase();}}
+}
+return "";}
+if(dojo.render.html.ie && !dojo.render.html.ie70){if(window.location.href.substr(0,6).toLowerCase() != "https:"){(function(){var xscript = dojo.doc().createElement('script');xscript.src = "javascript:'dojo.html.createExternalElement=function(doc, tag){ return doc.createElement(tag); }'";dojo.doc().getElementsByTagName("head")[0].appendChild(xscript);})();}}else{dojo.html.createExternalElement = function(doc, tag){return doc.createElement(tag);}}

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/common.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/display.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/display.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/display.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/display.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,25 @@
+
+dojo.provide("dojo.html.display");dojo.require("dojo.html.style");dojo.html._toggle = function(node, tester, setter){node = dojo.byId(node);setter(node, !tester(node));return tester(node);}
+dojo.html.show = function(node){node = dojo.byId(node);if(dojo.html.getStyleProperty(node, 'display')=='none'){var djDisplayCache = dojo.html.getAttribute('djDisplayCache');dojo.html.setStyle(node, 'display', (djDisplayCache||''));node.removeAttribute('djDisplayCache');}}
+dojo.html.hide = function(node){node = dojo.byId(node);var djDisplayCache = dojo.html.getAttribute('djDisplayCache');if(djDisplayCache == null){var d = dojo.html.getStyleProperty(node, 'display')
+if(d!='none'){node.setAttribute('djDisplayCache', d);}}
+dojo.html.setStyle(node, 'display', 'none');}
+dojo.html.setShowing = function(node, showing){dojo.html[(showing ? 'show' : 'hide')](node);}
+dojo.html.isShowing = function(node){return (dojo.html.getStyleProperty(node, 'display') != 'none');}
+dojo.html.toggleShowing = function(node){return dojo.html._toggle(node, dojo.html.isShowing, dojo.html.setShowing);}
+dojo.html.displayMap = { tr: '', td: '', th: '', img: 'inline', span: 'inline', input: 'inline', button: 'inline' };dojo.html.suggestDisplayByTagName = function(node){node = dojo.byId(node);if(node && node.tagName){var tag = node.tagName.toLowerCase();return (tag in dojo.html.displayMap ? dojo.html.displayMap[tag] : 'block');}}
+dojo.html.setDisplay = function(node, display){dojo.html.setStyle(node, 'display', ((display instanceof String || typeof display == "string") ? display : (display ? dojo.html.suggestDisplayByTagName(node) : 'none')));}
+dojo.html.isDisplayed = function(node){return (dojo.html.getComputedStyle(node, 'display') != 'none');}
+dojo.html.toggleDisplay = function(node){return dojo.html._toggle(node, dojo.html.isDisplayed, dojo.html.setDisplay);}
+dojo.html.setVisibility = function(node, visibility){dojo.html.setStyle(node, 'visibility', ((visibility instanceof String || typeof visibility == "string") ? visibility : (visibility ? 'visible' : 'hidden')));}
+dojo.html.isVisible = function(node){return (dojo.html.getComputedStyle(node, 'visibility') != 'hidden');}
+dojo.html.toggleVisibility = function(node){return dojo.html._toggle(node, dojo.html.isVisible, dojo.html.setVisibility);}
+dojo.html.setOpacity = function(node, opacity, dontFixOpacity){node = dojo.byId(node);var h = dojo.render.html;if(!dontFixOpacity){if( opacity >= 1.0){if(h.ie){dojo.html.clearOpacity(node);return;}else{opacity = 0.999999;}}else if( opacity < 0.0){ opacity = 0; }}
+if(h.ie){if(node.nodeName.toLowerCase() == "tr"){var tds = node.getElementsByTagName("td");for(var x=0; x<tds.length; x++){tds[x].style.filter = "Alpha(Opacity="+opacity*100+")";}}
+node.style.filter = "Alpha(Opacity="+opacity*100+")";}else if(h.moz){node.style.opacity = opacity;node.style.MozOpacity = opacity;}else if(h.safari){node.style.opacity = opacity;node.style.KhtmlOpacity = opacity;}else{node.style.opacity = opacity;}}
+dojo.html.clearOpacity = function(node){node = dojo.byId(node);var ns = node.style;var h = dojo.render.html;if(h.ie){try {if( node.filters && node.filters.alpha ){ns.filter = "";}} catch(e) {}}else if(h.moz){ns.opacity = 1;ns.MozOpacity = 1;}else if(h.safari){ns.opacity = 1;ns.KhtmlOpacity = 1;}else{ns.opacity = 1;}}
+dojo.html.getOpacity = function(node){node = dojo.byId(node);var h = dojo.render.html;if(h.ie){var opac = (node.filters && node.filters.alpha &&
+typeof node.filters.alpha.opacity == "number"
+? node.filters.alpha.opacity : 100) / 100;}else{var opac = node.style.opacity || node.style.MozOpacity ||
+node.style.KhtmlOpacity || 1;}
+return opac >= 0.999999 ? 1.0 : Number(opac);}

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/display.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/iframe.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/iframe.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/iframe.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/iframe.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,18 @@
+
+dojo.provide("dojo.html.iframe");dojo.require("dojo.html.util");dojo.html.iframeContentWindow = function(iframe_el) {var win = dojo.html.getDocumentWindow(dojo.html.iframeContentDocument(iframe_el)) ||
+dojo.html.iframeContentDocument(iframe_el).__parent__ ||
+(iframe_el.name && document.frames[iframe_el.name]) || null;return win;}
+dojo.html.iframeContentDocument = function(iframe_el){var doc = iframe_el.contentDocument
+|| ((iframe_el.contentWindow)&&(iframe_el.contentWindow.document))
+|| ((iframe_el.name)&&(document.frames[iframe_el.name])&&(document.frames[iframe_el.name].document))
+|| null;return doc;}
+dojo.html.BackgroundIframe = function(node) {if(dojo.render.html.ie55 || dojo.render.html.ie60) {var html="<iframe src='javascript:false'"
++ " style='position: absolute; left: 0px; top: 0px; width: 100%; height: 100%;"
++ "z-index: -1; filter:Alpha(Opacity=\"0\");' "
++ ">";this.iframe = dojo.doc().createElement(html);this.iframe.tabIndex = -1;if(node){node.appendChild(this.iframe);this.domNode=node;}else{dojo.body().appendChild(this.iframe);this.iframe.style.display="none";}}
+}
+dojo.lang.extend(dojo.html.BackgroundIframe, {iframe: null,onResized: function(){if(this.iframe && this.domNode && this.domNode.parentNode){var outer = dojo.html.getMarginBox(this.domNode);if (outer.width  == 0 || outer.height == 0 ){dojo.lang.setTimeout(this, this.onResized, 100);return;}
+this.iframe.style.width = outer.width + "px";this.iframe.style.height = outer.height + "px";}},size: function(node) {if(!this.iframe){ return; }
+var coords = dojo.html.toCoordinateObject(node, true, dojo.html.boxSizing.BORDER_BOX);with(this.iframe.style){width = coords.width + "px";height = coords.height + "px";left = coords.left + "px";top = coords.top + "px";}},setZIndex: function(node){if(!this.iframe){ return; }
+if(dojo.dom.isNode(node)){this.iframe.style.zIndex = dojo.html.getStyle(node, "z-index") - 1;}else if(!isNaN(node)){this.iframe.style.zIndex = node;}},show: function(){if(this.iframe){this.iframe.style.display = "block";}},hide: function(){if(this.iframe){this.iframe.style.display = "none";}},remove: function(){if(this.iframe){dojo.html.removeNode(this.iframe, true);delete this.iframe;this.iframe=null;}}
+});
\ No newline at end of file

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/iframe.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowB.png
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowB.png?view=auto&rev=498423
==============================================================================
Binary file - no diff available.

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowB.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowBL.png
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowBL.png?view=auto&rev=498423
==============================================================================
Binary file - no diff available.

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowBL.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowBR.png
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowBR.png?view=auto&rev=498423
==============================================================================
Binary file - no diff available.

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowBR.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowL.png
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowL.png?view=auto&rev=498423
==============================================================================
Binary file - no diff available.

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowL.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowR.png
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowR.png?view=auto&rev=498423
==============================================================================
Binary file - no diff available.

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowR.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowT.png
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowT.png?view=auto&rev=498423
==============================================================================
Binary file - no diff available.

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowT.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowTL.png
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowTL.png?view=auto&rev=498423
==============================================================================
Binary file - no diff available.

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowTL.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowTR.png
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowTR.png?view=auto&rev=498423
==============================================================================
Binary file - no diff available.

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/images/shadowTR.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/layout.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/layout.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/layout.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/layout.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,94 @@
+
+dojo.provide("dojo.html.layout");dojo.require("dojo.html.common");dojo.require("dojo.html.style");dojo.require("dojo.html.display");dojo.html.sumAncestorProperties = function(node, prop){node = dojo.byId(node);if(!node){ return 0; }
+var retVal = 0;while(node){if(dojo.html.getComputedStyle(node, 'position') == 'fixed'){return 0;}
+var val = node[prop];if(val){retVal += val - 0;if(node==dojo.body()){ break; }}
+node = node.parentNode;}
+return retVal;}
+dojo.html.setStyleAttributes = function(node, attributes) {node = dojo.byId(node);var splittedAttribs=attributes.replace(/(;)?\s*$/, "").split(";");for(var i=0; i<splittedAttribs.length; i++){var nameValue=splittedAttribs[i].split(":");var name=nameValue[0].replace(/\s*$/, "").replace(/^\s*/, "").toLowerCase();var value=nameValue[1].replace(/\s*$/, "").replace(/^\s*/, "");switch(name){case "opacity":
+dojo.html.setOpacity(node, value);break;case "content-height":
+dojo.html.setContentBox(node, {height: value});break;case "content-width":
+dojo.html.setContentBox(node, {width: value});break;case "outer-height":
+dojo.html.setMarginBox(node, {height: value});break;case "outer-width":
+dojo.html.setMarginBox(node, {width: value});break;default:
+node.style[dojo.html.toCamelCase(name)]=value;}}
+}
+dojo.html.boxSizing = {MARGIN_BOX: "margin-box",BORDER_BOX: "border-box",PADDING_BOX: "padding-box",CONTENT_BOX: "content-box"
+};dojo.html.getAbsolutePosition = dojo.html.abs = function(node, includeScroll, boxType){node = dojo.byId(node);var ownerDocument = dojo.doc();var ret = {x: 0,y: 0
+};var bs = dojo.html.boxSizing;if(!boxType) { boxType = bs.CONTENT_BOX; }
+var nativeBoxType = 2;var targetBoxType;switch(boxType){case bs.MARGIN_BOX:
+targetBoxType = 3;break;case bs.BORDER_BOX:
+targetBoxType = 2;break;case bs.PADDING_BOX:
+default:
+targetBoxType = 1;break;case bs.CONTENT_BOX:
+targetBoxType = 0;break;}
+var h = dojo.render.html;var db = ownerDocument["body"]||ownerDocument["documentElement"];if(h.ie){with(node.getBoundingClientRect()){ret.x = left-2;ret.y = top-2;}}else if(ownerDocument['getBoxObjectFor']){nativeBoxType = 1;try{var bo = ownerDocument.getBoxObjectFor(node);ret.x = bo.x - dojo.html.sumAncestorProperties(node, "scrollLeft");ret.y = bo.y - dojo.html.sumAncestorProperties(node, "scrollTop");}catch(e){}}else{if(node["offsetParent"]){var endNode;if((h.safari)&&
+(node.style.getPropertyValue("position") == "absolute")&&
+(node.parentNode == db)){endNode = db;}else{endNode = db.parentNode;}
+if(node.parentNode != db){var nd = node;if(dojo.render.html.opera){ nd = db; }
+ret.x -= dojo.html.sumAncestorProperties(nd, "scrollLeft");ret.y -= dojo.html.sumAncestorProperties(nd, "scrollTop");}
+var curnode = node;do{var n = curnode["offsetLeft"];if(!h.opera || n>0){ret.x += isNaN(n) ? 0 : n;}
+var m = curnode["offsetTop"];ret.y += isNaN(m) ? 0 : m;curnode = curnode.offsetParent;}while((curnode != endNode)&&(curnode != null));}else if(node["x"]&&node["y"]){ret.x += isNaN(node.x) ? 0 : node.x;ret.y += isNaN(node.y) ? 0 : node.y;}}
+if(includeScroll){var scroll = dojo.html.getScroll();ret.y += scroll.top;ret.x += scroll.left;}
+var extentFuncArray=[dojo.html.getPaddingExtent, dojo.html.getBorderExtent, dojo.html.getMarginExtent];if(nativeBoxType > targetBoxType){for(var i=targetBoxType;i<nativeBoxType;++i){ret.y += extentFuncArray[i](node, 'top');ret.x += extentFuncArray[i](node, 'left');}}else if(nativeBoxType < targetBoxType){for(var i=targetBoxType;i>nativeBoxType;--i){ret.y -= extentFuncArray[i-1](node, 'top');ret.x -= extentFuncArray[i-1](node, 'left');}}
+ret.top = ret.y;ret.left = ret.x;return ret;}
+dojo.html.isPositionAbsolute = function(node){return (dojo.html.getComputedStyle(node, 'position') == 'absolute');}
+dojo.html._getComponentPixelValues = function(node, componentPrefix,getPixels, autoIsZero){var sides = ["top", "bottom", "left", "right"];var obj = {};for (var i in sides){side = sides[i];obj[side] = getPixels(node, componentPrefix+side, autoIsZero);}
+obj.width = obj.left + obj.right;obj.height = obj.top + obj.bottom;return obj;}
+dojo.html.getMargin = function(node){return dojo.html._getComponentPixelValues(node, "margin-", dojo.html.getPixelValue, dojo.html.isPositionAbsolute(node));}
+dojo.html.getBorder = function(node){return dojo.html._getComponentPixelValues(node, "", dojo.html.getBorderExtent);}
+dojo.html.getBorderExtent = function(node, side){return (dojo.html.getStyle(node, 'border-' + side + '-style') == 'none' ? 0 : dojo.html.getPixelValue(node, 'border-' + side + '-width'));}
+dojo.html.getMarginExtent = function(node, side){return dojo.html.getPixelValue(node, "margin-" + side, dojo.html.isPositionAbsolute(node));}
+dojo.html.getPaddingExtent = function(node, side){return dojo.html.getPixelValue(node, "padding-" + side, true);}
+dojo.html.getPadding = function(node){return dojo.html._getComponentPixelValues(node, "padding-", dojo.html.getPixelValue, true);}
+dojo.html.getPadBorder = function(node){var pad = dojo.html.getPadding(node);var border = dojo.html.getBorder(node);return { width: pad.width + border.width, height: pad.height + border.height };}
+dojo.html.getBoxSizing = function(node){var h = dojo.render.html;var bs = dojo.html.boxSizing;if(((h.ie)||(h.opera)) && node.nodeName!="IMG"){var cm = document["compatMode"];if((cm == "BackCompat")||(cm == "QuirksMode")){return bs.BORDER_BOX;}else{return bs.CONTENT_BOX;}}else{if(arguments.length == 0){ node = document.documentElement; }
+var sizing = dojo.html.getStyle(node, "-moz-box-sizing");if(!sizing){ sizing = dojo.html.getStyle(node, "box-sizing"); }
+return (sizing ? sizing : bs.CONTENT_BOX);}}
+dojo.html.isBorderBox = function(node){return (dojo.html.getBoxSizing(node) == dojo.html.boxSizing.BORDER_BOX);}
+dojo.html.getBorderBox = function(node){node = dojo.byId(node);return { width: node.offsetWidth, height: node.offsetHeight };}
+dojo.html.getPaddingBox = function(node){var box = dojo.html.getBorderBox(node);var border = dojo.html.getBorder(node);return {width: box.width - border.width,height:box.height - border.height
+};}
+dojo.html.getContentBox = function(node){node = dojo.byId(node);var padborder = dojo.html.getPadBorder(node);return {width: node.offsetWidth - padborder.width,height: node.offsetHeight - padborder.height
+};}
+dojo.html.setContentBox = function(node, args){node = dojo.byId(node);var width = 0; var height = 0;var isbb = dojo.html.isBorderBox(node);var padborder = (isbb ? dojo.html.getPadBorder(node) : { width: 0, height: 0});var ret = {};if(typeof args.width != "undefined"){width = args.width + padborder.width;ret.width = dojo.html.setPositivePixelValue(node, "width", width);}
+if(typeof args.height != "undefined"){height = args.height + padborder.height;ret.height = dojo.html.setPositivePixelValue(node, "height", height);}
+return ret;}
+dojo.html.getMarginBox = function(node){var borderbox = dojo.html.getBorderBox(node);var margin = dojo.html.getMargin(node);return { width: borderbox.width + margin.width, height: borderbox.height + margin.height };}
+dojo.html.setMarginBox = function(node, args){node = dojo.byId(node);var width = 0; var height = 0;var isbb = dojo.html.isBorderBox(node);var padborder = (!isbb ? dojo.html.getPadBorder(node) : { width: 0, height: 0 });var margin = dojo.html.getMargin(node);var ret = {};if(typeof args.width != "undefined"){width = args.width - padborder.width;width -= margin.width;ret.width = dojo.html.setPositivePixelValue(node, "width", width);}
+if(typeof args.height != "undefined"){height = args.height - padborder.height;height -= margin.height;ret.height = dojo.html.setPositivePixelValue(node, "height", height);}
+return ret;}
+dojo.html.getElementBox = function(node, type){var bs = dojo.html.boxSizing;switch(type){case bs.MARGIN_BOX:
+return dojo.html.getMarginBox(node);case bs.BORDER_BOX:
+return dojo.html.getBorderBox(node);case bs.PADDING_BOX:
+return dojo.html.getPaddingBox(node);case bs.CONTENT_BOX:
+default:
+return dojo.html.getContentBox(node);}}
+dojo.html.toCoordinateObject = dojo.html.toCoordinateArray = function(coords, includeScroll, boxtype) {if(!coords.nodeType && !(coords instanceof String || typeof coords == "string") &&
+('width' in coords || 'height' in coords || 'left' in coords ||
+'x' in coords || 'top' in coords || 'y' in coords)){var ret = {left: coords.left||coords.x||0,top: coords.top||coords.y||0,width: coords.width||0,height: coords.height||0
+};}else{var node = dojo.byId(coords);var pos = dojo.html.abs(node, includeScroll, boxtype);var marginbox = dojo.html.getMarginBox(node);var ret = {left: pos.left,top: pos.top,width: marginbox.width,height: marginbox.height
+};}
+ret.x = ret.left;ret.y = ret.top;return ret;}
+dojo.html.setMarginBoxWidth = dojo.html.setOuterWidth = function(node, width){return dojo.html._callDeprecated("setMarginBoxWidth", "setMarginBox", arguments, "width");}
+dojo.html.setMarginBoxHeight = dojo.html.setOuterHeight = function(){return dojo.html._callDeprecated("setMarginBoxHeight", "setMarginBox", arguments, "height");}
+dojo.html.getMarginBoxWidth = dojo.html.getOuterWidth = function(){return dojo.html._callDeprecated("getMarginBoxWidth", "getMarginBox", arguments, null, "width");}
+dojo.html.getMarginBoxHeight = dojo.html.getOuterHeight = function(){return dojo.html._callDeprecated("getMarginBoxHeight", "getMarginBox", arguments, null, "height");}
+dojo.html.getTotalOffset = function(node, type, includeScroll){return dojo.html._callDeprecated("getTotalOffset", "getAbsolutePosition", arguments, null, type);}
+dojo.html.getAbsoluteX = function(node, includeScroll){return dojo.html._callDeprecated("getAbsoluteX", "getAbsolutePosition", arguments, null, "x");}
+dojo.html.getAbsoluteY = function(node, includeScroll){return dojo.html._callDeprecated("getAbsoluteY", "getAbsolutePosition", arguments, null, "y");}
+dojo.html.totalOffsetLeft = function(node, includeScroll){return dojo.html._callDeprecated("totalOffsetLeft", "getAbsolutePosition", arguments, null, "left");}
+dojo.html.totalOffsetTop = function(node, includeScroll){return dojo.html._callDeprecated("totalOffsetTop", "getAbsolutePosition", arguments, null, "top");}
+dojo.html.getMarginWidth = function(node){return dojo.html._callDeprecated("getMarginWidth", "getMargin", arguments, null, "width");}
+dojo.html.getMarginHeight = function(node){return dojo.html._callDeprecated("getMarginHeight", "getMargin", arguments, null, "height");}
+dojo.html.getBorderWidth = function(node){return dojo.html._callDeprecated("getBorderWidth", "getBorder", arguments, null, "width");}
+dojo.html.getBorderHeight = function(node){return dojo.html._callDeprecated("getBorderHeight", "getBorder", arguments, null, "height");}
+dojo.html.getPaddingWidth = function(node){return dojo.html._callDeprecated("getPaddingWidth", "getPadding", arguments, null, "width");}
+dojo.html.getPaddingHeight = function(node){return dojo.html._callDeprecated("getPaddingHeight", "getPadding", arguments, null, "height");}
+dojo.html.getPadBorderWidth = function(node){return dojo.html._callDeprecated("getPadBorderWidth", "getPadBorder", arguments, null, "width");}
+dojo.html.getPadBorderHeight = function(node){return dojo.html._callDeprecated("getPadBorderHeight", "getPadBorder", arguments, null, "height");}
+dojo.html.getBorderBoxWidth = dojo.html.getInnerWidth = function(){return dojo.html._callDeprecated("getBorderBoxWidth", "getBorderBox", arguments, null, "width");}
+dojo.html.getBorderBoxHeight = dojo.html.getInnerHeight = function(){return dojo.html._callDeprecated("getBorderBoxHeight", "getBorderBox", arguments, null, "height");}
+dojo.html.getContentBoxWidth = dojo.html.getContentWidth = function(){return dojo.html._callDeprecated("getContentBoxWidth", "getContentBox", arguments, null, "width");}
+dojo.html.getContentBoxHeight = dojo.html.getContentHeight = function(){return dojo.html._callDeprecated("getContentBoxHeight", "getContentBox", arguments, null, "height");}
+dojo.html.setContentBoxWidth = dojo.html.setContentWidth = function(node, width){return dojo.html._callDeprecated("setContentBoxWidth", "setContentBox", arguments, "width");}
+dojo.html.setContentBoxHeight = dojo.html.setContentHeight = function(node, height){return dojo.html._callDeprecated("setContentBoxHeight", "setContentBox", arguments, "height");}

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/layout.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/metrics.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/metrics.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/metrics.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/metrics.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,36 @@
+
+dojo.provide("dojo.html.metrics");dojo.require("dojo.html.layout");dojo.html.getScrollbar=function(){var scroll = document.createElement("div");scroll.style.width="100px";scroll.style.height="100px";scroll.style.overflow="scroll";scroll.style.position="absolute";scroll.style.top="-300px";scroll.style.left="0px"
+var test = document.createElement("div");test.style.width="400px";test.style.height="400px";scroll.appendChild(test);dojo.body().appendChild(scroll);var width=scroll.offsetWidth - scroll.clientWidth;dojo.body().removeChild(scroll);scroll.removeChild(test);scroll=test=null;return { width: width };};dojo.html.getFontMeasurements = function(){var heights = {'1em':0, '1ex':0, '100%':0, '12pt':0, '16px':0, 'xx-small':0, 'x-small':0,'small':0, 'medium':0, 'large':0, 'x-large':0, 'xx-large':0
+};if(dojo.render.html.ie){document.documentElement.style.fontSize="100%";}
+var div=document.createElement("div");div.style.position="absolute";div.style.left="-100px";div.style.top="0";div.style.width="30px";div.style.height="1000em";div.style.border="0";div.style.margin="0";div.style.padding="0";div.style.outline="0";div.style.lineHeight="1";div.style.overflow="hidden";dojo.body().appendChild(div);for(var p in heights){div.style.fontSize = p;heights[p] = Math.round(div.offsetHeight * 12/16) * 16/12 / 1000;}
+dojo.body().removeChild(div);div = null;return heights;};dojo.html._fontMeasurements = null;dojo.html.getCachedFontMeasurements = function(recalculate){if(recalculate || !dojo.html._fontMeasurements){dojo.html._fontMeasurements = dojo.html.getFontMeasurements();}
+return dojo.html._fontMeasurements;};dojo.html.onFontResize = function(){ };dojo.html._fontresize = function(){dojo.html.onFontResize();};dojo.html.initOnFontResize = function(){dojo.html.getFontMeasurements();dojo.html._metrics={};dojo.html._metrics.iframeNode = document.createElement('iframe');var s=dojo.html._metrics.iframeNode.style;s.position="absolute";s.width="5em";s.height="10em";s.top="-10000px";if(dojo.render.html.ie){dojo.html._metrics.iframeNode.onreadystatechange = function(){if(dojo.html._metrics.iframeNode.contentWindow.document.readyState == "complete"){dojo.html._metrics.iframeNode.onresize = Function('window.parent.dojo.html._fontresize()');}};} else {dojo.html._metrics.iframeNode.onload = function(){dojo.html._metrics.iframeNode.contentWindow.onresize = Function('window.parent.dojo.html._fontresize()');};}
+dojo.body().appendChild(dojo.html._metrics.iframeNode);};dojo.html.measureFragment = function(node, html, boxType){var clone = node.cloneNode(true);clone.innerHTML = html;node.parentNode.appendChild(clone);var ret = dojo.html.getElementBox(clone, boxType);node.parentNode.removeChild(clone);clone=null;return ret;};dojo.html.getFittedFragment = function(node, html){function cl(node){var element = document.createElement(node.tagName);element.id = node.id + "-clone";element.className = node.className;for (var j = 0; j < node.attributes.length; j++) {if (node.attributes[j].specified) {if (node.attributes[j].nodeName.toLowerCase() != "style" 
+&& node.attributes[j].nodeName.toLowerCase() != "edited" 
+&& node.attributes[j].nodeName.toLowerCase() != "contenteditable"
+&& node.attributes[j].nodeName.toLowerCase() != "id"
+&& node.attributes[j].nodeName.toLowerCase() != "class"
+){element.setAttribute(node.attributes[j].nodeName.toLowerCase(), node.attributes[j].nodeValue);}}
+}
+return element;}
+var height = dojo.html.getFontMeasurements()["16px"];var n=cl(node);n.style.width=dojo.html.getBorderBox(node).width+"px";n.style.height=(height+4)+"px";node.parentNode.appendChild(n);var rem = dojo.html.fitToElement(n, html);var ret = n.innerHTML;n.parentNode.removeChild(n);return ret;};dojo.html.fitToElement = function(node, html){function cl(node){var element = document.createElement(node.tagName);element.id = node.id + "-clone";element.className = node.className;for (var j = 0; j < node.attributes.length; j++) {if (node.attributes[j].specified) {if (node.attributes[j].nodeName.toLowerCase() != "style" 
+&& node.attributes[j].nodeName.toLowerCase() != "edited" 
+&& node.attributes[j].nodeName.toLowerCase() != "contenteditable"
+&& node.attributes[j].nodeName.toLowerCase() != "id"
+&& node.attributes[j].nodeName.toLowerCase() != "class"
+){element.setAttribute(node.attributes[j].nodeName.toLowerCase(), node.attributes[j].nodeValue);}}
+}
+return element;}
+var clone = cl(node);node.parentNode.appendChild(clone);var t=dojo.html.getBorderBox(node);clone.style.width = t.width+"px";var singletons = ["br","img", "hr", "input", "!--"];var chop = ["<BR>","<br>","<br/>","<br />","<p></p>","<P></P>"];var openTags = [];var str = html;var i = 0;var limit = str.length;var add = 0;var doLoop = true;clone.innerHTML = str;while (doLoop) {add = Math.round((limit - i) / 2);if (add <= 1) doLoop = false;i += add;clone.innerHTML = str.substr(0, i);if (clone.offsetHeight > t.height) {limit = i;i -= add;}}
+if (str.substr(0, i) != str) {var lastSpace = str.substr(0, i).lastIndexOf(" ");var lastNewLine = str.substr(0, i).lastIndexOf("\n");var lastGreater = str.substr(0, i).lastIndexOf(">");var lastLess = str.substr(0, i).lastIndexOf("<");if (lastLess <= lastGreater && lastNewLine == i - 1) i = i;else if (lastSpace != -1 && lastSpace > lastGreater && lastGreater > lastLess) i = lastSpace + 1;else if (lastLess > lastGreater) i = lastLess;else if (lastGreater != -1) i = lastGreater + 1;}
+str = str.substr(0, i);var ret = html.substr(str.length);var doPush = true;var tags = str.split("<");tags.shift();for (var j = 0; j < tags.length; j++) {tags[j] = tags[j].split(">")[0];if (tags[j].charAt(tags[j].length - 1) == "/"){ continue; }
+if (tags[j].charAt(0) != "/") {for (var k = 0; k < singletons.length; k++) {if (tags[j].split(" ")[0].toLowerCase() == singletons[k]){doPush = false;}}
+if (doPush){openTags.push(tags[j]);}
+doPush = true;} else {openTags.pop();}}
+for(var j=0; j<chop.length; j++){if(ret.charAt(0) == "\n"){ ret = ret.substr(1); }
+while(ret.indexOf(chop[j]) == 0){ret = ret.substr(chop[j].length);}}
+for(var j=openTags.length-1; j>=0; j--){if(str.lastIndexOf(openTags[j]) == (str.length-openTags[j].length-1)){str = str.substring(0, str.lastIndexOf(openTags[j]));} else {str += "</"+openTags[j]+">";}
+if(ret.length > 0){ret = "<"+openTags[j]+">"+ret;}}
+for(var j=0; j<chop.length; j++){if(ret.charAt(0) == "\n"){ ret = ret.substr(1); }
+while(ret.indexOf(chop[j]) == 0){ret = ret.substr(chop[j].length);}}
+node.innerHTML = str;clone.parentNode.removeChild(clone);clone = null;return ret;};
\ No newline at end of file

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/metrics.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/selection.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/selection.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/selection.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/selection.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,37 @@
+
+dojo.require("dojo.html.common");dojo.provide("dojo.html.selection");dojo.require("dojo.dom");dojo.require("dojo.lang.common");dojo.html.selectionType = {NONE : 0,TEXT : 1,CONTROL : 2
+};dojo.html.clearSelection = function(){var _window = dojo.global();var _document = dojo.doc();try{if(_window["getSelection"]){if(dojo.render.html.safari){_window.getSelection().collapse();}else{_window.getSelection().removeAllRanges();}}else if(_document.selection){if(_document.selection.empty){_document.selection.empty();}else if(_document.selection.clear){_document.selection.clear();}}
+return true;}catch(e){dojo.debug(e);return false;}}
+dojo.html.disableSelection = function(element){element = dojo.byId(element)||dojo.body();var h = dojo.render.html;if(h.mozilla){element.style.MozUserSelect = "none";}else if(h.safari){element.style.KhtmlUserSelect = "none";}else if(h.ie){element.unselectable = "on";}else{return false;}
+return true;}
+dojo.html.enableSelection = function(element){element = dojo.byId(element)||dojo.body();var h = dojo.render.html;if(h.mozilla){element.style.MozUserSelect = "";}else if(h.safari){element.style.KhtmlUserSelect = "";}else if(h.ie){element.unselectable = "off";}else{return false;}
+return true;}
+dojo.html.selectInputText = function(element){var _window = dojo.global();var _document = dojo.doc();element = dojo.byId(element);if(_document["selection"] && dojo.body()["createTextRange"]){var range = element.createTextRange();range.moveStart("character", 0);range.moveEnd("character", element.value.length);range.select();}else if(_window["getSelection"]){var selection = _window.getSelection();element.setSelectionRange(0, element.value.length);}
+element.focus();}
+dojo.lang.mixin(dojo.html.selection, {getType: function() {if(dojo.doc()["selection"]){return dojo.html.selectionType[dojo.doc().selection.type.toUpperCase()];}else{var stype = dojo.html.selectionType.TEXT;var oSel;try {oSel = dojo.global().getSelection();}
+catch (e) {}
+if(oSel && oSel.rangeCount==1){var oRange = oSel.getRangeAt(0);if (oRange.startContainer == oRange.endContainer && (oRange.endOffset - oRange.startOffset) == 1
+&& oRange.startContainer.nodeType != dojo.dom.TEXT_NODE) {stype = dojo.html.selectionType.CONTROL;}}
+return stype;}},isCollapsed: function() {var _window = dojo.global();var _document = dojo.doc();if(_document["selection"]){return _document.selection.createRange().text == "";}else if(_window["getSelection"]){var selection = _window.getSelection();if(dojo.lang.isString(selection)){return selection == "";}else{return selection.isCollapsed || selection.toString() == "";}}
+},getSelectedElement: function() {if ( dojo.html.selection.getType() == dojo.html.selectionType.CONTROL ){if(dojo.doc()["selection"]){var range = dojo.doc().selection.createRange();if ( range && range.item ){return dojo.doc().selection.createRange().item(0);}}else{var selection = dojo.global().getSelection();return selection.anchorNode.childNodes[ selection.anchorOffset ];}}
+},getParentElement: function() {if(dojo.html.selection.getType() == dojo.html.selectionType.CONTROL){var p = dojo.html.selection.getSelectedElement();if(p){ return p.parentNode; }}else{if(dojo.doc()["selection"]){return dojo.doc().selection.createRange().parentElement();}else{var selection = dojo.global().getSelection();if(selection){var node = selection.anchorNode;while ( node && node.nodeType != dojo.dom.ELEMENT_NODE ){node = node.parentNode;}
+return node;}}
+}},getSelectedText: function(){if(dojo.doc()["selection"]){if(dojo.html.selection.getType() == dojo.html.selectionType.CONTROL){return null;}
+return dojo.doc().selection.createRange().text;}else{var selection = dojo.global().getSelection();if(selection){return selection.toString();}}
+},getSelectedHtml: function(){if(dojo.doc()["selection"]){if(dojo.html.selection.getType() == dojo.html.selectionType.CONTROL){return null;}
+return dojo.doc().selection.createRange().htmlText;}else{var selection = dojo.global().getSelection();if(selection && selection.rangeCount){var frag = selection.getRangeAt(0).cloneContents();var div = document.createElement("div");div.appendChild(frag);return div.innerHTML;}
+return null;}},hasAncestorElement: function(tagName ){return (dojo.html.selection.getAncestorElement.apply(this, arguments) != null);},getAncestorElement: function(tagName ){var node = dojo.html.selection.getSelectedElement() || dojo.html.selection.getParentElement();return dojo.html.selection.getParentOfType(node, arguments);},getParentOfType: function(node, tags){while(node){if(dojo.html.selection.isTag(node, tags).length>0){return node;}
+node = node.parentNode;}
+return null;},isTag: function(node, tags) {if(node && node.tagName) {for (var i=0; i<tags.length; i++){if (node.tagName.toLowerCase()==String(tags[i]).toLowerCase()){return String(tags[i]).toLowerCase();}}
+}
+return "";},selectElement: function(element) {var _window = dojo.global();var _document = dojo.doc();element = dojo.byId(element);if(_document.selection && dojo.body().createTextRange){try{var range = dojo.body().createControlRange();range.addElement(element);range.select();}catch(e){dojo.html.selection.selectElementChildren(element);}}else if(_window["getSelection"]){var selection = _window.getSelection();if(selection["removeAllRanges"]){var range = _document.createRange() ;range.selectNode(element) ;selection.removeAllRanges() ;selection.addRange(range) ;}}
+},selectElementChildren: function(element){var _window = dojo.global();var _document = dojo.doc();element = dojo.byId(element);if(_document.selection && dojo.body().createTextRange){var range = dojo.body().createTextRange();range.moveToElementText(element);range.select();}else if(_window["getSelection"]){var selection = _window.getSelection();if(selection["setBaseAndExtent"]){selection.setBaseAndExtent(element, 0, element, element.innerText.length - 1);} else if(selection["selectAllChildren"]){selection.selectAllChildren(element);}}
+},getBookmark: function(){var bookmark;var _document = dojo.doc();if(_document["selection"]){var range = _document.selection.createRange();bookmark = range.getBookmark();}else{var selection;try {selection = dojo.global().getSelection();}
+catch (e) {}
+if(selection){var range = selection.getRangeAt(0);bookmark = range.cloneRange();}else{dojo.debug("No idea how to store the current selection for this browser!");}}
+return bookmark;},moveToBookmark: function(bookmark){var _document = dojo.doc();if(_document["selection"]){var range = _document.selection.createRange();range.moveToBookmark(bookmark);range.select();}else{var selection;try {selection = dojo.global().getSelection();}
+catch (e) {}
+if(selection && selection['removeAllRanges']){selection.removeAllRanges() ;selection.addRange(bookmark) ;}else{dojo.debug("No idea how to restore selection for this browser!");}}
+},collapse: function(beginning) {if(dojo.global()['getSelection']){var selection = dojo.global().getSelection();if(selection.removeAllRanges){if(beginning){selection.collapseToStart();}else{selection.collapseToEnd();}}else{dojo.global().getSelection().collapse(beginning);}}else if(dojo.doc().selection){var range = dojo.doc().selection.createRange();range.collapse(beginning);range.select();}},remove: function() {if(dojo.doc().selection) {var selection = dojo.doc().selection;if ( selection.type.toUpperCase() != "NONE" ){selection.clear();}
+return selection;}else{var selection = dojo.global().getSelection();selection.deleteFromDocument();return selection;}}
+});
\ No newline at end of file

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/selection.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/style.js
URL: http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/style.js?view=auto&rev=498423
==============================================================================
--- tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/style.js (added)
+++ tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/style.js Sun Jan 21 10:25:59 2007
@@ -0,0 +1,98 @@
+
+dojo.provide("dojo.html.style");dojo.require("dojo.html.common");dojo.require("dojo.uri.Uri");dojo.html.getClass = function(node){node = dojo.byId(node);if(!node){ return ""; }
+var cs = "";if(node.className){cs = node.className;}else if(dojo.html.hasAttribute(node, "class")){cs = dojo.html.getAttribute(node, "class");}
+return cs.replace(/^\s+|\s+$/g, "");}
+dojo.html.getClasses = function(node) {var c = dojo.html.getClass(node);return (c == "") ? [] : c.split(/\s+/g);}
+dojo.html.hasClass = function(node, classname){return (new RegExp('(^|\\s+)'+classname+'(\\s+|$)')).test(dojo.html.getClass(node))
+}
+dojo.html.prependClass = function(node, classStr){classStr += " " + dojo.html.getClass(node);return dojo.html.setClass(node, classStr);}
+dojo.html.addClass = function(node, classStr){if (dojo.html.hasClass(node, classStr)) {return false;}
+classStr = (dojo.html.getClass(node) + " " + classStr).replace(/^\s+|\s+$/g,"");return dojo.html.setClass(node, classStr);}
+dojo.html.setClass = function(node, classStr){node = dojo.byId(node);var cs = new String(classStr);try{if(typeof node.className == "string"){node.className = cs;}else if(node.setAttribute){node.setAttribute("class", classStr);node.className = cs;}else{return false;}}catch(e){dojo.debug("dojo.html.setClass() failed", e);}
+return true;}
+dojo.html.removeClass = function(node, classStr, allowPartialMatches){try{if (!allowPartialMatches) {var newcs = dojo.html.getClass(node).replace(new RegExp('(^|\\s+)'+classStr+'(\\s+|$)'), "$1$2");} else {var newcs = dojo.html.getClass(node).replace(classStr,'');}
+dojo.html.setClass(node, newcs);}catch(e){dojo.debug("dojo.html.removeClass() failed", e);}
+return true;}
+dojo.html.replaceClass = function(node, newClass, oldClass) {dojo.html.removeClass(node, oldClass);dojo.html.addClass(node, newClass);}
+dojo.html.classMatchType = {ContainsAll : 0,ContainsAny : 1,IsOnly : 2
+}
+dojo.html.getElementsByClass = function(
+classStr,parent,nodeType,classMatchType,useNonXpath
+){useNonXpath = false;var _document = dojo.doc();parent = dojo.byId(parent) || _document;var classes = classStr.split(/\s+/g);var nodes = [];if( classMatchType != 1 && classMatchType != 2 ) classMatchType = 0;var reClass = new RegExp("(\\s|^)((" + classes.join(")|(") + "))(\\s|$)");var srtLength = classes.join(" ").length;var candidateNodes = [];if(!useNonXpath && _document.evaluate) {var xpath = ".//" + (nodeType || "*") + "[contains(";if(classMatchType != dojo.html.classMatchType.ContainsAny){xpath += "concat(' ',@class,' '), ' " +
+classes.join(" ') and contains(concat(' ',@class,' '), ' ") +
+" ')";if (classMatchType == 2) {xpath += " and string-length(@class)="+srtLength+"]";}else{xpath += "]";}}else{xpath += "concat(' ',@class,' '), ' " +
+classes.join(" ') or contains(concat(' ',@class,' '), ' ") +
+" ')]";}
+var xpathResult = _document.evaluate(xpath, parent, null, XPathResult.ANY_TYPE, null);var result = xpathResult.iterateNext();while(result){try{candidateNodes.push(result);result = xpathResult.iterateNext();}catch(e){ break; }}
+return candidateNodes;}else{if(!nodeType){nodeType = "*";}
+candidateNodes = parent.getElementsByTagName(nodeType);var node, i = 0;outer:
+while(node = candidateNodes[i++]){var nodeClasses = dojo.html.getClasses(node);if(nodeClasses.length == 0){ continue outer; }
+var matches = 0;for(var j = 0; j < nodeClasses.length; j++){if(reClass.test(nodeClasses[j])){if(classMatchType == dojo.html.classMatchType.ContainsAny){nodes.push(node);continue outer;}else{matches++;}}else{if(classMatchType == dojo.html.classMatchType.IsOnly){continue outer;}}
+}
+if(matches == classes.length){if((classMatchType == dojo.html.classMatchType.IsOnly)&&
+(matches == nodeClasses.length)){nodes.push(node);}else if(classMatchType == dojo.html.classMatchType.ContainsAll){nodes.push(node);}}
+}
+return nodes;}}
+dojo.html.getElementsByClassName = dojo.html.getElementsByClass;dojo.html.toCamelCase = function(selector){var arr = selector.split('-'), cc = arr[0];for(var i = 1; i < arr.length; i++) {cc += arr[i].charAt(0).toUpperCase() + arr[i].substring(1);}
+return cc;}
+dojo.html.toSelectorCase = function(selector){return selector.replace(/([A-Z])/g, "-$1" ).toLowerCase();}
+dojo.html.getComputedStyle = function(node, cssSelector, inValue){node = dojo.byId(node);var cssSelector = dojo.html.toSelectorCase(cssSelector);var property = dojo.html.toCamelCase(cssSelector);if(!node || !node.style){return inValue;} else if (document.defaultView && dojo.html.isDescendantOf(node, node.ownerDocument)){try{var cs = document.defaultView.getComputedStyle(node, "");if(cs){return cs.getPropertyValue(cssSelector);}}catch(e){if(node.style.getPropertyValue){return node.style.getPropertyValue(cssSelector);} else {return inValue;}}
+} else if(node.currentStyle){return node.currentStyle[property];}
+if(node.style.getPropertyValue){return node.style.getPropertyValue(cssSelector);}else{return inValue;}}
+dojo.html.getStyleProperty = function(node, cssSelector){node = dojo.byId(node);return (node && node.style ? node.style[dojo.html.toCamelCase(cssSelector)] : undefined);}
+dojo.html.getStyle = function(node, cssSelector){var value = dojo.html.getStyleProperty(node, cssSelector);return (value ? value : dojo.html.getComputedStyle(node, cssSelector));}
+dojo.html.setStyle = function(node, cssSelector, value){node = dojo.byId(node);if(node && node.style){var camelCased = dojo.html.toCamelCase(cssSelector);node.style[camelCased] = value;}}
+dojo.html.setStyleText = function (target, text) {try {target.style.cssText = text;} catch (e) {target.setAttribute("style", text);}}
+dojo.html.copyStyle = function(target, source){if(!source.style.cssText){target.setAttribute("style", source.getAttribute("style"));}else{target.style.cssText = source.style.cssText;}
+dojo.html.addClass(target, dojo.html.getClass(source));}
+dojo.html.getUnitValue = function(node, cssSelector, autoIsZero){var s = dojo.html.getComputedStyle(node, cssSelector);if((!s)||((s == 'auto')&&(autoIsZero))){return { value: 0, units: 'px' };}
+var match = s.match(/(\-?[\d.]+)([a-z%]*)/i);if (!match){return dojo.html.getUnitValue.bad;}
+return { value: Number(match[1]), units: match[2].toLowerCase() };}
+dojo.html.getUnitValue.bad = { value: NaN, units: '' };dojo.html.getPixelValue = function(node, cssSelector, autoIsZero){var result = dojo.html.getUnitValue(node, cssSelector, autoIsZero);if(isNaN(result.value)){return 0;}
+if((result.value)&&(result.units != 'px')){return NaN;}
+return result.value;}
+dojo.html.setPositivePixelValue = function(node, selector, value){if(isNaN(value)){return false;}
+node.style[selector] = Math.max(0, value) + 'px';return true;}
+dojo.html.styleSheet = null;dojo.html.insertCssRule = function(selector, declaration, index) {if (!dojo.html.styleSheet) {if (document.createStyleSheet) {dojo.html.styleSheet = document.createStyleSheet();} else if (document.styleSheets[0]) {dojo.html.styleSheet = document.styleSheets[0];} else {return null;}}
+if (arguments.length < 3) {if (dojo.html.styleSheet.cssRules) {index = dojo.html.styleSheet.cssRules.length;} else if (dojo.html.styleSheet.rules) {index = dojo.html.styleSheet.rules.length;} else {return null;}}
+if (dojo.html.styleSheet.insertRule) {var rule = selector + " { " + declaration + " }";return dojo.html.styleSheet.insertRule(rule, index);} else if (dojo.html.styleSheet.addRule) {return dojo.html.styleSheet.addRule(selector, declaration, index);} else {return null;}}
+dojo.html.removeCssRule = function(index){if(!dojo.html.styleSheet){dojo.debug("no stylesheet defined for removing rules");return false;}
+if(dojo.render.html.ie){if(!index){index = dojo.html.styleSheet.rules.length;dojo.html.styleSheet.removeRule(index);}}else if(document.styleSheets[0]){if(!index){index = dojo.html.styleSheet.cssRules.length;}
+dojo.html.styleSheet.deleteRule(index);}
+return true;}
+dojo.html._insertedCssFiles = [];dojo.html.insertCssFile = function(URI, doc, checkDuplicates, fail_ok){if(!URI){ return; }
+if(!doc){ doc = document; }
+var cssStr = dojo.hostenv.getText(URI, false, fail_ok);if(cssStr===null){ return; }
+cssStr = dojo.html.fixPathsInCssText(cssStr, URI);if(checkDuplicates){var idx = -1, node, ent = dojo.html._insertedCssFiles;for(var i = 0; i < ent.length; i++){if((ent[i].doc == doc) && (ent[i].cssText == cssStr)){idx = i; node = ent[i].nodeRef;break;}}
+if(node){var styles = doc.getElementsByTagName("style");for(var i = 0; i < styles.length; i++){if(styles[i] == node){return;}}
+dojo.html._insertedCssFiles.shift(idx, 1);}}
+var style = dojo.html.insertCssText(cssStr, doc);dojo.html._insertedCssFiles.push({'doc': doc, 'cssText': cssStr, 'nodeRef': style});if(style && djConfig.isDebug){style.setAttribute("dbgHref", URI);}
+return style;}
+dojo.html.insertCssText = function(cssStr, doc, URI){if(!cssStr){return;}
+if(!doc){ doc = document; }
+if(URI){cssStr = dojo.html.fixPathsInCssText(cssStr, URI);}
+var style = doc.createElement("style");style.setAttribute("type", "text/css");var head = doc.getElementsByTagName("head")[0];if(!head){dojo.debug("No head tag in document, aborting styles");return;}else{head.appendChild(style);}
+if(style.styleSheet){var setFunc = function(){try{style.styleSheet.cssText = cssStr;}catch(e){ dojo.debug(e); }};if(style.styleSheet.disabled){setTimeout(setFunc, 10);}else{setFunc();}}else{var cssText = doc.createTextNode(cssStr);style.appendChild(cssText);}
+return style;}
+dojo.html.fixPathsInCssText = function(cssStr, URI){if(!cssStr || !URI){ return; }
+var match, str = "", url = "", urlChrs = "[\\t\\s\\w\\(\\)\\/\\.\\\\'\"-:#=&?~]+";var regex = new RegExp('url\\(\\s*('+urlChrs+')\\s*\\)');var regexProtocol = /(file|https?|ftps?):\/\//;regexTrim = new RegExp("^[\\s]*(['\"]?)("+urlChrs+")\\1[\\s]*?$");if(dojo.render.html.ie55 || dojo.render.html.ie60){var regexIe = new RegExp("AlphaImageLoader\\((.*)src\=['\"]("+urlChrs+")['\"]");while(match = regexIe.exec(cssStr)){url = match[2].replace(regexTrim, "$2");if(!regexProtocol.exec(url)){url = (new dojo.uri.Uri(URI, url).toString());}
+str += cssStr.substring(0, match.index) + "AlphaImageLoader(" + match[1] + "src='" + url + "'";cssStr = cssStr.substr(match.index + match[0].length);}
+cssStr = str + cssStr;str = "";}
+while(match = regex.exec(cssStr)){url = match[1].replace(regexTrim, "$2");if(!regexProtocol.exec(url)){url = (new dojo.uri.Uri(URI, url).toString());}
+str += cssStr.substring(0, match.index) + "url(" + url + ")";cssStr = cssStr.substr(match.index + match[0].length);}
+return str + cssStr;}
+dojo.html.setActiveStyleSheet = function(title){var i = 0, a, els = dojo.doc().getElementsByTagName("link");while (a = els[i++]) {if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("title")){a.disabled = true;if (a.getAttribute("title") == title) { a.disabled = false; }}
+}}
+dojo.html.getActiveStyleSheet = function(){var i = 0, a, els = dojo.doc().getElementsByTagName("link");while (a = els[i++]) {if (a.getAttribute("rel").indexOf("style") != -1
+&& a.getAttribute("title")
+&& !a.disabled
+){return a.getAttribute("title");}}
+return null;}
+dojo.html.getPreferredStyleSheet = function(){var i = 0, a, els = dojo.doc().getElementsByTagName("link");while (a = els[i++]) {if(a.getAttribute("rel").indexOf("style") != -1
+&& a.getAttribute("rel").indexOf("alt") == -1
+&& a.getAttribute("title")
+){return a.getAttribute("title");}}
+return null;}
+dojo.html.applyBrowserClass = function(node){var drh=dojo.render.html;var classes = {dj_ie: drh.ie,dj_ie55: drh.ie55,dj_ie6: drh.ie60,dj_ie7: drh.ie70,dj_iequirks: drh.ie && drh.quirks,dj_opera: drh.opera,dj_opera8: drh.opera && (Math.floor(dojo.render.version)==8),dj_opera9: drh.opera && (Math.floor(dojo.render.version)==9),dj_khtml: drh.khtml,dj_safari: drh.safari,dj_gecko: drh.mozilla
+};for(var p in classes){if(classes[p]){dojo.html.addClass(node, p);}}
+};
\ No newline at end of file

Propchange: tapestry/tapestry4/trunk/tapestry-framework/src/js/dojo/src/html/style.js
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message