XObject.js
authorAlan Knowles <alan@akkbhome.com>
Tue, 18 May 2010 15:30:41 +0000 (23:30 +0800)
committerAlan Knowles <alan@akkbhome.com>
Tue, 18 May 2010 15:30:41 +0000 (23:30 +0800)
XObject.js

index 88edd83..598c2a4 100644 (file)
@@ -203,10 +203,14 @@ XObject.prototype = {
         //}
         
         if (this.items) {
-            
+            var items = [];
+            this.items.forEach(function(i) {
+                items.push(i);
+            });
+            this.items = [];
             var _this=this;
             
-            this.items.forEach(function(i) {
+            items.forEach(function(i) {
                 _this.addItem(i);
             });
         }