ios7

How to change UIStatusBarStyle in iOS 7 in modal views with navigation bar?

房东的猫 提交于 2019-12-18 13:08:37
问题 The iOS 7 Transition Guide give a good hint how to change the UIStatusBarStyle dynamically in a UIViewController using - (UIStatusBarStyle)preferredStatusBarStyle { return UIStatusBarStyleDefault; } together with [self setNeedsStatusBarAppearanceUpdate]; This works fine in a single view application. However, I'm now trying to change the UIStatusBarStyle in a modal view to UIStatusBarStyleLightContent . There is a MainViewController which segues to the ModalViewController , which itself is

UITextView with clickable links but no text highlighting

孤街醉人 提交于 2019-12-18 12:52:35
问题 I have a UITextView displaying non-editable text. I want the text to automatically parse links, phone numbers, etc for the user, and for those to be clickable. I don't want the user to be able to highlight text, though, because I want to override those long press and double-tap interactions to do something different. In order for links to be parsed in iOS7, the Selectable switch needs to be turned on for the UITextView, but Selectable also enables highlighting, which I don't want. I tried

How do I create a standard iOS Share button?

感情迁移 提交于 2019-12-18 12:45:19
问题 The iOS Human Interface Guidelines say: Use the system-provided Share button. Users are familiar with the meaning and behavior of this button, so it’s a good idea to use it when possible. The main exception to this is if your app does not contain a toolbar or navigation bar[, as] the Share button can only be used in a toolbar or navigation bar. OK, but how do I “use the system-provided Share button”? A search of the documentation turns up nothing useful. I've gathered that I should use

Base64 encoding weirdness for iOS7 in-app purchase receipt server verification

和自甴很熟 提交于 2019-12-18 12:38:34
问题 I've found some very odd issues with base64 encoding of iOS7 receipts. At the moment (Xcode5/iOS7) have 2 methods for getting a receipt for an in-app purchase: Deprecated method that returns a single receipt. [SKPaymentTransaction transactionReceipt] A bundle of all receipts from location appStoreReceiptURL My App sells web site based services using a credit system which makes server receipt validation necessary. The App also sells downloadable extensions. So a mixture of consumables and non

iAd in sprite kit game

耗尽温柔 提交于 2019-12-18 12:38:12
问题 I know there is at least one question asking how to integrate iAd into a sprite kit game, but that is not what I am looking for. I am looking for a portrait version of how to do it. There seem to be absolutely 0 tutorials online as to how to do this, so I came here. Can someone please tell me how to simply enable iAd in a Sprite Kit game? I have enabled canDisplayBannerAds and have used the originalContentView property for my UIView, but I keep getting a crash that says * Terminating app due

Adding iOS 7 version of iPhone 4-inch launch image to project breaks launch image when run on iOS 7

江枫思渺然 提交于 2019-12-18 12:34:38
问题 I'm running into a problem on our landscape only app that targets iOS 6 and 7. Xcode gives me the following warning: An iPhone Retina (4-inch) launch image for iOS 7.0 and later is required. If I add the required images, when I launch the app on iOS 7, I get a black launch image shown. On iOS 6, it displays correctly. But without the images, it works just fine on both iOS 6 and 7. I am already using Asset Catalogs in this project, so I don't think that's an issue. I would really like to get

Completion handler is not called on iOS7 GM

北慕城南 提交于 2019-12-18 12:14:32
问题 I'm using AVAssetWriter, and it is perfectly working on iOS6. The problem is, when I called finishWritingWithCompletionHandler , the completion handler is not called on iOS7 GM. I called markAsFinished , and even endSessionAtSourceTime before I call finishWritingWithCompletionHandler. It works fine on iOS6. And even more, on iOS7, it works some times, and then it doesn't work again. I don't know why, but it works if I call the method using alert view. So I tried performSelectorOnMainThread

UITextView's text going beyond bounds

陌路散爱 提交于 2019-12-18 12:14:13
问题 I have a non-scrollable UITextView with it's layoutManager maximumNumberOfLines set to 9, which works fine, but, I cannot seem to find a method in NSLayoutManager that restricts the text to not go beyond the frame of the UITextView. Take for example in this screenshot, the cursor is on the 9th line (the 1st line is clipped at top of screenshot, so disregard that). If the user continues to type new characters, spaces, or hit the return key, the cursor continues off screen and the UITextView's

What should I use instead of deprecated GKLeaderboardViewController in iOS7?

ε祈祈猫儿з 提交于 2019-12-18 12:08:44
问题 ive updated my app for IOS 7 and game center has a few things deprecated such as loading and dismissing the leaderboard and achievements how can i fix them it says GKLeaderboardViewController is deprecated - (IBAction)LeaderBoardsButton:(id)sender { GKLeaderboardViewController *leaderboardController = [[GKLeaderboardViewController alloc] init]; if (leaderboardController != NULL) { leaderboardController.leaderboardDelegate = self; [self presentViewController:leaderboardController animated:YES

iOS 7 UIWebView not rendering

我的梦境 提交于 2019-12-18 12:07:56
问题 I'm porting my app to iOS 7 and I have a problem with UIWebView in iOS 7. I load local html string in it with this code: NSURL *baseURL = [NSURL fileURLWithPath: DOCUMENTS_DIRECTORY]; [self.descWebView loadHTMLString:html baseURL:baseURL]; It works perfectly on iOS 6 and prior but on iOS 7 it doesn't rendering and the UIWebView is still white. And this message appears in console: void SendDelegateMessage(NSInvocation *): delegate (webView:decidePolicyForNavigationAction:request:frame