Is there a way to open a file with QLPreviewController or UIDocumentInteractionController, knowing its UTI, but without a file extension in the NSURL? Thanks for your help!
I've just found another way to deal with it. Implement an item with the following properties:
@interface QuickLookPreviewItem : NSObject <QLPreviewItem>
@property (nonatomic, strong) NSURL *url;
@property (nonatomic, strong) NSString *title;
@property (nonatomic, strong) NSString *uti;
@end
@implementation QuickLookPreviewItem
- (NSString *)previewItemTitle { return self.title; }
- (NSURL *)previewItemURL { return self.url; }
- (NSString *)previewItemContentType { return self.uti; }
@end
Though it's not clear that it works that way in the documentation.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With