ios7

iOS 7 uinavigationcontroller how to detect swipe?

给你一囗甜甜゛ 提交于 2019-12-12 08:27:41
问题 In the new iOS 7 UINavigationController , there is a swipe gesture to switch between views. Is there a way to detect or intercept the gesture? 回答1: The interactive pop gesture recognizer is exposed through UINavigationController 's interactivePopGestureRecognizer property. You can add your own controller as a target of the gesture recognizer and respond appropriately: @implementation MyViewController ... - (void)viewDidLoad { [super viewDidLoad]; [self.navigationController

ios7 UINavigationBar stops extending under status bar after a while

≡放荡痞女 提交于 2019-12-12 08:26:39
问题 First of all - this is NOT a question about navigation bar overlapping status bar (as many others). UINavigationBar (of my navigation controller) is perfectly aligned as I want. The problem is with my navigation bar custom background. Background image (or navigation bar itself) stops expending under status bar randomly (after few seconds after my application starts or when I present / dismiss modal navigation controllers over it). My custom image has proper dimensions for iOS (640x128px). 1.

how to set animation curve when using keyframe animation in ios?

徘徊边缘 提交于 2019-12-12 08:24:44
问题 How to set animation curve when using UIView's keyframe animation : animateKeyframesWithDuration:delay:options:animations:completion: Whatever I do in the animation block seems to be linear (unless I use the UIViewKeyframeAnimationOptionCalculationModeCubic option but this isn't what I want). I'd like to have an ease out curve on the animation like the UIViewAnimationOptionCurveEaseOut option when using regular animation : animateWithDuration:delay:options:animations:completion: 回答1: If you

UIPickerView with custom views broken in iOS7

好久不见. 提交于 2019-12-12 07:49:15
问题 I have an app with a UIPickerView. I am returning a custom view with the method - (UIView *)pickerView:(UIPickerView *)pickerView viewForRow:(NSInteger)row forComponent:(NSInteger)component reusingView:(UIView *)view It looked fine in iOS 6. In iOS 7, not so much -- screen shot below. Notice that in the cells that don't have focus, the second and third columns overlap. The central row is correct. Any suggestions? 回答1: It seems that for a strange reason, if the width of any column is higher

Storyboard app run on iOS 7 OK but Navbar shift view on iOS 6.1

﹥>﹥吖頭↗ 提交于 2019-12-12 07:47:05
问题 While rebuilding my project with the new Xcode 5 released yesterday, I was disappointed to see my storyboard view controller shaken up. After many attempts to fix things, I must conclude I'm stuck with one remaining issue: Navigation View Controller makes the navigation bar overlaps with the content of the view. Doing so, the app is ok on a iOS 7 device (no overlapping), but with a iOS 6.1 device, the navbar overlaps. I ran a sample project from FlatUI to crosscheck the issue, and they have

itemFailedToPlayToEnd - MPMoviePlayerController - iOS7

爷,独闯天下 提交于 2019-12-12 07:46:57
问题 Running into a weird issue while updating my app for iOS 7 . For iOS 6 , there is no problem and the videos are always loaded. However that is not the case here. I have a scrollview which displays playlistItems - and once you click on the playlistItem , a MPMoviePlayerController is created to show the playlist item (video). Here is the method that I believe is causing issues: - (void) play:(NSInteger)itemId withAutostart:(BOOL)autostart { // remember whether it is in fullscreen or not to

Using NSLayoutManager to calculate frames for each glyph

℡╲_俬逩灬. 提交于 2019-12-12 07:44:49
问题 On this thread, Core Text calculate letter frame in iOS, they were able to calculate the frame of each glyph very precisely using Core Text. The final rects hug the actual drawn glyphs perfectly. Using NSLayoutManager's boundingRectForGlyphRange:inTextContainer: doesn't seem to return the glyph bounding boxes that precisely: And the returned rects don't fully enclose more complex fonts (Zapfino example): Does anyone know how to replicate the results from the above mentioned discussion without

How to determine if compiling for 64-bit iOS in Xcode

拥有回忆 提交于 2019-12-12 07:44:44
问题 Consider the following function CGSize CGSizeIntegral(CGSize size) { return CGSizeMake(ceilf(size.width), ceilf(size.height)); } CGSize actually consists of two CGFloat s, and CGFloat 's definition changes depending on the architecture: typedef float CGFloat;// 32-bit typedef double CGFloat;// 64-bit So, the above code is wrong on 64-bit systems, and needs to be updated with something like CGSize CGSizeIntegral(CGSize size) { #if 64_bit return CGSizeMake(ceil(size.width), ceil(size.height));

ios 7 customizing UITableViewCell's content view

落花浮王杯 提交于 2019-12-12 07:40:07
问题 Using storyboard in ios7 the content view is explicitly viewed under the Table View Cell in the story board editor (opposed to previous versions where it was hidden from the interface). The problem is that I cannot connect the cell's custom elements to my custom cell's ib outlets anymore (subclass of UITableCellView ) and can only connect them to the table's content view ( UIView ) which CANNOT be customized (i.e. its custom class attribute is grayed) This leaves me with the option to use

Why is this UISearchBar getting resized?

主宰稳场 提交于 2019-12-12 07:36:06
问题 As shown below, my UISearchBar is getting resized when I tap on the search field. It animates nicely to cover the navigation bar, and then pop... it shrinks. The setup The UISearchBar is inside a vanilla UIView set as the tableHeaderView . I'm using a UIView (as opposed to setting the UISearchBar as the header) because I would like to put additional views in the header. The view is defined in a XIB file and the UISearchBar is anchored to all of its borders. The constraints don't seem to