[Zope-CVS] CVS: Packages/Moztop/moztop/content/lib - jsdav.js:1.15

Stephan Richter srichter@cbu.edu
Sun, 25 May 2003 15:12:26 -0400


Update of /cvs-repository/Packages/Moztop/moztop/content/lib
In directory cvs.zope.org:/tmp/cvs-serv31071/moztop/content/lib

Modified Files:
	jsdav.js 
Log Message:
making prelinary checkin; I dunno whether anything works


=== Packages/Moztop/moztop/content/lib/jsdav.js 1.14 => 1.15 === (408/508 lines abridged)
--- Packages/Moztop/moztop/content/lib/jsdav.js:1.14	Mon Apr  7 07:21:39 2003
+++ Packages/Moztop/moztop/content/lib/jsdav.js	Sun May 25 15:11:55 2003
@@ -178,9 +178,9 @@
 	    /* The DavClient is stashed in request.thisobject and the */
 	    /* widget is in DavClient.callbackObj                     */
 	    // Parse the resulting XML for successful return
-	    stat = new DavMultiStatus();
-	    stat.parseXML(request.responseXML.documentElement)
-	    callback(request);
+	    status = new DavMultiStatus();
+	    status.parseXML(request.responseXML.documentElement)
+	    callback(request, status);
 	}
 	return;
     };
@@ -190,7 +190,7 @@
 	alert("You must supply a URL");
 	return;
     }
-
+    
     // Prepare the request
     request.onload = handleResponse;
     request.open("PROPFIND", url);
@@ -630,53 +630,54 @@
 	
        See http://asg.web.cmu.edu/rfc/rfc2518.html#sec-12.1
     */
-    this.lockscope = null;
-    this.locktype = null;
-    this.depth = null;
-    this.owner = null;
-    this.timeout = null;
-    this.locktoken = null;
+    this.lockscope = scope || null;
+    this.locktype = type || null;
+    this.depth = depth || null;
+    this.owner = owner || null;
+    this.timeout = timeout || null;
+    this.locktoken = locktoken || null;
 }
 
 
 DavActiveLock.prototype = {
     getLockScope: function() {
-	return self.lockscope;
+	return this.lockscope;
     },
     getLockType: function() {
-	return self.locktype;

[-=- -=- -=- 408 lines omitted -=- -=- -=-]

 	this.value = node.firstChild.nodeValue;
     },
     createXML: function(parent, doc) {
@@ -1805,6 +1897,7 @@
 	this.locks[this.locks.length] = lock;
     },
     parseXML: function(node) {
+	this.xmlNode = node;
 	for (var index = 0; index < node.childNodes.length; index++) {
 	    sub = node.childNodes[index];
 	    if (sub.localName == 'activelock') {
@@ -1829,17 +1922,20 @@
 	
        See http://asg.web.cmu.edu/rfc/rfc2518.html#sec-13.9
     */
+    if (!value)
+	value = '';
     this.value = value;
 }
 
 DavResourceType.prototype = {
     getValue: function() {
-	return self.value;
+	return this.value;
     },
     setValue: function(value) {
-	self.value = value;
+	this.value = value;
     },
     parseXML: function(node) {
+	this.xmlNode = node;
 	this.value = node.firstChild.nodeValue;
     },
     createXML: function(parent, doc) {
@@ -1866,6 +1962,7 @@
 	this.links[this.links.length] = link;
     },
     parseXML: function(node) {
+	this.xmlNode = node;
 	for (var index = 0; index < node.childNodes.length; index++) {
 	    sub = node.childNodes[index];
 	    if (sub.localName == 'link') {
@@ -1901,6 +1998,7 @@
 	this.entries[this.entries.length] = entry;
     },
     parseXML: function(node) {
+	this.xmlNode = node;
 	for (var index = 0; index < node.childNodes.length; index++) {
 	    sub = node.childNodes[index];
 	    if (sub.localName == 'lockentry') {