apple-watch

Max memory usage on watchOS 2?

女生的网名这么多〃 提交于 2019-12-02 09:32:06
I didn't find anything regarding the memory usage availavable for an app in watchOS 2. I'm currently developing an app for watchOS and I'm using Core Data in the watch side. When I load 166 of 189 objects to an array, the app crashes, the memory usage at that point is 34mb. As the watch has 512mb of memory I'm not entirely sure how much can you use with just one app. I'm gonna improve my code's performance and ram usage but eitherway I still don't know what amount of memory can I use as it's not availavable on Apple Developer portal as far as I know. Would appreciate information regarding this

Detecting Apple Watch in iOS 8

牧云@^-^@ 提交于 2019-12-02 08:14:00
I have some events that should only be fired off if a user has an Apple Watch. Is there a way to detect whether a watch is paired? I'm not sure if I can use the shared app group to detect the Apple Watch extension or maybe I can use bluetooth? The best you an do is set a BOOL to true in shared NSUserDefaults the first time the Watch app is run and then check for that value in your iOS app. All indications on the dev forums and publicly have been that there isn't a way to programatically know if a Watch has been paired. This is possible on watchOS2.0+ I tried to give an answer here https:/

WatchKit 2 Complication Text Only Shows Up in Preview

旧时模样 提交于 2019-12-02 07:18:56
问题 I'm trying to develop a very simple complication for watchkit2 that says "Hi" from a simple text provider. I've managed to achieve some strange behavior; I can see the text when the complication is clicked or when you are previewing it from the customize watchface screen, but not when the watchface is displayed. Have a look: Any ideas what might be causing this? My text provider looks like this var textProvider: CLKSimpleTextProvider override init() { textProvider = CLKSimpleTextProvider()

How to build an application with the watchOS 2 SDK

老子叫甜甜 提交于 2019-12-02 06:32:29
In the last submission of our application, we have received this warning : Invalid WatchKit Support - Starting April 1, 2018, all apps submitted to the App Store for Apple Watch must be built with the watchOS 2 SDK or later My question is to know how to to build the application with the watchOS 2 SDK? I was thinking that is enough to build with XCODE 9. Thank's. Check your Deployment Target. It's likely it wasn't updated just by using a newer version of Xcode. Also try checking Base SDK in Build Settings of your Watch Extension to make sure it is up to date. 来源: https://stackoverflow.com

WatchKit return reply() inside a block in handleWatchKitExtensionRequest:

本小妞迷上赌 提交于 2019-12-02 05:55:12
问题 I saw this SO post where apparently data was being fetched and returned to the Watch extension like so: - (void)application:(UIApplication *)application handleWatchKitExtensionRequest:(NSDictionary *)userInfo reply:(void ( ^)( NSDictionary * ))reply { if ( [[userInfo objectForKey:@"request"] isEqualToString:@"getData"] ) { // get data // ... reply( data ); } } But when I try to call 'reply()' inside a block after getting network data like so: __block UIBackgroundTaskIdentifier watchKitHandler

WatchKit 2 Complication Text Only Shows Up in Preview

試著忘記壹切 提交于 2019-12-02 03:14:35
I'm trying to develop a very simple complication for watchkit 2 that says "Hi" from a simple text provider. I've managed to achieve some strange behavior; I can see the text when the complication is clicked or when you are previewing it from the customize watchface screen, but not when the watchface is displayed. Have a look: Any ideas what might be causing this? My text provider looks like this var textProvider: CLKSimpleTextProvider override init() { textProvider = CLKSimpleTextProvider() textProvider.text = "Hi" textProvider.shortText = "HI" textProvider.tintColor = UIColor.whiteColor()

Unable to find interface controller class 'InterfaceController' to instantiate

╄→гoц情女王★ 提交于 2019-12-01 19:17:00
I'm getting this error every-time I run the project and try to navigate to another screen. Unable to find interface controller class 'HelpInterfaceController' to instantiate I'm using the correctly that I know: - (IBAction)HelpButton { [self presentControllerWithName:@"help" context:nil]; } Also the name help is as it is in the identifier. So what or where I'm going wrong? I've found the error! It was because of my .m file, it's target membership was MemGame instead of MenGame WatchKit Extension . So I uncheck the first option and selected the third option and now it's running perfectly. 来源:

Is there a way to determine rough distance between Apple Watch and iPhone?

此生再无相见时 提交于 2019-12-01 18:38:55
I know this might be unanswerable until the Apple Watch is released. But does anyone know if there may be a way to determine the rough distance (in feet) between an Apple Watch and an iPhone? Currently, the WatchKit framework does not give you this kind of information, since third-party apps are still quite limited in what they can do. For example, they require a connection to the iPhone . There is some speculation that later this year, third-party developers will be given more access to the hardware, e.g., bluetooth, accelerometer, pulse, NFC, etc. 来源: https://stackoverflow.com/questions

Approaching Size Limit - The size of watch application (50MB limit is headache.)

♀尐吖头ヾ 提交于 2019-12-01 18:20:54
Our app reaches approx 49MB and we are not halfway. So definitely it will exceed the limit of 50MB. I have few questions as follow. 1) Is On-Demand Resources possible in watchOS? 2) My resources(images, custom fonts) make 2 copy each one is watch app and other is watch extension. How to solve that? 3) Swift core and other swift frameworks are consuming about ~28MB of space. is there any way to disable that? (PS. we have bit code disabled) Edit for watchOS4: Previously our app size was 44.3 MB but when we generate IPA from xcode9 size increased to 54.5. You can definitely save space by only

Unable to find interface controller class 'InterfaceController' to instantiate

我是研究僧i 提交于 2019-12-01 18:03:43
问题 I'm getting this error every-time I run the project and try to navigate to another screen. Unable to find interface controller class 'HelpInterfaceController' to instantiate I'm using the correctly that I know: - (IBAction)HelpButton { [self presentControllerWithName:@"help" context:nil]; } Also the name help is as it is in the identifier. So what or where I'm going wrong? 回答1: I've found the error! It was because of my .m file, it's target membership was MemGame instead of MenGame WatchKit