From: Ben Soares Date: Wed, 9 Nov 2022 18:11:42 +0000 (+0000) Subject: JAL-3416 Add necessary logo to non-internal Frames X-Git-Tag: Release_2_11_3_0~23^2~4^2~10 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=a87e70e6c8fd8e899a42becd0dc6a3bfdf317613;p=jalview.git JAL-3416 Add necessary logo to non-internal Frames --- diff --git a/src/jalview/gui/JvOptionPane.java b/src/jalview/gui/JvOptionPane.java index c228cb9..0e0b13d 100644 --- a/src/jalview/gui/JvOptionPane.java +++ b/src/jalview/gui/JvOptionPane.java @@ -1166,7 +1166,7 @@ public class JvOptionPane extends JOptionPane // A better hack which works is to create a new JFrame parent with // setAlwaysOnTop(true) JFrame dialogParent = new JFrame(); - dialogParent.setIconImage(null); + dialogParent.setIconImages(ChannelProperties.getIconList()); dialogParent.setAlwaysOnTop(true); int answer = JOptionPane.showConfirmDialog(dialogParent, label, @@ -1183,7 +1183,7 @@ public class JvOptionPane extends JOptionPane Object[] options, Object initialValue, boolean modal) { JFrame frame = new JFrame(); - frame.setIconImage(null); + frame.setIconImages(ChannelProperties.getIconList()); showDialogOnTopAsync(frame, label, actionString, JOPTIONPANE_OPTION, JOPTIONPANE_MESSAGETYPE, icon, options, initialValue, modal); } @@ -1408,7 +1408,7 @@ public class JvOptionPane extends JOptionPane Platform.isJS() ? initialValue : initialValueButton); JDialog dialog = joptionpane.createDialog(parentComponent, title); - dialog.setIconImage(null); + dialog.setIconImages(ChannelProperties.getIconList()); dialog.setModalityType( modal ? ModalityType.APPLICATION_MODAL : ModalityType.MODELESS); dialog.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);