git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
JAL-2388 Make sure resizing still works
[jalview.git]
/
src
/
jalview
/
viewmodel
/
OverviewDimensionsWithHidden.java
diff --git
a/src/jalview/viewmodel/OverviewDimensionsWithHidden.java
b/src/jalview/viewmodel/OverviewDimensionsWithHidden.java
index
575167a
..
eff27dd
100644
(file)
--- a/
src/jalview/viewmodel/OverviewDimensionsWithHidden.java
+++ b/
src/jalview/viewmodel/OverviewDimensionsWithHidden.java
@@
-20,18
+20,16
@@
*/
package jalview.viewmodel;
*/
package jalview.viewmodel;
-import jalview.datamodel.AlignmentColsCollection;
+import jalview.api.AlignmentColsCollectionI;
+import jalview.api.AlignmentRowsCollectionI;
import jalview.datamodel.AlignmentI;
import jalview.datamodel.AlignmentI;
-import jalview.datamodel.AlignmentRowsCollection;
+import jalview.datamodel.AllColsCollection;
+import jalview.datamodel.AllRowsCollection;
import jalview.datamodel.ColumnSelection;
import jalview.datamodel.HiddenSequences;
public class OverviewDimensionsWithHidden extends OverviewDimensions
{
import jalview.datamodel.ColumnSelection;
import jalview.datamodel.HiddenSequences;
public class OverviewDimensionsWithHidden extends OverviewDimensions
{
- private float pixelsPerCol;
-
- private float pixelsPerSeq;
-
/**
* Create an OverviewDimensions object
*
/**
* Create an OverviewDimensions object
*
@@
-45,11
+43,8
@@
public class OverviewDimensionsWithHidden extends OverviewDimensions
{
super(ranges, showAnnotationPanel);
{
super(ranges, showAnnotationPanel);
- int alwidth = ranges.getAbsoluteAlignmentWidth();
- int alheight = ranges.getAbsoluteAlignmentHeight();
-
- pixelsPerCol = (float) width / alwidth;
- pixelsPerSeq = (float) sequencesHeight / alheight;
+ alwidth = ranges.getAbsoluteAlignmentWidth();
+ alheight = ranges.getAbsoluteAlignmentHeight();
}
/**
}
/**
@@
-74,8
+69,8
@@
public class OverviewDimensionsWithHidden extends OverviewDimensions
int x = mousex;
int y = mousey;
int x = mousex;
int y = mousey;
- int alwidth = ranges.getAbsoluteAlignmentWidth();
- int alheight = ranges.getAbsoluteAlignmentHeight();
+ alwidth = ranges.getAbsoluteAlignmentWidth();
+ alheight = ranges.getAbsoluteAlignmentHeight();
if (x < 0)
{
if (x < 0)
{
@@
-181,8
+176,8
@@
public class OverviewDimensionsWithHidden extends OverviewDimensions
public void setBoxPosition(HiddenSequences hiddenSeqs,
ColumnSelection hiddenCols, ViewportRanges ranges)
{
public void setBoxPosition(HiddenSequences hiddenSeqs,
ColumnSelection hiddenCols, ViewportRanges ranges)
{
- int alwidth = ranges.getAbsoluteAlignmentWidth();
- int alheight = ranges.getAbsoluteAlignmentHeight();
+ alwidth = ranges.getAbsoluteAlignmentWidth();
+ alheight = ranges.getAbsoluteAlignmentHeight();
// work with absolute values of startRes and endRes
int startRes = hiddenCols.adjustForHiddenColumns(ranges.getStartRes());
// work with absolute values of startRes and endRes
int startRes = hiddenCols.adjustForHiddenColumns(ranges.getStartRes());
@@
-208,32
+203,20
@@
public class OverviewDimensionsWithHidden extends OverviewDimensions
}
@Override
}
@Override
- public AlignmentColsCollection getColumns(ViewportRanges ranges,
+ public AlignmentColsCollectionI getColumns(ViewportRanges ranges,
ColumnSelection hiddenCols)
{
ColumnSelection hiddenCols)
{
- return new AlignmentColsCollection(0,
+ return new AllColsCollection(0,
ranges.getAbsoluteAlignmentWidth() - 1,
hiddenCols);
}
@Override
ranges.getAbsoluteAlignmentWidth() - 1,
hiddenCols);
}
@Override
- public AlignmentRowsCollection getRows(ViewportRanges ranges,
+ public AlignmentRowsCollectionI getRows(ViewportRanges ranges,
AlignmentI al)
{
AlignmentI al)
{
- return new AlignmentRowsCollection(0,
+ return new AllRowsCollection(0,
ranges.getAbsoluteAlignmentHeight() - 1,
al);
}
ranges.getAbsoluteAlignmentHeight() - 1,
al);
}
-
- @Override
- public float getPixelsPerCol()
- {
- return pixelsPerCol;
- }
-
- @Override
- public float getPixelsPerSeq()
- {
- return pixelsPerSeq;
- }
}
}