iOS 8 Today Extension not working on device

后端 未结 8 1984
我在风中等你
我在风中等你 2021-02-20 10:10

When I run my Today Extension on the simulator everything works fine and it displays the following as expected:

\"en

相关标签:
8条回答
  • 2021-02-20 10:47

    I had an issue using custom ViewController in my Share Extension. It turns out that the resources are limited in Extension mini-apps, so when my Extension was generating thumbnails, it crashed the extension because too many background threads were being used. Reducing thumbnail generation to a single one at a time fixed the issue.

    The confusing part was that this limitation was not seen in Simulator, only on a real device.

    0 讨论(0)
  • 2021-02-20 10:54

    The sources of my problems:

    • on simulator viewDidLoad was called each time, on the device the view is loaded once and only viewWillAppear is called.
    • the widget does not receive core data changes notifications
    • do not call NCWidgetController.widgetController().setHasContent from widgetPerformUpdateWithCompletionHandler. The best place to use it (mostly) is your containing app, not the widget itself.

    hope this helps someone

    0 讨论(0)
提交回复
热议问题