X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fstructure%2FCommandListener.java;fp=src%2Fjalview%2Fstructure%2FCommandListener.java;h=e5f3e36cbead143dc6f59065cebb7a6c9837e160;hb=cf491d18e6affbfacfc67eda7c6bceedd457982f;hp=0000000000000000000000000000000000000000;hpb=5dc62d509b6d0f90f3545bf40b272390410eda45;p=jalview.git diff --git a/src/jalview/structure/CommandListener.java b/src/jalview/structure/CommandListener.java new file mode 100644 index 0000000..e5f3e36 --- /dev/null +++ b/src/jalview/structure/CommandListener.java @@ -0,0 +1,35 @@ +package jalview.structure; + +import jalview.commands.CommandI; + +/** + * Defines a listener for commands performed on another alignment. This is to + * support linked editing of two alternative representations of an alignment (in + * particular, cDNA and protein). + * + * @author gmcarstairs + * + */ +public interface CommandListener +{ + /** + * The listener may attempt to perform the specified command; the region acted + * on is determined by a callback to the StructureSelectionManager (which + * holds mappings between alignments). + * + * @param command + * @param undo + * @param ssm + * @param source + * the originator of the command + */ + public void mirrorCommand(CommandI command, boolean undo, + StructureSelectionManager ssm, VamsasSource source); + + /** + * Temporary workaround to make check for source == listener work. + * + * @return + */ + public VamsasSource getVamsasSource(); +}