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 [30/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/...
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/Wizard.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/Wizard.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/Wizard.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/Wizard.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,127 @@
+/*
+ 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.widget.Wizard");
+dojo.require("dojo.widget.*");
+dojo.require("dojo.widget.LayoutContainer");
+dojo.require("dojo.widget.ContentPane");
+dojo.require("dojo.event.*");
+dojo.require("dojo.html.style");
+dojo.widget.defineWidget("dojo.widget.WizardContainer", dojo.widget.LayoutContainer, {templateString:"<div class=\"WizardContainer\" dojoAttachPoint=\"wizardNode\">\n <div class=\"WizardText\" dojoAttachPoint=\"wizardPanelContainerNode\">\n </div>\n <div class=\"WizardButtonHolder\" dojoAttachPoint=\"wizardControlContainerNode\">\n <input class=\"WizardButton\" type=\"button\" dojoAttachPoint=\"previousButton\"/>\n <input class=\"WizardButton\" type=\"button\" dojoAttachPoint=\"nextButton\"/>\n <input class=\"WizardButton\" type=\"button\" dojoAttachPoint=\"doneButton\" style=\"display:none\"/>\n <input class=\"WizardButton\" type=\"button\" dojoAttachPoint=\"cancelButton\"/>\n </div>\n</div>\n", templateCssString:".WizardContainer {\n\tbackground: #EEEEEE;\n\tborder: #798EC5 1px solid;\n\tpadding: 2px;\n}\n\n.WizardTitle {\n\tcolor: #003366;\n\tpadding: 8px 5px 15px 2px;\n\tfont-weight: bold;\n\tfont-size: x-small;\n\tfont-style: normal;\n\tfont-family: Verdana, Arial,
Helvetica;\n\ttext-align: left;\n}\n\n.WizardText {\n\tcolor: #000033;\n\tfont-weight: normal;\n\tfont-size: xx-small;\n\tfont-family: Verdana, Arial, Helvetica;\n\tpadding: 2 50; text-align: justify;\n}\n\n.WizardLightText {\n\tcolor: #666666;\n\tfont-weight: normal;\n\tfont-size: xx-small;\n\tfont-family: verdana, arial, helvetica;\n\tpadding: 2px 50px;\n\ttext-align: justify;\n}\n\n.WizardButtonHolder {\n\ttext-align: right;\n\tpadding: 10px 5px;\n}\n\n.WizardButton {\n\tcolor: #ffffff;\n\tbackground: #798EC5;\n\tfont-size: xx-small;\n\tfont-family: verdana, arial, helvetica, sans-serif;\n\tborder-right: #000000 1px solid;\n\tborder-bottom: #000000 1px solid;\n\tborder-left: #666666 1px solid;\n\tborder-top: #666666 1px solid;\n\tpadding-right: 4px;\n\tpadding-left: 4px;\n\ttext-decoration: none; height: 18px;\n}\n\n.WizardButton:hover {\n\tcursor: pointer;\n}\n\n.WizardButtonDisabled {\n\tcolor: #eeeeee;\n\tbackground-color: #999999;\n\tfont-size: xx-small;\n\tFONT-FAMIL
Y: verdana, arial, helvetica, sans-serif;\n\tborder-right: #000000 1px solid;\n\tborder-bottom: #000000 1px solid;\n\tborder-left: #798EC5 1px solid;\n\tborder-top: #798EC5 1px solid;\n\tpadding-right: 4px;\n\tpadding-left: 4px;\n\ttext-decoration: none;\n\theight: 18px;\n}\n\n\n", templateCssPath:dojo.uri.moduleUri("dojo.widget", "templates/Wizard.css"), selected:null, nextButtonLabel:"next", previousButtonLabel:"previous", cancelButtonLabel:"cancel", doneButtonLabel:"done", cancelFunction:"", hideDisabledButtons:false, fillInTemplate:function (args, frag) {
+ dojo.event.connect(this.nextButton, "onclick", this, "_onNextButtonClick");
+ dojo.event.connect(this.previousButton, "onclick", this, "_onPreviousButtonClick");
+ if (this.cancelFunction) {
+ dojo.event.connect(this.cancelButton, "onclick", this.cancelFunction);
+ } else {
+ this.cancelButton.style.display = "none";
+ }
+ dojo.event.connect(this.doneButton, "onclick", this, "done");
+ this.nextButton.value = this.nextButtonLabel;
+ this.previousButton.value = this.previousButtonLabel;
+ this.cancelButton.value = this.cancelButtonLabel;
+ this.doneButton.value = this.doneButtonLabel;
+}, _checkButtons:function () {
+ var lastStep = !this.hasNextPanel();
+ this.nextButton.disabled = lastStep;
+ this._setButtonClass(this.nextButton);
+ if (this.selected.doneFunction) {
+ this.doneButton.style.display = "";
+ if (lastStep) {
+ this.nextButton.style.display = "none";
+ }
+ } else {
+ this.doneButton.style.display = "none";
+ }
+ this.previousButton.disabled = ((!this.hasPreviousPanel()) || (!this.selected.canGoBack));
+ this._setButtonClass(this.previousButton);
+}, _setButtonClass:function (button) {
+ if (!this.hideDisabledButtons) {
+ button.style.display = "";
+ dojo.html.setClass(button, button.disabled ? "WizardButtonDisabled" : "WizardButton");
+ } else {
+ button.style.display = button.disabled ? "none" : "";
+ }
+}, registerChild:function (panel, insertionIndex) {
+ dojo.widget.WizardContainer.superclass.registerChild.call(this, panel, insertionIndex);
+ this.wizardPanelContainerNode.appendChild(panel.domNode);
+ panel.hide();
+ if (!this.selected) {
+ this.onSelected(panel);
+ }
+ this._checkButtons();
+}, onSelected:function (panel) {
+ if (this.selected) {
+ if (this.selected._checkPass()) {
+ this.selected.hide();
+ } else {
+ return;
+ }
+ }
+ panel.show();
+ this.selected = panel;
+}, getPanels:function () {
+ return this.getChildrenOfType("WizardPane", false);
+}, selectedIndex:function () {
+ if (this.selected) {
+ return dojo.lang.indexOf(this.getPanels(), this.selected);
+ }
+ return -1;
+}, _onNextButtonClick:function () {
+ var selectedIndex = this.selectedIndex();
+ if (selectedIndex > -1) {
+ var childPanels = this.getPanels();
+ if (childPanels[selectedIndex + 1]) {
+ this.onSelected(childPanels[selectedIndex + 1]);
+ }
+ }
+ this._checkButtons();
+}, _onPreviousButtonClick:function () {
+ var selectedIndex = this.selectedIndex();
+ if (selectedIndex > -1) {
+ var childPanels = this.getPanels();
+ if (childPanels[selectedIndex - 1]) {
+ this.onSelected(childPanels[selectedIndex - 1]);
+ }
+ }
+ this._checkButtons();
+}, hasNextPanel:function () {
+ var selectedIndex = this.selectedIndex();
+ return (selectedIndex < (this.getPanels().length - 1));
+}, hasPreviousPanel:function () {
+ var selectedIndex = this.selectedIndex();
+ return (selectedIndex > 0);
+}, done:function () {
+ this.selected.done();
+}});
+dojo.widget.defineWidget("dojo.widget.WizardPane", dojo.widget.ContentPane, {canGoBack:true, passFunction:"", doneFunction:"", postMixInProperties:function (args, frag) {
+ if (this.passFunction) {
+ this.passFunction = dj_global[this.passFunction];
+ }
+ if (this.doneFunction) {
+ this.doneFunction = dj_global[this.doneFunction];
+ }
+ dojo.widget.WizardPane.superclass.postMixInProperties.apply(this, arguments);
+}, _checkPass:function () {
+ if (this.passFunction && dojo.lang.isFunction(this.passFunction)) {
+ var failMessage = this.passFunction();
+ if (failMessage) {
+ alert(failMessage);
+ return false;
+ }
+ }
+ return true;
+}, done:function () {
+ if (this.doneFunction && dojo.lang.isFunction(this.doneFunction)) {
+ this.doneFunction();
+ }
+}});
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/Wizard.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/Wizard.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/Wizard.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/YahooMap.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/YahooMap.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/YahooMap.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/YahooMap.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,145 @@
+/*
+ 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.widget.YahooMap");
+dojo.require("dojo.event.*");
+dojo.require("dojo.math");
+dojo.require("dojo.widget.*");
+dojo.require("dojo.widget.HtmlWidget");
+(function () {
+ var yappid = djConfig["yAppId"] || djConfig["yahooAppId"] || "dojotoolkit";
+ if (!dojo.hostenv.post_load_) {
+ if (yappid == "dojotoolkit") {
+ dojo.debug("please provide a unique Yahoo App ID in djConfig.yahooAppId when using the map widget");
+ }
+ var tag = "<scr" + "ipt src='http://api.maps.yahoo.com/ajaxymap?v=3.0&appid=" + yappid + "'></scri" + "pt>";
+ if (!dj_global["YMap"]) {
+ document.write(tag);
+ }
+ } else {
+ dojo.debug("cannot initialize map system after the page has been loaded! Please either manually include the script block provided by Yahoo in your page or require() the YahooMap widget before onload has fired");
+ }
+})();
+dojo.widget.defineWidget("dojo.widget.YahooMap", dojo.widget.HtmlWidget, function () {
+ this.map = null;
+ this.datasrc = "";
+ this.data = [];
+ this.width = 0;
+ this.height = 0;
+ this.controls = ["zoomlong", "maptype", "pan"];
+}, {isContainer:false, templatePath:null, templateCssPath:null, findCenter:function (aPts) {
+ var start = new YGeoPoint(37, -90);
+ if (aPts.length == 0) {
+ return start;
+ }
+ var minLat, maxLat, minLon, maxLon, cLat, cLon;
+ minLat = maxLat = aPts[0].Lat;
+ minLon = maxLon = aPts[0].Lon;
+ for (var i = 0; i < aPts.length; i++) {
+ minLat = Math.min(minLat, aPts[i].Lat);
+ maxLat = Math.max(maxLat, aPts[i].Lat);
+ minLon = Math.min(minLon, aPts[i].Lon);
+ maxLon = Math.max(maxLon, aPts[i].Lon);
+ }
+ cLat = dojo.math.round((minLat + maxLat) / 2, 6);
+ cLon = dojo.math.round((minLon + maxLon) / 2, 6);
+ return new YGeoPoint(cLat, cLon);
+}, setControls:function () {
+ var methodmap = {maptype:"addTypeControl", pan:"addPanControl", zoomlong:"addZoomLong", zoomshort:"addZoomShort"};
+ var c = this.controls;
+ for (var i = 0; i < c.length; i++) {
+ var controlMethod = methodmap[c[i].toLowerCase()];
+ if (this.map[controlMethod]) {
+ this.map[controlMethod]();
+ }
+ }
+}, parse:function (table) {
+ this.data = [];
+ var h = table.getElementsByTagName("thead")[0];
+ if (!h) {
+ return;
+ }
+ var a = [];
+ var cols = h.getElementsByTagName("td");
+ if (cols.length == 0) {
+ cols = h.getElementsByTagName("th");
+ }
+ for (var i = 0; i < cols.length; i++) {
+ var c = cols[i].innerHTML.toLowerCase();
+ if (c == "long") {
+ c = "lng";
+ }
+ a.push(c);
+ }
+ var b = table.getElementsByTagName("tbody")[0];
+ if (!b) {
+ return;
+ }
+ for (var i = 0; i < b.childNodes.length; i++) {
+ if (!(b.childNodes[i].nodeName && b.childNodes[i].nodeName.toLowerCase() == "tr")) {
+ continue;
+ }
+ var cells = b.childNodes[i].getElementsByTagName("td");
+ var o = {};
+ for (var j = 0; j < a.length; j++) {
+ var col = a[j];
+ if (col == "lat" || col == "lng") {
+ o[col] = parseFloat(cells[j].innerHTML);
+ } else {
+ o[col] = cells[j].innerHTML;
+ }
+ }
+ this.data.push(o);
+ }
+}, render:function () {
+ var pts = [];
+ var d = this.data;
+ for (var i = 0; i < d.length; i++) {
+ var pt = new YGeoPoint(d[i].lat, d[i].lng);
+ pts.push(pt);
+ var icon = d[i].icon || null;
+ if (icon) {
+ icon = new YImage(icon);
+ }
+ var m = new YMarker(pt, icon);
+ if (d[i].description) {
+ m.addAutoExpand("<div>" + d[i].description + "</div>");
+ }
+ this.map.addOverlay(m);
+ }
+ var c = this.findCenter(pts);
+ var z = this.map.getZoomLevel(pts);
+ this.map.drawZoomAndCenter(c, z);
+}, initialize:function (args, frag) {
+ if (!YMap || !YGeoPoint) {
+ dojo.raise("dojo.widget.YahooMap: The Yahoo Map script must be included in order to use this widget.");
+ }
+ if (this.datasrc) {
+ this.parse(dojo.byId(this.datasrc));
+ } else {
+ if (this.domNode.getElementsByTagName("table")[0]) {
+ this.parse(this.domNode.getElementsByTagName("table")[0]);
+ }
+ }
+}, postCreate:function () {
+ while (this.domNode.childNodes.length > 0) {
+ this.domNode.removeChild(this.domNode.childNodes[0]);
+ }
+ if (this.width > 0 && this.height > 0) {
+ this.map = new YMap(this.domNode, YAHOO_MAP_REG, new YSize(this.width, this.height));
+ } else {
+ this.map = new YMap(this.domNode);
+ }
+ this.setControls();
+ this.render();
+}});
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/YahooMap.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/YahooMap.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/YahooMap.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/__package__.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/__package__.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/__package__.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/__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.xml.Parse", "dojo.widget.Widget", "dojo.widget.Parse", "dojo.widget.Manager"], browser:["dojo.widget.DomWidget", "dojo.widget.HtmlWidget"], dashboard:["dojo.widget.DomWidget", "dojo.widget.HtmlWidget"], svg:["dojo.widget.SvgWidget"], rhino:["dojo.widget.SwtWidget"]});
+dojo.provide("dojo.widget.*");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/__package__.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/__package__.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/__package__.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoContainer.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoContainer.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoContainer.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoContainer.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,75 @@
+/*
+ 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.widget.demoEngine.DemoContainer");
+dojo.require("dojo.widget.*");
+dojo.require("dojo.widget.HtmlWidget");
+dojo.require("dojo.widget.demoEngine.DemoPane");
+dojo.require("dojo.widget.demoEngine.SourcePane");
+dojo.require("dojo.widget.TabContainer");
+dojo.widget.defineWidget("my.widget.demoEngine.DemoContainer", dojo.widget.HtmlWidget, {templateString:"<div dojoAttachPoint=\"domNode\">\n\t<table width=\"100%\" cellspacing=\"0\" cellpadding=\"5\">\n\t\t<tbody>\n\t\t\t<tr dojoAttachPoint=\"headerNode\">\n\t\t\t\t<td dojoAttachPoint=\"returnNode\" valign=\"middle\" width=\"1%\">\n\t\t\t\t\t<img dojoAttachPoint=\"returnImageNode\" dojoAttachEvent=\"onclick: returnToDemos\"/>\n\t\t\t\t</td>\n\t\t\t\t<td>\n\t\t\t\t\t<h1 dojoAttachPoint=\"demoNameNode\"></h1>\n\t\t\t\t\t<p dojoAttachPoint=\"summaryNode\"></p>\n\t\t\t\t</td>\n\t\t\t\t<td dojoAttachPoint=\"tabControlNode\" valign=\"middle\" align=\"right\" nowrap>\n\t\t\t\t\t<span dojoAttachPoint=\"sourceButtonNode\" dojoAttachEvent=\"onclick: showSource\">source</span>\n\t\t\t\t\t<span dojoAttachPoint=\"demoButtonNode\" dojoAttachEvent=\"onclick: showDemo\">demo</span>\n\t\t\t\t</td>\n\t\t\t</tr>\n\t\t\t<tr>\n\t\t\t\t<td colspan=\"3\">\n\t\t\t\t\t<div dojoAttachPoint=\"tabNode\"
>\n\t\t\t\t\t</div>\n\t\t\t\t</td>\n\t\t\t</tr>\n\t\t</tbody>\n\t</table>\n</div>\n", templateCssString:".demoContainer{\n\twidth: 100%;\n\theight: 100%;\n\tpadding: 0px;\n\tmargin: 0px;\n}\n\n.demoContainer .return {\n\tcursor: pointer;\n}\n\n.demoContainer span {\n\tmargin-right: 10px;\n\tcursor: pointer;\n}\n\n.demoContainer .selected {\n\tborder-bottom: 5px solid #95bfff;\n}\n\n.demoContainer table {\n\tbackground: #f5f5f5;\n\twidth: 100%;\n\theight: 100%;\n}\n\n.demoContainerTabs {\n\twidth: 100%;\n\theight: 400px;\n}\n\n.demoContainerTabs .dojoTabLabels-top {\n\tdisplay: none;\n}\n\n.demoContainerTabs .dojoTabPaneWrapper {\n\tborder: 0px;\n}\n\n", templateCssPath:dojo.uri.moduleUri("dojo.widget", "demoEngine/templates/DemoContainer.css"), postCreate:function () {
+ dojo.html.addClass(this.domNode, this.domNodeClass);
+ dojo.html.addClass(this.tabNode, this.tabClass);
+ dojo.html.addClass(this.returnImageNode, this.returnClass);
+ this.returnImageNode.src = this.returnImage;
+ this.tabContainer = dojo.widget.createWidget("TabContainer", {}, this.tabNode);
+ this.demoTab = dojo.widget.createWidget("DemoPane", {});
+ this.tabContainer.addChild(this.demoTab);
+ this.sourceTab = dojo.widget.createWidget("SourcePane", {});
+ this.tabContainer.addChild(this.sourceTab);
+ dojo.html.setOpacity(this.domNode, 0);
+ dojo.html.hide(this.domNode);
+}, loadDemo:function (url) {
+ this.demoTab.setHref(url);
+ this.sourceTab.setHref(url);
+ this.showDemo();
+}, setName:function (name) {
+ dojo.html.removeChildren(this.demoNameNode);
+ this.demoNameNode.appendChild(document.createTextNode(name));
+}, setSummary:function (summary) {
+ dojo.html.removeChildren(this.summaryNode);
+ this.summaryNode.appendChild(document.createTextNode(summary));
+}, showSource:function () {
+ dojo.html.removeClass(this.demoButtonNode, this.selectedButtonClass);
+ dojo.html.addClass(this.sourceButtonNode, this.selectedButtonClass);
+ this.tabContainer.selectTab(this.sourceTab);
+}, showDemo:function () {
+ dojo.html.removeClass(this.sourceButtonNode, this.selectedButtonClass);
+ dojo.html.addClass(this.demoButtonNode, this.selectedButtonClass);
+ this.tabContainer.selectTab(this.demoTab);
+}, returnToDemos:function () {
+ dojo.debug("Return To Demos");
+}, show:function () {
+ dojo.html.setOpacity(this.domNode, 1);
+ dojo.html.show(this.domNode);
+ this.tabContainer.checkSize();
+}}, "", function () {
+ dojo.debug("DemoPane Init");
+ this.domNodeClass = "demoContainer";
+ this.tabContainer = "";
+ this.sourceTab = "";
+ this.demoTab = "";
+ this.headerNode = "";
+ this.returnNode = "";
+ this.returnImageNode = "";
+ this.returnImage = "images/dojoDemos.gif";
+ this.returnClass = "return";
+ this.summaryNode = "";
+ this.demoNameNode = "";
+ this.tabControlNode = "";
+ this.tabNode = "";
+ this.tabClass = "demoContainerTabs";
+ this.sourceButtonNode = "";
+ this.demoButtonNode = "";
+ this.selectedButtonClass = "selected";
+});
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoContainer.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoContainer.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoContainer.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoItem.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoItem.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoItem.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoItem.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,52 @@
+/*
+ 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.widget.demoEngine.DemoItem");
+dojo.require("dojo.widget.*");
+dojo.require("dojo.widget.HtmlWidget");
+dojo.widget.defineWidget("my.widget.demoEngine.DemoItem", dojo.widget.HtmlWidget, {templateString:"<div dojoAttachPoint=\"domNode\">\n\t<div dojoAttachPoint=\"summaryBoxNode\">\n\t\t<table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\">\n\t\t\t<tbody>\n\t\t\t\t<tr>\n\t\t\t\t\t<td dojoAttachPoint=\"screenshotTdNode\" valign=\"top\" width=\"1%\">\n\t\t\t\t\t\t<img dojoAttachPoint=\"thumbnailImageNode\" dojoAttachEvent=\"onclick: onSelectDemo\" />\n\t\t\t\t\t</td>\n\t\t\t\t\t<td dojoAttachPoint=\"summaryContainerNode\" valign=\"top\">\n\t\t\t\t\t\t<h1 dojoAttachPoint=\"nameNode\">\n\t\t\t\t\t\t</h1>\n\t\t\t\t\t\t<div dojoAttachPoint=\"summaryNode\">\n\t\t\t\t\t\t\t<p dojoAttachPoint=\"descriptionNode\"></p>\n\t\t\t\t\t\t\t<div dojoAttachPoint=\"viewDemoLinkNode\"><img dojoAttachPoint=\"viewDemoImageNode\"/ dojoAttachEvent=\"onclick: onSelectDemo\"></div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\t\t\t</tbody>\n\t\t</table>\n\t</div>\n</div>\n", templateCssString
:".demoItemSummaryBox {\n\tbackground: #efefef;\n\tborder:1px solid #dae3ee;\n}\n\n.demoItemScreenshot {\n\tpadding:0.65em;\n\twidth:175px;\n\tborder-right:1px solid #fafafa;\n\ttext-align:center;\n\tcursor: pointer;\n}\n\n.demoItemWrapper{\n\tmargin-bottom:1em;\n}\n\n.demoItemWrapper a:link, .demoItemWrapper a:visited {\n\tcolor:#a6238f;\n\ttext-decoration:none;\n}\n\n.demoItemSummaryContainer {\n\tborder-left:1px solid #ddd;\n}\n\n.demoItemSummaryContainer h1 {\n\tbackground-color:#e8e8e8;\n\tborder-bottom: 1px solid #e6e6e6;\n\tcolor:#738fb9;\n\tmargin:1px;\n\tpadding:0.5em;\n\tfont-family:\"Lucida Grande\", \"Tahoma\", serif;\n\tfont-size:1.25em;\n\tfont-weight:normal;\n}\n\n.demoItemSummaryContainer h1 .packageSummary {\n\tdisplay:block;\n\tcolor:#000;\n\tfont-size:10px;\n\tmargin-top:2px;\n}\n\n.demoItemSummaryContainer .demoItemSummary{\n\tpadding:1em;\n}\n\n.demoItemSummaryContainer .demoItemSummary p {\n\tfont-size:0.85em;\n\tpadding:0;\n\tmargin:0;\n}\n\n.demoItemV
iew {\n\ttext-align:right;\n\tcursor: pointer;\n}\n", templateCssPath:dojo.uri.moduleUri("dojo.widget", "demoEngine/templates/DemoItem.css"), postCreate:function () {
+ dojo.html.addClass(this.domNode, this.domNodeClass);
+ dojo.html.addClass(this.summaryBoxNode, this.summaryBoxClass);
+ dojo.html.addClass(this.screenshotTdNode, this.screenshotTdClass);
+ dojo.html.addClass(this.summaryContainerNode, this.summaryContainerClass);
+ dojo.html.addClass(this.summaryNode, this.summaryClass);
+ dojo.html.addClass(this.viewDemoLinkNode, this.viewDemoLinkClass);
+ this.nameNode.appendChild(document.createTextNode(this.name));
+ this.descriptionNode.appendChild(document.createTextNode(this.description));
+ this.thumbnailImageNode.src = this.thumbnail;
+ this.thumbnailImageNode.name = this.name;
+ this.viewDemoImageNode.src = this.viewDemoImage;
+ this.viewDemoImageNode.name = this.name;
+}, onSelectDemo:function () {
+}}, "", function () {
+ this.demo = "";
+ this.domNodeClass = "demoItemWrapper";
+ this.summaryBoxNode = "";
+ this.summaryBoxClass = "demoItemSummaryBox";
+ this.nameNode = "";
+ this.thumbnailImageNode = "";
+ this.viewDemoImageNode = "";
+ this.screenshotTdNode = "";
+ this.screenshotTdClass = "demoItemScreenshot";
+ this.summaryContainerNode = "";
+ this.summaryContainerClass = "demoItemSummaryContainer";
+ this.summaryNode = "";
+ this.summaryClass = "demoItemSummary";
+ this.viewDemoLinkNode = "";
+ this.viewDemoLinkClass = "demoItemView";
+ this.descriptionNode = "";
+ this.name = "Some Demo";
+ this.description = "This is the description of this demo.";
+ this.thumbnail = "images/test_thumb.gif";
+ this.viewDemoImage = "images/viewDemo.png";
+});
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoItem.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoItem.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoItem.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoNavigator.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoNavigator.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoNavigator.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoNavigator.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,134 @@
+/*
+ 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.widget.demoEngine.DemoNavigator");
+dojo.require("dojo.widget.*");
+dojo.require("dojo.widget.HtmlWidget");
+dojo.require("dojo.widget.Button");
+dojo.require("dojo.widget.demoEngine.DemoItem");
+dojo.require("dojo.io.*");
+dojo.require("dojo.lfx.*");
+dojo.require("dojo.lang.common");
+dojo.widget.defineWidget("my.widget.demoEngine.DemoNavigator", dojo.widget.HtmlWidget, {templateString:"<div dojoAttachPoint=\"domNode\">\n\t<table width=\"100%\" cellspacing=\"0\" cellpadding=\"5\">\n\t\t<tbody>\n\t\t\t<tr dojoAttachPoint=\"navigationContainer\">\n\t\t\t\t<td dojoAttachPoint=\"categoriesNode\" valign=\"top\" width=\"1%\">\n\t\t\t\t\t<h1>Categories</h1>\n\t\t\t\t\t<div dojoAttachPoint=\"categoriesButtonsNode\"></div>\n\t\t\t\t</td>\n\n\t\t\t\t<td dojoAttachPoint=\"demoListNode\" valign=\"top\">\n\t\t\t\t\t<div dojoAttachPoint=\"demoListWrapperNode\">\n\t\t\t\t\t\t<div dojoAttachPoint=\"demoListContainerNode\">\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t</td>\n\t\t\t</tr>\n\t\t\t<tr>\n\t\t\t\t<td colspan=\"2\">\n\t\t\t\t\t<div dojoAttachPoint=\"demoNode\"></div>\n\t\t\t\t</td>\n\t\t\t</tr>\n\t\t</tbody>\n\t</table>\n</div>\n", templateCssString:".demoNavigatorListWrapper {\n\tborder:1px solid #dcdbdb;\n\tbackground-color:#f8f8f8;\n\tpadding:2px;\n}\n\n.de
moNavigatorListContainer {\n\tborder:1px solid #f0f0f0;\n\tbackground-color:#fff;\n\tpadding:1em;\n}\n\n.demoNavigator h1 {\n\tmargin-top: 0px;\n\tmargin-bottom: 10px;\n\tfont-size: 1.2em;\n\tborder-bottom:1px dotted #a9ccf5;\n}\n\n.demoNavigator .dojoButton {\n\tmargin-bottom: 5px;\n}\n\n.demoNavigator .dojoButton .dojoButtonContents {\n\tfont-size: 1.1em;\n\twidth: 100px;\n\tcolor: black;\n}\n", templateCssPath:dojo.uri.moduleUri("dojo.widget", "demoEngine/templates/DemoNavigator.css"), postCreate:function () {
+ dojo.html.addClass(this.domNode, this.domNodeClass);
+ dojo.html.addClass(this.demoListWrapperNode, this.demoListWrapperClass);
+ dojo.html.addClass(this.demoListContainerNode, this.demoListContainerClass);
+ if (dojo.render.html.ie) {
+ dojo.debug("render ie");
+ dojo.html.hide(this.demoListWrapperNode);
+ } else {
+ dojo.debug("render non-ie");
+ dojo.lfx.html.fadeHide(this.demoListWrapperNode, 0).play();
+ }
+ this.getRegistry(this.demoRegistryUrl);
+ this.demoContainer = dojo.widget.createWidget("DemoContainer", {returnImage:this.returnImage}, this.demoNode);
+ dojo.event.connect(this.demoContainer, "returnToDemos", this, "returnToDemos");
+ this.demoContainer.hide();
+}, returnToDemos:function () {
+ this.demoContainer.hide();
+ if (dojo.render.html.ie) {
+ dojo.debug("render ie");
+ dojo.html.show(this.navigationContainer);
+ } else {
+ dojo.debug("render non-ie");
+ dojo.lfx.html.fadeShow(this.navigationContainer, 250).play();
+ }
+ dojo.lang.forEach(this.categoriesChildren, dojo.lang.hitch(this, function (child) {
+ child.checkSize();
+ }));
+ dojo.lang.forEach(this.demoListChildren, dojo.lang.hitch(this, function (child) {
+ child.checkSize();
+ }));
+}, show:function () {
+ dojo.html.show(this.domNode);
+ dojo.html.setOpacity(this.domNode, 1);
+ dojo.html.setOpacity(this.navigationContainer, 1);
+ dojo.lang.forEach(this.categoriesChildren, dojo.lang.hitch(this, function (child) {
+ child.checkSize();
+ }));
+ dojo.lang.forEach(this.demoListChildren, dojo.lang.hitch(this, function (child) {
+ child.checkSize();
+ }));
+}, getRegistry:function (url) {
+ dojo.io.bind({url:url, load:dojo.lang.hitch(this, this.processRegistry), mimetype:"text/json"});
+}, processRegistry:function (type, registry, e) {
+ dojo.debug("Processing Registry");
+ this.registry = registry;
+ dojo.lang.forEach(this.registry.navigation, dojo.lang.hitch(this, this.addCategory));
+}, addCategory:function (category) {
+ var newCat = dojo.widget.createWidget("Button", {caption:category.name});
+ if (!dojo.lang.isObject(this.registry.categories)) {
+ this.registry.categories = function () {
+ };
+ }
+ this.registry.categories[category.name] = category;
+ this.categoriesChildren.push(newCat);
+ this.categoriesButtonsNode.appendChild(newCat.domNode);
+ newCat.domNode.categoryName = category.name;
+ dojo.event.connect(newCat, "onClick", this, "onSelectCategory");
+}, addDemo:function (demoName) {
+ var demo = this.registry.definitions[demoName];
+ if (dojo.render.html.ie) {
+ dojo.html.show(this.demoListWrapperNode);
+ } else {
+ dojo.lfx.html.fadeShow(this.demoListWrapperNode, 250).play();
+ }
+ var newDemo = dojo.widget.createWidget("DemoItem", {viewDemoImage:this.viewDemoImage, name:demoName, description:demo.description, thumbnail:demo.thumbnail});
+ this.demoListChildren.push(newDemo);
+ this.demoListContainerNode.appendChild(newDemo.domNode);
+ dojo.event.connect(newDemo, "onSelectDemo", this, "onSelectDemo");
+}, onSelectCategory:function (e) {
+ catName = e.currentTarget.categoryName;
+ dojo.debug("Selected Category: " + catName);
+ dojo.lang.forEach(this.demoListChildren, function (child) {
+ child.destroy();
+ });
+ this.demoListChildren = [];
+ dojo.lang.forEach(this.registry.categories[catName].demos, dojo.lang.hitch(this, function (demoName) {
+ this.addDemo(demoName);
+ }));
+}, onSelectDemo:function (e) {
+ dojo.debug("Demo Selected: " + e.target.name);
+ if (dojo.render.html.ie) {
+ dojo.debug("render ie");
+ dojo.html.hide(this.navigationContainer);
+ this.demoContainer.show();
+ this.demoContainer.showDemo();
+ } else {
+ dojo.debug("render non-ie");
+ dojo.lfx.html.fadeHide(this.navigationContainer, 250, null, dojo.lang.hitch(this, function () {
+ this.demoContainer.show();
+ this.demoContainer.showDemo();
+ })).play();
+ }
+ this.demoContainer.loadDemo(this.registry.definitions[e.target.name].url);
+ this.demoContainer.setName(e.target.name);
+ this.demoContainer.setSummary(this.registry.definitions[e.target.name].description);
+}}, "", function () {
+ this.demoRegistryUrl = "demoRegistry.json";
+ this.registry = function () {
+ };
+ this.categoriesNode = "";
+ this.categoriesButtonsNode = "";
+ this.navigationContainer = "";
+ this.domNodeClass = "demoNavigator";
+ this.demoNode = "";
+ this.demoContainer = "";
+ this.demoListWrapperNode = "";
+ this.demoListWrapperClass = "demoNavigatorListWrapper";
+ this.demoListContainerClass = "demoNavigatorListContainer";
+ this.returnImage = "images/dojoDemos.gif";
+ this.viewDemoImage = "images/viewDemo.png";
+ this.demoListChildren = [];
+ this.categoriesChildren = [];
+});
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoNavigator.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoNavigator.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoNavigator.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoPane.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoPane.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoPane.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoPane.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,33 @@
+/*
+ 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.widget.demoEngine.DemoPane");
+dojo.require("dojo.widget.*");
+dojo.require("dojo.widget.HtmlWidget");
+dojo.widget.defineWidget("my.widget.demoEngine.DemoPane", dojo.widget.HtmlWidget, {templateString:"<div dojoAttachPoint=\"domNode\">\n\t<iframe dojoAttachPoint=\"demoNode\"></iframe>\n</div>\n", templateCssString:".demoPane {\n\twidth: 100%;\n\theight: 100%;\n\tpadding: 0px;\n\tmargin: 0px;\n\toverflow: hidden;\n}\n\n.demoPane iframe {\n\twidth: 100%;\n\theight: 100%;\n\tborder: 0px;\n\tborder: none;\n\toverflow: auto;\n\tpadding: 0px;\n\tmargin:0px;\n\tbackground: #ffffff;\n}\n", templateCssPath:dojo.uri.moduleUri("dojo.widget", "demoEngine/templates/DemoPane.css"), postCreate:function () {
+ dojo.html.addClass(this.domNode, this.domNodeClass);
+ dojo.debug("PostCreate");
+ this._launchDemo();
+}, _launchDemo:function () {
+ dojo.debug("Launching Demo");
+ dojo.debug(this.demoNode);
+ this.demoNode.src = this.href;
+}, setHref:function (url) {
+ this.href = url;
+ this._launchDemo();
+}}, "", function () {
+ dojo.debug("DemoPane Init");
+ this.domNodeClass = "demoPane";
+ this.demoNode = "";
+ this.href = "";
+});
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoPane.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoPane.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/DemoPane.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/SourcePane.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/SourcePane.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/SourcePane.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/SourcePane.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.provide("dojo.widget.demoEngine.SourcePane");
+dojo.require("dojo.widget.*");
+dojo.require("dojo.widget.HtmlWidget");
+dojo.require("dojo.io.*");
+dojo.widget.defineWidget("my.widget.demoEngine.SourcePane", dojo.widget.HtmlWidget, {templateString:"<div dojoAttachPoint=\"domNode\">\n\t<textarea dojoAttachPoint=\"sourceNode\" rows=\"100%\"></textarea>\n</div>\n", templateCssString:".sourcePane {\n\twidth: 100%;\n\theight: 100%;\n\tpadding: 0px;\n\tmargin: 0px;\n\toverflow: hidden;\n}\n\n.sourcePane textarea{\n\twidth: 100%;\n\theight: 100%;\n\tborder: 0px;\n\toverflow: auto;\n\tpadding: 0px;\n\tmargin:0px;\n}\n\n* html .sourcePane {\n\toverflow: auto;\n}\n", templateCssPath:dojo.uri.moduleUri("dojo.widget", "demoEngine/templates/SourcePane.css"), postCreate:function () {
+ dojo.html.addClass(this.domNode, this.domNodeClass);
+ dojo.debug("PostCreate");
+}, getSource:function () {
+ if (this.href) {
+ dojo.io.bind({url:this.href, load:dojo.lang.hitch(this, "fillInSource"), mimetype:"text/plain"});
+ }
+}, fillInSource:function (type, source, e) {
+ this.sourceNode.value = source;
+}, setHref:function (url) {
+ this.href = url;
+ this.getSource();
+}}, "", function () {
+ dojo.debug("SourcePane Init");
+ this.domNodeClass = "sourcePane";
+ this.sourceNode = "";
+ this.href = "";
+});
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/SourcePane.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/SourcePane.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/SourcePane.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/__package__.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/__package__.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/__package__.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/__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({browser:["dojo.widget.demoEngine.DemoItem", "dojo.widget.demoEngine.DemoNavigator", "dojo.widget.demoEngine.DemoPane", "dojo.widget.demoEngine.SourcePane", "dojo.widget.demoEngine.DemoContainer"]});
+dojo.provide("dojo.widget.demoEngine.*");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/__package__.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/__package__.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/__package__.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.css
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.css?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.css (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.css Thu Jul 16 19:14:41 2009
@@ -0,0 +1,39 @@
+.demoContainer{
+ width: 100%;
+ height: 100%;
+ padding: 0px;
+ margin: 0px;
+}
+
+.demoContainer .return {
+ cursor: pointer;
+}
+
+.demoContainer span {
+ margin-right: 10px;
+ cursor: pointer;
+}
+
+.demoContainer .selected {
+ border-bottom: 5px solid #95bfff;
+}
+
+.demoContainer table {
+ background: #f5f5f5;
+ width: 100%;
+ height: 100%;
+}
+
+.demoContainerTabs {
+ width: 100%;
+ height: 400px;
+}
+
+.demoContainerTabs .dojoTabLabels-top {
+ display: none;
+}
+
+.demoContainerTabs .dojoTabPaneWrapper {
+ border: 0px;
+}
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.css
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.css
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.css
------------------------------------------------------------------------------
svn:mime-type = text/css
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.html
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.html?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.html (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.html Thu Jul 16 19:14:41 2009
@@ -0,0 +1,25 @@
+<div dojoAttachPoint="domNode">
+ <table width="100%" cellspacing="0" cellpadding="5">
+ <tbody>
+ <tr dojoAttachPoint="headerNode">
+ <td dojoAttachPoint="returnNode" valign="middle" width="1%">
+ <img dojoAttachPoint="returnImageNode" dojoAttachEvent="onclick: returnToDemos"/>
+ </td>
+ <td>
+ <h1 dojoAttachPoint="demoNameNode"></h1>
+ <p dojoAttachPoint="summaryNode"></p>
+ </td>
+ <td dojoAttachPoint="tabControlNode" valign="middle" align="right" nowrap>
+ <span dojoAttachPoint="sourceButtonNode" dojoAttachEvent="onclick: showSource">source</span>
+ <span dojoAttachPoint="demoButtonNode" dojoAttachEvent="onclick: showDemo">demo</span>
+ </td>
+ </tr>
+ <tr>
+ <td colspan="3">
+ <div dojoAttachPoint="tabNode">
+ </div>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+</div>
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.html
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.html
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoContainer.html
------------------------------------------------------------------------------
svn:mime-type = text/html
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.css
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.css?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.css (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.css Thu Jul 16 19:14:41 2009
@@ -0,0 +1,58 @@
+.demoItemSummaryBox {
+ background: #efefef;
+ border:1px solid #dae3ee;
+}
+
+.demoItemScreenshot {
+ padding:0.65em;
+ width:175px;
+ border-right:1px solid #fafafa;
+ text-align:center;
+ cursor: pointer;
+}
+
+.demoItemWrapper{
+ margin-bottom:1em;
+}
+
+.demoItemWrapper a:link, .demoItemWrapper a:visited {
+ color:#a6238f;
+ text-decoration:none;
+}
+
+.demoItemSummaryContainer {
+ border-left:1px solid #ddd;
+}
+
+.demoItemSummaryContainer h1 {
+ background-color:#e8e8e8;
+ border-bottom: 1px solid #e6e6e6;
+ color:#738fb9;
+ margin:1px;
+ padding:0.5em;
+ font-family:"Lucida Grande", "Tahoma", serif;
+ font-size:1.25em;
+ font-weight:normal;
+}
+
+.demoItemSummaryContainer h1 .packageSummary {
+ display:block;
+ color:#000;
+ font-size:10px;
+ margin-top:2px;
+}
+
+.demoItemSummaryContainer .demoItemSummary{
+ padding:1em;
+}
+
+.demoItemSummaryContainer .demoItemSummary p {
+ font-size:0.85em;
+ padding:0;
+ margin:0;
+}
+
+.demoItemView {
+ text-align:right;
+ cursor: pointer;
+}
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.css
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.css
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.css
------------------------------------------------------------------------------
svn:mime-type = text/css
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.html
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.html?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.html (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.html Thu Jul 16 19:14:41 2009
@@ -0,0 +1,21 @@
+<div dojoAttachPoint="domNode">
+ <div dojoAttachPoint="summaryBoxNode">
+ <table width="100%" cellspacing="0" cellpadding="0">
+ <tbody>
+ <tr>
+ <td dojoAttachPoint="screenshotTdNode" valign="top" width="1%">
+ <img dojoAttachPoint="thumbnailImageNode" dojoAttachEvent="onclick: onSelectDemo" />
+ </td>
+ <td dojoAttachPoint="summaryContainerNode" valign="top">
+ <h1 dojoAttachPoint="nameNode">
+ </h1>
+ <div dojoAttachPoint="summaryNode">
+ <p dojoAttachPoint="descriptionNode"></p>
+ <div dojoAttachPoint="viewDemoLinkNode"><img dojoAttachPoint="viewDemoImageNode"/ dojoAttachEvent="onclick: onSelectDemo"></div>
+ </div>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
+</div>
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.html
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.html
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoItem.html
------------------------------------------------------------------------------
svn:mime-type = text/html
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.css
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.css?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.css (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.css Thu Jul 16 19:14:41 2009
@@ -0,0 +1,28 @@
+.demoNavigatorListWrapper {
+ border:1px solid #dcdbdb;
+ background-color:#f8f8f8;
+ padding:2px;
+}
+
+.demoNavigatorListContainer {
+ border:1px solid #f0f0f0;
+ background-color:#fff;
+ padding:1em;
+}
+
+.demoNavigator h1 {
+ margin-top: 0px;
+ margin-bottom: 10px;
+ font-size: 1.2em;
+ border-bottom:1px dotted #a9ccf5;
+}
+
+.demoNavigator .dojoButton {
+ margin-bottom: 5px;
+}
+
+.demoNavigator .dojoButton .dojoButtonContents {
+ font-size: 1.1em;
+ width: 100px;
+ color: black;
+}
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.css
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.css
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.css
------------------------------------------------------------------------------
svn:mime-type = text/css
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.html
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.html?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.html (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.html Thu Jul 16 19:14:41 2009
@@ -0,0 +1,24 @@
+<div dojoAttachPoint="domNode">
+ <table width="100%" cellspacing="0" cellpadding="5">
+ <tbody>
+ <tr dojoAttachPoint="navigationContainer">
+ <td dojoAttachPoint="categoriesNode" valign="top" width="1%">
+ <h1>Categories</h1>
+ <div dojoAttachPoint="categoriesButtonsNode"></div>
+ </td>
+
+ <td dojoAttachPoint="demoListNode" valign="top">
+ <div dojoAttachPoint="demoListWrapperNode">
+ <div dojoAttachPoint="demoListContainerNode">
+ </div>
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td colspan="2">
+ <div dojoAttachPoint="demoNode"></div>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+</div>
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.html
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.html
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoNavigator.html
------------------------------------------------------------------------------
svn:mime-type = text/html
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.css
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.css?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.css (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.css Thu Jul 16 19:14:41 2009
@@ -0,0 +1,18 @@
+.demoPane {
+ width: 100%;
+ height: 100%;
+ padding: 0px;
+ margin: 0px;
+ overflow: hidden;
+}
+
+.demoPane iframe {
+ width: 100%;
+ height: 100%;
+ border: 0px;
+ border: none;
+ overflow: auto;
+ padding: 0px;
+ margin:0px;
+ background: #ffffff;
+}
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.css
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.css
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.css
------------------------------------------------------------------------------
svn:mime-type = text/css
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.html
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.html?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.html (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.html Thu Jul 16 19:14:41 2009
@@ -0,0 +1,3 @@
+<div dojoAttachPoint="domNode">
+ <iframe dojoAttachPoint="demoNode"></iframe>
+</div>
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.html
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.html
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/DemoPane.html
------------------------------------------------------------------------------
svn:mime-type = text/html
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.css
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.css?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.css (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.css Thu Jul 16 19:14:41 2009
@@ -0,0 +1,20 @@
+.sourcePane {
+ width: 100%;
+ height: 100%;
+ padding: 0px;
+ margin: 0px;
+ overflow: hidden;
+}
+
+.sourcePane textarea{
+ width: 100%;
+ height: 100%;
+ border: 0px;
+ overflow: auto;
+ padding: 0px;
+ margin:0px;
+}
+
+* html .sourcePane {
+ overflow: auto;
+}
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.css
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.css
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.css
------------------------------------------------------------------------------
svn:mime-type = text/css
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.html
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.html?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.html (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.html Thu Jul 16 19:14:41 2009
@@ -0,0 +1,3 @@
+<div dojoAttachPoint="domNode">
+ <textarea dojoAttachPoint="sourceNode" rows="100%"></textarea>
+</div>
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.html
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.html
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/SourcePane.html
------------------------------------------------------------------------------
svn:mime-type = text/html
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/general.css
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/general.css?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/general.css (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/general.css Thu Jul 16 19:14:41 2009
@@ -0,0 +1,73 @@
+.demoListWrapper {
+ border:1px solid #dcdbdb;
+ background-color:#f8f8f8;
+ padding:2px;
+}
+
+.demoListContainer {
+ border:1px solid #f0f0f0;
+ background-color:#fff;
+ padding:1em;
+}
+
+.demoSummaryBox {
+ background: #efefef;
+ border:1px solid #dae3ee;
+}
+
+.screenshot {
+ padding:0.65em;
+ width:175px;
+ border-right:1px solid #fafafa;
+ text-align:center;
+}
+
+.demoSummary {
+ margin-bottom:1em;
+}
+
+.demoSummary a:link, .demoSummary a:visited {
+ color:#a6238f;
+ text-decoration:none;
+}
+
+.summaryContainer {
+ border-left:1px solid #ddd;
+}
+
+.summaryContainer h1 {
+ background-color:#e8e8e8;
+ border-bottom: 1px solid #e6e6e6;
+ color:#738fb9;
+ margin:1px;
+ padding:0.5em;
+ font-family:"Lucida Grande", "Tahoma", serif;
+ font-size:1.25em;
+ font-weight:normal;
+}
+
+.summaryContainer h1 .packageSummary {
+ display:block;
+ color:#000;
+ font-size:10px;
+ margin-top:2px;
+}
+
+.summaryContainer .summary {
+ padding:1em;
+}
+
+.summaryContainer .summary p {
+ font-size:0.85em;
+ padding:0;
+ margin:0;
+}
+
+.reflection {
+ background: url("images/demoBoxReflection.gif") repeat-x top left;
+ height:25px;
+}
+
+.view {
+ text-align:right;
+}
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/general.css
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/general.css
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/demoEngine/templates/general.css
------------------------------------------------------------------------------
svn:mime-type = text/css
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/layout.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/layout.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/layout.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/layout.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,94 @@
+/*
+ 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.widget.html.layout");
+dojo.require("dojo.lang.common");
+dojo.require("dojo.string.extras");
+dojo.require("dojo.html.style");
+dojo.require("dojo.html.layout");
+dojo.widget.html.layout = function (container, children, layoutPriority) {
+ dojo.html.addClass(container, "dojoLayoutContainer");
+ children = dojo.lang.filter(children, function (child, idx) {
+ child.idx = idx;
+ return dojo.lang.inArray(["top", "bottom", "left", "right", "client", "flood"], child.layoutAlign);
+ });
+ if (layoutPriority && layoutPriority != "none") {
+ var rank = function (child) {
+ switch (child.layoutAlign) {
+ case "flood":
+ return 1;
+ case "left":
+ case "right":
+ return (layoutPriority == "left-right") ? 2 : 3;
+ case "top":
+ case "bottom":
+ return (layoutPriority == "left-right") ? 3 : 2;
+ default:
+ return 4;
+ }
+ };
+ children.sort(function (a, b) {
+ return (rank(a) - rank(b)) || (a.idx - b.idx);
+ });
+ }
+ var f = {top:dojo.html.getPixelValue(container, "padding-top", true), left:dojo.html.getPixelValue(container, "padding-left", true)};
+ dojo.lang.mixin(f, dojo.html.getContentBox(container));
+ dojo.lang.forEach(children, function (child) {
+ var elm = child.domNode;
+ var pos = child.layoutAlign;
+ with (elm.style) {
+ left = f.left + "px";
+ top = f.top + "px";
+ bottom = "auto";
+ right = "auto";
+ }
+ dojo.html.addClass(elm, "dojoAlign" + dojo.string.capitalize(pos));
+ if ((pos == "top") || (pos == "bottom")) {
+ dojo.html.setMarginBox(elm, {width:f.width});
+ var h = dojo.html.getMarginBox(elm).height;
+ f.height -= h;
+ if (pos == "top") {
+ f.top += h;
+ } else {
+ elm.style.top = f.top + f.height + "px";
+ }
+ if (child.onResized) {
+ child.onResized();
+ }
+ } else {
+ if (pos == "left" || pos == "right") {
+ var w = dojo.html.getMarginBox(elm).width;
+ if (child.resizeTo) {
+ child.resizeTo(w, f.height);
+ } else {
+ dojo.html.setMarginBox(elm, {width:w, height:f.height});
+ }
+ f.width -= w;
+ if (pos == "left") {
+ f.left += w;
+ } else {
+ elm.style.left = f.left + f.width + "px";
+ }
+ } else {
+ if (pos == "flood" || pos == "client") {
+ if (child.resizeTo) {
+ child.resizeTo(f.width, f.height);
+ } else {
+ dojo.html.setMarginBox(elm, {width:f.width, height:f.height});
+ }
+ }
+ }
+ }
+ });
+};
+dojo.html.insertCssText(".dojoLayoutContainer{ position: relative; display: block; overflow: hidden; }\n" + "body .dojoAlignTop, body .dojoAlignBottom, body .dojoAlignLeft, body .dojoAlignRight { position: absolute; overflow: hidden; }\n" + "body .dojoAlignClient { position: absolute }\n" + ".dojoAlignClient { overflow: auto; }\n");
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/layout.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/layout.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/layout.js
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/loader.js
URL: http://svn.apache.org/viewvc/geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/loader.js?rev=794787&view=auto
==============================================================================
--- geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/loader.js (added)
+++ geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/loader.js Thu Jul 16 19:14:41 2009
@@ -0,0 +1,622 @@
+/*
+ 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.widget.html.loader");
+dojo.require("dojo.widget.HtmlWidget");
+dojo.require("dojo.io.*");
+dojo.require("dojo.lang.common");
+dojo.require("dojo.lang.extras");
+dojo.require("dojo.experimental");
+dojo.experimental("dojo.widget.html.loader");
+dojo.widget.html.loader = new (function () {
+ this.toString = function () {
+ return "dojo.widget.html.loader";
+ };
+ var _loader = this;
+ dojo.addOnLoad(function () {
+ dojo.experimental(_loader.toString());
+ var undo = dojo.evalObjPath("dojo.undo.browser");
+ if (djConfig["preventBackButtonFix"] && undo && !undo.initialState) {
+ undo.setInitialState(new trackerObj);
+ }
+ });
+ var logger = {};
+ var trackerObj = function (id, data) {
+ this.id = id;
+ this.data = data;
+ };
+ trackerObj.prototype.handle = function (type) {
+ if (typeof dojo == "undefined") {
+ return;
+ }
+ var wg = dojo.widget.byId(this.id);
+ if (wg) {
+ wg.setContent(this.data, true);
+ }
+ };
+ this._log = function (widget, data) {
+ if (widget.trackHistory) {
+ if (!logger[widget.widgetId]) {
+ logger[widget.widgetId] = {childrenIds:[], stack:[data]};
+ }
+ var children = logger[widget.widgetId].childrenIds;
+ while (children && children.length) {
+ delete logger[children.pop()];
+ }
+ for (var child in widget.children) {
+ logger[widget.widgetId].childrenIds = child.widgetId;
+ }
+ dojo.undo.browser.addToHistory(new trackerObj(widget.widgetId, dojo.lang.shallowCopy(data, true)));
+ }
+ };
+ var undef = dojo.lang.isUndefined;
+ var isFunc = dojo.lang.isFunction;
+ function handleDefaults(e, handler, useAlert) {
+ if (!handler) {
+ handler = "onContentError";
+ }
+ if (dojo.lang.isString(e)) {
+ e = {_text:e};
+ }
+ if (!e._text) {
+ e._text = e.toString();
+ }
+ e.toString = function () {
+ return this._text;
+ };
+ if (typeof e.returnValue != "boolean") {
+ e.returnValue = true;
+ }
+ if (typeof e.preventDefault != "function") {
+ e.preventDefault = function () {
+ this.returnValue = false;
+ };
+ }
+ this[handler](e);
+ if (e.returnValue) {
+ if (useAlert) {
+ alert(e.toString());
+ } else {
+ this.loader.callOnUnLoad.call(this, false);
+ this.onSetContent(e.toString());
+ }
+ }
+ }
+ function downloader(bindArgs) {
+ for (var x in this.bindArgs) {
+ bindArgs[x] = (undef(bindArgs[x]) ? this.bindArgs[x] : undefined);
+ }
+ var cache = this.cacheContent;
+ if (undef(bindArgs.useCache)) {
+ bindArgs.useCache = cache;
+ }
+ if (undef(bindArgs.preventCache)) {
+ bindArgs.preventCache = !cache;
+ }
+ if (undef(bindArgs.mimetype)) {
+ bindArgs.mimetype = "text/html";
+ }
+ this.loader.bindObj = dojo.io.bind(bindArgs);
+ }
+ function stackRunner(st) {
+ var err = "", func = null;
+ var scope = this.scriptScope || dojo.global();
+ while (st.length) {
+ func = st.shift();
+ try {
+ func.call(scope);
+ }
+ catch (e) {
+ err += "\n" + func + " failed: " + e;
+ }
+ }
+ if (err.length) {
+ var name = (st == this.loader.addOnLoads) ? "addOnLoad" : "addOnUnLoad";
+ handleDefaults.call(this, name + " failure\n " + err, "onExecError", true);
+ }
+ }
+ function stackPusher(st, obj, func) {
+ if (typeof func == "undefined") {
+ st.push(obj);
+ } else {
+ st.push(function () {
+ obj[func]();
+ });
+ }
+ }
+ function refreshed() {
+ this.onResized();
+ this.onLoad();
+ this.isLoaded = true;
+ }
+ function asyncParse(data) {
+ if (this.executeScripts) {
+ this.onExecScript.call(this, data.scripts);
+ }
+ if (this.parseContent) {
+ this.onContentParse.call(this);
+ }
+ refreshed.call(this);
+ }
+ function runHandler() {
+ if (dojo.lang.isFunction(this.handler)) {
+ this.handler(this, this.containerNode || this.domNode);
+ refreshed.call(this);
+ return false;
+ }
+ return true;
+ }
+ this.htmlContentBasicFix = function (s, url) {
+ var titles = [], styles = [];
+ var regex = /<title[^>]*>([\s\S]*?)<\/title>/i;
+ var match, attr;
+ while (match = regex.exec(s)) {
+ titles.push(match[1]);
+ s = s.substring(0, match.index) + s.substr(match.index + match[0].length);
+ }
+ regex = /(?:<(style)[^>]*>([\s\S]*?)<\/style>|<link ([^>]*rel=['"]?stylesheet['"]?[^>]*)>)/i;
+ while (match = regex.exec(s)) {
+ if (match[1] && match[1].toLowerCase() == "style") {
+ styles.push(dojo.html.fixPathsInCssText(match[2], url));
+ } else {
+ if (attr = match[3].match(/href=(['"]?)([^'">]*)\1/i)) {
+ styles.push({path:attr[2]});
+ }
+ }
+ s = s.substring(0, match.index) + s.substr(match.index + match[0].length);
+ }
+ return {"s":s, "titles":titles, "styles":styles};
+ };
+ this.htmlContentAdjustPaths = function (s, url) {
+ var tag = "", str = "", tagFix = "", path = "";
+ var attr = [], origPath = "", fix = "";
+ var regexFindTag = /<[a-z][a-z0-9]*[^>]*\s(?:(?:src|href|style)=[^>])+[^>]*>/i;
+ var regexFindAttr = /\s(src|href|style)=(['"]?)([\w()\[\]\/.,\\'"-:;#=&?\s@]+?)\2/i;
+ var regexProtocols = /^(?:[#]|(?:(?:https?|ftps?|file|javascript|mailto|news):))/;
+ while (tag = regexFindTag.exec(s)) {
+ str += s.substring(0, tag.index);
+ s = s.substring((tag.index + tag[0].length), s.length);
+ tag = tag[0];
+ tagFix = "";
+ while (attr = regexFindAttr.exec(tag)) {
+ path = "";
+ origPath = attr[3];
+ switch (attr[1].toLowerCase()) {
+ case "src":
+ case "href":
+ if (regexProtocols.exec(origPath)) {
+ path = origPath;
+ } else {
+ path = (new dojo.uri.Uri(url, origPath).toString());
+ }
+ break;
+ case "style":
+ path = dojo.html.fixPathsInCssText(origPath, url);
+ break;
+ default:
+ path = origPath;
+ }
+ fix = " " + attr[1] + "=" + attr[2] + path + attr[2];
+ tagFix += tag.substring(0, attr.index) + fix;
+ tag = tag.substring((attr.index + attr[0].length), tag.length);
+ }
+ str += tagFix + tag;
+ }
+ return str + s;
+ };
+ this.htmlContentScripts = function (s, collectScripts) {
+ var scripts = [], requires = [], match = [];
+ var attr = "", tmp = null, tag = "", sc = "", str = "";
+ var regex = /<script([^>]*)>([\s\S]*?)<\/script>/i;
+ var regexSrc = /src=(['"]?)([^"']*)\1/i;
+ var regexDojoJs = /.*(\bdojo\b\.js(?:\.uncompressed\.js)?)$/;
+ var regexInvalid = /(?:var )?\bdjConfig\b(?:[\s]*=[\s]*\{[^}]+\}|\.[\w]*[\s]*=[\s]*[^;\n]*)?;?|dojo\.hostenv\.writeIncludes\(\s*\);?/g;
+ var regexRequires = /dojo\.(?:(?:require(?:After)?(?:If)?)|(?:widget\.(?:manager\.)?registerWidgetPackage)|(?:(?:hostenv\.)?setModulePrefix)|defineNamespace)\((['"]).*?\1\)\s*;?/;
+ while (match = regex.exec(s)) {
+ if (this.executeScripts && match[1]) {
+ if (attr = regexSrc.exec(match[1])) {
+ if (regexDojoJs.exec(attr[2])) {
+ dojo.debug("Security note! inhibit:" + attr[2] + " from beeing loaded again.");
+ } else {
+ scripts.push({path:attr[2]});
+ }
+ }
+ }
+ if (match[2]) {
+ sc = match[2].replace(regexInvalid, "");
+ if (!sc) {
+ continue;
+ }
+ while (tmp = regexRequires.exec(sc)) {
+ requires.push(tmp[0]);
+ sc = sc.substring(0, tmp.index) + sc.substr(tmp.index + tmp[0].length);
+ }
+ if (collectScripts) {
+ scripts.push(sc);
+ }
+ }
+ s = s.substr(0, match.index) + s.substr(match.index + match[0].length);
+ }
+ if (collectScripts) {
+ var regex = /(<[a-zA-Z][a-zA-Z0-9]*\s[^>]*\S=(['"])[^>]*[^\.\]])scriptScope([^>]*>)/;
+ str = "";
+ while (tag = regex.exec(s)) {
+ tmp = ((tag[2] == "'") ? "\"" : "'");
+ str += s.substring(0, tag.index);
+ s = s.substr(tag.index).replace(regex, "$1dojo.widget.byId(" + tmp + this.widgetId + tmp + ").scriptScope$3");
+ }
+ s = str + s;
+ }
+ return {"s":s, "requires":requires, "scripts":scripts};
+ };
+ this.splitAndFixPaths = function (args) {
+ if (!args.url) {
+ args.url = "./";
+ }
+ url = new dojo.uri.Uri(location, args.url).toString();
+ var ret = {"xml":"", "styles":[], "titles":[], "requires":[], "scripts":[], "url":url};
+ if (args.content) {
+ var tmp = null, content = args.content;
+ if (args.adjustPaths) {
+ content = _loader.htmlContentAdjustPaths.call(this, content, url);
+ }
+ tmp = _loader.htmlContentBasicFix.call(this, content, url);
+ content = tmp.s;
+ ret.styles = tmp.styles;
+ ret.titles = tmp.titles;
+ if (args.collectRequires || args.collectScripts) {
+ tmp = _loader.htmlContentScripts.call(this, content, args.collectScripts);
+ content = tmp.s;
+ ret.requires = tmp.requires;
+ ret.scripts = tmp.scripts;
+ }
+ var match = [];
+ if (args.bodyExtract) {
+ match = content.match(/<body[^>]*>\s*([\s\S]+)\s*<\/body>/im);
+ if (match) {
+ content = match[1];
+ }
+ }
+ ret.xml = content;
+ }
+ return ret;
+ };
+ this.hookUp = function (args) {
+ var widget = args.widget;
+ if (dojo.lang.isString(widget)) {
+ if (args.mixin) {
+ dojo.raise(this.toString() + ", cant use mixin when widget is a string");
+ }
+ widget = dojo.evalObjPath(widget);
+ }
+ if (!widget || !(widget instanceof dojo.widget.HtmlWidget)) {
+ dojo.raise(this.toString() + " Widget isn't defined or isn't a HtmlWidget instance");
+ }
+ if (widget.loader && widget.setUrl) {
+ return;
+ }
+ var widgetProto = (args.mixin) ? widget : widget.constructor.prototype;
+ widget.loader = {isLoaded:false, styleNodes:[], addOnLoads:[], addOnUnLoads:[], callOnUnLoad:(function (canCall) {
+ return function (after) {
+ this.abort();
+ if (canCall) {
+ this.onUnLoad();
+ }
+ canCall = after;
+ };
+ })(false), bindObj:null, unHook:(function (w, wg) {
+ var oldProps = {isContainer:w.isContainer, adjustPats:w.adjustPaths, href:w.href, extractContent:w.extractContent, parseContent:w.parseContent, cacheContent:w.cacheContent, bindArgs:w.bindArgs, preload:w.preload, refreshOnShow:w.refreshOnShow, handler:w.handler, trackHistory:w.trackHistory, executeScripts:w.executeScripts, scriptScope:w.scriptScope, postCreate:w.postCreate, show:w.show, refresh:w.refresh, loadContents:w.loadContents, abort:w.abort, destroy:w.destroy, onLoad:w.onLoad, onUnLoad:w.onUnLoad, addOnLoad:w.addOnLoad, addOnUnLoad:w.addOnUnLoad, onDownloadStart:w.onDownloadStart, onDownloadEnd:w.onDownloadEnd, onDownloadError:w.onDownloadError, onContentError:w.onContentError, onExecError:w.onExecError, onSetContent:w.onSetContent, setUrl:w.setUrl, setContent:w.setContent, onContentParse:w.onContentParse, onExecScript:w.onExecScript, setHandler:w.setHandler};
+ return function () {
+ if (wg.abort) {
+ wg.abort();
+ }
+ if ((w != wg) && (dojo.widget.byType(wg.widgetType).length > 1)) {
+ return;
+ }
+ for (var x in oldProps) {
+ if (oldProps[x] === undefined) {
+ delete w[x];
+ continue;
+ }
+ w[x] = oldProps[x];
+ }
+ delete wg._loader_defined;
+ delete wg.loader;
+ };
+ })(widgetProto, widget)};
+ if (widgetProto._loader_defined || widget._loader_defined) {
+ return;
+ }
+ dojo.mixin(widgetProto, {isContainer:true, adjustPaths:undef(widgetProto.adjustPaths) ? true : widgetProto.adjustPaths, href:undef(widgetProto.href) ? "" : widgetProto.href, extractContent:undef(widgetProto.extractContent) ? true : widgetProto.extractContent, parseContent:undef(widgetProto.parseContent) ? true : widgetProto.parseContent, cacheContent:undef(widgetProto.cacheContent) ? true : widgetProto.cacheContent, bindArgs:undef(widgetProto.bindArgs) ? {} : widgetProto.bindArgs, preload:undef(widgetProto.preload) ? false : widgetProto.preload, refreshOnShow:undef(widgetProto.refreshOnShow) ? false : widgetProto.refreshOnShow, handler:undef(widgetProto.handler) ? "" : widgetProto.handler, executeScripts:undef(widgetProto.executeScripts) ? false : widgetProto.executeScripts, trackHistory:undef(widgetProto.tracHistory) ? false : widgetProto.trackHistory, scriptScope:null});
+ widgetProto.postCreate = (function (postCreate) {
+ return function () {
+ if (widgetProto.constructor.superclass.postCreate != postCreate) {
+ postCreate.apply(this, arguments);
+ } else {
+ widgetProto.constructor.superclass.postCreate.apply(this, arguments);
+ }
+ if (this.handler !== "") {
+ this.setHandler(this.handler);
+ }
+ if (this.isShowing() || this.preload) {
+ this.loadContents();
+ if (!this.href) {
+ _loader._log(this, (this.domNode || this.containerNode).innerHTML);
+ }
+ }
+ };
+ })(widgetProto.postCreate);
+ widgetProto.show = (function (show) {
+ return function () {
+ if (this.refreshOnShow) {
+ this.refresh();
+ } else {
+ this.loadContents();
+ }
+ if ((widgetProto.constructor.superclass.show == show) || !isFunc(show)) {
+ widgetProto.constructor.superclass.show.apply(this, arguments);
+ } else {
+ show.apply(this, arguments);
+ }
+ };
+ })(widgetProto.show);
+ widgetProto.destroy = (function (destroy) {
+ return function (destroy) {
+ this.onUnLoad();
+ this.abort();
+ this.loader.unHook();
+ if ((widgetProto.constructor.superclass.destroy != destroy) && isFunc(destroy)) {
+ destroy.apply(this, arguments);
+ } else {
+ widgetProto.constructor.superclass.destroy.apply(this, arguments);
+ }
+ };
+ })(widgetProto.destroy);
+ if (!widgetProto.refresh) {
+ widgetProto.refresh = function () {
+ this.loader.isLoaded = false;
+ this.loadContents();
+ };
+ }
+ if (!widgetProto.loadContents) {
+ widgetProto.loadContents = function () {
+ if (this.loader.isLoaded) {
+ return;
+ }
+ if (isFunc(this.handler)) {
+ runHandler.call(this);
+ } else {
+ if (this.href !== "") {
+ handleDefaults.call(this, "Loading...", "onDownloadStart");
+ var self = this, url = this.href;
+ downloader.call(this, {url:url, load:function (type, data, xhr) {
+ self.onDownloadEnd.call(self, url, data);
+ }, error:function (type, err, xhr) {
+ var e = {responseText:xhr.responseText, status:xhr.status, statusText:xhr.statusText, responseHeaders:(xhr.getAllResponseHeaders) ? xhr.getAllResponseHeaders() : [], _text:"Error loading '" + url + "' (" + xhr.status + " " + xhr.statusText + ")"};
+ handleDefaults.call(self, e, "onDownloadError");
+ self.onLoad();
+ }});
+ }
+ }
+ };
+ }
+ if (!widgetProto.abort) {
+ widgetProto.abort = function () {
+ if (!this.loader || !this.loader.bindObj || !this.loader.bindObj.abort) {
+ return;
+ }
+ this.loader.bindObj.abort();
+ this.loader.bindObj = null;
+ };
+ }
+ if (!widgetProto.onLoad) {
+ widgetProto.onLoad = function () {
+ stackRunner.call(this, this.loader.addOnLoads);
+ this.loader.isLoaded = true;
+ };
+ }
+ if (!widgetProto.onUnLoad) {
+ widgetProto.onUnLoad = function () {
+ stackRunner.call(this, this.loader.addOnUnLoads);
+ delete this.scriptScope;
+ };
+ }
+ if (!widgetProto.addOnLoad) {
+ widgetProto.addOnLoad = function (obj, func) {
+ stackPusher.call(this, this.loader.addOnLoads, obj, func);
+ };
+ }
+ if (!widgetProto.addOnUnLoad) {
+ widgetProto.addOnUnLoad = function (obj, func) {
+ stackPusher.call(this, this.loader.addOnUnLoads, obj, func);
+ };
+ }
+ if (!widgetProto.onExecError) {
+ widgetProto.onExecError = function () {
+ };
+ }
+ if (!widgetProto.onContentError) {
+ widgetProto.onContentError = function () {
+ };
+ }
+ if (!widgetProto.onDownloadError) {
+ widgetProto.onDownloadError = function () {
+ };
+ }
+ if (!widgetProto.onDownloadStart) {
+ widgetProto.onDownloadStart = function (onDownloadStart) {
+ };
+ }
+ if (!widgetProto.onDownloadEnd) {
+ widgetProto.onDownloadEnd = function (url, data) {
+ var args = {content:data, url:url, adjustPaths:this.adjustPaths, collectScripts:this.executeScripts, collectRequires:this.parseContent, bodyExtract:this.extractContent};
+ data = _loader.splitAndFixPaths.call(this, args);
+ this.setContent(data);
+ };
+ }
+ if (!widgetProto.onSetContent) {
+ widgetProto.onSetContent = function (cont) {
+ this.destroyChildren();
+ var styleNodes = this.loader.styleNodes;
+ while (styleNodes.length) {
+ var st = styleNodes.pop();
+ if (st && st.parentNode) {
+ st.parentNode.removeChild(st);
+ }
+ }
+ var node = this.containerNode || this.domNode;
+ while (node.firstChild) {
+ try {
+ dojo.event.browser.clean(node.firstChild);
+ }
+ catch (e) {
+ }
+ node.removeChild(node.firstChild);
+ }
+ try {
+ if (typeof cont != "string") {
+ node.appendChild(cont);
+ } else {
+ try {
+ node.innerHTML = cont;
+ }
+ catch (e) {
+ var tmp;
+ (tmp = dojo.doc().createElement("div")).innerHTML = cont;
+ while (tmp.firstChild) {
+ node.appendChild(tmp.removeChild(tmp.firstChild));
+ }
+ }
+ }
+ }
+ catch (e) {
+ e._text = "Could'nt load content: " + e;
+ var useAlert = (this.loader._onSetContent_err == e._text);
+ this.loader._onSetContent_err = e._text;
+ handleDefaults.call(this, e, "onContentError", useAlert);
+ }
+ };
+ }
+ if (!widgetProto.setUrl) {
+ widgetProto.setUrl = function (url) {
+ this.href = url;
+ this.loader.isLoaded = false;
+ if (this.preload || this.isShowing()) {
+ this.loadContents();
+ }
+ };
+ }
+ if (!widgetProto.setContent) {
+ widgetProto.setContent = function (data, dontLog) {
+ this.loader.callOnUnLoad.call(this, true);
+ if (!data || dojo.html.isNode(data)) {
+ this.onSetContent(data);
+ refreshed.call(this);
+ } else {
+ if (typeof data.xml != "string") {
+ this.href = "";
+ var args = {content:data, url:this.href, adjustPaths:this.adjustPaths, collectScripts:this.executeScripts, collectRequires:this.parseContent, bodyExtract:this.extractContent};
+ data = _loader.splitAndFixPaths.call(this, args);
+ } else {
+ if (data.url != "./") {
+ this.url = data.url;
+ }
+ }
+ this.onSetContent(data.xml);
+ for (var i = 0, styles = data.styles; i < styles.length; i++) {
+ if (styles[i].path) {
+ this.loader.styleNodes.push(dojo.html.insertCssFile(styles[i].path));
+ } else {
+ this.loader.styleNodes.push(dojo.html.insertCssText(styles[i]));
+ }
+ }
+ if (this.parseContent) {
+ for (var i = 0, requires = data.requires; i < requires.length; i++) {
+ try {
+ eval(requires[i]);
+ }
+ catch (e) {
+ e._text = "dojo.widget.html.loader.hookUp: error in package loading calls, " + (e.description || e);
+ handleDefaults.call(this, e, "onContentError", true);
+ }
+ }
+ }
+ if (dojo.hostenv.isXDomain && data.requires.length) {
+ dojo.addOnLoad(function () {
+ asyncParse.call(this, data);
+ if (!dontLog) {
+ _loader._log(this, data);
+ }
+ });
+ dontLog = true;
+ } else {
+ asyncParse.call(this, data);
+ }
+ }
+ if (!dontLog) {
+ }
+ };
+ }
+ if (!widgetProto.onContentParse) {
+ widgetProto.onContentParse = function () {
+ var node = this.containerNode || this.domNode;
+ var parser = new dojo.xml.Parse();
+ var frag = parser.parseElement(node, null, true);
+ dojo.widget.getParser().createSubComponents(frag, this);
+ };
+ }
+ if (!widgetProto.onExecScript) {
+ widgetProto.onExecScript = function (scripts) {
+ var self = this, tmp = "", code = "";
+ for (var i = 0; i < scripts.length; i++) {
+ if (scripts[i].path) {
+ var url = scripts[i].path;
+ downloader.call(this, {"url":url, "load":function (type, scriptStr) {
+ (function () {
+ tmp = scriptStr;
+ scripts[i] = scriptStr;
+ }).call(self);
+ }, "error":function (type, error) {
+ error._text = type + " downloading remote script";
+ handleDefaults.call(self, error, "onExecError", true);
+ }, "mimetype":"text/plain", "sync":true});
+ code += tmp;
+ } else {
+ code += scripts[i];
+ }
+ }
+ try {
+ delete this.scriptScope;
+ this.scriptScope = new (new Function("_container_", code + "; return this;"))(self);
+ }
+ catch (e) {
+ e._text = "Error running scripts from content:\n" + (e.description || e.toString());
+ handleDefaults.call(this, e, "onExecError", true);
+ }
+ };
+ }
+ if (!widgetProto.setHandler) {
+ widgetProto.setHandler = function (handler) {
+ var fcn = dojo.lang.isFunction(handler) ? handler : window[handler];
+ if (!isFunc(fcn)) {
+ handleDefaults.call(this, "Unable to set handler, '" + handler + "' not a function.", "onExecError", true);
+ return;
+ }
+ this.handler = function () {
+ return fcn.apply(this, arguments);
+ };
+ };
+ }
+ widgetProto._loader_defined = true;
+ };
+})();
+
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/loader.js
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/loader.js
------------------------------------------------------------------------------
svn:keywords = Date Revision
Propchange: geronimo/external/trunk/geronimo-dojo-0.4.3/src/main/webapp/src/widget/html/loader.js
------------------------------------------------------------------------------
svn:mime-type = text/plain