watchos-simulator

Can I test local notifications on the WatchOS 2 Simulator?

孤街醉人 提交于 2019-12-12 05:24:30
问题 I am Googling a lot to find out way to check local notifications on the WatchOS Simulator because I don't have an iWatch. Right now I have implemented local notification but due some reason notification is shown on iPhone simulator but not on iWatch (WatchOS 2) simulator. I have added following code in applicationDidFinishLaunchingWithOptions: UIMutableUserNotificationAction *action1; action1 = [[UIMutableUserNotificationAction alloc] init]; [action1 setActivationMode

Location detection in WatchOS simulator has been failed

我怕爱的太早我们不能终老 提交于 2019-12-11 06:27:44
问题 How to simulate a location for watchOS simulator? using with request - (void) requestLocation { locationManager = [CLLocationManager new]; locationManager.delegate = self; [locationManager requestWhenInUseAuthorization]; [locationManager requestLocation]; } I always catch an error: - (void)locationManager:(CLLocationManager *)manager didFailWithError:(NSError *)error { // Error here if no location can be found } The error is NSError * domain: @"kCLErrorDomain" - code: 0 0x7a867970 回答1: In