From 1ddc3a75c4668625be0a76ee34860e5d45325a3c Mon Sep 17 00:00:00 2001 From: Alan Knowles Date: Fri, 11 Mar 2011 01:40:48 +0000 Subject: [PATCH] Minor Coding style fixes --- Roo/grid/Grid.js | 142 ++++++++++++++++++++++++----------------------- 1 file changed, 72 insertions(+), 70 deletions(-) diff --git a/Roo/grid/Grid.js b/Roo/grid/Grid.js index d1cac21f85..553efe522c 100644 --- a/Roo/grid/Grid.js +++ b/Roo/grid/Grid.js @@ -300,8 +300,8 @@ Roo.grid.Grid = function(container, config){ /** * @event rowclass * Fires when a row is rendered, so you can change add a style to it. - * @param {GridView} gridview The grid view - * @param {Object} rowcfg contains record, rowIndex and rowClass - set rowClass to add a style. + * @param {GridView} gridview The grid view + * @param {Object} rowcfg contains record rowIndex and rowClass - set rowClass to add a style. */ 'rowclass' : true, @@ -319,74 +319,74 @@ Roo.extend(Roo.grid.Grid, Roo.util.Observable, { /** * @cfg {String} ddGroup - drag drop group. - */ - + */ + /** * @cfg {Number} minColumnWidth The minimum width a column can be resized to. Default is 25. - */ - minColumnWidth : 25, + */ + minColumnWidth : 25, /** - * @cfg {Boolean} autoSizeColumns True to automatically resize the columns to fit their content - * on initial render. It is more efficient to explicitly size the columns - * through the ColumnModel's {@link Roo.grid.ColumnModel#width} config option. Default is false. - */ - autoSizeColumns : false, + * @cfg {Boolean} autoSizeColumns True to automatically resize the columns to fit their content + * on initial render. It is more efficient to explicitly size the columns + * through the ColumnModel's {@link Roo.grid.ColumnModel#width} config option. Default is false. + */ + autoSizeColumns : false, - /** - * @cfg {Boolean} autoSizeHeaders True to measure headers with column data when auto sizing columns. Default is true. - */ - autoSizeHeaders : true, + /** + * @cfg {Boolean} autoSizeHeaders True to measure headers with column data when auto sizing columns. Default is true. + */ + autoSizeHeaders : true, - /** - * @cfg {Boolean} monitorWindowResize True to autoSize the grid when the window resizes. Default is true. - */ - monitorWindowResize : true, + /** + * @cfg {Boolean} monitorWindowResize True to autoSize the grid when the window resizes. Default is true. + */ + monitorWindowResize : true, - /** - * @cfg {Boolean} maxRowsToMeasure If autoSizeColumns is on, maxRowsToMeasure can be used to limit the number of - * rows measured to get a columns size. Default is 0 (all rows). - */ - maxRowsToMeasure : 0, + /** + * @cfg {Boolean} maxRowsToMeasure If autoSizeColumns is on, maxRowsToMeasure can be used to limit the number of + * rows measured to get a columns size. Default is 0 (all rows). + */ + maxRowsToMeasure : 0, - /** - * @cfg {Boolean} trackMouseOver True to highlight rows when the mouse is over. Default is true. - */ - trackMouseOver : true, + /** + * @cfg {Boolean} trackMouseOver True to highlight rows when the mouse is over. Default is true. + */ + trackMouseOver : true, /** - * @cfg {Boolean} enableDrag True to enable drag of rows. Default is false. (double check if this is needed?) - */ + * @cfg {Boolean} enableDrag True to enable drag of rows. Default is false. (double check if this is needed?) + */ - /** - * @cfg {Boolean} enableDragDrop True to enable drag and drop of rows. Default is false. - */ - enableDragDrop : false, - - /** - * @cfg {Boolean} enableColumnMove True to enable drag and drop reorder of columns. Default is true. - */ - enableColumnMove : true, - - /** - * @cfg {Boolean} enableColumnHide True to enable hiding of columns with the header context menu. Default is true. - */ - enableColumnHide : true, - - /** - * @cfg {Boolean} enableRowHeightSync True to manually sync row heights across locked and not locked rows. Default is false. - */ - enableRowHeightSync : false, - - /** - * @cfg {Boolean} stripeRows True to stripe the rows. Default is true. - */ - stripeRows : true, - - /** - * @cfg {Boolean} autoHeight True to fit the height of the grid container to the height of the data. Default is false. - */ - autoHeight : false, + /** + * @cfg {Boolean} enableDragDrop True to enable drag and drop of rows. Default is false. + */ + enableDragDrop : false, + + /** + * @cfg {Boolean} enableColumnMove True to enable drag and drop reorder of columns. Default is true. + */ + enableColumnMove : true, + + /** + * @cfg {Boolean} enableColumnHide True to enable hiding of columns with the header context menu. Default is true. + */ + enableColumnHide : true, + + /** + * @cfg {Boolean} enableRowHeightSync True to manually sync row heights across locked and not locked rows. Default is false. + */ + enableRowHeightSync : false, + + /** + * @cfg {Boolean} stripeRows True to stripe the rows. Default is true. + */ + stripeRows : true, + + /** + * @cfg {Boolean} autoHeight True to fit the height of the grid container to the height of the data. Default is false. + */ + autoHeight : false, /** * @cfg {String} autoExpandColumn The id (or dataIndex) of a column in this grid that should expand to fill unused space. This id can not be 0. Default is false. @@ -405,18 +405,19 @@ Roo.extend(Roo.grid.Grid, Roo.util.Observable, { autoExpandMax : 1000, /** - * @cfg {Object} view The {@link Roo.grid.GridView} used by the grid. This can be set before a call to render(). - */ - view : null, + * @cfg {Object} view The {@link Roo.grid.GridView} used by the grid. This can be set before a call to render(). + */ + view : null, - /** - * @cfg {Object} loadMask An {@link Roo.LoadMask} config or true to mask the grid while loading. Default is false. - */ - loadMask : false, /** - * @cfg {Roo.dd.DropTarget} dragTarget An {@link Roo.dd.DragTarget} config - */ - dropTarget: false, + * @cfg {Object} loadMask An {@link Roo.LoadMask} config or true to mask the grid while loading. Default is false. + */ + loadMask : false, + /** + * @cfg {Roo.dd.DropTarget} dragTarget An {@link Roo.dd.DragTarget} config + */ + dropTarget: false, + // private rendered : false, @@ -431,7 +432,8 @@ Roo.extend(Roo.grid.Grid, Roo.util.Observable, { * Called once after all setup has been completed and the grid is ready to be rendered. * @return {Roo.grid.Grid} this */ - render : function(){ + render : function() + { var c = this.container; // try to detect autoHeight/width mode if((!c.dom.offsetHeight || c.dom.offsetHeight < 20) || c.getStyle("height") == "auto"){ -- 2.39.2