if (jvobjs[o] == null)
{
// can't cope with selections for unmapped objects
- // continue;
+ continue;
}
if (type == null)
{
{
int[] prange = uk.ac.vamsas.objects.utils.Range
.getBounds(sm.getRanges());
- boolean rangeset = false;
- colsel = new ColumnSelection();
+ jselection.setStartRes(prange[0] - 1);
+ jselection.setEndRes(prange[1] - 1);
prange = uk.ac.vamsas.objects.utils.Range
.getIntervals(sm.getRanges());
+ colsel = new ColumnSelection();
for (int p = 0; p < prange.length; p += 2)
{
int d = (prange[p] <= prange[p + 1]) ? 1 : -1;
- if (!rangeset)
- {
- if (jselection != null)
- {
- // set the bounds of the selected area using the first
- // interval.
- jselection.setStartRes(prange[p] - 1);
- jselection.setEndRes(prange[p + 1] - 1);
- rangeset = true;
- }
- }
- else
- {
// try to join up adjacent columns to make a larger
// selection
// lower and upper bounds
{
jselection.setEndRes(prange[p + u] - 1);
}
- }
// mark all the columns in the range.
for (int sr = prange[p], er = prange[p + 1], de = er
+ d; sr != de; sr += d)