From: gmungoc Date: Wed, 5 Jun 2019 14:22:02 +0000 (+0100) Subject: JAL-3288 override JInternalFrame.setSelected() to avoid cancelling menus X-Git-Tag: Release_2_11_1_0~53^2 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=9fa3368723ed450b77baeb02c5eaec33f7668965;p=jalview.git JAL-3288 override JInternalFrame.setSelected() to avoid cancelling menus --- diff --git a/src/jalview/gui/SplitFrame.java b/src/jalview/gui/SplitFrame.java index 4a4c10c..44a97bc 100644 --- a/src/jalview/gui/SplitFrame.java +++ b/src/jalview/gui/SplitFrame.java @@ -29,7 +29,6 @@ import jalview.util.Platform; import jalview.viewmodel.AlignmentViewport; import java.awt.Component; -import java.awt.Toolkit; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.KeyAdapter; @@ -789,4 +788,13 @@ public class SplitFrame extends GSplitFrame implements SplitContainerI }; overrideKeyBinding(key_cmdF, action); } + + /** + * Override to do nothing - let the embedded AlignFrame's be the selected frame + */ + @Override + public void setSelected(boolean selected) throws PropertyVetoException + { + // no-op here fixes JAL-3288 (menus close immediately) + } }