Bug 328 - Crash on CATransaction.CompletionBlock set
Summary: Crash on CATransaction.CompletionBlock set
Alias: None
Product: iOS
Classification: Xamarin
Component: Xamarin.iOS.dll ()
Version: 4.x
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: Untriaged
Assignee: Sebastien Pouliot
Depends on:
Reported: 2011-08-18 23:05 UTC by rumination.xamarin
Modified: 2011-08-19 14:11 UTC (History)
3 users (show)

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:

Description rumination.xamarin 2011-08-18 23:05:48 UTC
I'm trying to do something like this:

CATransaction.CompletionBlock = delegate {
  Console.WriteLine("CATransaction completed");

But I get a crash when attempting to set the CompletionBlock property:

+[CATransaction setSetCompletionBlock::]: unrecognized selector sent to class 0x3202104

Unhandled Exception: MonoTouch.Foundation.MonoTouchException: Objective-C exception thrown.  Name: NSInvalidArgumentException Reason: +[CATransaction setSetCompletionBlock::]: unrecognized selector sent to class 0x3202104
  at (wrapper managed-to-native) MonoTouch.ObjCRuntime.Messaging:void_objc_msgSend_IntPtr (intptr,intptr,intptr)
  at MonoTouch.CoreAnimation.CATransaction.set_CompletionBlock (MonoTouch.Foundation.NSAction value) [0x00029] in /Developer/MonoTouch/Source/monotouch/monotouch/CoreAnimation/CATransaction.g.cs:183 

This is in MT
Comment 1 Sebastien Pouliot 2011-08-19 08:56:38 UTC
I can duplicate the issue using the lastest MonoTouch code.
Comment 2 Sebastien Pouliot 2011-08-19 09:45:08 UTC
It's a typo and/or generator errors (prefix and suffix).

	[Export ("setSetCompletionBlock::")]

should be

	[Export ("setCompletionBlock:")]