ios4

iOS 4 app flickers and crashes when returning from background mode

I just converted an iPhone OS 3 app to iOS 4, and once in a while, the screen will flicker and then turn black when the app returns from background mode. Has anyone else experienced this? I finally resorted to terminating the app before it enters background mode. This is definitely a temporary band aid: - (void)applicationDidEnterBackg...

iPhone: Reload view after switch back from foreground/background?

This is for iOS4 with multitask issue. How do I reload view after my app is re-appear from background running app? ...

NSURLConnection delegate methods not executing

I'm running the following example code from Apple - NSString *requestURL = [[NSString alloc] initWithString:@"http://google.com/"]; NSURLRequest *theRequest = [NSURLRequest requestWithURL:[NSURL URLWithString:requestURL] cachePolicy:NSURLRequestUseProtocolCachePolicy timeoutInterval:60.0]; NSURLConnectio...

quit app in iOS4

Hi folks, I have an old app which did many UI initialization work in viewDidLoad of various views. In iOS4 home button just put the app in background so viewDidLoad won't get called when re-launching the app. I don't want to put those initialization procedures in viewWillAppear as it is unnecessary to re-initialize the data every time...

Iphone Speaker Buttons used as App Controls

Is it possible to use the external speaker volume controls of iphone as a control for an App you have developed? For example as a control of a timer app for which the enable button for the timer to start counting is the top external volume button and disable timer is the lower external button. If so, which classes of iOS 4 sdk can ov...

App freeze and then crashes on splash screen

Hello guys, I have an iPhone App published for a while, developed under the SDK3, and everything works great. Some weeks ago, when Apple released the SDK4 I made some changes to my app to support multitasking (it plays audio in the background). In my simulator and my device (iPhone 3GS iOS4) the app runs great, there is no problem at ...

iOS 4.0 and 3.0 on one mac

Hi, I have just submit my app to the App store, and received many comments that the application crashes on startup on older iphones. The deployment target was set to 3.1.3 and base sdk to 4.0. I thought I didn't use any api from 4.0 so the only problem could be three20 library. Now I have two xcodes installed on my computer. After some...

iPhone: How to set repeat daily/hourly local notification?

I want to test add local notification. I want it repeat daily/hourly. How can I do that? NSCalendar *calendar = [NSCalendar autoupdatingCurrentCalendar]; // Get the current date NSDate *now = [NSDate date]; // Break the date up into components NSDateComponents *dateComponents = [calendar components:( NSYearCalendarUnit | NSMo...

Can I access the URLs of all open websites on iPhone's mobile Safari?

I am thinking about creating an iPhone App and I wonder if it is possible for an app to access the URLs websites, which are opened in mobile Safari? ...

AVCaptureMovieFileOutput doesn't respond to minFreeDiskSpaceLimit

After setting the minFreeDiskSpaceLimit property of an AVCaptureMovieFileOutput the delegate should call the captureOutput:didFinishRecordingToOutputFileAtURL:fromConnections:error: method if the disk space is less then the value specified in minFreeDiskSpaceLimit, but it doesn't. The delegate calls correctly the method only if I call th...

Playback decompressed G.711 mu-law audio on iPhone

What is the best way to playback decompressed G.711 mu-law audio in iOS? Thanks, Rob ...

Python--How do I write the value of a variable into the pasteboard in iPhone (iOS 4)/

I am running iOS 4 on a jailbroken iPhone 3GS. Before I upgraded to iOS 4, I had installed Python on the iPhone and had found the following snippet of Python code to copy a variable (key in this case) to the pasteboard. I then was able to open another application and paste the value into a text field. out = os.popen('\usr\bin\pbcopy',...

AVAudioPlayer leak in Simulator

Hi, I have the following code, that leaks in instruments when running in simulator ( memomry allocation is stable though) and is fine on the device. The code gets called everytime a button gets pressed. Im a newbie - so any help and comments welcome :-) if ( audioPlayer){ if ( [audioPlayer isPlaying] ) { [audioPlayer stop];...

Using applicationwillenterforeground for a passcode screen

Before iOS4, my app's initial view controller would check a passcode on/off settings variable in viewWillAppear and if set on, present a modal passcode screen that would stay there until the correct passcode was entered or the Home button was pressed. With iOS4, if my app has been in the background, I would like the user to feel comfort...

Launching my app causes iPod music to stop

Hi, I'm compiling using iOS4. When I launch my application that uses UIImagePickerController and iAds the iPod music halts and doesn't continue in the background? Any settings I have to add to my app? Thanks ...

Updating iPhone application from 3.0 to iOS4

Hi, I was just wondering if anyone knows of any articles relating to upgrading an iPhone application from 3.0 to iOS4. (Thanks for this iWasRobbed). While the application still runs on iOS4, it will not run on the iPhone 4, but does on my iPhone 3G. When I deploy the app on the iPhone 4, the Default screen loads and it will sit there ...

Insert metadata on song on iOS

I'm developing an application that generates a MP3 file. I would like to insert metadata( name, artist and cover to be exact) on it. How may I do that? ...

How to communicate between objects

Still having trouble with this language. Ok, let's say I have two objects. The first is my application delegate, the second is a custom view containing the various buttons that make up the main menu. When a button is clicked, it is the menu that responds. However, I need to make use of certain instance variables in the application deleg...

iPhone iOS4 low-level camera control?

Is there a way to manually set low-level still-camera settings like shutter speed, aperture, or ISO in iOS4 on the iPhone 4? I don't think it exists in the official SDK but perhaps someone has found some private APIs to allow this? I find my iPhone 4 camera to be unusable because even in fairly decent lighting, it always insists on shoo...

sharing NSManagedObjectContext and other service classes between iphone/ipad tabs

Hi geniuses out there, I am well into building a Core Data tab-based iPad application. I am passing in my NSManagedObjectContext to my root view using the following in my app delegate class. - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { self.rootViewController.man...