ios4

UITextField resign first responder iOS4

Hi Everybody! I have a simple piece of code that works on every system except iOS4. It's about resigning first responder for a UITextField. The text field is all wired up, and here's the code for the delegate: - (BOOL)textFieldShouldReturn:(UITextField *)textField{ [opis resignFirstResponder]; return YES; } I've tried it almo...

iOS4 removing app from memory via code

Is there a way (with iOS4) when the user hits the home button (in order to exit an application) to convey to the iOS4 system to not keep the app running in the background but to remove the app completely from memory (like iPhone 3)? My app could potentially display sensitive information and I'd like for it to exit completely. Thanks ...

Xcode: Architectures settings for a universal\iOS4 app

Hi all, I was wondering what my project settings should be in case I have a universal app that I am now updating to 4.0. The Base SDK is iPhone Device 4.0 iPhone OS Deployment Target is iPhone OS 3.0 What should I enter in the Architectures, Build Active Architecture Only checkbox and the Valis Architectures for the different configur...

Black Opaque UIToolbar and UISearchBar look too much different

I need to show different "titlebar" for application, depending on situation. The problem with iOS4 is that black opaque UIToolbar looks so much different that black opaque UISearchBar. Have I messed up some settings or is there some work-arounds to make UIToolbar and UISearchBar use more similar coloring? These are overlapping in real...

Is there any TTPickerTextField alternative? perhaps in iOS4?

Is there an alternative or new stuff in iOS4 that resembles TTPickerTextField I am looking for a way to recreate the "new mail" control view and I've read about TTPickerTextField. Three20 is my last option (especially as it has no iPad version) and I wanted to know if iOS4 gives some new UI controls to do this. ...

Turn on torch/flash on iPhone 4

I know that the only way to turn on the flash and keep it on on iPhone 4 is by turning the video camera on. I'm not too sure of the code though. Here is what I am trying: -(IBAction)turnTorchOn { AVCaptureSession *captureSession = [[AVCaptureSession alloc] init]; AVCaptureDevice *videoCaptureDevice = [AVCaptureDevice defaultDeviceWithMe...

How to solve "Cannot connect to server" message with wireless app distribution on iPhone iOS 4

I found the pre-release docs for this at https://developer.apple.com/iphone/prerelease/library/featuredarticles/FA_Wireless_Enterprise_App_Distribution/Introduction/Introduction.html (Developer account required) and some more at: http://jeffreysambells.com/posts/2010/06/22/ios-wireless-app-distribution/ I'm running into issues when I c...

Splash screen appears on Debug mode but not on Release (iOS4)

I have iPhone 3GS, iOS4, xcode 3.2.3. After loading the Default.png, I add a little splash screen the looks exactly like the application start view. This splash screen appears animating in Debug mode, but do not show at all in Release mode(I get a blank screen), this of course rules out any problems with the image, like size or name. I ...

Play iPod music while receiving remote control events

Ok, I'm trying to let a user choose songs from their iPod library to listen to, but I still want to receive remote control notifications (headphones, lock screen osd, etc.) in my app so I can do some extra things. So far I can get either iPod music playing, or headphone events, but not both simultaneously. Here's what I know so far... ...

How to let my application support iOS 4?

I tested my application on 8GB iPod Touch using iOS 4.0(within multitask), it works. But when I change my original source code, and built it in the simulator. The application load, but nothing appear, it all dark. What I should do to solve the problem? I check the console, it didn't show any error msg. Thank u. ...

How to get an update NSUserDefault on iOS 4?

Hello I am developing an iPhone application, I encounter a problem on the iOS4 because of multi task. This application has the default settings defined in a Settings.bundle. If I run my application then I left it (so it goes in the background). I'll change the settings and restarts the application (it comes out of standby and method: a...

Is there an iPhone OS4 iCal API ...

does anyone know whether iPhone OS4 contains an iCal API? If yes, are there code samples how to use it to add events to iCal? cheers ...

(iPhone) How to enable ipod controls in the background to control non-ipod music (in ios4) ?

A good example of what I'm trying to accomplish is implemented in the latest version of the Spotify iPhone application for (Pandora seems to have the same feature) . When Spotify is in the background, double tapping opens the "multi-task dock", where the ipod controls (play/pause, forward etc) allow to control the music playback of Spot...

Can Blocks built for the iPhone 4 SDK work when deployed to iPhone OS 3.0?

The latest Xcode IDE requires you to target iPhone SDK 4 while dynamically handling deprecated and new functionality if you set the application to deploy to earlier releases. So can I use new features like Blocks and still have it work on a device running iPhone OS 3.0 or 3.1 or 3.1.3? I have not found documentation on how to do backwa...

What to do to fix "no qualified ads found for this request" on iAd?

Hi, Somehow I got this error message when testing iAd on the device. "no qualified ads found for this request" What to do to fix it? Anyone has any idea? On the simulator there is no error, it succeeds to show the "Test Advertisement" UPDATE: The real problem here is that the delegate to raise the error IS NOT BEING CALLED, on the ...

How does iBooks do this?

I am currently displaying text in a uiwebview. However, I would like to allow a user to select text and perform some action with the selected text (google it). Apple has done this sort of thing with iBooks. When you click on a word you can choose to look up the word in a dictionary. How can I do the same thing with Webview? UIMenuContro...

Question on how to add a UIview as a subview to a UITableCell

Hello users, I've got a question on how to add a UIView to a UITableViewCell. In my learning Project I've got a UITableViewController (TableTestViewController, a UITabelViewCell.xib (MainTabelCell.xib) and a UIView (InnerTableView). My Goal ist to show the MainTableCell in the UITableView and in this MainTabelCell the InnerTabelView bu...

iPhone Game Center iOS4 support my game? How?

I'm currently building a multiplayer game for the iOS4 and I am trying to understand how I can make it support Game Center when it is released? Is there ANY documentation on it? I can't find it anywhere I'm using cocos2d to build my game and am currently not finished, but would like to be able to code directly in hopes of the game bein...

Getting started with AR on the iPhone: How to position things?

Just starting to play with Augmented Reality on the iPhone ... and I have some questions: How do you position elements on the screen? I assume that it is based on a given longitude, latitude and altitude (but I could be wrong)??? Any solid resources, tutorials, etc... dedicated to building AR type apps for iOS? Thanks much ...

My app crash on exit after upgrading to iOS 4.0 sdk. How to fix this?

Everytime I quit the app in the simulator. The console display this error message: * -[NSThread _nq:]: message sent to deallocated instance 0x6d770e0 Looks the app try to access an deallocated instance. But I cannot find it anyhow, even using the instrument. I can't find the line of code that cause the problem. p.s. I have already tr...