Author: konstantin.mishin
Date: 2007-07-09 04:26:33 -0400 (Mon, 09 Jul 2007)
New Revision: 1540
Modified:
branches/3.0.2/sandbox/scrollable-grid/src/main/java/org/richfaces/renderkit/html/GridRendererState.java
Log:
small fix
Modified:
branches/3.0.2/sandbox/scrollable-grid/src/main/java/org/richfaces/renderkit/html/GridRendererState.java
===================================================================
---
branches/3.0.2/sandbox/scrollable-grid/src/main/java/org/richfaces/renderkit/html/GridRendererState.java 2007-07-09
08:16:34 UTC (rev 1539)
+++
branches/3.0.2/sandbox/scrollable-grid/src/main/java/org/richfaces/renderkit/html/GridRendererState.java 2007-07-09
08:26:33 UTC (rev 1540)
@@ -112,14 +112,8 @@
}
GridRendererState oldState = getRendererState(context);
GridRendererState state = new GridRendererState(context,oldState,grid);
- if(grid.getAttributes().get("columnClasses") != null){
- String columnClasses = (String)grid.getAttributes().get("columnClasses");
- state.setColumnClasses(columnClasses.split(","));
- }
- if(grid.getAttributes().get("rowClasses") != null){
- String rowClasses = (String)grid.getAttributes().get("rowClasses");
- state.setRowClasses(rowClasses.split(","));
- }
+ state.setColumnClasses(grid.getAttributes().get("columnClasses"));
+ state.setRowClasses(grid.getAttributes().get("rowClasses"));
context.getExternalContext().getRequestMap().put(DATA_GRID_RENDERER_STATE,state);
return state;
}
@@ -406,9 +400,9 @@
}
}
- public void setColumnClasses(String columnClasses[]) {
+ public void setColumnClasses(Object columnClasses) {
if(columnClasses != null) {
- this.columnClasses = columnClasses;
+ this.columnClasses = ((String)columnClasses).split(",");
columnClassesSize = this.columnClasses.length;
}
}
@@ -421,9 +415,9 @@
}
}
- public void setRowClasses(String rowClasses[]) {
+ public void setRowClasses(Object rowClasses) {
if(rowClasses != null) {
- this.rowClasses = rowClasses;
+ this.rowClasses = ((String)rowClasses).split(",");
rowClassesSize = this.rowClasses.length;
}
}