Changeset 7695 in josm for trunk/src


Ignore:
Timestamp:
2014-11-02T18:43:27+01:00 (5 years ago)
Author:
Don-vip
Message:

fix #10695 - NPE

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/tools/ImageProvider.java

    r7694 r7695  
    256256        case MAP: sizeval = Main.pref.getInteger("iconsize.mapmax", 16); break;
    257257        case LARGEICON: sizeval = Main.pref.getInteger("iconsize.largeicon", 24); break;
    258         case MENU: /* MENU is SMALLICON - only provided in case of future changes */ 
     258        case MENU: /* MENU is SMALLICON - only provided in case of future changes */
    259259        case SMALLICON: sizeval = Main.pref.getInteger("iconsize.smallicon", 16); break;
    260260        default: sizeval = Main.pref.getInteger("iconsize.default", 24); break;
     
    262262        return new Dimension(sizeval, sizeval);
    263263    }
    264    
     264
    265265    /**
    266266     * Set the dimensions of the image.
     
    401401    public ImageIcon get() {
    402402        ImageResource ir = getResource();
     403        if (ir == null)
     404            return null;
    403405        if (maxWidth != -1 || maxHeight != -1)
    404406            return ir.getImageIconBounded(new Dimension(maxWidth, maxHeight));
Note: See TracChangeset for help on using the changeset viewer.