Changeset 600 for trunk


Ignore:
Timestamp:
08/23/12 13:42:35 (12 years ago)
Author:
pharms
Message:
  • added hashCode, but will perhaps be reverted later
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/quest-plugin-jfc/src/main/java/de/ugoe/cs/quest/plugin/jfc/guimodel/JFCGUIElementSpec.java

    r589 r600  
    6060        boolean hashEqual = CollectionUtils.containsAny(elementHash, otherSpec.elementHash); 
    6161         
    62         if( type.equals("Class") ) { 
     62        if (type.equals("Class") ) { 
    6363            retVal = type.equals(otherSpec.type) && (titleEqual || hashEqual); 
    64         } else { 
    65             retVal = type.equals(otherSpec.type) && index==otherSpec.index && (titleEqual || hashEqual); 
     64        } 
     65        else { 
     66            retVal = type.equals(otherSpec.type) && index==otherSpec.index && 
     67                (titleEqual || hashEqual); 
    6668        } 
    6769         
     
    9193            ((icon == otherSpec.icon) || ((icon != null) && (icon.equals(otherSpec.icon)))) && 
    9294            (index == otherSpec.index) && (elementHash == otherSpec.elementHash); 
     95    } 
     96 
     97    /* (non-Javadoc) 
     98     * @see java.lang.Object#hashCode() 
     99     */ 
     100    @Override 
     101    public int hashCode() { 
     102        return (name + type + icon + index + elementHash).hashCode(); 
    93103    } 
    94104 
Note: See TracChangeset for help on using the changeset viewer.