private ImageIcon createIcon(String resourcePath) {
		if (getView() == null) {
			return null;
		}
		return new ImageIcon(ExtensionScript.class.getResource(resourcePath));
	}
private ImageIcon createIcon ( String resourcePath ) { if ( getView ( ) == null ) { return null ; } return new ImageIcon ( ExtensionScript . class . getResource ( resourcePath ) ) ; }
Creates an {@code ImageIcon} with the given resource path, if in view mode.

@param resourcePath the resource path of the icon, must not be {@code null}.
@return the icon, or {@code null} if not in view mode.