From: Jim Procter Date: Thu, 5 Apr 2018 13:28:10 +0000 (+0100) Subject: JAL-2944 combo box to pick which viewer to load structures into X-Git-Tag: Release_2_10_4~32^2~13 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=1b0124237cbc666219ec85a6acefbd57d1e00a9d;p=jalview.git JAL-2944 combo box to pick which viewer to load structures into --- diff --git a/src/jalview/jbgui/GStructureChooser.java b/src/jalview/jbgui/GStructureChooser.java index 9bcaa5a..9c7ba6d 100644 --- a/src/jalview/jbgui/GStructureChooser.java +++ b/src/jalview/jbgui/GStructureChooser.java @@ -29,6 +29,7 @@ import jalview.fts.service.pdb.PDBFTSRestClient; import jalview.gui.AlignmentPanel; import jalview.gui.Desktop; import jalview.gui.JvSwingUtils; +import jalview.gui.StructureViewer; import jalview.util.MessageManager; import java.awt.BorderLayout; @@ -70,6 +71,8 @@ import javax.swing.event.DocumentListener; import javax.swing.event.InternalFrameEvent; import javax.swing.table.TableColumn; +import net.miginfocom.swing.MigLayout; + @SuppressWarnings("serial") /** * GUI layout for structure chooser @@ -108,7 +111,7 @@ public abstract class GStructureChooser extends JPanel protected JTextField txt_search = new JTextField(14); - private JPanel pnl_actions = new JPanel(); + private JPanel pnl_actions = new JPanel(new MigLayout()); private JPanel pnl_main = new JPanel(); @@ -165,6 +168,8 @@ public abstract class GStructureChooser extends JPanel protected static final String VIEWS_ENTER_ID = "VIEWS_ENTER_ID"; + protected JComboBox targetView = new JComboBox(); + /** * 'cached' structure view */ @@ -514,6 +519,8 @@ public abstract class GStructureChooser extends JPanel chk_invertFilter.addItemListener(this); + targetView.setVisible(false); + pnl_actions.add(targetView,"wrap"); pnl_actions.add(chk_rememberSettings); pnl_actions.add(btn_view); pnl_actions.add(btn_cancel);