/*************************************************************************\ * Copyright (c) 2002 The University of Chicago, as Operator of Argonne * National Laboratory. * Copyright (c) 2002 The Regents of the University of California, as * Operator of Los Alamos National Laboratory. * This file is distributed subject to a Software License Agreement found * in the file LICENSE that is included with this distribution. \*************************************************************************/ package SDDS.java.SDDSedit; import javax.swing.*; import java.beans.*; import java.awt.*; import java.awt.event.*; import java.lang.reflect.*; import SDDS.java.SDDS.*; class SearchDialog extends JDialog { private String[] names = null; private JOptionPane optionPane; private JTextField[] fields = null; private JRadioButton[] labels = null; private JPanel panel1=null; private JScrollPane scrollPane=null; private GridBagLayout gbl=null; private GridBagConstraints gbc=null; private ButtonGroup typeButtonGroup=null; private boolean canceled=false; public String getName() { if ((canceled == true) || (names == null)) { return null; } int length,i; length = Array.getLength(names); for (i=0;i 13) { height = 352; } else { height = length * 25 + 2; } scrollPane.setPreferredSize(new Dimension(300, height)); scrollPane.setMinimumSize(new Dimension(300, height)); panel1.removeAll(); names = n; labels = new JRadioButton[length]; fields = new JTextField[length]; for (i=0;i