diff --git a/src/uikit.cs b/src/uikit.cs index f51e9a56d083..6735d353b800 100644 --- a/src/uikit.cs +++ b/src/uikit.cs @@ -445,7 +445,7 @@ public enum UISearchControllerScopeBarActivation : long { /// Completion handler used with . delegate void UIPrinterContactPrinterHandler (bool available); /// Completion handler used with various presentation methods. - delegate void UIPrinterPickerCompletionHandler (UIPrinterPickerController printerPickerController, bool userDidSelect, NSError error); + delegate void UIPrinterPickerCompletionHandler ([NullAllowed] UIPrinterPickerController printerPickerController, bool userDidSelect, [NullAllowed] NSError error); delegate UISplitViewControllerDisplayMode UISplitViewControllerFetchTargetForActionHandler (UISplitViewController svc); delegate bool UISplitViewControllerDisplayEvent (UISplitViewController splitViewController, UIViewController vc, NSObject sender); @@ -453,7 +453,7 @@ public enum UISearchControllerScopeBarActivation : long { delegate bool UISplitViewControllerCanCollapsePredicate (UISplitViewController splitViewController, UIViewController secondaryViewController, UIViewController primaryViewController); delegate UIViewController UISplitViewControllerGetSecondaryViewController (UISplitViewController splitViewController, UIViewController primaryViewController); /// The callback executed after a is dismissed. - delegate void UIActivityViewControllerCompletion (NSString activityType, bool completed, NSExtensionItem [] returnedItems, NSError error); + delegate void UIActivityViewControllerCompletion ([NullAllowed] NSString activityType, bool completed, [NullAllowed] NSExtensionItem [] returnedItems, [NullAllowed] NSError error); // In the hopes that the parameter is self document: this array can contain either UIDocuments or UIResponders /// To be added. @@ -1703,6 +1703,7 @@ partial interface UIAccessibilityCustomAction { NSString CategoryEdit { get; } } + [return: NullAllowed] delegate UIAccessibilityCustomRotorItemResult UIAccessibilityCustomRotorSearch (UIAccessibilityCustomRotorSearchPredicate predicate); [MacCatalyst (13, 1)] @@ -4494,7 +4495,9 @@ public enum UITextSearchMatchMethod : long { FullWord, } + [return: NullAllowed] delegate UIViewController UIContextMenuContentPreviewProvider (); + [return: NullAllowed] delegate UIMenu UIContextMenuActionProvider (UIMenuElement [] suggestedActions); [TV (17, 0), iOS (13, 0)] @@ -12193,6 +12196,7 @@ interface UIBezierPath : NSSecureCoding, NSCopying { [NoTV, iOS (13, 4)] [MacCatalyst (13, 1)] + [return: NullAllowed] delegate UIPointerStyle UIButtonPointerStyleProvider (UIButton button, UIPointerEffect proposedEffect, UIPointerShape proposedShape); [NoTV, iOS (15, 0), MacCatalyst (15, 0)] @@ -25336,6 +25340,7 @@ interface UIStepper { [iOS (13, 0), TV (13, 0)] [MacCatalyst (13, 1)] + [return: NullAllowed] delegate UIViewController UIStoryboardViewControllerCreator (NSCoder coder); [MacCatalyst (13, 1)] @@ -26270,7 +26275,7 @@ interface UIPrintInteractionControllerDelegate { } /// A delegate executed after printing completes or after a printing error occurs. - delegate void UIPrintInteractionCompletionHandler (UIPrintInteractionController printInteractionController, bool completed, NSError error); + delegate void UIPrintInteractionCompletionHandler ([NullAllowed] UIPrintInteractionController printInteractionController, bool completed, [NullAllowed] NSError error); /// [NoTV] @@ -31250,6 +31255,7 @@ interface UICollectionViewCompositionalLayoutConfiguration : NSCopying { [TV (13, 0), iOS (13, 0)] [MacCatalyst (13, 1)] + [return: NullAllowed] delegate NSCollectionLayoutSection UICollectionViewCompositionalLayoutSectionProvider (nint section, INSCollectionLayoutEnvironment layoutEnvironment); [TV (13, 0), iOS (13, 0)] @@ -31665,7 +31671,7 @@ interface UIScreenshotService { [iOS (13, 0), TV (13, 0)] [MacCatalyst (13, 1)] - delegate NSDictionary UIScreenshotServiceDelegatePdfHandler (NSData pdfData, nint indexOfCurrentPage, CGRect rectInCurrentPage); + delegate NSDictionary UIScreenshotServiceDelegatePdfHandler ([NullAllowed] NSData pdfData, nint indexOfCurrentPage, CGRect rectInCurrentPage); interface IUIScreenshotServiceDelegate { } @@ -32120,10 +32126,12 @@ interface UITabBarItemAppearance : NSCopying, NSSecureCoding { [TV (13, 0), iOS (13, 0)] [MacCatalyst (13, 1)] + [return: NullAllowed] delegate UICollectionViewCell UICollectionViewDiffableDataSourceCellProvider (UICollectionView collectionView, NSIndexPath indexPath, NSObject itemIdentifier); [TV (13, 0), iOS (13, 0)] [MacCatalyst (13, 1)] + [return: NullAllowed] delegate UICollectionReusableView UICollectionViewDiffableDataSourceSupplementaryViewProvider (UICollectionView collectionView, string elementKind, NSIndexPath indexPath); [TV (13, 0), iOS (13, 0)] @@ -32204,6 +32212,7 @@ interface UICollectionViewDiffableDataSource attributes, NSTextRange textRange); [TV (15, 0), iOS (15, 0), MacCatalyst (15, 0)] - delegate bool NSTextLayoutManagerEnumerateTextSegmentsDelegate (NSTextRange textSegmentRange, CGRect textSegmentFrame, nfloat baselinePosition, NSTextContainer textContainer); + delegate bool NSTextLayoutManagerEnumerateTextSegmentsDelegate ([NullAllowed] NSTextRange textSegmentRange, CGRect textSegmentFrame, nfloat baselinePosition, NSTextContainer textContainer); [TV (15, 0), iOS (15, 0), MacCatalyst (15, 0)] [DesignatedDefaultCtor] @@ -4409,7 +4409,7 @@ interface NSTextSelection : NSSecureCoding { } [TV (15, 0), iOS (15, 0), MacCatalyst (15, 0)] - delegate void NSTextSelectionDataSourceEnumerateSubstringsDelegate (NSString substring, NSTextRange substringRange, NSTextRange enclodingRange, out bool stop); + delegate void NSTextSelectionDataSourceEnumerateSubstringsDelegate ([NullAllowed] NSString substring, NSTextRange substringRange, [NullAllowed] NSTextRange enclodingRange, out bool stop); [TV (15, 0), iOS (15, 0), MacCatalyst (15, 0)] delegate void NSTextSelectionDataSourceEnumerateCaretOffsetsDelegate (nfloat caretOffset, INSTextLocation location, bool leadingEdge, out bool stop);