This commit is contained in:
parent
0f884679a5
commit
e0eeb67192
|
@ -22,7 +22,8 @@ export default function bigData(Table) {
|
|||
};
|
||||
const rowHeight = this.props.height?this.props.height:defaultHeight
|
||||
//默认显示25条,rowsInView根据定高算的。在非固定高下,这个只是一个大概的值。
|
||||
this.rowsInView = this.props.scroll.y?Math.ceil(this.props.scroll.y/rowHeight):20 ;
|
||||
const scrollY = this.props.scroll.y ? parseInt(this.props.scroll.y) : 0;
|
||||
this.rowsInView = scrollY ? Math.ceil(scrollY/rowHeight):20 ;
|
||||
this.currentIndex = 0;
|
||||
this.loadCount = props.loadBuffer? this.rowsInView + props.loadBuffer*2:26;//一次加载多少数据
|
||||
this.cachedRowHeight = [];//缓存每行的高度
|
||||
|
|
Loading…
Reference in New Issue