@Override
public String renderThumbnailImageLink(WikiLink link) {
// TODO: This is not typesafe and clean, need different rendering strategy for WikiUpload subclasses
WikiUploadImage image = (WikiUploadImage)link.getFile();
if (image.getThumbnail() == WikiUploadImage.Thumbnail.FULL.getFlag()) {
// Full size display, no thumbnail
//TODO: Make sure we really don't need this - but it messes up the comment form conversation:
//String imageUrl = WikiUtil.renderURL(image) + "&cid=" + Conversation.instance().getId();
String imageUrl = wikiURLRenderer.renderURL(image);
return "<img src='"+ imageUrl + "'" +
" width='"+ image.getSizeX()+"'" +
" height='"+ image.getSizeY() +"'/>";
} else {
// Thumbnail with link display
//TODO: Make sure we really don't need this - but it messes up the comment form conversation:
// String thumbnailUrl = WikiUtil.renderURL(image) + "&thumbnail=true&cid=" + Conversation.instance().getId();