Ignore:
Timestamp:
2015-10-10T21:01:42+02:00 (9 years ago)
Author:
Don-vip
Message:

sonar - Unused private method should be removed
sonar - Unused protected methods should be removed
sonar - Sections of code should not be "commented out"
sonar - Empty statements should be removed
sonar - squid:S1172 - Unused method parameters should be removed
sonar - squid:S1481 - Unused local variables should be removed

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/actions/mapmode/MapMode.java

    r8510 r8855  
    2121 * is another.
    2222 *
    23  * MapModes should register/deregister all necessary listeners on the map's view
    24  * control.
     23 * MapModes should register/deregister all necessary listeners on the map's view control.
    2524 */
    2625public abstract class MapMode extends JosmAction implements MouseListener, MouseMotionListener {
     
    3231    /**
    3332     * Constructor for mapmodes without an menu
     33     * @param mapFrame unused but kept for plugin compatibility. Can be {@code null}
    3434     */
    3535    public MapMode(String name, String iconName, String tooltip, Shortcut shortcut, MapFrame mapFrame, Cursor cursor) {
     
    4141    /**
    4242     * Constructor for mapmodes with an menu (no shortcut will be registered)
     43     * @param mapFrame unused but kept for plugin compatibility. Can be {@code null}
    4344     */
    4445    public MapMode(String name, String iconName, String tooltip, MapFrame mapFrame, Cursor cursor) {
     
    8485    }
    8586
    86     // By default, all tools will work with all layers. Can be overwritten to require
    87     // a special type of layer
     87    /**
     88     * Determines if layer {@code l} is supported by this map mode.
     89     * By default, all tools will work with all layers.
     90     * Can be overwritten to require a special type of layer
     91     * @param l layer
     92     * @return {@code true} if the layer is supported by this map mode
     93     */
    8894    public boolean layerIsSupported(Layer l) {
    89         return true;
     95        return l != null;
    9096    }
    9197
Note: See TracChangeset for help on using the changeset viewer.