Hello Delphi Developer:
Something is wrong in ProgressBarPager.js
When initialized, if the number of records per page is 20,
then adjusted to 10, click on the toolbar the number of pages is wrong.
Here is the code
-------------------------------------------------------------
// private
// This method handles the click for the progress bar
handleProgressBarClick : function(e){
var parent = this.parent,
displayItem = parent.displayItem,
box = this.progressBar.getBox(),
xy = e.getXY(),
position = xy[0]- box.x,
pages = Math.ceil(parent.store.getTotalCount() / parent.pageSize),
newPage = Math.max(Math.ceil(position / (displayItem.width / pages)), 1);
parent.store.loadPage(newPage);
},
Thank you!