Bug 8716 - UICollectionViewContoller missing sizeForItemAtIndexPath method
Summary: UICollectionViewContoller missing sizeForItemAtIndexPath method
Status: RESOLVED FIXED
Alias: None
Product: iOS
Classification: Xamarin
Component: XI runtime ()
Version: 6.0.x
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: Untriaged
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2012-12-02 11:23 UTC by Nic Wise
Modified: 2013-02-12 11:10 UTC (History)
4 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Nic Wise 2012-12-02 11:23:29 UTC
UICollectionViewController binds to


[Export("collectionView:cellForItemAtIndexPath:")]
public override UICollectionViewCell GetCell(UICollectionView collectionView, NSIndexPath indexPath)

But not the SizeForItemAtIndexPath

[Export("collectionView:layout:sizeForItemAtIndexPath:")]
public virtual SizeF SizeForItemAtIndexPath(UICollectionView collectionView, UICollectionViewLayout layout, NSIndexPath indexPath)

Please add?
Comment 1 Rolf Bjarne Kvinge [MSFT] 2012-12-10 08:54:13 UTC
As far as I can see collectionView:layout:sizeForItemAtIndexPath: is defined on UICollectionViewDelegateFlowLayout, not UICollectionViewController.
Comment 2 Nic Wise 2012-12-10 09:21:31 UTC
I wonder why my UICollectionViewController gets called then. Is MT doing some magic in the background to set the delegate to this?
Comment 3 Rolf Bjarne Kvinge [MSFT] 2012-12-11 08:34:03 UTC
Do you have a sample?
Comment 4 Nic Wise 2012-12-11 09:41:58 UTC
I'll see if I can extract one out of the project I'm working on
Comment 5 Miguel de Icaza [MSFT] 2013-02-11 23:31:02 UTC
Hello Nic, were you able to extract that test case?
Comment 6 Nic Wise 2013-02-12 02:24:11 UTC
Hi Miguel

No, I've not been able to isolate it, or been back into that bit of code for a while (will be in the next week or 2)

Close it, and I'll reopen if it proves to be a problem. I'm using UICollectionView in a few places without issue, so I suspect it might be PEBKAC

Thanks

Nic
Comment 7 Nic Wise 2013-02-12 02:24:32 UTC
"reopen" => Make a new one. oops.
Comment 8 Miguel de Icaza [MSFT] 2013-02-12 11:10:23 UTC
ok, closing.