Changeset 12749


Ignore:
Timestamp:
2006-09-15T10:06:05+12:00 (18 years ago)
Author:
mdewsnip
Message:

Fixed some bugs in noticing what type of rebuild is required. This is all done completely wrong though -- it should be done at the CollectionConfiguration level, not at the GUI level.

Location:
trunk/gli/src/org/greenstone/gatherer/cdm
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/gli/src/org/greenstone/gatherer/cdm/ArgumentConfiguration.java

    r12305 r12749  
    103103    cancel.addActionListener(this);
    104104    ok.addActionListener(this);
    105     ok.addActionListener(CollectionDesignManager.all_change_listener);
    106105
    107106    button_pane.setBorder(BorderFactory.createEmptyBorder(5,0,0,0));
     
    153152    }
    154153
     154
     155    public void addOKButtonActionListener(ActionListener action_listener)
     156    {
     157    ok.addActionListener(action_listener);
     158    }
     159
     160
    155161    /** Destructor. */
    156162    public void destroy() {
  • trunk/gli/src/org/greenstone/gatherer/cdm/ClassifierManager.java

    r12644 r12749  
    315315        // Listeners
    316316        add.addActionListener(new AddListener());
    317         add.addActionListener(CollectionDesignManager.buildcol_change_listener);
    318317        classifier_combobox.addItemListener(ccl);
    319318        configure.addActionListener(new ConfigureListener());
    320         configure.addActionListener(CollectionDesignManager.buildcol_change_listener);
    321319        remove.addActionListener(new RemoveListener());
    322320        remove.addActionListener(CollectionDesignManager.buildcol_change_listener);
     
    427425
    428426        ArgumentConfiguration ac = new ArgumentConfiguration(new_classifier);
     427        ac.addOKButtonActionListener(CollectionDesignManager.buildcol_change_listener);
    429428        if (ac.display()) {
    430429            assignClassifier(new_classifier);
     
    462461            Classifier classifier = (Classifier) classifier_list.getSelectedValue();
    463462            ArgumentConfiguration ac = new ArgumentConfiguration(classifier);
    464             if(ac.display()) {
     463            ac.addOKButtonActionListener(CollectionDesignManager.buildcol_change_listener);
     464            if (ac.display()) {
    465465                refresh(classifier);
    466466            }
     
    487487           Classifier classifier = (Classifier) classifier_list.getSelectedValue();
    488488           ArgumentConfiguration ac = new ArgumentConfiguration(classifier);
    489            if(ac.display()) {
     489           ac.addOKButtonActionListener(CollectionDesignManager.buildcol_change_listener);
     490           if (ac.display()) {
    490491               refresh(classifier);
    491492           }
  • trunk/gli/src/org/greenstone/gatherer/cdm/PluginManager.java

    r12642 r12749  
    463463       
    464464        // Listeners
    465         add.addActionListener(new AddListener()); //all_change_listener is listening to the ArgumentConfiguration
     465        add.addActionListener(new AddListener());
    466466        configure.addActionListener(new ConfigureListener());
    467467        MoveListener ml = new MoveListener();
     
    593593
    594594        ArgumentConfiguration ac = new ArgumentConfiguration(new_plugin);
     595        ac.addOKButtonActionListener(CollectionDesignManager.all_change_listener);
    595596        if (ac.display()) {
    596597            assignPlugin(new_plugin);
     
    619620            if(!plugin.isSeparator()) {
    620621                ArgumentConfiguration ac = new ArgumentConfiguration(plugin);
    621                 if(ac.display()) {
     622                ac.addOKButtonActionListener(CollectionDesignManager.all_change_listener);
     623                if (ac.display()) {
    622624                refresh(plugin);
    623625                }
     
    645647            if(!plugin.isSeparator()) {
    646648            ArgumentConfiguration ac = new ArgumentConfiguration(plugin);
    647             if(ac.display()) {
     649            ac.addOKButtonActionListener(CollectionDesignManager.all_change_listener);
     650            if (ac.display()) {
    648651                refresh(plugin);
    649652            }
Note: See TracChangeset for help on using the changeset viewer.