From 42bea4b01f68b27e089fafe94b13791ba6c56e6f Mon Sep 17 00:00:00 2001 From: Pykaso Date: Mon, 19 Mar 2012 14:09:30 +0100 Subject: [PATCH 1/4] after editing is focus lost somewhere outside of the cell and its not possible to continue with navigation by keys --- editor.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/editor.js b/editor.js index 86f953305..32a703896 100644 --- a/editor.js +++ b/editor.js @@ -197,6 +197,12 @@ function createSharedEditor(column, originalRenderCell){ // reset state now that editor is deactivated activeCell = activeValue = null; column._editorBlurHandle.pause(); + + // after editing is focus lost somewhere outside of the cell + // and its not possible to continue with navigation by keys + setTimeout(function(){ + try{ parentNode.focus(); }catch(e){/** no exception please */} + },1); } function dismissOnKey(evt){ From 8e1289ab867352ac49804a06794999d7d83328f0 Mon Sep 17 00:00:00 2001 From: Pykaso Date: Mon, 19 Mar 2012 14:15:20 +0100 Subject: [PATCH 2/4] typo fix --- editor.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/editor.js b/editor.js index 32a703896..f8525a098 100644 --- a/editor.js +++ b/editor.js @@ -201,7 +201,7 @@ function createSharedEditor(column, originalRenderCell){ // after editing is focus lost somewhere outside of the cell // and its not possible to continue with navigation by keys setTimeout(function(){ - try{ parentNode.focus(); }catch(e){/** no exception please */} + try{ parentNode.focus(); }catch(e){/** no exception here */} },1); } From 8e5dd50d5ef65aa9cc792e5a7c7c759b8626535e Mon Sep 17 00:00:00 2001 From: Pykaso Date: Mon, 19 Mar 2012 14:25:09 +0100 Subject: [PATCH 3/4] special css attribute 'dgrid-cell-inedit' on cell with editor for better editor sizing --- editor.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/editor.js b/editor.js index f8525a098..14047d0f6 100644 --- a/editor.js +++ b/editor.js @@ -190,6 +190,9 @@ function createSharedEditor(column, originalRenderCell){ // remove the editor from the cell parentNode.removeChild(node); + // remove the special css attribute for cell with editor + put(parentNode, '!dgrid-cell-inedit'); + // pass new value to original renderCell implementation for this cell Grid.appendIfNode(parentNode, originalRenderCell( column.grid.row(parentNode).data, activeValue, parentNode)); From b963075d91ccfdca4e33029901de3570ba478570 Mon Sep 17 00:00:00 2001 From: Pykaso Date: Mon, 19 Mar 2012 14:27:17 +0100 Subject: [PATCH 4/4] special css attribute 'dgrid-cell-inedit' on cell with editor for better editor sizing --- editor.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/editor.js b/editor.js index 14047d0f6..0455956be 100644 --- a/editor.js +++ b/editor.js @@ -244,6 +244,8 @@ function showEditor(cmp, column, cell, value){ if(!isWidget){ updateInputValue(cmp, value); } cell.innerHTML = ""; + //special css attribute for cell with editor + put(cell, '.dgrid-cell-inedit'); put(cell, cmp.domNode || cmp); if(isWidget){