Changeset 5658


Ignore:
Timestamp:
2003-10-16T11:42:31+13:00 (21 years ago)
Author:
jmt12
Message:

Extra method for loss of focus

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gli/src/org/greenstone/gatherer/gui/GConfigPane.java

    r5589 r5658  
    8282    this.setLayout(new BorderLayout());
    8383    }
    84     public void gainFocus() {
    85     if(cdm == null && Gatherer.c_man.ready()) {
    86         // Retrieve the new config manager.
    87         cdm = Gatherer.c_man.getCollection().cdm;
    88         // Display it.
    89         cdm.display(this);
    90     }
    91     if(cdm != null) {
    92         cdm.gainFocus();
    93     }
    94     }
     84   
     85   public void gainFocus() {
     86      if(cdm == null && Gatherer.c_man.ready()) {
     87     // Retrieve the new config manager.
     88     cdm = Gatherer.c_man.getCollection().cdm;
     89     // Display it.
     90     cdm.display(this);
     91      }
     92      if(cdm != null) {
     93     cdm.gainFocus();
     94      }
     95   }
    9596
    96     public ArrayList getLanguageCodes() {
    97     return cdm.language_manager.getLanguageCodes();
    98     }
     97   public ArrayList getLanguageCodes() {
     98      return cdm.language_manager.getLanguageCodes();
     99   }
    99100
    100     public Rectangle setSelectedElement(ElementWrapper element) {
    101     return cdm.setSelectedElement(element.getName());
    102     }
    103     public void saveConfiguration() {
    104     if(cdm != null) {
    105         cdm.save();
    106     }
    107     }
     101   public void loseFocus() {
     102      if(cdm != null) {
     103     cdm.save();
     104      }
     105   }
     106   
     107   public Rectangle setSelectedElement(ElementWrapper element) {
     108      return cdm.setSelectedElement(element.getName());
     109   }
     110
     111   public void saveConfiguration() {
     112      if(cdm != null) {
     113     cdm.save();
     114      }
     115   }
    108116}
Note: See TracChangeset for help on using the changeset viewer.