ios11

How to add support for 10.5 inch iPad Pro

安稳与你 提交于 2019-12-12 07:13:05
问题 I've just downloaded the latest Xcode 8.3.3 update from the MAS. I was wondering how to add support for the new 10.5-inch iPad Pro? I'm using storyboards with auto-layout, a launch screen storyboard and all app icon sizes are added to the xcassets. 回答1: I believe that the auto-layout launch screen story board should be all that is needed. However, I have found that if I build an application under Xcode 8.3.3, the UIScreen.mainScreen.bounds returns 736 x 1024. If I build the same application

Extend the View Underneath the Status Bar and Multi-tasking Bar on iPhone X Without Manually Adjusting Constraints in Code?

…衆ロ難τιáo~ 提交于 2019-12-12 05:05:05
问题 I was wondering if there's a way to extend a view to be underneath the status bar and multi-tasking bar of the iPhone X without manually adjusting constraints in code based on the device. Using the safe area, container, container margins and top/bottom layout guides doesn't seem to help because the status bar is a different height on the iPhone X vs the previous iPhones and the safe area ends at the top of the multi-tasking bar whereas it ends at the bottom of the screen for previous iPhones.

Not getting file URL from bundle

邮差的信 提交于 2019-12-12 04:57:44
问题 I am loading PDF file in PDFView but unable to get PDF File URL from Bundle. Please check below code : let pdfView = PDFView(frame: self.view.bounds) let myFileName = "sample" guard let url = Bundle.main.url(forResource: myFileName, withExtension: "pdf") else { return } pdfView.document = PDFDocument(url: url) self.view.addSubview(pdfView) Every time I am getting nil in url . Edit : Here is my Project Window: Am I making any silly mistake ? Please guide me. Thanks in Advance. 回答1: I got

How to import self-signed certificate in iOS 11 to build the app instead of adding to simulator manuelly after building?

穿精又带淫゛_ 提交于 2019-12-11 18:54:07
问题 I'm currently getting this "SSL error" on the simulator of my app. Error Screenshot I have my own self-signed certificate. And this problem can be solved by installing the cert file manually on the simulator. However, we are trying to avoid manually installing the certificate to the simulator (drag and drop) every time after building the app. And instead, I want to find a way to import the certificate file into our ios app bundle. I followed this article and tried with the following way, but

Customize iOS11 Document Based App Template

非 Y 不嫁゛ 提交于 2019-12-11 18:08:52
问题 I need to do the following customizations on the provided iOS 11 Document Based App Template: A library with only my App files, as Procreate example App bellow Get rid of the sidebar browser, so I have a fullscreen that shows only my library. https://assets.procreate.art/video/home/mp4/block-10.mp4 I have asked Apple Code Level suport but still haven't got an answear. Can someone please help? Thanks! 来源: https://stackoverflow.com/questions/48233085/ios-11-document-based-app-template-remove

Facebook integration IOS 11

妖精的绣舞 提交于 2019-12-11 17:29:34
问题 I've been trying to integrate Facebook with an IOS app using cocoapods (Xcode 9.0, IOS 11). After installing pods and adjusting the info.plist with all fb info, I got stuck on importing FacebookCore (it won't work with FBSDKCoreKit, FacebookLoginKit, FBSDKLoginKit also). Xcode issues the "No such module" warn. More than that, if I choose to run the project (without importing anything), it issues more than 20 warns, including Bolts framework, FBSDKCoreKit, FacebookCore etc.. Does anyone know

Error when running coreml in the background: Error computing NN outputs error

独自空忆成欢 提交于 2019-12-11 16:56:58
问题 I'm running an mlmodel that is coming from keras on an iPhone 6. The predictions often fails with the error Error computing NN outputs . Does anyone know what could be the cause and if there is anything I can do about it? do { return try model.prediction(input1: input) } catch let err { fatalError(err.localizedDescription) // Error computing NN outputs error } EDIT: I tried apple's sample project and that one works in the background so it seems it's specific to either our project or model

How to set JSON output into UILabel in Swift 4.0?

梦想的初衷 提交于 2019-12-11 15:37:29
问题 I'm working on an app built in Swift 4.0 (Xcode Beta 9) that will pull in Bitcoin values from the Bitstamp API (this part is working) and output the value in a label. Where I'm stuck is getting the output of this call into my label. The value prints out here: let btcValues = try JSONDecoder().decode(BitcoinResponse.self, from: data) print("$" + btcValues.last) Complete code in my ViewController.swift file: import UIKit struct BitcoinResponse: Decodable { let high: String let last: String let

validateTextureDimensions:759: failed assertion `MTLTextureDescriptor has width (45000) greater than the maximum allowed size of 16384.'

馋奶兔 提交于 2019-12-11 14:47:44
问题 I am getting this error on iOS 11 while trying to load the MKMapView on a collection cell. Everything works fine until I face this issue, I also tried by disabling the Metal API validation in Edit Scheme's but no luck. Any idea whats going wrong? 回答1: The problem is with UICollectionViewDelegateFlowLayout where I am passing the CGSize width as collectionView.bounds.width * 0.75. By setting it to fixed width the error is gone. Weird but true! 来源: https://stackoverflow.com/questions/48016319

How to disable swipe back gesture with master-detail view in ios 11?

故事扮演 提交于 2019-12-11 14:33:54
问题 I'm trying to disable the swipe back gesture, so that swiping back in my detail view will not open the master view. I'm aware that this question and this question exist, but I have tried all the solutions suggested and none of them have worked for me. It may be because I am on iOS 11. To demonstrate the issue, I've created a new master-detail project in Xcode and only added the solutions which I saw in the linked questions, which is adding this: self.splitViewController.presentsWithGesture =