I have a grid panel where some cells are editable, and others aren't. I'd like to make it so that when you tab through the grid with your keyboard, the non-editable cells are skipped over i.e. never get selected.
Here's my simple grid so far:
var store = Ext.create('Ext.data.Store', {
fields:['name', 'age', 'country'],
data:[
{name:'Lisa', age:13, country: 'USA'},
{name:'Bart', age:75, country: 'France'},
{name:'Homer', age:32, country: 'Germany'},
{name:'Marge', age:56, country: 'Australia'}
]
});
var grid = Ext.create('Ext.grid.Panel', {
title: 'People',
store: store,
columns: [
{header: 'Name', dataIndex: 'name', flex: 1},
{header: 'Age', dataIndex: 'age', flex: 1, editor: 'numberfield'},
{header: 'Country', dataIndex: 'country', flex: 1, editor: 'textfield'},
],
selType: 'cellmodel',
plugins: [{
ptype: 'cellediting',
clicksToEdit: 2
}],
height: 150,
width: 200,
renderTo: Ext.getBody()
});
As you can see, the first column (Name) is not editable, where as the second (Age) and third (Country) have editors defined. I'd like the Name column to be skipped over whenever you tab through the grid with your keyboard. In other words, I mean this kind of tab order:
COL1 | COL2 | COL3 |
-----------------------------
SKIP | 1 | 2 |
-----------------------------
SKIP | 3 | 4 |
-----------------------------
SKIP | 5 | 6 |
-----------------------------
I have no idea where I can inject this kind of custom tabbing behaviour, but I can't imagine it is impossible to do.
Here's a JS fiddle of my code: http://jsfiddle.net/qnXrp/