ios6

iOS7 Status Bar over Navigation Bar

别来无恙 提交于 2019-12-03 06:07:46
I'm testing my application with iOS7 and I have an issue with status bar. Basically the status bar appear over navigation bar like the image below: I try to call in my viewDidLoad self.edgesForExtendedLayout = UIRectEdgeNone; self.automaticallyAdjustsScrollViewInsets = YES; without success. I have also added to the info.plist file UIViewControllerBasedStatusBarAppearance with no luck. The main problem is that the application must be compatible with iOS6 and iOS7 and currently on iOS7 the view shifted 20px from the top. edgesForExtendedLayout and automaticallyAdjustsScrollViewInsets are just

viewDidUnload no longer called in ios6

时光毁灭记忆、已成空白 提交于 2019-12-03 05:46:23
问题 I just installed the new version of Xcode/ios6. viewDidUnload is now depreciated. In the apple doc, viewDidUnload [...] Deprecated in iOS 6.0. Views are no longer purged under low-memory conditions and so this method is never called. But numbers of apps are using this callback to release their properties, like : - (void)viewDidUnload { [super viewDidUnload]; self.recipientButton = nil; self.connectButton = nil; self.infoLabel = nil; } This was the best practice to release your IBOutlets. So,

Handling gesture recognizers in iOS6

我们两清 提交于 2019-12-03 05:26:20
Apparently iOS 6 tries to automatically handle the situation when you have a gesture recognizer and a UIButton in the same place, being activated for the same gesture. This new automatic handling solves the issue when you want to click the button instead of activating the gesture recognizer, but creates a new problem when you want the gesture recognizer to act. In iOS 5 you could implement: -(BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldReceiveTouch:(UITouch *)touch to transfer the action to the UIButton when in a conflict. This doesn't seem to work in iOS 6. Also,

UIButton not works in iOS 5.x , everything is fine in iOS 6.x

孤者浪人 提交于 2019-12-03 05:18:00
问题 By tapping simple UIButton on main UIView, additional View (subview) appears in the center of screen (subview created programmatically). On that subview I have UIButton that launches MPMoviePlayer (this code is inside method that creates subview): // Create play button UIButton *playButton = [UIButton buttonWithType:UIButtonTypeCustom]; [playButton addTarget:self action:@selector(wtf) forControlEvents:UIControlEventTouchUpInside]; [playButton setTitle:@"" forState:UIControlEventTouchUpInside]

Possible to show a “in App Store modal” in iOS 6?

柔情痞子 提交于 2019-12-03 05:15:47
问题 Is it possible to show a modal view controller in iOS 6 that present my app in App Store? 回答1: Yes you can. (iOS6+) Take a look at SKStoreProductViewController NSDictionary *appParameters = [NSDictionary dictionaryWithObject:@"533886215" forKey:SKStoreProductParameterITunesItemIdentifier]; SKStoreProductViewController *productViewController = [[SKStoreProductViewController alloc] init]; [productViewController setDelegate:self]; [productViewController loadProductWithParameters:appParameters

Use UIRefreshControl for UIWebView

孤街醉人 提交于 2019-12-03 05:11:23
问题 I saw the UIRefreshControl in iOS 6 and my question is if it is possible to refresh a WebView by pulling it down and than let it pop up like in mail? Code I used rabih is the WebView: UIRefreshControl *refreshControl = [[UIRefreshControl alloc] init]; [refreshControl addTarget:self action:@selector(handleRefresh:) forControlEvents:UIControlEventValueChanged]; [rabih addSubview:rabih]; 回答1: This is how you can use pull down to refresh on UIWebview: - (void)viewDidLoad { [super viewDidLoad]; //

How to get a snappy UICollectionView with lots of images (50-200)?

我的梦境 提交于 2019-12-03 05:09:49
问题 I'm using UICollectionView in an app that is displaying quite a lot of photos (50-200) and I'm having issues getting it to be snappy (as snappy as Photos app for example). I have a custom UICollectionViewCell with a UIImageView as it's subview. I'm loading images from the filesystem, with UIImage.imageWithContentsOfFile: , into the UIImageViews inside the cells. I've tried quite a few approaches now but they have either been buggy or had performance issues. NOTE: I'm using RubyMotion so I'll

Why does my Cordova WebView have an extra 20px of scrolling?

淺唱寂寞╮ 提交于 2019-12-03 04:59:50
I am building a Cordova app, and I'm testing it on my iOS 6 device (iPod Touch w/ iOS 6.1.6). For some reason, the WebView is scrollable with an extra 20px, seemingly making up for the 20px status bar at the top of the screen. This sometimes causes the scrollable WebView to take focus, essentially causing "nothing" to scroll in the eyes of the user, rather than allowing scrollable div s in my app to scroll. I have tried numerous fixes pertaining to config.xml changes, plugins, etc, but nothing makes a difference, which I've outlined below. Tried manually hiding the status bar , with no effect.

table view in popover is not scrolling

本小妞迷上赌 提交于 2019-12-03 04:56:14
I have the code below to display popover with tableview and it works perfectly. The tableview displays 13 numbers and I can scroll and see the same but when I release mouse-touch on simulator it goes back to the top. It does not stay at the row which its displaying but takes me back to 1st to 10th row . How do I make it stay in the position after scrolling. Or any fix in the below code. Thanks in Advance. - (IBAction)btn:(id)sender { if([popoverController isPopoverVisible]) { [popoverController dismissPopoverAnimated:YES]; return; } //build our custom popover view UIViewController*

Get Facebook access token from Social.framework(iOS6)

落花浮王杯 提交于 2019-12-03 04:52:40
问题 I need to retrieve Facebook access token of my system account, which I set in Settings application. I know that Social.framework(iOS6) knows all my FB account information & I can perform API calls to Graph API using SLRequest class, like in this post http://blogs.captechconsulting.com/blog/eric-stroh/ios-6-tutorial-integrating-facebook-your-applications But, my question is - how can I retrieve my Facebook system account's access token? I found solution for Twitter https://dev.twitter.com/docs