setForeground static method
Set foreground notification for android Accepts bool and String Returns void
Implementation
static Future<void> setForeground(bool enabled,
String title,
String description,
String icon,
String activity) async {
final Map<String, dynamic> param = <String, dynamic>{
'enableForeground': enabled,
'foregroundTitle': title,
'foregroundDescription': description,
'foregroundImage': icon,
'foregroundActivity': activity
};
await _channel.invokeMethod(METHOD_FOREGROUND_SERVICE, param);
}