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
Merge branch 'develop' into improvement/JAL-4124_dont_duplacate_PAE_data_acrossviews
[jalview.git]
/
src
/
jalview
/
gui
/
TreeCanvas.java
diff --git
a/src/jalview/gui/TreeCanvas.java
b/src/jalview/gui/TreeCanvas.java
index
6fbd422
..
2d4bdc8
100755
(executable)
--- a/
src/jalview/gui/TreeCanvas.java
+++ b/
src/jalview/gui/TreeCanvas.java
@@
-406,9
+406,9
@@
public class TreeCanvas extends JPanel implements MouseListener, Runnable,
}
int ystart = (node.left() == null ? 0
}
int ystart = (node.left() == null ? 0
- : (int) (((BinaryNode) node.left()).ycount * chunk)) + offy;
+ : (int) (node.left().ycount * chunk)) + offy;
int yend = (node.right() == null ? 0
int yend = (node.right() == null ? 0
- : (int) (((BinaryNode) node.right()).ycount * chunk)) + offy;
+ : (int) (node.right().ycount * chunk)) + offy;
Rectangle pos = new Rectangle(xend - 2, ypos - 2, 5, 5);
nodeHash.put(node, pos);
Rectangle pos = new Rectangle(xend - 2, ypos - 2, 5, 5);
nodeHash.put(node, pos);
@@
-791,11
+791,11
@@
public class TreeCanvas extends JPanel implements MouseListener, Runnable,
if (top.count == 0)
{
if (top.count == 0)
{
- top.count = ((BinaryNode) top.left()).count
- + ((BinaryNode) top.right()).count;
+ top.count = top.left().count
+ + top.right().count;
}
}
- double chunk = (double) (height - (offy)) / (double)top.count;
+ float chunk = (float) (height - (offy)) / top.count;
drawNode(g2, tree.getTopNode(), chunk, wscale, width, offx, offy);
drawNode(g2, tree.getTopNode(), chunk, wscale, width, offx, offy);