fix scroll obfuscation.

This commit is contained in:
Christopher Jeffrey 2013-07-23 16:57:30 -05:00
parent 9aaabacf68
commit b6bee303a9

View File

@ -2656,30 +2656,24 @@ Box.prototype._getCoords = function(get) {
ryl = yl - el._getTop(get) - el.ibottom;
visible = el._getHeight(get) - el.iheight;
// if (ryi < el.childBase) {
// if (ryl > el.childBase) {
// // Is partially covered above.
// v = ryl - el.childBase;
// yi += (ryl - ryi) - v;
// } else {
// // Is above.
// return;
// }
// } else if (ryi >= el.childBase + visible) {
// // Is below.
// return;
// } else if (ryl >= el.childBase + visible) {
// // Is partially covered below.
// v = el.childBase + visible + (yl - yi) - ryl;
// yl = yi + v;
// }
if (ryi < el.childBase) {
// Is above.
return;
if (ryl > el.childBase) {
// Is partially covered above.
v = ryl - el.childBase;
yi += (ryl - ryi) - v;
return;
} else {
// Is above.
return;
}
} else if (ryi >= el.childBase + visible) {
// Is below.
return;
} else if (ryl > el.childBase + visible) {
// Is partially covered below.
v = el.childBase + visible + (yl - yi) - ryl;
yl = yi + v;
return;
}
yi -= el.childBase;