/**
* 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());