You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by dj...@apache.org on 2009/07/16 21:14:56 UTC
svn commit: r794787 [10/34] - in
/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src: ./
animation/ cal/ charting/ charting/svg/ charting/vml/ collections/ crypto/
data/ data/core/ data/old/ data/old/format/ data/old/provider/ date/
debug/...
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/gfx/vml.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/gfx/vml.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/gfx/vml.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/Colorspace.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/Colorspace.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/Colorspace.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/Colorspace.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,17 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+dojo.provide("dojo.graphics.Colorspace");
+dojo.require("dojo.gfx.Colorspace");
+dojo.deprecated("dojo.graphics.Colorspace: use dojo.gfx.Colorspace instead.", "0.5");
+dojo.graphics.Colorspace = dojo.gfx.Colorspace;
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/Colorspace.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/Colorspace.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/Colorspace.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/__package__.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/__package__.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/__package__.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/__package__.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,14 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+dojo.provide("dojo.graphics.*");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/__package__.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/__package__.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/__package__.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,38 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+dojo.provide("dojo.graphics.color");
+dojo.require("dojo.gfx.color");
+dojo.deprecated("dojo.graphics.color.Color is now dojo.gfx.color.Color.", "0.5");
+dojo.graphics.color.Color = dojo.gfx.color.Color;
+dojo.graphics.color.named = dojo.gfx.color.named;
+dojo.graphics.color.blend = function (a, b, weight) {
+ dojo.deprecated("dojo.graphics.color.blend is now dojo.gfx.color.blend", "0.5");
+ return dojo.gfx.color.blend(a, b, weight);
+};
+dojo.graphics.color.blendHex = function (a, b, weight) {
+ dojo.deprecated("dojo.graphics.color.blendHex is now dojo.gfx.color.blendHex", "0.5");
+ return dojo.gfx.color.rgb2hex(dojo.gfx.color.blend(dojo.gfx.color.hex2rgb(a), dojo.gfx.color.hex2rgb(b), weight));
+};
+dojo.graphics.color.extractRGB = function (color) {
+ dojo.deprecated("dojo.graphics.color.extractRGB is now dojo.gfx.color.extractRGB", "0.5");
+ return dojo.gfx.color.extractRGB(color);
+};
+dojo.graphics.color.hex2rgb = function (hex) {
+ dojo.deprecated("dojo.graphics.color.hex2rgb is now dojo.gfx.color.hex2rgb", "0.5");
+ return dojo.gfx.color.hex2rgb(hex);
+};
+dojo.graphics.color.rgb2hex = function (r, g, b) {
+ dojo.deprecated("dojo.graphics.color.rgb2hex is now dojo.gfx.color.rgb2hex", "0.5");
+ return dojo.gfx.color.rgb2hex;
+};
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsl.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsl.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsl.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsl.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,32 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+dojo.provide("dojo.graphics.color.hsl");
+dojo.require("dojo.gfx.color.hsl");
+dojo.deprecated("dojo.graphics.color.hsl has been replaced with dojo.gfx.color.hsl", "0.5");
+dojo.graphics.color.rgb2hsl = function (r, g, b) {
+ dojo.deprecated("dojo.graphics.color.rgb2hsl has been replaced with dojo.gfx.color.rgb2hsl", "0.5");
+ return dojo.gfx.color.rgb2hsl(r, g, b);
+};
+dojo.graphics.color.hsl2rgb = function (h, s, l) {
+ dojo.deprecated("dojo.graphics.color.hsl2rgb has been replaced with dojo.gfx.color.hsl2rgb", "0.5");
+ return dojo.gfx.color.hsl2rgb(h, s, l);
+};
+dojo.graphics.color.hsl2hex = function (h, s, l) {
+ dojo.deprecated("dojo.graphics.color.hsl2hex has been replaced with dojo.gfx.color.hsl2hex", "0.5");
+ return dojo.gfx.color.hsl2hex(h, s, l);
+};
+dojo.graphics.color.hex2hsl = function (hex) {
+ dojo.deprecated("dojo.graphics.color.hex2hsl has been replaced with dojo.gfx.color.hex2hsl", "0.5");
+ return dojo.gfx.color.hex2hsl(hex);
+};
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsl.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsl.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsl.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsv.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsv.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsv.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsv.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,24 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+dojo.provide("dojo.graphics.color.hsv");
+dojo.require("dojo.gfx.color.hsv");
+dojo.deprecated("dojo.graphics.color.hsv has been replaced by dojo.gfx.color.hsv", "0.5");
+dojo.graphics.color.rgb2hsv = function (r, g, b) {
+ dojo.deprecated("dojo.graphics.color.rgb2hsv has been replaced by dojo.gfx.color.rgb2hsv", "0.5");
+ return dojo.gfx.color.rgb2hsv(r, g, b);
+};
+dojo.graphics.color.hsv2rgb = function (h, s, v) {
+ dojo.deprecated("dojo.graphics.color.hsv2rgb has been replaced by dojo.gfx.color.hsv2rgb", "0.5");
+ return dojo.gfx.color.hsv2rgb(h, s, v);
+};
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsv.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsv.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/graphics/color/hsv.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_adobesvg.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_adobesvg.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_adobesvg.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_adobesvg.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,380 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+if (typeof window == "undefined") {
+ dojo.raise("attempt to use adobe svg hostenv when no window object");
+}
+with (dojo.render) {
+ name = navigator.appName;
+ ver = parseFloat(navigator.appVersion, 10);
+ switch (navigator.platform) {
+ case "MacOS":
+ os.osx = true;
+ break;
+ case "Linux":
+ os.linux = true;
+ break;
+ case "Windows":
+ os.win = true;
+ break;
+ default:
+ os.linux = true;
+ break;
+ }
+ svg.capable = true;
+ svg.support.builtin = true;
+ svg.adobe = true;
+}
+dojo.hostenv.println = function (s) {
+ try {
+ var ti = document.createElement("text");
+ ti.setAttribute("x", "50");
+ var yPos = 25 + 15 * document.getElementsByTagName("text").length;
+ ti.setAttribute("y", yPos);
+ var tn = document.createTextNode(s);
+ ti.appendChild(tn);
+ document.documentElement.appendChild(ti);
+ }
+ catch (e) {
+ }
+};
+dojo.debug = function () {
+ if (!djConfig.isDebug) {
+ return;
+ }
+ var args = arguments;
+ if (typeof dojo.hostenv.println != "function") {
+ dojo.raise("attempt to call dojo.debug when there is no dojo.hostenv println implementation (yet?)");
+ }
+ 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.hostenv.startPackage("dojo.hostenv");
+dojo.hostenv.name_ = "adobesvg";
+dojo.hostenv.anonCtr = 0;
+dojo.hostenv.anon = {};
+dojo.hostenv.nameAnonFunc = function (anonFuncPtr, namespaceObj) {
+ var ret = "_" + this.anonCtr++;
+ var nso = (namespaceObj || this.anon);
+ while (typeof nso[ret] != "undefined") {
+ ret = "_" + this.anonCtr++;
+ }
+ nso[ret] = anonFuncPtr;
+ return ret;
+};
+dojo.hostenv.modulesLoadedFired = false;
+dojo.hostenv.modulesLoadedListeners = [];
+dojo.hostenv.getTextStack = [];
+dojo.hostenv.loadUriStack = [];
+dojo.hostenv.loadedUris = [];
+dojo.hostenv.modulesLoaded = function () {
+ if (this.modulesLoadedFired) {
+ return;
+ }
+ if ((this.loadUriStack.length == 0) && (this.getTextStack.length == 0)) {
+ if (this.inFlightCount > 0) {
+ dojo.debug("couldn't initialize, there are files still in flight");
+ return;
+ }
+ this.modulesLoadedFired = true;
+ var mll = this.modulesLoadedListeners;
+ for (var x = 0; x < mll.length; x++) {
+ mll[x]();
+ }
+ }
+};
+dojo.hostenv.getNewAnonFunc = function () {
+ var ret = "_" + this.anonCtr++;
+ while (typeof this.anon[ret] != "undefined") {
+ ret = "_" + this.anonCtr++;
+ }
+ eval("dojo.nostenv.anon." + ret + " = function(){};");
+ return [ret, this.anon[ret]];
+};
+dojo.hostenv.displayStack = function () {
+ var oa = [];
+ var stack = this.loadUriStack;
+ for (var x = 0; x < stack.length; x++) {
+ oa.unshift([stack[x][0], (typeof stack[x][2])]);
+ }
+ dojo.debug("<pre>" + oa.join("\n") + "</pre>");
+};
+dojo.hostenv.unwindUriStack = function () {
+ var stack = this.loadUriStack;
+ for (var x in dojo.hostenv.loadedUris) {
+ for (var y = stack.length - 1; y >= 0; y--) {
+ if (stack[y][0] == x) {
+ stack.splice(y, 1);
+ }
+ }
+ }
+ var next = stack.pop();
+ if ((!next) && (stack.length == 0)) {
+ return;
+ }
+ for (var x = 0; x < stack.length; x++) {
+ if ((stack[x][0] == next[0]) && (stack[x][2])) {
+ next[2] == stack[x][2];
+ }
+ }
+ var last = next;
+ while (dojo.hostenv.loadedUris[next[0]]) {
+ last = next;
+ next = stack.pop();
+ }
+ while (typeof next[2] == "string") {
+ try {
+ dj_eval(next[2]);
+ next[1](true);
+ }
+ catch (e) {
+ dojo.debug("we got an error when loading " + next[0]);
+ dojo.debug("error: " + e);
+ }
+ dojo.hostenv.loadedUris[next[0]] = true;
+ dojo.hostenv.loadedUris.push(next[0]);
+ last = next;
+ next = stack.pop();
+ if ((!next) && (stack.length == 0)) {
+ break;
+ }
+ while (dojo.hostenv.loadedUris[next[0]]) {
+ last = next;
+ next = stack.pop();
+ }
+ }
+ if (next) {
+ stack.push(next);
+ dojo.debug("### CHOKED ON: " + next[0]);
+ }
+};
+dojo.hostenv.loadUri = function (uri, cb) {
+ if (dojo.hostenv.loadedUris[uri]) {
+ return;
+ }
+ var stack = this.loadUriStack;
+ stack.push([uri, cb, null]);
+ var tcb = function (contents) {
+ if (contents.content) {
+ contents = contents.content;
+ }
+ var next = stack.pop();
+ if ((!next) && (stack.length == 0)) {
+ dojo.hostenv.modulesLoaded();
+ return;
+ }
+ if (typeof contents == "string") {
+ stack.push(next);
+ for (var x = 0; x < stack.length; x++) {
+ if (stack[x][0] == uri) {
+ stack[x][2] = contents;
+ }
+ }
+ next = stack.pop();
+ }
+ if (dojo.hostenv.loadedUris[next[0]]) {
+ dojo.hostenv.unwindUriStack();
+ return;
+ }
+ stack.push(next);
+ if (next[0] != uri) {
+ if (typeof next[2] == "string") {
+ dojo.hostenv.unwindUriStack();
+ }
+ } else {
+ if (!contents) {
+ next[1](false);
+ } else {
+ var deps = dojo.hostenv.getDepsForEval(next[2]);
+ if (deps.length > 0) {
+ eval(deps.join(";"));
+ } else {
+ dojo.hostenv.unwindUriStack();
+ }
+ }
+ }
+ };
+ this.getText(uri, tcb, true);
+};
+dojo.hostenv.loadModule = function (modulename, exact_only, omit_module_check) {
+ var module = this.findModule(modulename, 0);
+ if (module) {
+ return module;
+ }
+ if (typeof this.loading_modules_[modulename] !== "undefined") {
+ dojo.debug("recursive attempt to load module '" + modulename + "'");
+ } else {
+ this.addedToLoadingCount.push(modulename);
+ }
+ this.loading_modules_[modulename] = 1;
+ var relpath = modulename.replace(/\./g, "/") + ".js";
+ var syms = modulename.split(".");
+ var nsyms = modulename.split(".");
+ if (syms[0] == "dojo") {
+ syms[0] = "src";
+ }
+ var last = syms.pop();
+ syms.push(last);
+ var _this = this;
+ var pfn = this.pkgFileName;
+ if (last == "*") {
+ modulename = (nsyms.slice(0, -1)).join(".");
+ var module = this.findModule(modulename, 0);
+ if (module) {
+ _this.removedFromLoadingCount.push(modulename);
+ return module;
+ }
+ var nextTry = function (lastStatus) {
+ if (lastStatus) {
+ module = _this.findModule(modulename, false);
+ if ((!module) && (syms[syms.length - 1] != pfn)) {
+ dojo.raise("Module symbol '" + modulename + "' is not defined after loading '" + relpath + "'");
+ }
+ if (module) {
+ _this.removedFromLoadingCount.push(modulename);
+ dojo.hostenv.modulesLoaded();
+ return;
+ }
+ }
+ syms.pop();
+ syms.push(pfn);
+ relpath = syms.join("/") + ".js";
+ if (relpath.charAt(0) == "/") {
+ relpath = relpath.slice(1);
+ }
+ _this.loadPath(relpath, ((!omit_module_check) ? modulename : null), nextTry);
+ };
+ nextTry();
+ } else {
+ relpath = syms.join("/") + ".js";
+ modulename = nsyms.join(".");
+ var nextTry = function (lastStatus) {
+ if (lastStatus) {
+ module = _this.findModule(modulename, false);
+ if ((!module) && (syms[syms.length - 1] != pfn)) {
+ dojo.raise("Module symbol '" + modulename + "' is not defined after loading '" + relpath + "'");
+ }
+ if (module) {
+ _this.removedFromLoadingCount.push(modulename);
+ dojo.hostenv.modulesLoaded();
+ return;
+ }
+ }
+ var setPKG = (syms[syms.length - 1] == pfn) ? false : true;
+ syms.pop();
+ if (setPKG) {
+ syms.push(pfn);
+ }
+ relpath = syms.join("/") + ".js";
+ if (relpath.charAt(0) == "/") {
+ relpath = relpath.slice(1);
+ }
+ _this.loadPath(relpath, ((!omit_module_check) ? modulename : null), nextTry);
+ };
+ this.loadPath(relpath, ((!omit_module_check) ? modulename : null), nextTry);
+ }
+ return;
+};
+dojo.hostenv.async_cb = null;
+dojo.hostenv.unWindGetTextStack = function () {
+ if (dojo.hostenv.inFlightCount > 0) {
+ setTimeout("dojo.hostenv.unWindGetTextStack()", 100);
+ return;
+ }
+ dojo.hostenv.inFlightCount++;
+ var next = dojo.hostenv.getTextStack.pop();
+ if ((!next) && (dojo.hostenv.getTextStack.length == 0)) {
+ dojo.hostenv.inFlightCount--;
+ dojo.hostenv.async_cb = function () {
+ };
+ return;
+ }
+ dojo.hostenv.async_cb = next[1];
+ window.getURL(next[0], function (result) {
+ dojo.hostenv.inFlightCount--;
+ dojo.hostenv.async_cb(result.content);
+ dojo.hostenv.unWindGetTextStack();
+ });
+};
+dojo.hostenv.getText = function (uri, async_cb, fail_ok) {
+ try {
+ if (async_cb) {
+ dojo.hostenv.getTextStack.push([uri, async_cb, fail_ok]);
+ dojo.hostenv.unWindGetTextStack();
+ } else {
+ return dojo.raise("No synchronous XMLHTTP implementation available, for uri " + uri);
+ }
+ }
+ catch (e) {
+ return dojo.raise("No XMLHTTP implementation available, for uri " + uri);
+ }
+};
+dojo.hostenv.postText = function (uri, async_cb, text, fail_ok, mime_type, encoding) {
+ var http = null;
+ var async_callback = function (httpResponse) {
+ if (!httpResponse.success) {
+ dojo.raise("Request for uri '" + uri + "' resulted in " + httpResponse.status);
+ }
+ if (!httpResponse.content) {
+ if (!fail_ok) {
+ dojo.raise("Request for uri '" + uri + "' resulted in no content");
+ }
+ return null;
+ }
+ async_cb(httpResponse.content);
+ };
+ try {
+ if (async_cb) {
+ http = window.postURL(uri, text, async_callback, mimeType, encoding);
+ } else {
+ return dojo.raise("No synchronous XMLHTTP post implementation available, for uri " + uri);
+ }
+ }
+ catch (e) {
+ return dojo.raise("No XMLHTTP post implementation available, for uri " + uri);
+ }
+};
+function dj_last_script_src() {
+ var scripts = window.document.getElementsByTagName("script");
+ if (scripts.length < 1) {
+ dojo.raise("No script elements in window.document, so can't figure out my script src");
+ }
+ var li = scripts.length - 1;
+ var xlinkNS = "http://www.w3.org/1999/xlink";
+ var src = null;
+ var script = null;
+ while (!src) {
+ script = scripts.item(li);
+ src = script.getAttributeNS(xlinkNS, "href");
+ li--;
+ if (li < 0) {
+ break;
+ }
+ }
+ if (!src) {
+ dojo.raise("Last script element (out of " + scripts.length + ") has no src");
+ }
+ return src;
+}
+if (!dojo.hostenv["library_script_uri_"]) {
+ dojo.hostenv.library_script_uri_ = dj_last_script_src();
+}
+dojo.requireIf((djConfig["isDebug"] || djConfig["debugAtAllCosts"]), "dojo.debug");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_adobesvg.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_adobesvg.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_adobesvg.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_browser.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_browser.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_browser.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_browser.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,417 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+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.evalObjPath("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;
+ }
+ dojo.hostenv._djInitFired = false;
+ function dj_load_init(e) {
+ dojo.hostenv._djInitFired = true;
+ 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.attachEvent("onreadystatechange", function (e) {
+ if (document.readyState == "complete") {
+ dj_load_init();
+ }
+ });
+ }
+ 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 () {
+ dojo.hostenv.unloaded();
+ 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.evalObjPath("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;
+ };
+}
+dojo.requireIf((djConfig["isDebug"] || djConfig["debugAtAllCosts"]), "dojo.debug");
+dojo.requireIf(djConfig["debugAtAllCosts"] && !window.widget && !djConfig["useXDomain"], "dojo.browser_debug");
+dojo.requireIf(djConfig["debugAtAllCosts"] && !window.widget && djConfig["useXDomain"], "dojo.browser_debug_xd");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_browser.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_browser.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_browser.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_dashboard.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_dashboard.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_dashboard.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_dashboard.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,180 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+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: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_dashboard.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_dashboard.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_dashboard.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_jsc.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_jsc.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_jsc.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_jsc.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,78 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+/*
+ * JScript .NET jsc
+ *
+ */
+
+dojo.hostenv.name_ = 'jsc';
+
+// Sanity check this is the right hostenv.
+// See the Rotor source code jscript/engine/globalobject.cs for what globals
+// are available.
+if((typeof ScriptEngineMajorVersion != 'function')||(ScriptEngineMajorVersion() < 7)){
+ dojo.raise("attempt to use JScript .NET host environment with inappropriate ScriptEngine");
+}
+
+// for more than you wanted to know about why this import is required even if
+// we fully qualify all symbols, see
+// http://groups.google.com/groups?th=f050c7aeefdcbde2&rnum=12
+import System;
+
+dojo.hostenv.getText = function(uri){
+ if(!System.IO.File.Exists(uri)){
+ // dojo.raise("No such file '" + 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);
+ }
+ // TODO: in JScript .NET, eval will not affect the symbol table of the current code?
+ var value = dj_eval(contents);
+ dojo.debug("jsc eval of contents returned: ", value);
+ return 1;
+
+ // for an example doing runtime code compilation, see:
+ // http://groups.google.com/groups?selm=eQ1aeciCBHA.1644%40tkmsftngp05&rnum=6
+ // Microsoft.JScript or System.CodeDom.Compiler ?
+ // var engine = new Microsoft.JScript.Vsa.VsaEngine()
+ // what about loading a js file vs. a dll?
+ // GetObject("script:" . uri);
+}
+
+/* The System.Environment object is useful:
+ print ("CommandLine='" + System.Environment.CommandLine + "' " +
+ "program name='" + System.Environment.GetCommandLineArgs()[0] + "' " +
+ "CurrentDirectory='" + System.Environment.CurrentDirectory + "' " +
+ "StackTrace='" + System.Environment.StackTrace + "'");
+*/
+
+// same as System.Console.WriteLine
+// sigh; Rotor treats symbol "print" at parse time without actually putting it
+// in the builtin symbol table.
+// Note that the print symbol is not available if jsc is run with the "/print-"
+// option.
+dojo.hostenv.println = function(s){
+ print(s); // = print
+}
+
+dojo.hostenv.getLibraryScriptUri = function(){
+ return System.Environment.GetCommandLineArgs()[0];
+}
+
+dojo.requireIf((djConfig["isDebug"] || djConfig["debugAtAllCosts"]), "dojo.debug");
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_jsc.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_jsc.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_jsc.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_rhino.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_rhino.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_rhino.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_rhino.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,163 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+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();
+}
+dojo.requireIf((djConfig["isDebug"] || djConfig["debugAtAllCosts"]), "dojo.debug");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_rhino.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_rhino.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_rhino.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_spidermonkey.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_spidermonkey.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_spidermonkey.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_spidermonkey.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,50 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+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;
+};
+dojo.requireIf((djConfig["isDebug"] || djConfig["debugAtAllCosts"]), "dojo.debug");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_spidermonkey.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_spidermonkey.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_spidermonkey.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_svg.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_svg.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_svg.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_svg.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,247 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+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.setModulePrefix = 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, "&").replace(/>/g, ">").replace(/</g, "<");
+ }
+ function fixAttribute(s) {
+ return fixText(s).replace(/\"/g, """);
+ }
+ 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);
+ }
+ };
+ };
+}
+dojo.requireIf((djConfig["isDebug"] || djConfig["debugAtAllCosts"]), "dojo.debug");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_svg.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_svg.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_svg.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_wsh.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_wsh.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_wsh.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_wsh.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,35 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+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);
+};
+dojo.requireIf((djConfig["isDebug"] || djConfig["debugAtAllCosts"]), "dojo.debug");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_wsh.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_wsh.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/hostenv_wsh.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,16 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+dojo.provide("dojo.html");
+dojo.require("dojo.html.*");
+dojo.deprecated("dojo.html", "replaced by dojo.html.*", "0.5");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/__package__.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/__package__.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/__package__.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/__package__.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,15 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+dojo.kwCompoundRequire({common:["dojo.html.common", "dojo.html.style"]});
+dojo.provide("dojo.html.*");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/__package__.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/__package__.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/__package__.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/color.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/color.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/color.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/color.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,38 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+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: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/color.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/color.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/color.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/common.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/common.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/common.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/common.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,182 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+dojo.provide("dojo.html.common");
+dojo.require("dojo.lang.common");
+dojo.require("dojo.dom");
+dojo.lang.mixin(dojo.html, dojo.dom);
+dojo.html.body = function () {
+ dojo.deprecated("dojo.html.body() moved to dojo.body()", "0.5");
+ return dojo.body();
+};
+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(_document, "documentElement.clientWidth")) {
+ 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);
+ };
+}
+dojo.html._callDeprecated = function (inFunc, replFunc, args, argName, retValue) {
+ dojo.deprecated("dojo.html." + inFunc, "replaced by dojo.html." + replFunc + "(" + (argName ? "node, {" + argName + ": " + argName + "}" : "") + ")" + (retValue ? "." + retValue : ""), "0.5");
+ var newArgs = [];
+ if (argName) {
+ var argsIn = {};
+ argsIn[argName] = args[1];
+ newArgs.push(args[0]);
+ newArgs.push(argsIn);
+ } else {
+ newArgs = args;
+ }
+ var ret = dojo.html[replFunc].apply(dojo.html, args);
+ if (retValue) {
+ return ret[retValue];
+ } else {
+ return ret;
+ }
+};
+dojo.html.getViewportWidth = function () {
+ return dojo.html._callDeprecated("getViewportWidth", "getViewport", arguments, null, "width");
+};
+dojo.html.getViewportHeight = function () {
+ return dojo.html._callDeprecated("getViewportHeight", "getViewport", arguments, null, "height");
+};
+dojo.html.getViewportSize = function () {
+ return dojo.html._callDeprecated("getViewportSize", "getViewport", arguments);
+};
+dojo.html.getScrollTop = function () {
+ return dojo.html._callDeprecated("getScrollTop", "getScroll", arguments, null, "top");
+};
+dojo.html.getScrollLeft = function () {
+ return dojo.html._callDeprecated("getScrollLeft", "getScroll", arguments, null, "left");
+};
+dojo.html.getScrollOffset = function () {
+ return dojo.html._callDeprecated("getScrollOffset", "getScroll", arguments, null, "offset");
+};
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/common.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/common.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/common.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/display.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/display.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/display.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/display.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,147 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+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") {
+ dojo.html.setStyle(node, "display", (node.dojoDisplayCache || ""));
+ node.dojoDisplayCache = undefined;
+ }
+};
+dojo.html.hide = function (node) {
+ node = dojo.byId(node);
+ if (typeof node["dojoDisplayCache"] == "undefined") {
+ var d = dojo.html.getStyleProperty(node, "display");
+ if (d != "none") {
+ node.dojoDisplayCache = 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) {
+ if (h.ie) {
+ dojo.html.clearOpacity(node);
+ return;
+ } else {
+ opacity = 0.999999;
+ }
+ } else {
+ if (opacity < 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 : Number(opac);
+};
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/display.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/display.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/display.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/iframe.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/iframe.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/iframe.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/iframe.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,84 @@
+/*
+ Copyright (c) 2004-2006, The Dojo Foundation
+ All Rights Reserved.
+
+ Licensed under the Academic Free License version 2.1 or above OR the
+ modified BSD license. For more information on Dojo licensing, see:
+
+ http://dojotoolkit.org/community/licensing.shtml
+*/
+
+
+
+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;
+ }
+}});
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/iframe.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/iframe.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/html/iframe.js
------------------------------------------------------------------------------
svn:mime-type = text/plain