today-extension

Maximum height of iOS 8 Today Extension?

青春壹個敷衍的年華 提交于 2019-11-28 16:18:14
问题 I am working on a Today Extension with a dynamically sized table. I have been able to get the table to resize for the content using: self.preferredContentSize = accountsTable.contentSize However, I have found that it will not get taller than a certain size (568 px) even though I can tell the table contentSize is larger. I'm not clear if this is a built-in limit or if there is a way around this to make a larger view. It appears that some previous extensions (Stocks widget) is able to become

How to add Firebase to Today Extension iOS

雨燕双飞 提交于 2019-11-28 11:15:50
I need to be able to use Firebase in my Today View Extension, however I cannot seem to import the Firebase module. I think it's because I need a new target in my cocoa pods file, but I'm not sure on how to do this. Thanks. You have to treat the today extension as its own separate app(somewhat) in your firebase project dashboard, you need to hit the "Add another app" button. select iOS and then enter the BUNDLE ID of your TODAY EXTENSION Complete the wizard and download the generated GoogleService-Info.plist file Add the plist file to your Today Extension's root folder go to your xcode project,

NSUserDefaultsDidChangeNotification and Today Extensions

喜你入骨 提交于 2019-11-28 07:36:40
I am developing an iPhone app with a Today Extension . The app has a Model module that loads from/saves to NSUserDefaults . Since I want this information to be available to both the main app and the extension, I use an app group: let storage = NSUserDefaults(suiteName: "group.etc.etc.etc...") Both the app and the extension can access the information without any problem. The main app occasionally might create a local notification to present to the user. That notification has two actions associated with it ( UIUserNotificationAction ). One of those actions triggers some code run on the

How to use Crashlytics with iOS / OS X today view extensions?

房东的猫 提交于 2019-11-28 05:50:32
Since today extensions run as separated a process I am sure they will not log any crashes out of the box. I assume we need to initialize Crashlytics on the widget separately. E.g. in the viewDidLoad method of the TodayViewController . Is anybody already using Crashlytics inside any iOS / OS X extensions? If so, how did you implemented it? I am also wondering if it would make sense to create a separate app in Crashlytics just for the extension. martn_st Crashlytics support got in touch with me and provided these steps. I tested them and it now works for me iOS 8 app. Add the Crashlytics Run

Finding out if the device is locked, from a Notification Widget

本秂侑毒 提交于 2019-11-28 04:15:22
问题 I'd like to know if the device is locked when I'm loading my Notification/Today widget, so I can show the widget appropriately. (it's financial, and we don't want to show balances on a locked phone) On devices with TouchID, I can just try to access the Keychain, and if I get errSecInteractionNotAllowed back, it's locked. All good. This doesn't work on devices without touchID (but with a PIN). I've found a few things, which recommend using [[UIApplication sharedApplication]

Flutter: Is it somehow possible to create App Widgets (Android) and Today Extensions (iOS)?

耗尽温柔 提交于 2019-11-27 12:20:28
问题 I took a look at flutter for building a mobile app. Is it possible to create Widgets (not flutter-widgets, but App Widgets (Android) and Today Extensions (iOS)) in a flutter app? I guess it can't be done with dart, but is there a way of implementing them native in Java/Swift and include them in the flutter-app? Thanks! 回答1: There is no guide or docs showing how to implement a App Widget for a flutter app. It is definitely possible to implement a app widget with native code. Just create a

How to add Firebase to Today Extension iOS

放肆的年华 提交于 2019-11-27 06:01:09
问题 I need to be able to use Firebase in my Today View Extension, however I cannot seem to import the Firebase module. I think it's because I need a new target in my cocoa pods file, but I'm not sure on how to do this. Thanks. 回答1: You have to treat the today extension as its own separate app(somewhat) in your firebase project dashboard, you need to hit the "Add another app" button. select iOS and then enter the BUNDLE ID of your TODAY EXTENSION Complete the wizard and download the generated

Today App Extension Widget Tap To Open Containing App

大城市里の小女人 提交于 2019-11-27 03:31:35
I've implemented a Today widget for my application +Quotes which displays the day's quote within the notification center with the help of these Apple Docs . What I'd like to accomplish is opening the Containing App, in this case +Quotes, when the user taps the +Quotes widget within their Today notification view, not entirely sure what to call this, as Calendar would if you tapped it in the Today view. I've tried overlaying a button over the label which would call -(void)openURL:(NSURL *)URL completionHandler:(void (^)(BOOL success))completionHandler upon it being tapped, then open the Custom

How to use Crashlytics with iOS / OS X today view extensions?

岁酱吖の 提交于 2019-11-27 01:04:59
问题 Since today extensions run as separated a process I am sure they will not log any crashes out of the box. I assume we need to initialize Crashlytics on the widget separately. E.g. in the viewDidLoad method of the TodayViewController . Is anybody already using Crashlytics inside any iOS / OS X extensions? If so, how did you implemented it? I am also wondering if it would make sense to create a separate app in Crashlytics just for the extension. 回答1: Crashlytics support got in touch with me and

How to access CoreData model in today extension (iOS)

痴心易碎 提交于 2019-11-27 00:05:54
Is it possible to work with my CoreData model in the today extension in swift like in the original app? If yes, how can I create the NSManagedObjectContext? I really have no clue, beside the group-identifier, but unfortunatly I don't know how to get the context.. In the past I created apps with the check at the beginning that I want to use CoreData and then I got the managedObjectContext via my AppDelegate.. But how can I do somethink like that in an extension? Apple doesn't offer information about that.. I edited this line in AppDelegate: NSURL *storeURL = [[self applicationDocumentsDirectory