ios8

Swift - App getting crashed in IOS 8.4 on launch with error _NSURLSessionTaskPriorityDefault

半城伤御伤魂 提交于 2019-12-11 12:15:54
问题 App is getting crashed on launch, with error log dyld: Symbol not found: _NSURLSessionTaskPriorityDefault Referenced from: /private/var/mobile/Containers/Bundle/Application/E302B99F-08D3-45C0-A8ED-F500052FF375/AppName.app/AppName Expected in: /System/Library/Frameworks/Foundation.framework/Foundation in /private/var/mobile/Containers/Bundle/Application/E302B99F-08D3-45C0-A8ED-F500052FF375/AppName.app/AppName IOS Target Version : 8.0 Swift : version 2.2 Device: Iphone 6 Device Version 8.4 回答1:

Mixpanel does not work with swift

梦想与她 提交于 2019-12-11 12:14:31
问题 Cocoapods is not ready for Swift yet. When I implemented Mixpanel into my iOS project that uses Swift, I got several errors. How to fix this issue and make mixpanel to work? 回答1: Add this line of code to every file that is giving an error #import <UIKit/UIKit.h> Also need to add these in your linked frameworks and libraries: libicucore.dylib CFNetwork.framework Security.framework Then add this to your Bridging-Header.h file: #import "Mixpanel.h" Then add this piece of code in your appdelegate

Missing argument for parameter #1 in call when setting initial value

时光总嘲笑我的痴心妄想 提交于 2019-12-11 12:09:17
问题 I'm trying to set current locale country as initial value: class Location: RLMObject { dynamic var country = currentCountry() func currentCountry() -> String!{ let locale = NSLocale.currentLocale() let countryCode = locale.objectForKey(NSLocaleCountryCode) as String let countryName = locale.displayNameForKey(NSLocaleCountryCode, value: countryCode) return countryName } } 回答1: The problem is that country is an instance variable and currentCountry is an instance function as well. When you want

How to differentiate top windows in iOS8?

限于喜欢 提交于 2019-12-11 12:08:35
问题 Following the strategy from this SO answer, in iOS 7 I could find the top window in my app like so: UIWindow *topWindow = [[[UIApplication sharedApplication].windows sortedArrayUsingComparator:^NSComparisonResult(UIWindow *win1, UIWindow *win2) { return win1.windowLevel - win2.windowLevel; }] lastObject]; However, since iOS8 there may be one or more UITextEffectsWindow s which may be the lastObject in the above strategy. No good. Initially I could run a predicate filter on the array of

Can't find keyplane that supports type for keyboard

試著忘記壹切 提交于 2019-12-11 11:35:53
问题 I have UITextField for entering e-mails. All is work - but I have this issue in debugger terminal: Can't find keyplane that supports type 7 for keyboard iPhone-Portrait-Emoji-Email; using 1582125428_Portrait_iPhone-Emoji-Keyboard_Letters How can I fixed it? 来源: https://stackoverflow.com/questions/27798912/cant-find-keyplane-that-supports-type-for-keyboard

Unwanted line on tab bar on iPhone 6

妖精的绣舞 提交于 2019-12-11 11:23:37
问题 Under iOS 8.1 a 1px line is showing on my tab bar. This problem is only present on iPhone 6. Here's another post with the same problem. Here is a screenshot of my tab bar. I am using this code in Swift for my tab bar. tabBarController?.tabBar.backgroundImage = UIImage(named: "tabbar_shadow.png") tabBarController?.tabBar.backgroundColor = UIColor.clearColor() tabBarController?.tabBar.shadowImage = UIImage() tabBarController?.tabBar.translucent = true This is working fine but a 1px line is

iOS App Extension has PFUser currentUser set to nil

为君一笑 提交于 2019-12-11 10:42:07
问题 I have a Parse-enabled iOS 8 app and I'm trying to enable Share Extension. I've done exactly what it says at https://www.parse.com/docs/ios/guide#extensions but in my app extension, [PFUser currentUser] is set to nil (while it is not nil in my app), and [PFInstallation currentInstallation] is set to a new instance instead of my existing installation. There seems to be a problem with App Extension communicating with my app. In the Parse docs it clearly states: If you have an existing app using

iOS 8 share extension show shared image issue

ⅰ亾dé卋堺 提交于 2019-12-11 10:41:22
问题 I have a problem with displaying image in my UIImageView. So this is how I get images in ShareViewController: - (void)viewWillAppear:(BOOL)animated { [super viewWillAppear:animated]; for (NSItemProvider* itemProvider in ((NSExtensionItem*)self.extensionContext.inputItems[0]).attachments ) { if([itemProvider hasItemConformingToTypeIdentifier:@"public.image"]) { ++counter; [itemProvider loadItemForTypeIdentifier:@"public.image" options:nil completionHandler: ^(id<NSSecureCoding> item, NSError

How to detect iPad orientation in iOS8 keyboard extension

旧巷老猫 提交于 2019-12-11 10:39:27
问题 Currently I'm using this method to detect the orientation and device: It works for iPhones, but these's an issue with iPad, that is whatever the orientation is, [[UIScreen mainScreen] bounds].size.width always ==768, and [[UIScreen mainScreen] bounds].size.height always == 1024. What's wrong with my coding? +(NSString*)GetOrientation{ if([UIScreen mainScreen].bounds.size.width < [UIScreen mainScreen].bounds.size.height){ NSLog(@"Potrait"); return @"Potrait"; } else{ NSLog(@"Landscape");

Using Facebook-iOS-SDK (4.0.1) result.isCancelled is set when using a browser

▼魔方 西西 提交于 2019-12-11 10:37:39
问题 I'm using Facebook-iOS-SDK (4.0.1) for logging in with custom button. I'm implementing the following code - (IBAction)fbButtonClicked:(UIButton *)sender { FBSDKLoginManager *login = [[FBSDKLoginManager alloc] init]; [login logInWithReadPermissions:@[@"email"] handler:^(FBSDKLoginManagerLoginResult *result, NSError *error) { if (error) { // Process error } else if (result.isCancelled) { // Handle cancellations } else { // If you ask for multiple permissions at once, you // should check if