projects
/
app.Builder.js
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
43e1f0b
)
XObject.js
author
Alan Knowles
<alan@akbkhome.com>
Tue, 25 May 2010 11:33:58 +0000
(19:33 +0800)
committer
Alan Knowles
<alan@akbkhome.com>
Tue, 25 May 2010 11:33:58 +0000
(19:33 +0800)
XObject.js
patch
|
blob
|
history
diff --git
a/XObject.js
b/XObject.js
index
3155dba
..
c2e27b8
100644
(file)
--- a/
XObject.js
+++ b/
XObject.js
@@
-353,8
+353,24
@@
XObject.prototype = {
return this.parent.get(xid.substring(1));
}
if (xid[0] == '/') {
return this.parent.get(xid.substring(1));
}
if (xid[0] == '/') {
+
if (typeof(XObject.cache[xid]) != 'undefined') {
return XObject.cache[xid];
if (typeof(XObject.cache[xid]) != 'undefined') {
return XObject.cache[xid];
+ }
+ if (xid.indexOf('.') > -1) {
+ var child = false;
+
+ if (xid.indexOf('.') > -1) {
+ child = xid.split('.');
+ var nxid = child.shift();
+
+ child = child.join('.');
+ if (typeof(XObject.cache[nxid]) != 'undefined') {
+ return XObject.cache[nxid].get(child);
+ }
+ }
+
+
}
var e = this;
while (e.parent) {
}
var e = this;
while (e.parent) {
@@
-381,8
+397,6
@@
XObject.prototype = {
xid = child.shift();
child = child.join('.');
xid = child.shift();
child = child.join('.');
-
-
}
if (xid == this.id) {
}
if (xid == this.id) {