How to use SDK3.0 to improve UI features

June 19, 2009 § Leave a comment

SDK3.0 offers significant UI improvements

Add toolbarItems

navController.toolbarHidden = NO;
self.toolbarItems = [self barItems];

Color & Translucent Navigation Bar

self.navigationController.navigationBar.tint – purpleColor;
self.navigationController.navigationBar.translucent = YES;

Make Status bar transparent

self.wantsFullScreenLayout = YES;

Single Step Rotation


Note: must remove previous 2.x Orientation code so 2.x won’t override the 3.0 rotation

Mixed Orientation

separate model view orientation so you assign a view in portrait and another view in landscape without rotating the device physically

Modal Transitions

// Flip the view without using animation
self.modalTransitionStyle = UIModalTransitionStyleFlipHorizontal;

// Fading the view without using animation
self. modalTransitionStyle = UIModalTransitionStyleCrossDissolve;

Memory Management

Check view without reloading
– (BOOL)isViewLoaded;

Respond to view removal


  • Automate manual coding
  • Hide navigation bar
  • Display search results
  • New scope buttons to filter search results & customize buttons
  • Delegate supplies search data

Table Cell Styles

Add more cell styles

  • UITableViewCellStyleDefault
  • UITableVeiwCellStyleSubtitle
  • UITableViewCellStyleValue1
  • UITableViewCellStyleValue2
  • initWithStyle:reuseIdentifier:

Add more label styles

  • cell.textLabel
  • cell.detailTextLabel
  • cell.imageView
  • cell.text
  • cell.image

MapKit Framework

  • Add MKMapView that is scrollable & zoomable
  • Drop multiple pins with annotation & actions
  • Use reverse geocoding API to get addresses from coordinates

Cut, Copy, Paste

  • Add copy paste to your views
  • Show menu with UIMenuController
  • New UIResponder methods


-(BOOL)canPerformAction:(SEL)action withSender:(id)sender

System Pasteboard
// Shared
[UIPasteboard generalPasteboard];

// Retain Last UISearchBar string
[UIPasteboard pasteboardWithName:UIPasteboardNameFind create:NO];

// Create your pasteboards that won’t add to system pasteboards
[UIPasteboard pasteboardWithName:@”myPasetboard” create: YES];
[UIPasteboard pasteboardWithUniqueName];

// Acessing 1st available item of matching type
NSString *firstString = pasteboard.string;
UIImage *firstImage = pasteboard.string;
NSURL *firstURL = pasteboard.URL;
UIColor *firstColor = pasteboard.color;

// Get all arrays of items
NSArray *allString = pasteboard.strings;
UIImage *allImages = pasteboard.images;
NSURL *allURLs = pasteboard.URLs;
UIColor *allColors = pasteboard.colors;

Sharing Data

// NSDictionary store how app was launched
-(void)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictrionary *)opts;

  • UIApplicationLaunchOptionsURLKey (which url it refers)
  • UIApplicationLaunchOptionsSourceApplicationKey (which app it refers)
  • UIApplicationLaunchOptionsRemoteNotificationKey (which push notifications it refers)

Note: You must replace previous launch methods in order to use new method

  • applicationDidFinishLaunching:
  • application:handleOpenURL:

Sending data to other apps

  • write data to a pasteboard
  • open a URL to another app & save data

-[UIApplication canOpenURL:]

Receiving data from other apps

  • parse URL
  • Check source application
  • read pasteboard

This support collaborations between iphone apps using pasteboard, parse URL and launch options.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

What’s this?

You are currently reading How to use SDK3.0 to improve UI features at Web Builders.


%d bloggers like this: