case 0:
return ImageLoader.getImage(Activator.class, IApplicationConstants.CAMPAIGN_ICON_PATH);
case 1:
// TODO: aggregate some icons to reflect the campaign's status
Campaign c = (Campaign)element;
Image img = null;
if(c.isExternal())
{
img = ImageLoader.getImage(Activator.class, IApplicationConstants.CAMPAIGN_EXTERNAL_ICON_PATH);
if(!c.isConnected())
{
img = new Image(Display.getCurrent(), img, SWT.IMAGE_DISABLE);
}
}
else
{
if(c.isHostable())
{
img = ImageLoader.getImage(Activator.class, IApplicationConstants.CAMPAIGN_LOCAL_ICON_PATH);
if(!c.isHosting())
{
img = new Image(Display.getCurrent(), img, SWT.IMAGE_DISABLE);
}
}
else