Skip to content

Commit 025c893

Browse files
committed
fix(gridEdit): issue 2885 non-character fields were invoking edit. Not sure if I got all the keys, but the most used ones are accounted for
1 parent aa56355 commit 025c893

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

Diff for: src/features/edit/js/gridEdit.js

+9-1
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,15 @@
271271
* @returns {boolean} true if an edit should start
272272
*/
273273
isStartEditKey: function (evt) {
274-
if (evt.keyCode === uiGridConstants.keymap.LEFT ||
274+
if (evt.metaKey ||
275+
evt.keyCode === uiGridConstants.keymap.ESC ||
276+
evt.keyCode === uiGridConstants.keymap.SHIFT ||
277+
evt.keyCode === uiGridConstants.keymap.CTRL ||
278+
evt.keyCode === uiGridConstants.keymap.ALT ||
279+
evt.keyCode === uiGridConstants.keymap.WIN ||
280+
evt.keyCode === uiGridConstants.keymap.CAPSLOCK ||
281+
282+
evt.keyCode === uiGridConstants.keymap.LEFT ||
275283
(evt.keyCode === uiGridConstants.keymap.TAB && evt.shiftKey) ||
276284

277285
evt.keyCode === uiGridConstants.keymap.RIGHT ||

Diff for: src/js/core/constants.js

+1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
keymap: {
2626
TAB: 9,
2727
STRG: 17,
28+
CAPSLOCK: 20,
2829
CTRL: 17,
2930
CTRLRIGHT: 18,
3031
CTRLR: 18,

0 commit comments

Comments
 (0)