Clover icon

Coverage Report

  1. Project Clover database Fri Dec 6 2024 13:47:14 GMT
  2. Package jalview.jbgui

File GRestInputParamEditDialog.java

 

Coverage histogram

../../img/srcFileCovDistChart0.png
60% of files have more coverage

Code metrics

0
26
8
1
136
92
8
0.31
3.25
8
1

Classes

Class Line # Actions
GRestInputParamEditDialog 43 26 8
0.00%
 

Contributing tests

No tests hitting this source file were found.

Source view

1    /*
2    * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
3    * Copyright (C) $$Year-Rel$$ The Jalview Authors
4    *
5    * This file is part of Jalview.
6    *
7    * Jalview is free software: you can redistribute it and/or
8    * modify it under the terms of the GNU General Public License
9    * as published by the Free Software Foundation, either version 3
10    * of the License, or (at your option) any later version.
11    *
12    * Jalview is distributed in the hope that it will be useful, but
13    * WITHOUT ANY WARRANTY; without even the implied warranty
14    * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15    * PURPOSE. See the GNU General Public License for more details.
16    *
17    * You should have received a copy of the GNU General Public License
18    * along with Jalview. If not, see <http://www.gnu.org/licenses/>.
19    * The Jalview Authors are detailed in the 'AUTHORS' file.
20    */
21    package jalview.jbgui;
22   
23    import jalview.gui.JvSwingUtils;
24    import jalview.gui.OptsAndParamsPage;
25    import jalview.util.MessageManager;
26   
27    import java.awt.Dimension;
28    import java.awt.event.KeyEvent;
29    import java.awt.event.KeyListener;
30   
31    import javax.swing.JLabel;
32    import javax.swing.JList;
33    import javax.swing.JPanel;
34    import javax.swing.JScrollPane;
35    import javax.swing.JTextField;
36    import javax.swing.ListSelectionModel;
37    import javax.swing.border.TitledBorder;
38    import javax.swing.event.ListSelectionEvent;
39    import javax.swing.event.ListSelectionListener;
40   
41    import net.miginfocom.swing.MigLayout;
42   
 
43    public class GRestInputParamEditDialog
44    {
45   
46    protected JPanel dpane;
47   
48    protected JPanel okcancel;
49   
50    protected JList typeList;
51   
52    protected JTextField tok;
53   
54    protected JPanel options;
55   
56    protected JPanel optionsPanel;
57   
 
58  0 toggle public GRestInputParamEditDialog()
59    {
60  0 jbInit();
61    }
62   
 
63  0 toggle protected void jbInit()
64    {
65  0 dpane = new JPanel(new MigLayout("", "[][][fill]", "[][fill][]"));
66  0 dpane.setPreferredSize(
67    new Dimension(110 + 100 + OptsAndParamsPage.PARAM_WIDTH, 400));
68  0 typeList = new JList();
69  0 typeList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
70  0 typeList.getSelectionModel()
71    .addListSelectionListener(new ListSelectionListener()
72    {
73   
 
74  0 toggle @Override
75    public void valueChanged(ListSelectionEvent e)
76    {
77  0 type_SelectionChangedActionPerformed(e);
78    };
79    });
80   
81  0 tok = new JTextField();
82  0 tok.addKeyListener(new KeyListener()
83    {
84   
 
85  0 toggle @Override
86    public void keyTyped(KeyEvent e)
87    {
88    }
89   
 
90  0 toggle @Override
91    public void keyReleased(KeyEvent e)
92    {
93  0 tokChanged_actionPerformed();
94    }
95   
 
96  0 toggle @Override
97    public void keyPressed(KeyEvent e)
98    {
99   
100    }
101    });
102  0 options = new JPanel(new MigLayout("", "[grow 100,fill]", ""));
103  0 optionsPanel = new JPanel(new MigLayout("", "[fill]", "[fill]"));
104  0 JScrollPane optionView = new JScrollPane();
105  0 optionView.setViewportView(options);
106  0 JvSwingUtils.mgAddtoLayout(dpane,
107    MessageManager.getString("label.input_parameter_name"),
108    new JLabel(MessageManager.getString("label.name")), tok,
109    "grow,spanx 3,wrap");
110  0 JPanel paramsType = new JPanel(
111    new MigLayout("", "[grow 100,fill]", "[grow 100,fill]"));
112  0 paramsType.setBorder(new TitledBorder(
113    MessageManager.getString("label.select_input_type")));
114  0 JScrollPane jlistScroller = new JScrollPane();
115  0 jlistScroller.setViewportView(typeList);
116  0 paramsType.add(jlistScroller, "spanx 2,spany 2");
117  0 dpane.add(paramsType);
118  0 optionsPanel.setBorder(new TitledBorder(
119    MessageManager.getString("label.set_options_for_type")));
120  0 optionsPanel.add(optionView);
121  0 dpane.add(optionsPanel, "wrap");
122  0 okcancel = new JPanel(new MigLayout("", "[center][center]", "[]"));
123  0 dpane.add(okcancel, "spanx 3,wrap");
124   
125    }
126   
 
127  0 toggle protected void tokChanged_actionPerformed()
128    {
129   
130    }
131   
 
132  0 toggle protected void type_SelectionChangedActionPerformed(ListSelectionEvent e)
133    {
134    }
135   
136    }