var top = this.topArr[ri],
var top = this.topArr ? this.topArr[ri] : 0,
calcTopBottom: function(left) { if(typeof(this.dims)==="undefined") return 0; ...getTop: function(ri, actual) { var top = this.topArr ? this.topArr[ri] : 0, ...getLeft: function(_ci, actual) { if(typeof(this.leftArr)==="undefined") return 0; ...