xcode6

Importing Project-Swift.h into a Objective-C class…file not found

家住魔仙堡 提交于 2019-12-17 03:23:22
问题 I have a project that was started in Objective-C, and I am trying to import some Swift code into the same class files that I have previously written Objective-C in. I have consulted the Apple docs on using Swift and Objective-C in the same project, as well as SO question like this, but still no avail: I continue to get the file not found error after putting in #import "NewTestApp-Swift.h" ( NewTestApp is the name of the Product and module). Here is what I have done so far: In Define Modules ,

How to implement tab bar controller with navigation controller in right way

雨燕双飞 提交于 2019-12-17 02:42:50
问题 I am using Storyboard and Xcode 6. I have next controllers and scenes in my Storyboard: UINavigationController that has HomeViewController as a root. HomeViewController has a button that Show (e.g. Push) UITabBarController . UITabBarController has 4 UIViewControllers . But my problem that after I Show UITabBarController there are no Navigation Bars in 4 UIViewControllers . But I supposed that if I Show (e.g. Push) UITabBarController then it should has embedded navigation controller that is

Move a view up only when the keyboard covers an input field

核能气质少年 提交于 2019-12-17 02:33:17
问题 I am trying to build an input screen for the iPhone. The screen has a number of input fields. Most of them on the top of the screen, but two fields are at the bottom. When the user tries to edit the text on the bottom of the screen, the keyboard will pop up and it will cover the screen. I found a simple solution to move the screen up when this happens, but the result is that the screen always moves up and the fields on top of the screen move out of reach when the user tries to edit those. Is

Xcode 6 - xcassets for universal image support

半世苍凉 提交于 2019-12-17 02:26:57
问题 Currently working on a universal SpriteKit project. I'll be supporting the following devices: iPhone 4/s, iPhone 5/c/s, iPhone 6, iPhone 6+ iPad non-ret, iPad retina I am confused on the iPhone part. I already have 4 versions for my background sprite for the 4 different screen resolutions of the iPhones. But which goes to which? I know the 3x is for the 6+, and I think the 5/c/s goes to the Retina 4 2x, but I do not know where the iPhone4/s, and 6 go. Anyone know? Side note, when I create a

How to “Delete derived data” in Xcode?

为君一笑 提交于 2019-12-17 02:22:27
问题 In Xcode5 there is simple option to Delete derived data: In organiser menu ( cmd + shift + 2 ): But with new interface of Xcode6 there is no similar options. Is there any quick methods to delete this trough Xcode6 interface? Or now I should remove this folders in system manually? 回答1: Pressing Cmd + Shift + 2 In Xcode 6 will present Devices, which is separated from Organizer . Instead you can go Window , then Organizer , then find your project in Projects to delete derived data. You may set a

Ineligible Devices section appeared in Xcode 6.x.x

冷暖自知 提交于 2019-12-17 02:02:38
问题 After installing Xcode 6 my devices moved to greyed-out section Ineligible Devices and I can't select them as deploy target: Update: This error occurs in all versions of Xcode 6.x.x . There are so many different reasons causing this problem Check this solution list for more details. 回答1: With the release of Xcode 6.3.1, check first the Update 5 Verify that "iOS Deployment Target" is <= the version of your iDevice. You find this option in "Build Settings" tab when you click on a target of your

Dealing with different iOS device resolutions in SpriteKit

核能气质少年 提交于 2019-12-17 01:39:50
问题 I'm playing around with SpriteKit in Xcode 6, iOS 8 beta 5. Everything is all laid out and working perfectly on the iPhone 4S simulator, however when switching to the 5S, the elements at the bottom of the screen are cut off. It was to my understanding that the bottom left corner of the iPhone screen should be CGPoint(0, 0) but after checking the location by printing the coordinates to the console that the lowest point of the left corner I could click was around (5, 44). Is there something

UITextField no longer reloads keyboardType after reloadInputViews call

笑着哭i 提交于 2019-12-14 04:16:24
问题 In iOS 7, I could change the keyboard type while it is the firstResponder (on the fly): if (textField.text.length > 2) { textField.keyboardType = UIKeyboardTypeNumbersAndPunctuation; } else { textField.keyboardType = UIKeyboardTypeDefault; } [textField reloadInputViews]; // (Omitting some efficiency stuff to keep example to bare bones) This no longer works under Xcode 6/iOS 8. The documentations mostly reflect changes regarding custom keyboard. Using resign/become first responder is (still)

There is no simulator in my xcode 5 after I install xcode 6 beta

非 Y 不嫁゛ 提交于 2019-12-14 03:59:15
问题 I have installed xcode 6 beta 4 but after that, when I use xcode 5, there is no simulator can be select, so I also cannot build the project, does anyone encounter this problem? I suppose the xcode 6 is another app so it should not cover the xocde 5, but I don't know why happen for me :( Thanks! 回答1: In Xcode6 go to Window -> Devices -> Then you will see sections in the left and a plus button at the bottom. Press it and add the required simulator. 来源: https://stackoverflow.com/questions

Access iPhone alarm from app?

可紊 提交于 2019-12-14 03:53:55
问题 Is there a way to access and update the native alarm settings in the iPhone from my app? I need to have a sliding alarm that changes based on the time of year and I want to use the native iPhone alarm for that. Is this possible in the iOS SDK, maybe asking the user for access to the alarm like when your app needs access to the camera or photos for example? 回答1: Unfortunately, I believe there is no public API for accessing the Clock app and settings. I think the reason for this is that Apple