public void valueChanged(SheetSelectionEvent e) {
if (e.isAdjusting) {
//only finished selection
return;
}
SheetSelectionModel smod = table.getSelectionModel();
if(smod.isSelectionEmpty()
|| smod.getAnchor().equals(smod.getLead())) {
//empty selection or single cell
return;
}
//without head
boolean dataAvailiable = true;
int headHeight = RangeParser.getDimensions(format.getCols().getList()).height;
if (smod.getAnchor().row < headHeight
|| smod.getLead().row < headHeight) {
dataAvailiable = false;
}
//without left head
int leftHeadHeight = RangeParser.getDimensions(format.getRows().getList()).height;
if (smod.getAnchor().col < leftHeadHeight
|| smod.getLead().col < leftHeadHeight) {
dataAvailiable = false;
}
checkIsFillRange(smod.getAnchor(), smod.getLead(), dataAvailiable);
}