public void mouseReleased(MouseEvent evt)
{
- if (!dragCancelled)
+ if (!resizePanel && !dragCancelled)
{
int start = selectedRow;
int end = getSelectedRow(evt.getY() + scrollOffset);
- if (start != end)
+ if (start>-1 && start != end)
{
// Swap these annotations
AlignmentAnnotation startAA = ap.av.alignment
public void paint(Graphics g)
{
int w = getSize().width;
- if (image == null || w != image.getWidth(this))
+ int h = getSize().height;
+ if (image == null || w != image.getWidth(this) || h!=image.getHeight(this) )
{
image = createImage(w, ap.annotationPanel.getSize().height);
}