DefaultPlatformMenuDelegate constructor Null safety
- {MethodChannel? channel}
Creates a const DefaultPlatformMenuDelegate.
The optional channel
argument defines the channel used to communicate
with the platform. It defaults to SystemChannels.menu if not supplied.
Implementation
DefaultPlatformMenuDelegate({MethodChannel? channel})
: channel = channel ?? SystemChannels.menu,
_idMap = <int, MenuItem>{} {
this.channel.setMethodCallHandler(_methodCallHandler);
}