Ignore:
Timestamp:
2014-05-09T06:03:50+02:00 (12 years ago)
Author:
Don-vip
Message:

see #8465 - replace Utils.equal by Objects.equals, new in Java 7

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/mappaint/TextElement.java

    r6889 r7083  
    22package org.openstreetmap.josm.gui.mappaint;
    33
    4 import static org.openstreetmap.josm.tools.Utils.equal;
    5 
    64import java.awt.Color;
    75import java.awt.Font;
     6import java.util.Objects;
    87
    98import org.openstreetmap.josm.data.osm.OsmPrimitive;
     
    9089
    9190        /*
    92          * Check whether the label composition strategy is given by
    93          * a keyword
     91         * Check whether the label composition strategy is given by a keyword
    9492         */
    9593        Keyword keyword = c.get(TEXT, null, Keyword.class, true);
    96         if (equal(keyword, Keyword.AUTO))
     94        if (Keyword.AUTO.equals(keyword))
    9795            return AUTO_LABEL_COMPOSITION_STRATEGY;
    9896
     
    212210            return false;
    213211        final TextElement other = (TextElement) obj;
    214         return  equal(labelCompositionStrategy, other.labelCompositionStrategy) &&
    215         equal(font, other.font) &&
     212        return Objects.equals(labelCompositionStrategy, other.labelCompositionStrategy) &&
     213        Objects.equals(font, other.font) &&
    216214        xOffset == other.xOffset &&
    217215        yOffset == other.yOffset &&
    218         equal(color, other.color) &&
    219         equal(haloRadius, other.haloRadius) &&
    220         equal(haloColor, other.haloColor);
     216        Objects.equals(color, other.color) &&
     217        Objects.equals(haloRadius, other.haloRadius) &&
     218        Objects.equals(haloColor, other.haloColor);
    221219    }
    222220}
Note: See TracChangeset for help on using the changeset viewer.