QLPreviewControllerDelegate method not called on iOS 11.2

Originator:mattio.valentino
Number:rdar://38038610 Date Originated:3/1/2018
Status:Duplicate Open Resolved:
Product:iOS SDK QuickLook Framework Product Version:iOS 11.2
Classification: Reproducible:Always
 
Summary:
When using QLPreviewController to open a .doc or .docx file, previewController:shouldOpenURL:forPreviewItem: is called as expected when the user taps text with an embedded URL using iOS 9.3 and iOS 10.3.1, but it is not called on iOS 11.2 (emulator) or iOS 11.2.6 (device).

Steps to Reproduce:
Use iOS 9.3 or iOS 10.3.1 to see the success case. Use the iOS 11.2 emulator or an iOS 11.2.6 device to see the failure.

1: Create a QLPreviewController and assign the dataSource and delegate. Be sure to implement previewController:shouldOpenURL:forPreviewItem: perhaps with just a breakpoint or an NSLog statement.

2: Load a .doc or .docx file that has text with an embedded URL in the QLPreviewController. 

3: Tap on the link.

4: The link loads correctly, but previewController:shouldOpenURL:forPreviewItem: is never called.

Expected Results:
The delegate method previewController:shouldOpenURL:forPreviewItem: should be called.

Actual Results:
The delegate method previewController:shouldOpenURL:forPreviewItem: is not called.

Version/Build:
iOS 11.2 emulator or an iOS 11.2.6 device. I'm running Xcode 9.2 (9C40b) if that helps, too.

Configuration:
I attached a test Word document if that helps.

Note that this is not a problem with a PDF of the same document -- the PDF version works correctly on all iOS version I tested.

Comments

Apple marked this as a duplicate of 33361502.

By mattio.valentino at March 2, 2018, 2:08 p.m. (reply...)

Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!