Skip to content

Commit f6e4fdb

Browse files
committed
slick_grid: don't make cell active on highlight. Closes #392.
1 parent 575365d commit f6e4fdb

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

src/modules/types/edition/slick_grid/controller.js

+1-5
Original file line numberDiff line numberDiff line change
@@ -257,15 +257,11 @@ define(['modules/default/defaultcontroller', 'src/util/util', 'lodash'], functio
257257
this.sendAction( 'row', item, 'onHover' );
258258
};
259259

260-
var onClick = _.throttle(function(row, item) {
260+
controller.prototype.onClick = _.throttle(function(row, item) {
261261
this.setVarFromEvent( 'onSelect', 'row', 'list', [ row ] );
262262
this.sendAction( 'row', item, 'onSelect' );
263263
}, 250, {trailing: false});
264264

265-
controller.prototype.onClick = function(row, item) {
266-
onClick.call(this, row, item);
267-
};
268-
269265
controller.prototype.onActive = function(row, item) {
270266
var itemId = item[this.module.view.idPropertyName];
271267
if(this.lastClickedItemId === itemId) return;

src/modules/types/edition/slick_grid/view.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -377,6 +377,7 @@ define(['require', 'modules/default/defaultview', 'src/util/debug', 'lodash', 's
377377
var hl = itemInfo.item._highlight;
378378
that._hl = hl;
379379
if(hl) {
380+
console.log('highlight id');
380381
API.highlightId(hl,1);
381382
lastHighlight = hl;
382383
}
@@ -733,7 +734,7 @@ define(['require', 'modules/default/defaultview', 'src/util/debug', 'lodash', 's
733734
this.grid.scrollRowToTop(gridRow);
734735
}
735736

736-
this.grid.setActiveCell(gridRow, 0);
737+
//this.grid.setActiveCell(gridRow, 0);
737738
}
738739
},
739740

0 commit comments

Comments
 (0)