Index: src/org/netbeans/modules/java/imptool/FqnPanel.java =================================================================== RCS file: /cvs/java/src/org/netbeans/modules/java/imptool/FqnPanel.java,v retrieving revision 1.11.2.1 diff -C3 -r1.11.2.1 FqnPanel.java *** src/org/netbeans/modules/java/imptool/FqnPanel.java 11 Mar 2003 15:55:36 -0000 1.11.2.1 --- src/org/netbeans/modules/java/imptool/FqnPanel.java 17 Sep 2003 09:45:21 -0000 *************** *** 32,41 **** * @author thurka */ class FqnPanel extends RootPanel { /** Creates new form fqnPanel */ public FqnPanel() { ! } /** This method is called from within the constructor to --- 32,42 ---- * @author thurka */ class FqnPanel extends RootPanel { + private boolean finalizable; /** Creates new form fqnPanel */ public FqnPanel() { ! this.finalizable=false; } /** This method is called from within the constructor to *************** *** 97,106 **** void initListTableView(Node masterNode,int width) { remove(pleaseWait); super.initListTableView(masterNode, width); ! AccessibleContext c = getListTableView().getAccessibleContext(); c.setAccessibleName(Util.getString("ACSN_FqnPanelIdentifierList")); // NOI18N c.setAccessibleDescription(Util.getString("ACSD_FqnPanelIdentifierList")); // NOI18N } void addNoRowsLabel() { --- 98,113 ---- void initListTableView(Node masterNode,int width) { remove(pleaseWait); super.initListTableView(masterNode, width); ! this.finalizable=true; ! fireStateChange(); ! AccessibleContext c = getListTableView().getAccessibleContext(); c.setAccessibleName(Util.getString("ACSN_FqnPanelIdentifierList")); // NOI18N c.setAccessibleDescription(Util.getString("ACSD_FqnPanelIdentifierList")); // NOI18N + } + + boolean isFinalizable() { + return this.finalizable; } void addNoRowsLabel() { Index: src/org/netbeans/modules/java/imptool/RootPanel.java =================================================================== RCS file: /cvs/java/src/org/netbeans/modules/java/imptool/RootPanel.java,v retrieving revision 1.18.2.1 diff -C3 -r1.18.2.1 RootPanel.java *** src/org/netbeans/modules/java/imptool/RootPanel.java 11 Mar 2003 15:55:37 -0000 1.18.2.1 --- src/org/netbeans/modules/java/imptool/RootPanel.java 17 Sep 2003 09:45:21 -0000 *************** *** 14,25 **** package org.netbeans.modules.java.imptool; import java.awt.*; import javax.swing.*; import org.openide.WizardDescriptor; import org.openide.nodes.Node; import org.openide.nodes.Sheet; - import javax.swing.event.ChangeListener; import org.openide.explorer.*; import org.openide.explorer.view.ListTableView; import org.openide.explorer.view.TreeTableView; --- 14,27 ---- package org.netbeans.modules.java.imptool; + import java.util.ArrayList; import java.awt.*; import javax.swing.*; + import javax.swing.event.ChangeEvent; + import javax.swing.event.ChangeListener; import org.openide.WizardDescriptor; import org.openide.nodes.Node; import org.openide.nodes.Sheet; import org.openide.explorer.*; import org.openide.explorer.view.ListTableView; import org.openide.explorer.view.TreeTableView; *************** *** 33,40 **** --- 35,45 ---- */ abstract class RootPanel extends JPanel { ImpDataSource dataSource; + boolean initialized=false; + private ArrayList changeListeners = new ArrayList(1); + /** See org.openide.WizardDescriptor.PROP_CONTENT_SELECTED_INDEX */ private static final String PROP_CONTENT_SELECTED_INDEX = "WizardPanel_contentSelectedIndex"; // NOI18N *************** *** 116,121 **** --- 121,130 ---- } } + boolean isFinalizable() { + return true; + } + public void addNotify() { super.addNotify(); *************** *** 144,149 **** --- 153,175 ---- add(noRowText,BorderLayout.NORTH); } + void addChangeListener(ChangeListener l) { + if(!changeListeners.contains(l)) { + changeListeners.add(l); + } + } + + void removeChangeListener(ChangeListener l) { + changeListeners.remove(l); + } + + protected void fireStateChange() { + for(int i=0; itrue if the user has entered satisfactory information */ public boolean isValid() { ! return true; } /** Add a listener to changes of the panel's validity. * @param l the listener to add * @see #isValid */ public void addChangeListener(ChangeListener l) { } /** Remove a listener to changes of the panel's validity. * @param l the listener to remove */ public void removeChangeListener(ChangeListener l) { } public String getName() { --- 243,262 ---- * @return true if the user has entered satisfactory information */ public boolean isValid() { ! return ((RootPanel)getComponent()).isFinalizable(); } /** Add a listener to changes of the panel's validity. * @param l the listener to add * @see #isValid */ public void addChangeListener(ChangeListener l) { + ((RootPanel)getComponent()).addChangeListener(l); } /** Remove a listener to changes of the panel's validity. * @param l the listener to remove */ public void removeChangeListener(ChangeListener l) { + ((RootPanel)getComponent()).removeChangeListener(l); } public String getName() {