Ignore:
Timestamp:
2004-11-03T11:30:47+13:00 (20 years ago)
Author:
mdewsnip
Message:

Some cosmetic improvements.

File:
1 edited

Legend:

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

    r8243 r8431  
    8484    }
    8585    }
     86
     87
    8688    /** Determine if a certain row should be shown in the table by checking it against all the current filters.
    8789     * @param model The <strong>TableModel</strong> the row is from.
     
    8991     * @return <i>true</i> if the rows data matches all autofilters set and should be displayed, <i>false</i> otherwise.
    9092     */
    91     public boolean filter(TableModel model, int row) {
    92     boolean result = true;
    93     for(int i = 0; result && i < filters.length; i++) {
    94         if(filters[i] != null && filters[i].active()) {
     93    public boolean filter(TableModel model, int row)
     94    {
     95    for (int i = 0; i < filters.length; i++) {
     96        if (filters[i] != null && filters[i].active()) {
    9597        ArrayList values = (ArrayList) model.getValueAt(row, i);
    96         result = result && filters[i].filter(values);
     98        if (filters[i].filter(values) == false) {
     99            return false;
     100        }
    97101        }
    98102    }
    99     return result;
     103
     104    return true;
    100105    }
     106
     107
    101108    /** Retrieve the autofilter associated with a certain column.
    102109     * @param column The column number as an <i>int</i>.
Note: See TracChangeset for help on using the changeset viewer.