public ViewerIcon(int w, int h, URL url) { super(); _width = w; _height = h; if (url != null) { CacheImageLoader.getInstance().loadImage(url, this); } }
public ViewerIcon(int w, int h, String path) { super(); _width = w; _height = h; try { URL url = (new File(path)).toURL(); if (url != null) { CacheImageLoader.getInstance().loadImage(url, this); } } catch (Exception e) { Trace.ignoredException(e); } }