0

QLPreviewControllerDelegateの次のメソッドを実装しようとしていますが、このメソッドでは、プレビューコントローラーの前にプレビューアイテムを表示するビューを返す必要があります。これはself.viewである必要がありますが、次のコンパイルエラーが発生します。

Automatic Reference Counting Issue: Implicit conversion of an Objective-C pointer to 'UIView *__autoreleasing *' is disallowed with ARC

これを修正するにはどうすればよいですか?

//Called when a Quick Look preview is about to be presented full screen or dismissed, to     provide a zoom effect.

- (CGRect)previewController:(QLPreviewController *)controller frameForPreviewItem:(id <QLPreviewItem>)item inSourceView:(UIView **)view
{

    // Set the source view  
    view = self.view;

    // Set the Rectangle of the Icon
    return self.view.bounds; 
}
4

1 に答える 1

1

ビューパラメータは、ビューへのポインタへのポインタです。これを設定するには、次の構文を使用します。

*view = self.view;
于 2011-12-13T20:51:29.277 に答える