git://source.jalview.org
/
jalview.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
053a605
)
JAL-2842 remove infinite loop in cursor move
bug/JAL-2842
author
kiramt
<k.mourao@dundee.ac.uk>
Thu, 16 Nov 2017 09:12:06 +0000
(09:12 +0000)
committer
kiramt
<k.mourao@dundee.ac.uk>
Thu, 16 Nov 2017 09:12:06 +0000
(09:12 +0000)
src/jalview/gui/SeqPanel.java
patch
|
blob
|
history
diff --git
a/src/jalview/gui/SeqPanel.java
b/src/jalview/gui/SeqPanel.java
index
2223ee5
..
dbbf510
100644
(file)
--- a/
src/jalview/gui/SeqPanel.java
+++ b/
src/jalview/gui/SeqPanel.java
@@
-363,8
+363,11
@@
public class SeqPanel extends JPanel
int original = seqCanvas.cursorX - dx;
int maxWidth = av.getAlignment().getWidth();
+ // TODO: once JAL-2759 is ready, change this loop to something more
+ // efficient
while (!hidden.isVisible(seqCanvas.cursorX)
- && seqCanvas.cursorX < maxWidth && seqCanvas.cursorX > 0)
+ && seqCanvas.cursorX < maxWidth && seqCanvas.cursorX > 0
+ && dx != 0)
{
seqCanvas.cursorX += dx;
}