Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
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
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.
I created a NSDatePicker and added two delegates as handlers.
The first delegate was overridden by the second.
Normally (using a Multicast-Delegate), the first handler is set to the Target/Method properties which are derived from Delegate. Adding another handler, the Target/Method properties are cleared and the delegates collection (member of Multicast-Delegate) is used to hold the references to the handlers.
But this is not happening in this case. Target/Method are just overridden.
Unfortunately, this is unfixable by design (by Apple). We're just exposing the underlying platform here.
The underlying delegate selector only accepts one instance. You can confirm this in objective-c with Xcode.
This also means that if you have to choose between using our C# wrapper events and the actual delegate (since the events are implemented by assigning our own delegate).
Ah okay, thanks for making this point clear!
A wrapper class, deriving from NSDatePicker, and exposing a new Multicast-Delegate seems to be a good workaround (connecting the ValidateProposedDateValue event).
Yep. Things like that are often needed to work around limitations in Cocoa.