Xcode 4 allows to develop applications for iPhone or iPad with lower target today's iPhone OS 4.3. However the same code that comes with templates "sin" of arrogance, assuming that our application will target iPhone OS 4 or higher. In the application delegate, for example, Xcode inserts the following lines of code:
1 2 3 4 5 6 7
| BOOL ) application : ( UIApplication * ) application didFinishLaunchingWithOptions : ( NSDictionary * ) launchOptions - (BOOL) application: (UIApplication *) application didFinishLaunchingWithOptions: ( NSDictionary *) launchOptions { / / Override point for customization after application launch. self.window.rootViewController = self.viewController; ; [Self.window makeKeyAndVisible]; ; return YES; } |
More ...
In asynchronous environments, where method calls or events are released daily bread (see Adobe ActionScript or Objective-C), often the same sequence of operations is not identical to the thousandth of a second. In addition, multiple methods can I call a more general function with the risk to cancel the effect of the other one o'clock.
To clarify the concept a prime example. Environment is often used to activate the iPhone network indicator on the status bar, indicating that there is - precisely - "traffic" network, that you are performing a download or upload (downloading or sending data).
More ...
The messages (methods) defined in the application (Application delegated) main can be invoked quickly by using performSelector :
1 2
| delegate ] [[[UIApplication sharedApplication] delegate] ( applicationMessage ) ] ; performSelector: @ selector (applicationMessage)]; |
More ...
I answer to Mirko asking me how to make the opposite case proposed in Getting Latitude and Longitude in Objective-C .
Starting from the values of Latitude and Longitude you can use the class MKReverseGeocoder to obtain a range of information, such as: city, state, address in full, chap!
More ...
1. Strings on multiple lines
In Xcode, you can "break" a string across multiple lines by inserting at the end with a backslash "\". This feature can be useful when, for example, we want to insert the HTML text in a control UIWebView :
More ...
Latest Comments
Subject : very helpful indeed! I tried it and it is just what I needed. Now I wonder how do I get ...
vik : With strategic help!
Pepper : Hi there, I do not know if you're one of the creators of the WP plugin Bannerize. I have spotted a ...
Rosanna : Can anyone tell me how do I delete the Snap Shots window that opens automatically when I ...
blessed Maresca : I can not download any skypemote me spiegaaa