Wednesday, June 09, 2010

iPhone dev Stupidity 127: How Three20 works

1. Create TTThumbesViewController via URL: "tt:\\phototest2"


2. When is the TTURLMap setuped?


3. And mapped to class


  [map from:@"*" toViewController:[TTWebController class]];

  [map from:@"tt://catalog" toViewController:[CatalogController class]];

  [map from:@"tt://photoTest1" toViewController:[PhotoTest1Controller class]];

  [map from:@"tt://photoTest2" toViewController:[PhotoTest2Controller class]];


4. How TTThumbsView get created?



5. URL protocol


The URL "protocol" for the bundled files is bundle:// 
while the one for the files in the documents directory is documents://

6. A Tutorial on How to create a photo browser using Three20

Most of the code is just copied from the TTCatalog sample code.







No comments: