Changeset 6182 in josm


Ignore:
Timestamp:
2013-08-24T02:45:16+02:00 (11 years ago)
Author:
Don-vip
Message:

fix #8849 - allow map icons up to 24x24 pixels without rescaling

File:
1 edited

Legend:

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

    r6174 r6182  
    154154     * Returns the really displayed node icon for this {@code MapImage}.
    155155     * @param disabled {@code} true to request disabled version, {@code false} for the standard version
    156      * @return The scaled down version to 16x16 pixels if the image size exceeds it and no size has been explicitely specified
     156     * @return The scaled down version to 16x16 pixels if the image size exceeds 24x24 pixels and no size has been explicitely specified
    157157     * @since 6174
    158158     */
    159159    public Image getDisplayedNodeIcon(boolean disabled) {
    160         final int maxSize = 16;
     160        final int maxSize = 24;
    161161        final Image image = disabled ? getDisabled() : getImage();
    162162        // Scale down large (.svg) images to 16x16 pixels if no size is explicitely specified
    163163        if ((width  == -1 && image.getWidth(null) > maxSize)
    164164         || (height == -1 && image.getHeight(null) > maxSize)) {
    165             return ImageProvider.createBoundedImage(image, maxSize);
     165            return ImageProvider.createBoundedImage(image, 16);
    166166        } else {
    167167            return image;
Note: See TracChangeset for help on using the changeset viewer.