Changeset 14906

Show
Ignore:
Timestamp:
08/18/08 23:30:20 (19 months ago)
Author:
toonetown
Message:

Fixes #7472 - prevent the scroller from loading the entire data set when using a number-based autoHeight !strict

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • dojox/trunk/grid/_Grid.js

    r14880 r14906  
    626626                                } 
    627627                        } 
    628                         this.scroller.windowHeight = h; 
     628                        if(this.autoHeight === true || h != -1 || (typeof this.autoHeight == "number" && this.autoHeight >= this.rowCount)){ 
     629                                this.scroller.windowHeight = h; 
     630                        }else{ 
     631                                this.scroller.windowHeight = Math.max(this.domNode.clientHeight - t, 0); 
     632                        } 
    629633                }, 
    630634 
     
    771775                        }else{ 
    772776                                this.rowCount = inRowCount; 
     777                                this._setAutoHeightAttr(this.autoHeight, true); 
    773778                                if(this.layout.cells.length){ 
    774779                                        this.scroller.updateRowCount(inRowCount); 
     780                                } 
     781                                this._resize();                          
     782                                if(this.layout.cells.length){ 
    775783                                        this.setScrollTop(this.scrollTop); 
    776784                                } 
    777                                 this._setAutoHeightAttr(this.autoHeight, true); 
    778                                 this._resize(); 
    779785                        } 
    780786                },