From: James Procter Date: Mon, 1 May 2023 14:12:18 +0000 (+0100) Subject: JAL-4134 double click to select column groups X-Git-Tag: Release_2_11_3_0~14^2~3^2^2~36^2~3 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=dd2acb4e1060219d28f3acbe34772b947a6a4547;p=jalview.git JAL-4134 double click to select column groups --- diff --git a/src/jalview/gui/AnnotationPanel.java b/src/jalview/gui/AnnotationPanel.java index eeda585..3bf24b4 100755 --- a/src/jalview/gui/AnnotationPanel.java +++ b/src/jalview/gui/AnnotationPanel.java @@ -655,7 +655,8 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI, fr = Math.min(cXci.cStart, cXci.cEnd); to = Math.max(cXci.cStart, cXci.cEnd); - if (evt.isControlDown()) + // double click selects the whole group + if (evt.getClickCount()==2) { ContactMatrixI matrix = av.getContactMatrix(clicked); @@ -705,7 +706,7 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI, // PAE SPECIFIC // and also select everything lower than the max range adjacent // (kind of works) - if (PAEContactMatrix.PAEMATRIX.equals(clicked.getCalcId())) + if (evt.isControlDown() && PAEContactMatrix.PAEMATRIX.equals(clicked.getCalcId())) { int c = fr - 1; ContactRange cr = forCurrentX.getRangeFor(fr, to);