[Solved] Xcode: Page-based application [closed]

Where to start learning about UIPageViewController: View Controller Catalog for iOS: “Page View Controllers” The last 15 minutes of WWDC 2011 Videos: Implementing UIViewController ContainmentTechtopia: An Example iOS 5 iPhone UIPageViewController Application solved Xcode: Page-based application [closed]

[Solved] presenting a view controller

Try doing this: HomeViewController *homeView = [[HomeViewController alloc]init]; [self presentViewController:homeView animated:YES completion:nil]; Also note that black is the default colour of the window. If you don’t have any view controller named HomeViewController, and you present it, by default it will be visible as black colour to the user. To Avoid this, you need to set … Read more

[Solved] Program crashing after trying to read a NSString

The problem is probably that that _guideDescription string already is deallocated when you try to access it in -saveIntoExisted. You are now doing _guideDescription = [[NSString alloc] initWithString:[[notification userInfo] valueForKey:@”selected”]]; and that works, but I would recommend: [_guideDescription retain]; That makes sure the system doesn’t deallocate the string. solved Program crashing after trying to read … Read more

[Solved] How to use autoresize on 2 UIViewControllers? [closed]

Well, part of the problem is that this is illegal: [UIViewControllers1.view addSubview:UIViewControllers2.view]; You must never just wantonly add one view controller’s view to another view controller’s view. There is only one way in which that is allowed outside of a built-in parent-child structure that does it for you (UINavigationController, UITabBafController, UIPageViewController), and that is when … Read more

[Solved] Timer: start-pause-resume-stop not working the way it should in ios [closed]

Here’s the basic outline of a class to achieve this. The idea is that the timer fires every second and timer is only accumlated (into _timerValue) if the paused flag (_paused) is NO. TimerClass.h: @interface TimerClass : NSObject { NSTimer *_timer; BOOL _paused; NSInteger _timerValue; } @end TimerClass.m: @implementation TimerClass – (IBAction)startTimer:(id)sender { NSAssert(!_timer, @”Already … Read more

[Solved] Long touch (touch and wait) on the cells in tableView

1) Add a UILongPressGestureRecognizer to you cell – (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@”MyIdentifier”]; if (cell == nil) { cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@”MyIdentifier”]; cell.selectionStyle = UITableViewCellSelectionStyleNone; //add longPressGestureRecognizer to your cell UILongPressGestureRecognizer *lpgr = [[UILongPressGestureRecognizer alloc] initWithTarget:self action:@selector(handleLongPress:)]; //how long the press is for in seconds lpgr.minimumPressDuration = … Read more

[Solved] Free and paid version of iOS app [closed]

I have seen many developers publish a “Lite” version of the app for free with limited features, and a full featured version of the app that costs $$. I think there is plenty of precedent for this approach that you shouldn’t get any push back from Apple. But I have heard they can be somewhat … Read more

[Solved] How to tell if a video is HDR or not in Swift?

Simple and precise: var isHdrVideo = false let pVideoTrack = AVAsset(url: URL(fileURLWithPath: assetURL!)) if #available(iOS 14.0, *) { let tracks = pVideoTrack.tracks(withMediaCharacteristic: .containsHDRVideo) for track in tracks{ isHdrVideo = track.hasMediaCharacteristic(.containsHDRVideo) if(isHdrVideo){ break } } } solved How to tell if a video is HDR or not in Swift?