mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Implementation of ALF-5066. Support for thumbnailing of .eps files.
Had to relax AbstractImageMagickContentTransformerWorker's restriction to 'image/*' mimetypes to allow 'application/eps'. Added application/eps to the MimetypeMap. Added application/eps to the view and edit modes of the mimetype.ftl forms control. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@22838 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -137,7 +137,13 @@ public abstract class AbstractImageMagickContentTransformerWorker extends Conten
|
||||
*/
|
||||
public static boolean isSupported(String mimetype)
|
||||
{
|
||||
if (!mimetype.startsWith(MIMETYPE_IMAGE_PREFIX))
|
||||
// ImageMagick supports the transformation of Encapsulated PostScript images,
|
||||
// whose MIME type is defined in mimetype-map.xml as "application/eps".
|
||||
if (mimetype.equals(MimetypeMap.MIMETYPE_APPLICATION_EPS))
|
||||
{
|
||||
return true; // This is an image although it doesn't start with "image/"
|
||||
}
|
||||
else if (!mimetype.startsWith(MIMETYPE_IMAGE_PREFIX))
|
||||
{
|
||||
return false; // not an image
|
||||
}
|
||||
|
@@ -60,6 +60,7 @@ public class ImageMagickContentTransformerWorker extends AbstractImageMagickCont
|
||||
*/
|
||||
public ImageMagickContentTransformerWorker()
|
||||
{
|
||||
// Intentionally empty
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -142,6 +143,7 @@ public class ImageMagickContentTransformerWorker extends AbstractImageMagickCont
|
||||
/**
|
||||
* Transform the image content from the source file to the target file
|
||||
*/
|
||||
@Override
|
||||
protected void transformInternal(File sourceFile, File targetFile, TransformationOptions options) throws Exception
|
||||
{
|
||||
Map<String, String> properties = new HashMap<String, String>(5);
|
||||
|
Reference in New Issue
Block a user