IE only,
I have an ed excell in grid. when I enter some value and press enter key it goes to next line within same editor cell. The editor does not close on enter key.
Earlier, on enter key press it is used to work fine ie. accept the value and close the editor.
This started happening after I made following changes to my code.
Following are the changes I made to the working code that broke.
-
I added mouseOver, To show color change on hover for editable cells.
mygrid.attachEvent(“onMouseOver”,function(rowId,cellInd){
if(prevCol!=-1 && prevRow!=-1) {
mygrid.cellById(prevRow,prevCol).cell.className="";
}
if(cellInd==2 ) {prevRow = rowId; prevCol = cellInd; mygrid.cellById(rowId,cellInd).cell.className="grid_hover_cell"; mygrid.cellById(rowId,cellInd).cell.title = "Double click to Edit"; } return false;
});
-
Added code to save and restore resize and sort user prefs.
mygrid.loadXML("/a?q="+$(’#viewFilter’).val(), function() {
postRefresh(“post”);
// Added Following lines
mygrid.loadSizeFromCookie();
mygrid.loadSortingFromCookie();
mygrid.enableAutoSizeSaving();
mygrid.enableSortingSaving();});
-
Added following events.
mygrid.attachEvent(“onResizeEnd”, function(obj){
mygrid.saveSizeToCookie();
});
mygrid.attachEvent(“onAfterSorting”, function(index,type,direction){
mygrid.saveSortingToCookie();
});