implementAsBlocking static method
NSPathCellDelegate
implementAsBlocking({
- void pathCell_willDisplayOpenPanel_()?,
- void pathCell_willPopUpMenu_()?,
- bool $keepIsolateAlive = true,
Builds an object that implements the NSPathCellDelegate protocol. To implement
multiple protocols, use addToBuilder or objc.ObjCProtocolBuilder directly. All
methods that can be implemented as blocking listeners will be.
If $keepIsolateAlive is true, this protocol will keep this isolate
alive until it is garbage collected by both Dart and ObjC.
Implementation
static NSPathCellDelegate implementAsBlocking({
void Function(NSPathCell, NSOpenPanel)? pathCell_willDisplayOpenPanel_,
void Function(NSPathCell, NSMenu)? pathCell_willPopUpMenu_,
bool $keepIsolateAlive = true,
}) {
final builder = objc.ObjCProtocolBuilder(debugName: 'NSPathCellDelegate');
NSPathCellDelegate.pathCell_willDisplayOpenPanel_.implementAsBlocking(
builder,
pathCell_willDisplayOpenPanel_,
);
NSPathCellDelegate.pathCell_willPopUpMenu_.implementAsBlocking(
builder,
pathCell_willPopUpMenu_,
);
builder.addProtocol($protocol);
return NSPathCellDelegate.castFrom(
builder.build(keepIsolateAlive: $keepIsolateAlive),
);
}