Set UICollectionView UIScrollViewDelegate delegate
Set UICollectionView UIScrollViewDelegate delegate
- Subject: Set UICollectionView UIScrollViewDelegate delegate
- From: "Mazzaroth M." <email@hidden>
- Date: Sat, 18 Oct 2014 17:22:59 -0400
Hi, I have a parent view controller that has two UICollectionViewController
subclasses as children in its view controller hierarchy. I'd like to set
the parentViewController as the Subclass1CollectionViewController and
Subclass2CollectionViewControllers' .colllectionView UIScrollView delegate.
However when I set the delegate, the compiler assumes I'm trying to assign
it as the UICollectionViewDelegate. UICollectionView is a subclass of
UIScrollView.. how do refer to its scrollview delegate pointer?
Xcode 6.0.1 iOS8.
self.bodyCollectionViewController.collectionView.backgroundColor =
UIColor.clearColor;
self.bodyCollectionViewController.collectionView.showsHorizontalScrollIndicator
= NO;
self.bodyCollectionViewController.collectionView.showsVerticalScrollIndicator
= NO;
self.bodyCollectionViewController.collectionView.delegate = self; //
warning -- Assigning to 'id<UICollectionViewDelegate>' from incompatible
type 'SCRPreviewViewController *const __strong'
@interface SCRPreviewViewController : UIViewController
<UIScrollViewDelegate>
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden