Package gov.nara.nwts.ftapp.filetest

Examples of gov.nara.nwts.ftapp.filetest.FileTest


  /**
   * Reset the filter and property tabs based on the selected FileTest.
   */
  void setFilters() {
    FileTest fileTest = (FileTest)criteriaPanel.actions.getSelectedItem();
    setPreference("action", fileTest.toString());
    criteriaPanel.description.setText(fileTest.getDescription());
    criteriaPanel.description.setCaretPosition(0);
    criteriaPanel.filterTabs.removeAll();
    for(Iterator<FileTestFilter>i=fileTest.getFilters().iterator(); i.hasNext();){
      FileTestFilter filter = i.next();
      new FilterPanel(this, filter);
    }
    criteriaPanel.propPanel.removeAll();
    Box b = new Box(BoxLayout.Y_AXIS);
    b.add(Box.createHorizontalStrut(500));
    criteriaPanel.propPanel.add(b);
    List<FTProp> myprops = fileTest.getPropertyList();
    criteriaPanel.propFilter.setEnabledAt(1, false);
    for(FTProp myprop: myprops) {
      JComponent c = myprop.getEditor();
      c.setBorder(BorderFactory.createTitledBorder(myprop.getName()));
      c.setToolTipText(myprop.describe());
View Full Code Here


    progressPanel.pause.setEnabled(false);
    setSelectedFile();
    resetTest();
  }
  public void resetTest() {
    FileTest next = ((FileTest)criteriaPanel.actions.getSelectedItem()).resetOption();
    if (next != null) {
      criteriaPanel.actions.setSelectedItem(next);
      setFilters();
    }   
  }
View Full Code Here

    p = addPanel("Action to perform on Files");
    actions = new JComboBox(parent.actionRegistry);
   
    String action = parent.preferences.get("action", "");
    for(int i=0; i<actions.getItemCount(); i++){
      FileTest ft = (FileTest)actions.getItemAt(i);
      if (ft.toString().equals(action)) {
        actions.setSelectedIndex(i);
        break;
      }
    }
   
View Full Code Here

TOP

Related Classes of gov.nara.nwts.ftapp.filetest.FileTest

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.