Rémi Rousselet, thank you very much. Your advice has helped. Below is the prototype of function that I need:
OverlayEntry
_modeless = null;
void _showModeless(BuildContext context)
{
_modeless = new OverlayEntry(
opaque: false,
builder: (context) {
return new Positioned(
top: 100.0,
left: 100.0,
child:
new Row(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
new Icon(Icons.content_paste, color: Colors.blueGrey),
new Padding(
padding: const EdgeInsets.only(left: 16.0),
child: new Text('Modeless', overflow: TextOverflow.ellipsis,
style: new TextStyle(fontSize: 14.0, fontWeight: FontWeight.bold, color: Colors.lightBlue, decoration: TextDecoration.none
),
),
),
],
),
);
});
Overlay.of(context).insert(_modeless);
_startWaiting();
}
static const TIMEOUT = const Duration(seconds: 8);
static Timer _timer = null;
void _startWaiting()
{
_timer = new Timer(TIMEOUT, _handleTimeout);
}
void _handleTimeout()
{
if (_modeless != null)
_modeless.remove();
}
PS. I added only another function that allows to remove the modeless after 8 sec. Once again many thanks.