addToBuilder static method
void
addToBuilder(
- ObjCProtocolBuilder builder, {
- bool popoverShouldClose_()?,
- bool popoverShouldDetach_()?,
- void popoverDidDetach_()?,
- NSWindow? detachableWindowForPopover_()?,
- void popoverWillShow_(
- NSNotification
- void popoverDidShow_(
- NSNotification
- void popoverWillClose_(
- NSNotification
- void popoverDidClose_(
- NSNotification
- bool $keepIsolateAlive = true,
Adds the implementation of the NSPopoverDelegate protocol to an existing
objc.ObjCProtocolBuilder.
Note: You cannot call this method after you have called builder.build.
Implementation
static void addToBuilder(
objc.ObjCProtocolBuilder builder, {
bool Function(NSPopover)? popoverShouldClose_,
bool Function(NSPopover)? popoverShouldDetach_,
void Function(NSPopover)? popoverDidDetach_,
NSWindow? Function(NSPopover)? detachableWindowForPopover_,
void Function(objc.NSNotification)? popoverWillShow_,
void Function(objc.NSNotification)? popoverDidShow_,
void Function(objc.NSNotification)? popoverWillClose_,
void Function(objc.NSNotification)? popoverDidClose_,
bool $keepIsolateAlive = true,
}) {
NSPopoverDelegate.popoverShouldClose_.implement(
builder,
popoverShouldClose_,
);
NSPopoverDelegate.popoverShouldDetach_.implement(
builder,
popoverShouldDetach_,
);
NSPopoverDelegate.popoverDidDetach_.implement(builder, popoverDidDetach_);
NSPopoverDelegate.detachableWindowForPopover_.implement(
builder,
detachableWindowForPopover_,
);
NSPopoverDelegate.popoverWillShow_.implement(builder, popoverWillShow_);
NSPopoverDelegate.popoverDidShow_.implement(builder, popoverDidShow_);
NSPopoverDelegate.popoverWillClose_.implement(builder, popoverWillClose_);
NSPopoverDelegate.popoverDidClose_.implement(builder, popoverDidClose_);
builder.addProtocol($protocol);
}