Changeset 36
- Timestamp:
- 11/23/08 19:59:51 (3 years ago)
- google:author:
- tsuckowhomberg
- Location:
- trunk
- Files:
-
- 15 added
- 7 modified
-
build (added)
-
build-tools (added)
-
build-tools/README (added)
-
build-tools/unix (added)
-
build-tools/unix/make.sh (added)
-
build-tools/windows (added)
-
build-tools/windows/make.bat (added)
-
build/livegrid-all.js (added)
-
build/livegrid-core.js (added)
-
build/livegrid-debug-all.js.js (added)
-
build/resources (added)
-
build/resources/css (added)
-
build/resources/css/ext-ux-livegrid.css (added)
-
build/resources/images (added)
-
build/resources/images/loading.gif (added)
-
CHANGELOG (modified) (1 diff)
-
README (modified) (2 diffs)
-
src/EditorGridPanel.js (modified) (1 diff)
-
src/GridPanel.js (modified) (1 diff)
-
src/GridView.js (modified) (8 diffs)
-
src/RowSelectionModel.js (modified) (1 diff)
-
src/Store.js (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/CHANGELOG
r35 r36 1 Version 0.3a4 (GPL) 1 Version 0.3RC1 (GPL) 2 23-November-2008 3 4 - enhancement: added build tools for creating minified deployable versions of 5 Ext.ux.Livegrid-scripts 6 - enhancement: (GridView.js) the rowIndex argument of the column's renderer will 7 now pass the value of the index of the row as available in the view, i.e. as defined 8 in the row's rowIndex property, which adds support for Ext.grid.RowNumberer 9 - fixed: (GridView.js) fixed a bug where "getPredictedBufferIndex()" would not 10 compute the next rowIndex for a request properly, leading to an endless loop 11 - enhancement: (GridView.js, RowSelectionModel.js) removed override of "onRefresh()" 12 to keep selections after a refresh or sort occured, if, and only if those records are 13 returned by the response; removed custom call to selection model's "clearSelections()" 14 in the GridView's "reset()" method 15 - enhancement: intercepted "autoLoad" property of Ext.ux.grid.livegrid.Store to make 16 sure the store gets only loaded if the view has been rendered, if the store's autoLoad 17 property was set to "true" 18 19 20 Version 0.3a4 (GPL) 2 21 1-November-2008 3 22 -
trunk/README
r31 r36 1 Note: 2 ----- 3 Including the file "ext-ux-livegrid.css" is mandatory, otherwise the view will 4 not be rendered properly. 5 1 6 Author: 2 7 ------- … … 6 11 ------------- 7 12 http://www.siteartwork.de/livegrid 8 9 History:10 --------11 Ext.ux.Livegrid is a subproject of ongoo. Visit <http://www.ongoo.org> for12 more informations. -
trunk/src/EditorGridPanel.js
r35 r36 71 71 }, 72 72 73 /** 74 * Since we do not have multiple inheritance, we need to override the 75 * same methods in this class we have overriden for 76 * Ext.ux.grid.livegrid.GridPanel 77 * 78 */ 73 // Since we do not have multiple inheritance, we need to override the 74 // same methods in this class we have overriden for 75 // Ext.ux.grid.livegrid.GridPanel 79 76 walkCells : function(row, col, step, fn, scope) 80 77 { 81 78 return Ext.ux.grid.livegrid.GridPanel.prototype.walkCells.call(this, row, col, step, fn, scope); 79 }, 80 81 onRender : function(ct, position) 82 { 83 return Ext.ux.grid.livegrid.GridPanel.prototype.onRender.call(this, ct, position); 82 84 } 83 85 -
trunk/src/GridPanel.js
r31 r36 37 37 38 38 /** 39 * Overriden to make sure the attached store loads only when the 40 * grid has been fully rendered if, and only if the store's 41 * "autoLoad" property is set to true. 42 * 43 */ 44 onRender : function(ct, position) 45 { 46 Ext.ux.grid.livegrid.GridPanel.superclass.onRender.call(this, ct, position); 47 48 var ds = this.getStore(); 49 50 if (ds._autoLoad === true) { 51 delete ds._autoLoad; 52 ds.load(); 53 } 54 }, 55 56 /** 39 57 * Overriden since the original implementation checks for 40 58 * getCount() of the store, not getTotalCount(). -
trunk/src/GridView.js
r35 r36 137 137 ); 138 138 139 Ext.ux.grid.livegrid.GridView.superclass.constructor.call(this); 139 // shorthands for often used parent classes 140 this._gridViewSuperclass = Ext.ux.grid.livegrid.GridView.superclass; 141 142 this._gridViewSuperclass.constructor.call(this); 143 144 140 145 }; 141 146 … … 276 281 if (forceReload === false) { 277 282 this.ds.modified = []; 278 this.grid.selModel.clearSelections(true);283 //this.grid.selModel.clearSelections(true); 279 284 this.rowIndex = 0; 280 285 this.lastScrollPos = 0; … … 325 330 g.enableDrag = false; 326 331 327 Ext.ux.grid.livegrid.GridView.superclass.renderUI.call(this);332 this._gridViewSuperclass.renderUI.call(this); 328 333 329 334 var g = this.grid; … … 360 365 init: function(grid) 361 366 { 362 Ext.ux.grid.livegrid.GridView.superclass.init.call(this, grid);367 this._gridViewSuperclass.init.call(this, grid); 363 368 364 369 grid.on('expand', this._onExpand, this); … … 376 381 } 377 382 378 Ext.ux.grid.livegrid.GridView.superclass.initData.call(this, ds, cm);383 this._gridViewSuperclass.initData.call(this, ds, cm); 379 384 }, 380 385 … … 389 394 var markup = this.renderRows(0, this.visibleRows-1); 390 395 return this.templates.body.apply({rows: markup}); 396 }, 397 398 /** 399 * Overriden so the renderer of the specific cells gets the index of the 400 * row as available in the view passed (row's rowIndex property)- 401 * 402 */ 403 doRender : function(cs, rs, ds, startRow, colCount, stripe) 404 { 405 return this._gridViewSuperclass.doRender.call( 406 this, cs, rs, ds, startRow + this.ds.bufferRange[0], colCount, stripe 407 ); 408 391 409 }, 392 410 … … 1272 1290 { 1273 1291 var lastRowIndex = Math.min(this.ds.totalLength-1, 1274 rowIndex + this.visibleRows);1292 rowIndex + (this.visibleRows-1)); 1275 1293 1276 1294 return (rowIndex >= this.ds.bufferRange[0]) && … … 1288 1306 { 1289 1307 if (!inRange) { 1290 var dNear = 2*this.nearLimit; 1291 return Math.max(0, index-((dNear >= this.ds.bufferSize ? this.nearLimit : dNear))); 1308 if (index + this.ds.bufferSize >= this.ds.totalLength) { 1309 return this.ds.totalLength - this.ds.bufferSize; 1310 } 1311 // we need at last to render the index + the visible Rows 1312 return Math.max(0, (index + this.visibleRows) - Math.round(this.ds.bufferSize/2)); 1292 1313 } 1293 1314 if (!down) { -
trunk/src/RowSelectionModel.js
r31 r36 66 66 this.grid.store.on('selectionsload', this.onSelectionsLoad, this); 67 67 }, 68 69 70 71 // private72 onRefresh : function()73 {74 this.clearSelections(true);75 },76 77 78 68 79 69 /** -
trunk/src/Store.js
r31 r36 98 98 // remoteSort will always be set to true. 99 99 config.remoteSort = true; 100 101 // we will intercept the autoLoad property and set it to false so we do not 102 // load any contents of the store before the View has not fully initialized 103 // itself. if autoLoad was set to true, the Ext.ux.grid.livegrid.GridPanel 104 // will take care of loading the store once it has been rendered 105 this._autoLoad = config.autoLoad ? true : false; 106 config.autoLoad = false; 100 107 101 108 this.addEvents(
