Fixed: <rdar://problem/3937663> repro assertion failure and crash dragging image...
[WebKit-https.git] / WebKit / WebView.subproj / WebImageView.m
index c75f2e080a991ea99af536d7f8edd8d24f3e4aa9..04416572753eb6a40aa730ee94654ab85b634af6 100644 (file)
 
 + (NSArray *)supportedImageMIMETypes
 {
-    return [[WebImageRendererFactory sharedFactory] supportedMIMETypes];
+    static NSMutableArray *imageMIMETypes = nil;
+    if (imageMIMETypes == nil) {
+        imageMIMETypes = [[[WebImageRendererFactory sharedFactory] supportedMIMETypes] mutableCopy];
+        [imageMIMETypes removeObject:@"application/pdf"];
+        [imageMIMETypes removeObject:@"application/postscript"];
+    }
+    return imageMIMETypes;
 }
 
 - (id)initWithFrame:(NSRect)frame