如何在iOS应用程序上清除安装的小部件
在iOS应用的最后版本中,我们实现了窗口小部件功能,但是在即将发布的版本中,我们决定删除窗口小部件扩展程序。
如果用户已经在他的主屏幕上添加了小部件,并且当用户使用不包含窗口小部件扩展名的最新代码更新他/她的应用程序时,用户仍然可以查看空白小部件。
是否有任何方法可以从主应用程序中编程清除/删除小部件。
In last version of iOS app we have implemented widget feature, but in the coming release we have decided to remove the widget extension.
If the user has already added widget to his Home Screen and when ever user updates his/her application with latest code that does not contain widget extension, still user is able to view blank widget.
Is there any way to clear/remove widgets programatically from main app.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果将WidgetConfiguration上的支持的Families修饰符设置为[],则窗口小部件将不再在窗口小部件库中显示。这可能是一种选择。
If you set the supportedFamilies modifier on the WidgetConfiguration to [] then the widget no longer shows in the widget gallery. That might be an option.