Alien-Web-ExtJS-V3
view release on metacpan or search on metacpan
share/adapter/ext/ext-base-debug.js view on Meta::CPAN
if (el.getBoundingClientRect) {
b = el.getBoundingClientRect();
scroll = fly(document).getScroll();
ret = [ROUND(b.left + scroll.left), ROUND(b.top + scroll.top)];
} else {
p = el;
hasAbsolute = fly(el).isStyle("position", "absolute");
while (p) {
pe = fly(p);
x += p.offsetLeft;
y += p.offsetTop;
hasAbsolute = hasAbsolute || pe.isStyle("position", "absolute");
if (Ext.isGecko) {
y += bt = PARSEINT(pe.getStyle("borderTopWidth"), 10) || 0;
x += bl = PARSEINT(pe.getStyle("borderLeftWidth"), 10) || 0;
if (p != el && !pe.isStyle('overflow','visible')) {
x += bl;
y += bt;
}
}
p = p.offsetParent;
}
if (Ext.isSafari && hasAbsolute) {
x -= bd.offsetLeft;
y -= bd.offsetTop;
}
if (Ext.isGecko && !hasAbsolute) {
dbd = fly(bd);
x += PARSEINT(dbd.getStyle("borderLeftWidth"), 10) || 0;
y += PARSEINT(dbd.getStyle("borderTopWidth"), 10) || 0;
}
p = el.parentNode;
while (p && p != bd) {
if (!Ext.isOpera || (p.tagName != 'TR' && !fly(p).isStyle("display", "inline"))) {
x -= p.scrollLeft;
y -= p.scrollTop;
}
p = p.parentNode;
}
ret = [x,y];
}
}
return ret;
},
setXY : function(el, xy) {
(el = Ext.fly(el, '_setXY')).position();
var pts = el.translatePoints(xy),
style = el.dom.style,
pos;
for (pos in pts) {
if (!isNaN(pts[pos])) {
style[pos] = pts[pos] + "px";
}
}
},
setX : function(el, x) {
this.setXY(el, [x, false]);
},
setY : function(el, y) {
this.setXY(el, [false, y]);
}
};
})();Ext.lib.Event = function() {
var loadComplete = false,
unloadListeners = {},
retryCount = 0,
onAvailStack = [],
_interval,
locked = false,
win = window,
doc = document,
// constants
POLL_RETRYS = 200,
POLL_INTERVAL = 20,
TYPE = 0,
FN = 1,
OBJ = 2,
ADJ_SCOPE = 3,
SCROLLLEFT = 'scrollLeft',
SCROLLTOP = 'scrollTop',
UNLOAD = 'unload',
MOUSEOVER = 'mouseover',
MOUSEOUT = 'mouseout',
// private
doAdd = function() {
var ret;
if (win.addEventListener) {
ret = function(el, eventName, fn, capture) {
if (eventName == 'mouseenter') {
fn = fn.createInterceptor(checkRelatedTarget);
el.addEventListener(MOUSEOVER, fn, (capture));
} else if (eventName == 'mouseleave') {
fn = fn.createInterceptor(checkRelatedTarget);
el.addEventListener(MOUSEOUT, fn, (capture));
} else {
el.addEventListener(eventName, fn, (capture));
}
return fn;
};
} else if (win.attachEvent) {
ret = function(el, eventName, fn, capture) {
el.attachEvent("on" + eventName, fn);
return fn;
};
} else {
ret = function(){};
}
return ret;
( run in 0.537 second using v1.01-cache-2.11-cpan-787462296c9 )