How to use Flutter Method Channel in background (app minimised/closed)

后端 未结 2 1291
滥情空心
滥情空心 2021-01-05 20:57

I am working on a native Android widget in a Flutter App. In which there is refresh button, on click of that I have to call a method in the Flutter code. I am using Flutter

2条回答
  •  陌清茗
    陌清茗 (楼主)
    2021-01-05 21:17

    You may start the Flutter Engine in the background by register a Dart callback function which will only be invoked whenever a background job is started in Flutter.

    Try this. https://medium.com/vrt-digital-studio/flutter-workmanager-81e0cfbd6f6e

提交回复
热议问题