//need to build menu each time because it can change
if (spreadSheet instanceof TimeSpreadSheet){
TimeSpreadSheetColumnsPopupMenu columnsPopup = new TimeSpreadSheetColumnsPopupMenu((TimeSpreadSheet)sp,sp.getSpreadSheetCategory());
columnsPopup.show(sp,e.getX(),e.getY());
}else{
SpreadSheetColumnsPopupMenu columnsPopup = new SpreadSheetColumnsPopupMenu(sp,sp.getSpreadSheetCategory());
columnsPopup.show(sp,e.getX(),e.getY());
}
}
}
}else{
SpreadSheetSelectionModel selection=spreadSheet.getSelection();