public ImageProviderResponse getColorizedIcon(
UIXRenderingContext context,
IconKey iconKey
)
{
ImageProvider provider = (ImageProvider)
context.getProperty(ImageConstants.TECATE_NAMESPACE,
ImageConstants.IMAGE_PROVIDER_PROPERTY);
Icon icon = getIcon(iconKey);
String iconName = null;
if ( icon != null )
iconName = icon.getName();
if (provider == null)
{
if (_LOG.isWarning())
_LOG.warning("CANNOT_GET_IMAGE_PROVIDER_FOR_ICON", iconName);
return null;
}
// Get the context and request objects
ImageContext imageContext = context.getImageContext();
ImageProviderRequest request = _getIconRequest(context, iconKey);
// Make the request
ImageProviderResponse response = provider.getImage(imageContext, request);
// Log any problems
if (response == null)
{
if (_LOG.isWarning())