Chapter 2
The iOS Simulator
The iOS Simulator is an application that runs on your Mac and allows you to test your apps without using an actual iOS device. The iOS Simulator is located in the /Developer/Platforms/iPhoneSimulator.platform/Developer/Applications folder and is a part of the standard iOS SDK installation. When you run your app in Xcode, you have the choice of launching it in the simulator or an actual device. If you choose to launch it in the simulator, Xcode will launch the iOS Simulator automatically.
Features of the iOS Simulator
You can use the iOS Simulator to simulate different device (iPad, iPhone 3GS, iPhone 4) and SDK versions. You can change the iOS version being simulated using the Hardware ➪ Version menu (Figure 2-1). The actual list of options you see here will depend on the different versions of the iOS SDK that you have installed on your Mac.
To switch devices use the Hardware ➪ Device menu. You can choose between an iPhone (iPhone 3GS), iPhone Retina (iPhone 4), or an iPad. Figure 2-2 shows the iPhone4 and iPad simulators.
You can rotate the simulator by using the Rotate Left or Rotate Right menu items from the Hardware menu (Figure 2-3).
The iOS Simulator allows you to simulate a variety of one and two-finger multi-touch gestures. Single-finger gestures such as taps and swipes can be performed by clicking and dragging with the mouse. The ...
Get iPhone and iPad App 24-Hour Trainer now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.