如何在Flutter中轻松开发与iOS和Android兼容的桌面小部件?

huangapple go评论96阅读模式
英文:

How to easily develop desktop widgets compatible with iOS and Android in Flutter?

问题

我正在使用Flutter开发一个应用程序,需要实现一些桌面小部件功能,比如音乐播放器的控制按钮。我希望这些小部件能够显示在设备的主屏幕上,并且即使在应用程序处于后台时也能够访问。我听说Flutter本身不支持这种类型的小部件开发,需要使用本机平台代码来实现。我想知道是否有可用的插件可以提高在这种情况下的开发效率。

英文:

I'm developing an application using Flutter, and I need to implement some desktop widget functionality, such as control buttons for a music player. I want these widgets to be displayed on the device's home screen and accessible even when the app is in the background. I heard that Flutter itself doesn't support this type of widget development, and it needs to be implemented using native platform code. I'm wondering if there are any plugins available to improve the development efficiency in this case.

答案1

得分: 1

如果是的,这个包应该是一个很好的起点

https://pub.dev/packages/home_widget

英文:

Are you looking for Home Screen widgets? If yes, this package should be a good starting point

https://pub.dev/packages/home_widget

huangapple
  • 本文由 发表于 2023年7月17日 16:47:50
  • 转载请务必保留本文链接:https://go.coder-hub.com/76702797.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定