build method
Implementation
@override
Widget build(AMapContext aMapContext, Widget child) {
return Stack(
key: ValueKey(this),
children: [
child,
StreamBuilder<InfoWindowExtension>(
initialData: this,
stream: _streamController.stream,
builder: (context, snapshot) {
final data = snapshot.data;
if (data == null ||
!(data.option?.show ?? false) ||
data._x == null) {
return Container();
}
return Positioned(
top: data._y,
left: data._x,
child: Container(
key: _infoWindowKey,
margin: data.option?.offset,
child: infoWindow,
),
);
}),
],
);
}