diff --git a/apps/common/main/lib/component/DataView.js b/apps/common/main/lib/component/DataView.js index bb4706c07..64c0533c0 100644 --- a/apps/common/main/lib/component/DataView.js +++ b/apps/common/main/lib/component/DataView.js @@ -575,11 +575,11 @@ define([ if (div.length<=0) return; var div_top = div.offset().top; - if (div_top < inner_top || div_top+div.outerHeight() > inner_top + innerEl.height()) { + if (div_top < inner_top+div[0].offsetTop || div_top+div.outerHeight() > inner_top + innerEl.height()) { if (this.scroller && this.allowScrollbar) { - this.scroller.scrollTop(innerEl.scrollTop() + div_top - inner_top, 0); + this.scroller.scrollTop(innerEl.scrollTop() + div_top - inner_top - div[0].offsetTop, 0); } else { - innerEl.scrollTop(innerEl.scrollTop() + div_top - inner_top); + innerEl.scrollTop(innerEl.scrollTop() + div_top - inner_top - div[0].offsetTop); } } },