I think that is standard grid control behavior. If you tell the grid what it's source data is it will create as many selectable cells as there are dataitems. If only 3, the 4th and later grid cells won't be selectable (by default).
that.controls.grid.changeDataset(that.cache.imgData, true);
changeDataset() is the api that connects an array to a grid and makes the grid display a limited number of items.
Hope that helps!