├── .gitignore ├── ASKit ├── Resources │ └── askit-hdr-bck.png └── Classes │ ├── ASTableViewCellLabel.h │ ├── ASSectionHeaderView.h │ ├── ASKit.h │ ├── ASFooterView.h │ ├── ASTableViewController.h │ ├── ASHeaderView.h │ ├── ASInfoCell.h │ ├── ASTableViewCellLabel.m │ ├── ASFooterView.m │ ├── ASTableViewCell.h │ ├── ASSectionHeaderView.m │ ├── ASHeaderView.m │ ├── ASInfoCell.m │ ├── ASTableViewController.m │ └── ASTableViewCell.m ├── Demo ├── Classes │ ├── Other │ │ ├── ASKitDemo_Prefix.pch │ │ └── main.m │ └── Controllers │ │ ├── TableViewController │ │ ├── TableHeaderView.h │ │ ├── TableViewController.h │ │ ├── TableHeaderView.m │ │ └── TableViewController.m │ │ └── AppDelegate │ │ ├── AppDelegate.h │ │ └── AppDelegate.m ├── Resources │ └── Info.plist ├── Views │ └── MainWindow.xib └── ASKitDemo.xcodeproj │ └── project.pbxproj └── README.markdown /.gitignore: -------------------------------------------------------------------------------- 1 | build 2 | *.pbxuser 3 | *.mode1v3 4 | .DS_Store 5 | 6 | -------------------------------------------------------------------------------- /ASKit/Resources/askit-hdr-bck.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/enormego/askit/HEAD/ASKit/Resources/askit-hdr-bck.png -------------------------------------------------------------------------------- /Demo/Classes/Other/ASKitDemo_Prefix.pch: -------------------------------------------------------------------------------- 1 | // 2 | // Prefix header for all source files of the 'ASKitDemo' target in the 'ASKitDemo' project 3 | // 4 | 5 | #ifdef __OBJC__ 6 | #import 7 | #import 8 | #endif 9 | -------------------------------------------------------------------------------- /ASKit/Classes/ASTableViewCellLabel.h: -------------------------------------------------------------------------------- 1 | // 2 | // ASTableViewCellLabel.h 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 10/27/08. 6 | // Copyright 2008 enormego. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface ASTableViewCellLabel : UILabel { 12 | 13 | } 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /Demo/Classes/Controllers/TableViewController/TableHeaderView.h: -------------------------------------------------------------------------------- 1 | // 2 | // TableHeaderView.h 3 | // ASKitDemo 4 | // 5 | // Created by Shaun Harrison on 1/6/09. 6 | // Copyright 2009 enormego. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "ASKit.h" 11 | 12 | @interface TableHeaderView : ASHeaderView { 13 | 14 | } 15 | 16 | @end 17 | -------------------------------------------------------------------------------- /Demo/Classes/Controllers/TableViewController/TableViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TableViewController.h 3 | // ASKitDemo 4 | // 5 | // Created by Shaun Harrison on 1/6/09. 6 | // Copyright 2009 enormego. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "ASKit.h" 11 | 12 | @interface TableViewController : ASTableViewController { 13 | 14 | } 15 | 16 | @end 17 | -------------------------------------------------------------------------------- /ASKit/Classes/ASSectionHeaderView.h: -------------------------------------------------------------------------------- 1 | // 2 | // ASSectionHeaderView.h 3 | // ASKitDemo 4 | // 5 | // Created by Shaun Harrison on 1/6/09. 6 | // Copyright 2009 enormego. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | 12 | @interface ASSectionHeaderView : UIView { 13 | @private 14 | UILabel* title; 15 | } 16 | 17 | @property(nonatomic, copy) NSString* text; 18 | @end 19 | -------------------------------------------------------------------------------- /ASKit/Classes/ASKit.h: -------------------------------------------------------------------------------- 1 | // 2 | // ASKit.h 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 10/27/08. 6 | // Copyright 2008 enormego. All rights reserved. 7 | // 8 | 9 | #import "ASTableViewController.h" 10 | #import "ASTableViewCell.h" 11 | #import "ASInfoCell.h" 12 | #import "ASHeaderView.h" 13 | #import "ASFooterView.h" 14 | #import "ASTableViewCellLabel.h" 15 | #import "ASSectionHeaderView.h" 16 | -------------------------------------------------------------------------------- /ASKit/Classes/ASFooterView.h: -------------------------------------------------------------------------------- 1 | // 2 | // ASFooterCell.h 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 10/27/08. 6 | // Copyright 2008 enormego. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | 12 | @interface ASFooterView : UIView { 13 | @private 14 | UILabel* title; 15 | } 16 | 17 | @property(nonatomic,readonly) UILabel* title; 18 | @property(nonatomic,copy) NSString* text; 19 | @end 20 | -------------------------------------------------------------------------------- /Demo/Classes/Other/main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // ASKitDemo 4 | // 5 | // Created by Shaun Harrison on 1/6/09. 6 | // Copyright enormego 2009. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | int main(int argc, char *argv[]) { 12 | 13 | NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; 14 | int retVal = UIApplicationMain(argc, argv, nil, nil); 15 | [pool release]; 16 | return retVal; 17 | } 18 | -------------------------------------------------------------------------------- /ASKit/Classes/ASTableViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // ASTableViewController.h 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 10/27/08. 6 | // Copyright 2008 enormego. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "ASTableViewCell.h" 11 | 12 | @interface ASTableViewController : UITableViewController { 13 | @private 14 | NSString* footerText; 15 | } 16 | 17 | @property(nonatomic, retain) NSString* footerText; 18 | @end 19 | -------------------------------------------------------------------------------- /ASKit/Classes/ASHeaderView.h: -------------------------------------------------------------------------------- 1 | // 2 | // ASHeaderView.h 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 1/6/09. 6 | // Copyright 2009 enormego. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | 12 | @interface ASHeaderView : UIView { 13 | @private 14 | UIImageView* imageView; 15 | UIView* borderLine; 16 | UIView* contentView; 17 | float height; 18 | } 19 | 20 | @property(nonatomic,assign) float height; 21 | @property(nonatomic,retain) UIView* contentView; 22 | @end 23 | -------------------------------------------------------------------------------- /ASKit/Classes/ASInfoCell.h: -------------------------------------------------------------------------------- 1 | // 2 | // ASInfoCell.h 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 10/27/08. 6 | // Copyright 2008 enormego. All rights reserved. 7 | // 8 | 9 | #import "ASTableViewCell.h" 10 | 11 | 12 | @interface ASInfoCell : ASTableViewCell { 13 | @private 14 | UILabel* title; 15 | UIActivityIndicatorView* activityIndicator; 16 | } 17 | 18 | @property(nonatomic, readonly) UILabel* title; 19 | @property(nonatomic, readonly) UIActivityIndicatorView* activityIndicator; 20 | 21 | @end 22 | -------------------------------------------------------------------------------- /Demo/Classes/Controllers/AppDelegate/AppDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.h 3 | // ASKitDemo 4 | // 5 | // Created by Shaun Harrison on 1/6/09. 6 | // Copyright enormego 2009. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @class TableViewController; 12 | 13 | @interface AppDelegate : NSObject { 14 | UIWindow *window; 15 | TableViewController *viewController; 16 | } 17 | 18 | @property (nonatomic, retain) IBOutlet UIWindow *window; 19 | @property (nonatomic, retain) IBOutlet TableViewController *viewController; 20 | 21 | @end 22 | 23 | -------------------------------------------------------------------------------- /Demo/Classes/Controllers/AppDelegate/AppDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.m 3 | // ASKitDemo 4 | // 5 | // Created by Shaun Harrison on 1/6/09. 6 | // Copyright enormego 2009. All rights reserved. 7 | // 8 | 9 | #import "AppDelegate.h" 10 | #import "TableViewController.h" 11 | 12 | @implementation AppDelegate 13 | 14 | @synthesize window; 15 | @synthesize viewController; 16 | 17 | 18 | - (void)applicationDidFinishLaunching:(UIApplication *)application { 19 | 20 | // Override point for customization after app launch 21 | [window addSubview:viewController.view]; 22 | [window makeKeyAndVisible]; 23 | } 24 | 25 | 26 | - (void)dealloc { 27 | [viewController release]; 28 | [window release]; 29 | [super dealloc]; 30 | } 31 | 32 | 33 | @end 34 | -------------------------------------------------------------------------------- /Demo/Resources/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | English 7 | CFBundleDisplayName 8 | ${PRODUCT_NAME} 9 | CFBundleExecutable 10 | ${EXECUTABLE_NAME} 11 | CFBundleIconFile 12 | 13 | CFBundleIdentifier 14 | com.enormego.${PRODUCT_NAME:identifier} 15 | CFBundleInfoDictionaryVersion 16 | 6.0 17 | CFBundleName 18 | ${PRODUCT_NAME} 19 | CFBundlePackageType 20 | APPL 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1.0 25 | LSRequiresIPhoneOS 26 | 27 | NSMainNibFile 28 | MainWindow 29 | 30 | 31 | -------------------------------------------------------------------------------- /ASKit/Classes/ASTableViewCellLabel.m: -------------------------------------------------------------------------------- 1 | // 2 | // ASTableViewCellLabel.m 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 10/27/08. 6 | // Copyright 2008 enormego. All rights reserved. 7 | // 8 | 9 | #import "ASTableViewCellLabel.h" 10 | 11 | 12 | @implementation ASTableViewCellLabel 13 | 14 | - (id)initWithFrame:(CGRect)frame { 15 | if((self = [super initWithFrame:frame])) { 16 | self.shadowColor = [UIColor colorWithWhite:1.0f alpha:0.52f]; 17 | self.shadowOffset = CGSizeMake(0.0f, 1.0f); 18 | } 19 | 20 | return self; 21 | } 22 | 23 | - (id)initWithCoder:(NSCoder*)aDecoder { 24 | if((self = [super initWithCoder:aDecoder])) { 25 | self.shadowColor = [UIColor colorWithWhite:1.0f alpha:0.52f]; 26 | self.shadowOffset = CGSizeMake(0.0f, 1.0f); 27 | } 28 | 29 | return self; 30 | } 31 | 32 | - (void)setHighlighted:(BOOL)highlighted { 33 | if(highlighted) { 34 | self.shadowColor = [UIColor clearColor]; 35 | } else { 36 | self.shadowColor = [UIColor colorWithWhite:1.0f alpha:0.52f]; 37 | } 38 | 39 | [super setHighlighted:highlighted]; 40 | } 41 | 42 | @end 43 | -------------------------------------------------------------------------------- /ASKit/Classes/ASFooterView.m: -------------------------------------------------------------------------------- 1 | // 2 | // ASFooterCell.m 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 10/27/08. 6 | // Copyright 2008 enormego. All rights reserved. 7 | // 8 | 9 | #import "ASFooterView.h" 10 | #import "ASTableViewCellLabel.h" 11 | 12 | 13 | @implementation ASFooterView 14 | @synthesize title; 15 | 16 | - (id)initWithFrame:(CGRect)frame { 17 | if((self = [super initWithFrame:frame])) { 18 | title = [[ASTableViewCellLabel alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 320.0f, 44.0f)]; 19 | title.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; 20 | title.textAlignment = UITextAlignmentCenter; 21 | title.backgroundColor = [UIColor clearColor]; 22 | title.textColor = [UIColor blackColor]; 23 | title.font = [UIFont boldSystemFontOfSize:12.0f]; 24 | title.highlightedTextColor = [UIColor whiteColor]; 25 | title.shadowColor = [UIColor colorWithWhite:1.0f alpha:0.52f]; 26 | title.shadowOffset = CGSizeMake(0.0f, 1.0f); 27 | [self addSubview:title]; 28 | } 29 | 30 | return self; 31 | } 32 | 33 | - (NSString*)text { 34 | return title.text; 35 | } 36 | 37 | - (void)setText:(NSString*)text { 38 | title.text = text; 39 | } 40 | 41 | - (void)dealloc { 42 | [super dealloc]; 43 | } 44 | 45 | 46 | @end 47 | -------------------------------------------------------------------------------- /ASKit/Classes/ASTableViewCell.h: -------------------------------------------------------------------------------- 1 | // 2 | // ASTableViewCell.h 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 10/27/08. 6 | // Copyright 2008 enormego. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | enum ASTableViewCellType { 12 | ASTableViewCellTypeList=0, // Themed like AppStores Category/App listing cells 13 | ASTableViewCellTypeContent=1, // Themed like AppStores Comment cells 14 | }; // Defaults to ASTableViewCellTypeList 15 | 16 | typedef NSInteger ASTableViewCellType; 17 | 18 | @interface ASTableViewCell : UITableViewCell { 19 | @private 20 | UIView* borderView; 21 | BOOL alternate; 22 | UILabel* label; 23 | ASTableViewCellType type; 24 | } 25 | 26 | - (id)initWithFrame:(CGRect)frame reuseIdentifier:(NSString *)reuseIdentifier type:(ASTableViewCellType)cellType; 27 | 28 | // These return based on ASTableViewCellTypeList 29 | + (UIColor*)regularColor; 30 | + (UIColor*)alternateColor; 31 | + (UIView*)borderView; 32 | + (UIView*)alternateBorderView; 33 | 34 | // These return based on self.type 35 | - (UIColor*)regularColor; 36 | - (UIColor*)alternateColor; 37 | - (UIView*)borderView; 38 | - (UIView*)alternateBorderView; 39 | 40 | @property(nonatomic,getter=isAlternate) BOOL alternate; 41 | @property(readonly) ASTableViewCellType type; 42 | @end 43 | -------------------------------------------------------------------------------- /Demo/Classes/Controllers/TableViewController/TableHeaderView.m: -------------------------------------------------------------------------------- 1 | // 2 | // TableHeaderView.m 3 | // ASKitDemo 4 | // 5 | // Created by Shaun Harrison on 1/6/09. 6 | // Copyright 2009 enormego. All rights reserved. 7 | // 8 | 9 | #import "TableHeaderView.h" 10 | 11 | 12 | @implementation TableHeaderView 13 | 14 | 15 | - (id)initWithFrame:(CGRect)frame { 16 | if (self = [super initWithFrame:frame]) { 17 | UILabel* title = [[UILabel alloc] initWithFrame:CGRectMake(10.0f, 8.0f, 300.0f, 22.0f)]; 18 | title.text = @"My ASTable"; 19 | title.font = [UIFont boldSystemFontOfSize:20.0f]; 20 | title.backgroundColor = [UIColor clearColor]; 21 | title.shadowColor = [UIColor colorWithWhite:1.0f alpha:0.49f]; 22 | title.shadowOffset = CGSizeMake(0.0f, 1.0f); 23 | [self.contentView addSubview:title]; 24 | [title release]; 25 | 26 | UILabel* text = [[UILabel alloc] initWithFrame:CGRectMake(10.0f, 35.0f, 300.0f, 80.0f)]; 27 | text.font = [UIFont systemFontOfSize:13.0f]; 28 | text.backgroundColor = [UIColor clearColor]; 29 | text.numberOfLines = 5; 30 | 31 | text.text = @"Curabitur ligula. Sed nunc quam, vehicula nec, ultrices non, condimentum vitae, metus. Fusce vel ante sed ante ultricies egestas. Vestibulum eget libero. Nullam vel diam. Sed nec mi. Proin lectus augue, lacinia id, blandit sit amet, volutpat at."; 32 | 33 | [self.contentView addSubview:text]; 34 | [text release]; 35 | } 36 | return self; 37 | } 38 | 39 | 40 | - (void)drawRect:(CGRect)rect { 41 | // Drawing code 42 | } 43 | 44 | 45 | - (void)dealloc { 46 | [super dealloc]; 47 | } 48 | 49 | 50 | @end 51 | -------------------------------------------------------------------------------- /ASKit/Classes/ASSectionHeaderView.m: -------------------------------------------------------------------------------- 1 | // 2 | // ASSectionHeaderView.m 3 | // ASKitDemo 4 | // 5 | // Created by Shaun Harrison on 1/6/09. 6 | // Copyright 2009 enormego. All rights reserved. 7 | // 8 | 9 | #import "ASSectionHeaderView.h" 10 | #import "ASTableViewCell.h" 11 | 12 | 13 | @implementation ASSectionHeaderView 14 | 15 | 16 | - (id)initWithFrame:(CGRect)frame { 17 | if (self = [super initWithFrame:frame]) { 18 | title = [[UILabel alloc] initWithFrame:CGRectMake(10.0f, 0.0f, 310.0f, self.frame.size.height-1.0f)]; 19 | title.backgroundColor = [UIColor clearColor]; 20 | title.font = [UIFont boldSystemFontOfSize:17.0f]; 21 | title.shadowColor = [UIColor whiteColor]; 22 | title.shadowOffset = CGSizeMake(0.0f, 1.0f); 23 | title.textColor = [UIColor colorWithWhite:0.1f alpha:1.0f]; 24 | title.autoresizingMask = UIViewAutoresizingFlexibleHeight | UIViewAutoresizingFlexibleWidth; 25 | [self addSubview:title]; 26 | 27 | UIView* border = [[UIView alloc] initWithFrame:CGRectMake(0.0f, self.frame.size.height-1.0f, 320.0f, 1.0f)]; 28 | border.backgroundColor = [UIColor colorWithWhite:1.0f alpha:0.78f]; 29 | border.autoresizingMask = UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleWidth; 30 | [self addSubview:border]; 31 | [border release]; 32 | 33 | self.backgroundColor = [UIColor colorWithWhite:1.0f alpha:0.55f]; 34 | } 35 | return self; 36 | } 37 | 38 | - (void)setText:(NSString*)text { 39 | title.text = text; 40 | } 41 | 42 | - (NSString*)text { 43 | return title.text; 44 | } 45 | 46 | - (void)dealloc { 47 | [title release]; 48 | [super dealloc]; 49 | } 50 | 51 | 52 | @end 53 | -------------------------------------------------------------------------------- /ASKit/Classes/ASHeaderView.m: -------------------------------------------------------------------------------- 1 | // 2 | // ASHeaderView.m 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 1/6/09. 6 | // Copyright 2009 enormego. All rights reserved. 7 | // 8 | 9 | #import "ASHeaderView.h" 10 | #import "ASTableViewCell.h" 11 | 12 | 13 | @implementation ASHeaderView 14 | @synthesize height, contentView; 15 | 16 | - (id)initWithFrame:(CGRect)frame { 17 | if (self = [super initWithFrame:frame]) { 18 | self.height = frame.size.height; 19 | 20 | contentView = [[UIView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, frame.size.width, self.height)]; 21 | contentView.autoresizingMask = UIViewAutoresizingFlexibleTopMargin; 22 | contentView.backgroundColor = [UIColor colorWithRed:0.678431373f green:0.678431373f blue:0.690196078f alpha:1.0f]; 23 | [self addSubview:contentView]; 24 | 25 | imageView = [[UIImageView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, frame.size.width, 86.0f)]; 26 | [self.contentView addSubview:imageView]; 27 | imageView.image = [UIImage imageNamed:@"askit-hdr-bck.png"]; 28 | self.backgroundColor = [UIColor colorWithRed:0.470588235f green:0.470588235f blue:0.482352941 alpha:1.0f]; 29 | 30 | borderLine = [[ASTableViewCell borderView] retain]; 31 | borderLine.frame = CGRectMake(0.0f, self.height-2.0f, frame.size.width, 2.0f); 32 | // borderLine.autoresizingMask = UIViewAutoresizingFlexibleTopMargin; 33 | [self.contentView addSubview:borderLine]; 34 | } 35 | 36 | return self; 37 | } 38 | 39 | 40 | - (void)drawRect:(CGRect)rect { 41 | // Drawing code 42 | } 43 | 44 | 45 | - (void)dealloc { 46 | [contentView release]; 47 | [imageView release]; 48 | [super dealloc]; 49 | } 50 | 51 | 52 | @end 53 | -------------------------------------------------------------------------------- /README.markdown: -------------------------------------------------------------------------------- 1 | # About ASKit 2 | ASKit is an easy to use library for your iPhone applications. ASKit provides AppStore styled table views 3 | 4 | # What you'll find 5 | ## Demo Project 6 | The demo app shows you how to use various parts of ASKit 7 | ## ASKit Overview 8 | * **ASTableViewController:** Instead of subclassing UITableViewController, you'll subclass ASTableViewController. This is where most of the work is done. 9 | * **ASTableViewCell:** This replaces UITableViewCell 10 | * **ASHeaderView:** Provides the gradient header that you can find when viewing a single app in AppStore 11 | * **ASFooterView:** This is the footer that AppStore shows your iTunes account in. 12 | * **ASInfoCell** This extends ASTableViewCell and should be used for various information messages such as "No Items" and "Loading" (it also contains an activity indicator for loading messages 13 | * **ASSectionHeaderView:** This is for table sections, you must return a view when using ASKit and not a string, otherwise it you won't have the correct theme. 14 | * **ASTableViewCellLabel:** Use this instead of UILabel while adding to an ASTableViewCell so the shadows are handled correctly when a cell is selected 15 | 16 | # Additional Information 17 | ## Alternating rows 18 | While ASKit handles just about everything itself, you'll need to set the cell alternate status yourself in order to have alternating rows. 19 | ## Footer 20 | ASTableViewController automatically creates the ASFooterView object for you, all you need to do to change the text while inside your subclass of ASTableViewController is set the footerText property to the desired string. 21 | ## Header 22 | ASTableViewController does *not* automatically create an instance of ASHeaderView for you, you'll need to create it on your own (or subclass it as the example does) and set it via the self.tableView.tableHeaderView property. 23 | # Questions 24 | Feel free to contact info@enormego.com if you need any other help with this framework. 25 | 26 | -------------------------------------------------------------------------------- /ASKit/Classes/ASInfoCell.m: -------------------------------------------------------------------------------- 1 | // 2 | // ASInfoCell.m 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 10/27/08. 6 | // Copyright 2008 enormego. All rights reserved. 7 | // 8 | 9 | #import "ASInfoCell.h" 10 | #import "ASTableViewCellLabel.h" 11 | 12 | 13 | @implementation ASInfoCell 14 | @synthesize title, activityIndicator; 15 | 16 | - (id)initWithFrame:(CGRect)frame reuseIdentifier:(NSString*)reuseIdentifier { 17 | if((self = [super initWithFrame:frame reuseIdentifier:reuseIdentifier])) { 18 | title = [[ASTableViewCellLabel alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 320.0f, 44.0f)]; 19 | title.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; 20 | title.textAlignment = UITextAlignmentCenter; 21 | title.backgroundColor = [UIColor clearColor]; 22 | title.textColor = [UIColor blackColor]; 23 | title.font = [UIFont boldSystemFontOfSize:12.0f]; 24 | title.highlightedTextColor = [UIColor whiteColor]; 25 | title.shadowColor = [UIColor colorWithWhite:1.0f alpha:0.52f]; 26 | title.shadowOffset = CGSizeMake(0.0f, 1.0f); 27 | 28 | activityIndicator = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleGray]; 29 | activityIndicator.frame = CGRectMake(290.0f, 34.0f, 20.0f, 20.0f); 30 | activityIndicator.hidesWhenStopped = YES; 31 | 32 | self.selectionStyle = UITableViewCellSelectionStyleNone; 33 | 34 | [self.contentView addSubview:activityIndicator]; 35 | [self.contentView addSubview:title]; 36 | } 37 | 38 | return self; 39 | } 40 | 41 | - (NSString*)text { 42 | return title.text; 43 | } 44 | 45 | - (void)setText:(NSString*)text { 46 | title.text = text; 47 | } 48 | 49 | - (void)setSelected:(BOOL)selected animated:(BOOL)animated { 50 | 51 | [super setSelected:selected animated:animated]; 52 | 53 | // Configure the view for the selected state 54 | } 55 | 56 | - (UITableViewCellEditingStyle)editingStyle { 57 | return UITableViewCellEditingStyleNone; 58 | } 59 | 60 | - (void)dealloc { 61 | [super dealloc]; 62 | } 63 | 64 | 65 | @end 66 | -------------------------------------------------------------------------------- /Demo/Classes/Controllers/TableViewController/TableViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // TableViewController.m 3 | // ASKitDemo 4 | // 5 | // Created by Shaun Harrison on 1/6/09. 6 | // Copyright 2009 enormego. All rights reserved. 7 | // 8 | 9 | #import "TableViewController.h" 10 | #import "TableHeaderView.h" 11 | 12 | @implementation TableViewController 13 | 14 | - (void)viewDidLoad { 15 | [super viewDidLoad]; 16 | 17 | self.footerText = @"ASKitDemo, enormego.com"; 18 | 19 | TableHeaderView* headerView = [[TableHeaderView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 320.0f, 125.0f)]; 20 | self.tableView.tableHeaderView = headerView; 21 | [headerView release]; 22 | } 23 | 24 | 25 | #pragma mark Table view methods 26 | 27 | - (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView { 28 | return 2; 29 | } 30 | 31 | 32 | // Customize the number of rows in the table view. 33 | - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { 34 | return 4; 35 | } 36 | 37 | 38 | // Customize the appearance of table view cells. 39 | - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { 40 | static NSString *CellIdentifier = @"ASTableViewCell"; 41 | 42 | ASTableViewCell *cell = (ASTableViewCell*)[tableView dequeueReusableCellWithIdentifier:CellIdentifier]; 43 | if (cell == nil) { 44 | cell = [[[ASTableViewCell alloc] initWithFrame:CGRectZero reuseIdentifier:CellIdentifier] autorelease]; 45 | cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator; 46 | } 47 | 48 | // Set up the cell... 49 | cell.text = [NSString stringWithFormat:@"ASTableViewCell: (%d,%d)", indexPath.section, indexPath.row]; 50 | cell.alternate = indexPath.row % 2 == 0; 51 | 52 | return cell; 53 | } 54 | 55 | 56 | - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { 57 | [tableView deselectRowAtIndexPath:indexPath animated:YES]; 58 | } 59 | 60 | - (UIView *)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section { 61 | if(section == 1) { 62 | ASSectionHeaderView* header = [[ASSectionHeaderView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 320.0f, 28.0f)]; 63 | header.text = @"Example Section Header"; 64 | return [header autorelease]; 65 | } else { 66 | return nil; 67 | } 68 | } 69 | 70 | - (void)dealloc { 71 | [super dealloc]; 72 | } 73 | 74 | 75 | @end 76 | 77 | -------------------------------------------------------------------------------- /ASKit/Classes/ASTableViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // ASTableViewController.m 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 10/27/08. 6 | // Copyright 2008 enormego. All rights reserved. 7 | // 8 | 9 | #import "ASTableViewController.h" 10 | #import "ASTableViewCell.h" 11 | #import "ASHeaderView.h" 12 | #import "ASFooterView.h" 13 | 14 | @implementation ASTableViewController 15 | @synthesize footerText; 16 | 17 | - (void)loadView { 18 | [super loadView]; 19 | self.view.backgroundColor = [ASTableViewCell regularColor]; 20 | self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone; 21 | 22 | ASFooterView* footerView = [[ASFooterView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 320.0f, 0.0f)]; 23 | footerView.text = footerText; 24 | self.tableView.tableFooterView = footerView; 25 | [footerView release]; 26 | 27 | UIView* view = [[UIView alloc] initWithFrame:CGRectZero]; 28 | self.tableView.tableHeaderView = view; 29 | [view release]; 30 | } 31 | 32 | - (void)setFooterText:(NSString*)text { 33 | [footerText release], footerText = nil; 34 | footerText = [text retain]; 35 | 36 | ((ASFooterView*)self.tableView.tableFooterView).text = footerText; 37 | } 38 | 39 | - (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView { 40 | return 1; 41 | } 42 | 43 | - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { 44 | return 0; 45 | } 46 | 47 | - (CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section { 48 | return 29.0f; 49 | } 50 | 51 | // Find out if last row is an alternate, and handle background/footerview accordingly 52 | - (void)tableView:(UITableView *)tableView willDisplayCell:(ASTableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath { 53 | if(indexPath.section == [tableView numberOfSections] - 1 && indexPath.row == [tableView numberOfRowsInSection:indexPath.section] - 1) { 54 | if([cell isKindOfClass:[ASTableViewCell class]]) { 55 | self.view.backgroundColor = cell.alternate ? [cell regularColor] : [cell alternateColor]; 56 | ((ASFooterView*)self.tableView.tableFooterView).backgroundColor = self.view.backgroundColor; 57 | } 58 | } 59 | } 60 | 61 | - (void)dealloc { 62 | [footerText release]; 63 | [super dealloc]; 64 | } 65 | 66 | - (void)scrollViewDidScroll:(UIScrollView *)scrollView { 67 | if(scrollView == self.tableView && self.tableView.tableHeaderView) { 68 | ASHeaderView* headerView = (ASHeaderView*)self.tableView.tableHeaderView; 69 | 70 | float y = (-scrollView.contentOffset.y); 71 | CGRect frame; 72 | 73 | if([headerView isKindOfClass:[ASHeaderView class]]) { 74 | float height = y > 0.0f ? y+headerView.height : headerView.height; 75 | frame = CGRectMake(0.0f, y > 0.0f ? -y : 0.0f, self.tableView.frame.size.width, height); 76 | } else if([headerView isKindOfClass:[UIView class]]) { 77 | float height = y > 0.0f ? y : 0.0f; 78 | frame = CGRectMake(0.0f, -y, self.tableView.frame.size.width, height); 79 | if([self.tableView numberOfRowsInSection:0] > 0 && height > 0.0f) { 80 | ASTableViewCell* cell = (ASTableViewCell*)[self.tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]]; 81 | if([cell isKindOfClass:[ASTableViewCell class]]) { 82 | headerView.backgroundColor = cell.backgroundColor; 83 | } 84 | } 85 | } 86 | 87 | headerView.frame = frame; 88 | } 89 | } 90 | 91 | @end 92 | 93 | -------------------------------------------------------------------------------- /ASKit/Classes/ASTableViewCell.m: -------------------------------------------------------------------------------- 1 | // 2 | // ASTableViewCell.m 3 | // ASKit 4 | // 5 | // Created by Shaun Harrison on 10/27/08. 6 | // Copyright 2008 enormego. All rights reserved. 7 | // 8 | 9 | #import "ASTableViewCell.h" 10 | #import "ASTableViewCellLabel.h" 11 | 12 | static UIColor* alternateColorList; 13 | static UIColor* regularColorList; 14 | static UIColor* alternateColorContent; 15 | static UIColor* regularColorContent; 16 | 17 | UIView* borderViewContent() { 18 | UIView* view = [[UIView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 1.0f, 1.0f)]; 19 | view.backgroundColor = [UIColor colorWithRed:0.894117647f green:0.898039216f blue:0.901960784f alpha:1.0f]; 20 | return [view autorelease]; 21 | } 22 | 23 | UIView* borderViewListRegular() { 24 | UIView* view = [[UIView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 1.0f, 2.0f)]; 25 | view.backgroundColor = [UIColor colorWithRed:0.733333333f green:0.733333333f blue:0.741176471f alpha:1.0f]; 26 | UIView* lineView = [[UIView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 1.0f, 1.0f)]; 27 | lineView.autoresizingMask = UIViewAutoresizingFlexibleWidth; 28 | lineView.backgroundColor = [UIColor colorWithRed:0.537254902f green:0.541176471f blue:0.552941176f alpha:1.0f]; 29 | [view addSubview:lineView]; 30 | [lineView release]; 31 | 32 | return [view autorelease]; 33 | } 34 | 35 | UIView* borderViewListAlternate() { 36 | UIView* view = [[UIView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 1.0f, 2.0f)]; 37 | view.backgroundColor = [UIColor colorWithRed:0.654901961f green:0.658823529f blue:0.670588235f alpha:1.0f]; 38 | UIView* lineView = [[UIView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 1.0f, 1.0f)]; 39 | lineView.autoresizingMask = UIViewAutoresizingFlexibleWidth; 40 | lineView.backgroundColor = [UIColor colorWithRed:0.541176471f green:0.541176471f blue:0.552941176f alpha:1.0f]; 41 | [view addSubview:lineView]; 42 | [lineView release]; 43 | 44 | return [view autorelease]; 45 | } 46 | 47 | 48 | @implementation ASTableViewCell 49 | @synthesize alternate, type; 50 | 51 | + (void)initialize { 52 | alternateColorContent = [[UIColor alloc] initWithRed:0.823529412f green:0.835294118f blue:0.839215686f alpha:1.0f]; 53 | regularColorContent = [[UIColor alloc] initWithRed:0.784313725f green:0.792156863f blue:0.8f alpha:1.0f]; 54 | 55 | alternateColorList = [[UIColor alloc] initWithRed:0.678431373f green:0.678431373f blue:0.690196078f alpha:1.0f]; 56 | regularColorList = [[UIColor alloc] initWithRed:0.596078431f green:0.596078431f blue:0.611764706f alpha:1.0f]; 57 | } 58 | 59 | + (UIColor*)regularColor { 60 | return regularColorList; 61 | } 62 | 63 | + (UIColor*)alternateColor { 64 | return alternateColorList; 65 | } 66 | 67 | + (UIView*)borderView { 68 | return borderViewListRegular(); 69 | } 70 | 71 | + (UIView*)alternateBorderView { 72 | return borderViewListAlternate(); 73 | } 74 | 75 | - (UIColor*)regularColor { 76 | return self.type == ASTableViewCellTypeList ? regularColorList : regularColorContent; 77 | } 78 | 79 | - (UIColor*)alternateColor { 80 | return self.type == ASTableViewCellTypeList ? alternateColorList : alternateColorContent; 81 | } 82 | 83 | - (UIView*)borderView { 84 | return self.type == ASTableViewCellTypeList ? borderViewListRegular() : borderViewContent(); 85 | } 86 | 87 | - (UIView*)alternateBorderView { 88 | return self.type == ASTableViewCellTypeList ? borderViewListAlternate() : borderViewContent(); 89 | } 90 | 91 | - (id)initWithFrame:(CGRect)frame reuseIdentifier:(NSString *)reuseIdentifier { 92 | return [self initWithFrame:frame reuseIdentifier:reuseIdentifier type:ASTableViewCellTypeList]; 93 | } 94 | 95 | - (id)initWithFrame:(CGRect)frame reuseIdentifier:(NSString *)reuseIdentifier type:(ASTableViewCellType)cellType { 96 | if((self = [super initWithFrame:frame reuseIdentifier:reuseIdentifier])) { 97 | type = cellType == ASTableViewCellTypeList ? ASTableViewCellTypeList : ASTableViewCellTypeContent; 98 | 99 | label = [(type == ASTableViewCellTypeList ? [ASTableViewCellLabel alloc] : [UILabel alloc]) initWithFrame:CGRectMake(10.0f, 0.0f, 300.0f, 44.0f)]; 100 | 101 | label.backgroundColor = [UIColor clearColor]; 102 | label.font = [UIFont boldSystemFontOfSize:20.0f]; 103 | label.textColor = [UIColor blackColor]; 104 | label.highlightedTextColor = [UIColor whiteColor]; 105 | label.autoresizingMask = UIViewAutoresizingFlexibleWidth; 106 | [self.contentView addSubview:label]; 107 | 108 | borderView = [[self borderView] retain]; 109 | borderView.frame = CGRectMake(0.0f, self.frame.size.height-borderView.frame.size.height, self.frame.size.width, borderView.frame.size.height); 110 | borderView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleTopMargin; 111 | [self addSubview:borderView]; 112 | } 113 | 114 | return self; 115 | } 116 | 117 | - (NSString*)text { 118 | return label.text; 119 | } 120 | 121 | - (void)setText:(NSString*)text { 122 | label.text = text; 123 | } 124 | 125 | - (void)setAlternate:(BOOL)isAlternate { 126 | if(alternate == isAlternate) return; 127 | alternate = isAlternate; 128 | 129 | if(self.type == ASTableViewCellTypeList) { 130 | [borderView removeFromSuperview]; 131 | [borderView release], borderView = nil; 132 | 133 | borderView = self.alternate ? [[self alternateBorderView] retain] : [[self borderView] retain]; 134 | borderView.frame = CGRectMake(0.0f, self.frame.size.height-borderView.frame.size.height, self.frame.size.width, borderView.frame.size.height); 135 | borderView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleTopMargin; 136 | [self addSubview:borderView]; 137 | } 138 | } 139 | 140 | - (void)layoutSubviews { 141 | [super layoutSubviews]; 142 | 143 | if([self.subviews objectAtIndex:self.subviews.count-1] != borderView) { 144 | [borderView removeFromSuperview]; 145 | [self addSubview:borderView]; 146 | } 147 | 148 | self.backgroundColor = alternate ? [self alternateColor] : [self regularColor]; 149 | } 150 | 151 | - (void)dealloc { 152 | [label release]; 153 | [borderView release]; 154 | [super dealloc]; 155 | } 156 | 157 | @end 158 | -------------------------------------------------------------------------------- /Demo/Views/MainWindow.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 528 5 | 9F33 6 | 677 7 | 949.34 8 | 352.00 9 | 10 | YES 11 | 12 | 13 | 14 | YES 15 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 16 | 17 | 18 | YES 19 | 20 | YES 21 | 22 | 23 | YES 24 | 25 | 26 | 27 | YES 28 | 29 | IBFilesOwner 30 | 31 | 32 | IBFirstResponder 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 292 41 | {320, 480} 42 | 43 | 1 44 | MSAxIDEAA 45 | 46 | NO 47 | NO 48 | 49 | 50 | 51 | 52 | 53 | YES 54 | 55 | 56 | delegate 57 | 58 | 59 | 60 | 4 61 | 62 | 63 | 64 | window 65 | 66 | 67 | 68 | 14 69 | 70 | 71 | 72 | viewController 73 | 74 | 75 | 76 | 15 77 | 78 | 79 | 80 | 81 | YES 82 | 83 | 0 84 | 85 | YES 86 | 87 | 88 | 89 | 90 | 91 | -1 92 | 93 | 94 | RmlsZSdzIE93bmVyA 95 | 96 | 97 | 3 98 | 99 | 100 | ASKit App Delegate 101 | 102 | 103 | -2 104 | 105 | 106 | 107 | 108 | 10 109 | 110 | 111 | 112 | 113 | 12 114 | 115 | 116 | 117 | 118 | 119 | 120 | YES 121 | 122 | YES 123 | -1.CustomClassName 124 | -2.CustomClassName 125 | 10.CustomClassName 126 | 10.IBEditorWindowLastContentRect 127 | 10.IBPluginDependency 128 | 12.IBEditorWindowLastContentRect 129 | 12.IBPluginDependency 130 | 3.CustomClassName 131 | 3.IBPluginDependency 132 | 133 | 134 | YES 135 | UIApplication 136 | UIResponder 137 | TableViewController 138 | {{155, 203}, {320, 480}} 139 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 140 | {{525, 346}, {320, 480}} 141 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 142 | AppDelegate 143 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 144 | 145 | 146 | 147 | YES 148 | 149 | YES 150 | 151 | 152 | YES 153 | 154 | 155 | 156 | 157 | YES 158 | 159 | YES 160 | 161 | 162 | YES 163 | 164 | 165 | 166 | 15 167 | 168 | 169 | 170 | YES 171 | 172 | ASTableViewController 173 | UITableViewController 174 | 175 | IBProjectSource 176 | ../ASKit/Classes/ASTableViewController.h 177 | 178 | 179 | 180 | AppDelegate 181 | NSObject 182 | 183 | YES 184 | 185 | YES 186 | viewController 187 | window 188 | 189 | 190 | YES 191 | TableViewController 192 | UIWindow 193 | 194 | 195 | 196 | IBProjectSource 197 | Classes/Controllers/AppDelegate/AppDelegate.h 198 | 199 | 200 | 201 | TableViewController 202 | ASTableViewController 203 | 204 | IBProjectSource 205 | Classes/Controllers/TableViewController/TableViewController.h 206 | 207 | 208 | 209 | 210 | 0 211 | ../ASKitDemo.xcodeproj 212 | 3 213 | 214 | 215 | -------------------------------------------------------------------------------- /Demo/ASKitDemo.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 45; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 1D60589F0D05DD5A006BFB54 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1D30AB110D05D00D00671497 /* Foundation.framework */; }; 11 | 1DF5F4E00D08C38300B7A737 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */; }; 12 | 283F8E500F13A75900AD4AF9 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 283F8E4D0F13A75900AD4AF9 /* main.m */; }; 13 | 283F8E590F13A77200AD4AF9 /* MainWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 283F8E570F13A77200AD4AF9 /* MainWindow.xib */; }; 14 | 283F8E870F13A96F00AD4AF9 /* ASFooterView.m in Sources */ = {isa = PBXBuildFile; fileRef = 283F8E7C0F13A96F00AD4AF9 /* ASFooterView.m */; }; 15 | 283F8E880F13A96F00AD4AF9 /* ASInfoCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 283F8E7E0F13A96F00AD4AF9 /* ASInfoCell.m */; }; 16 | 283F8E890F13A96F00AD4AF9 /* ASTableViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 283F8E810F13A96F00AD4AF9 /* ASTableViewCell.m */; }; 17 | 283F8E8A0F13A96F00AD4AF9 /* ASTableViewCellLabel.m in Sources */ = {isa = PBXBuildFile; fileRef = 283F8E830F13A96F00AD4AF9 /* ASTableViewCellLabel.m */; }; 18 | 283F8E8B0F13A96F00AD4AF9 /* ASTableViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 283F8E850F13A96F00AD4AF9 /* ASTableViewController.m */; }; 19 | 283F8E8F0F13AB2A00AD4AF9 /* ASHeaderView.m in Sources */ = {isa = PBXBuildFile; fileRef = 283F8E8E0F13AB2A00AD4AF9 /* ASHeaderView.m */; }; 20 | 286060CF0F13EB64002FD6CC /* ASSectionHeaderView.m in Sources */ = {isa = PBXBuildFile; fileRef = 286060CE0F13EB64002FD6CC /* ASSectionHeaderView.m */; }; 21 | 288765A50DF7441C002DB57D /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 288765A40DF7441C002DB57D /* CoreGraphics.framework */; }; 22 | 28A85B7B0F13AD7D00417936 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 28A85B770F13AD7D00417936 /* AppDelegate.m */; }; 23 | 28A85BA50F13AF1200417936 /* TableViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 28A85BA40F13AF1200417936 /* TableViewController.m */; }; 24 | 28A85C580F13C48C00417936 /* askit-hdr-bck.png in Resources */ = {isa = PBXBuildFile; fileRef = 28A85C570F13C48C00417936 /* askit-hdr-bck.png */; }; 25 | 28A85E4E0F13E12A00417936 /* TableHeaderView.m in Sources */ = {isa = PBXBuildFile; fileRef = 28A85E4D0F13E12A00417936 /* TableHeaderView.m */; }; 26 | /* End PBXBuildFile section */ 27 | 28 | /* Begin PBXFileReference section */ 29 | 1D30AB110D05D00D00671497 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; 30 | 1D6058910D05DD3D006BFB54 /* ASKitDemo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = ASKitDemo.app; sourceTree = BUILT_PRODUCTS_DIR; }; 31 | 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; 32 | 283F8E4C0F13A75900AD4AF9 /* ASKitDemo_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ASKitDemo_Prefix.pch; sourceTree = ""; }; 33 | 283F8E4D0F13A75900AD4AF9 /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 34 | 283F8E530F13A76C00AD4AF9 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 35 | 283F8E570F13A77200AD4AF9 /* MainWindow.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = MainWindow.xib; sourceTree = ""; }; 36 | 283F8E7B0F13A96F00AD4AF9 /* ASFooterView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ASFooterView.h; sourceTree = ""; }; 37 | 283F8E7C0F13A96F00AD4AF9 /* ASFooterView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ASFooterView.m; sourceTree = ""; }; 38 | 283F8E7D0F13A96F00AD4AF9 /* ASInfoCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ASInfoCell.h; sourceTree = ""; }; 39 | 283F8E7E0F13A96F00AD4AF9 /* ASInfoCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ASInfoCell.m; sourceTree = ""; }; 40 | 283F8E7F0F13A96F00AD4AF9 /* ASKit.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ASKit.h; sourceTree = ""; }; 41 | 283F8E800F13A96F00AD4AF9 /* ASTableViewCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ASTableViewCell.h; sourceTree = ""; }; 42 | 283F8E810F13A96F00AD4AF9 /* ASTableViewCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ASTableViewCell.m; sourceTree = ""; }; 43 | 283F8E820F13A96F00AD4AF9 /* ASTableViewCellLabel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ASTableViewCellLabel.h; sourceTree = ""; }; 44 | 283F8E830F13A96F00AD4AF9 /* ASTableViewCellLabel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ASTableViewCellLabel.m; sourceTree = ""; }; 45 | 283F8E840F13A96F00AD4AF9 /* ASTableViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ASTableViewController.h; sourceTree = ""; }; 46 | 283F8E850F13A96F00AD4AF9 /* ASTableViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ASTableViewController.m; sourceTree = ""; }; 47 | 283F8E8D0F13AB2A00AD4AF9 /* ASHeaderView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ASHeaderView.h; sourceTree = ""; }; 48 | 283F8E8E0F13AB2A00AD4AF9 /* ASHeaderView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ASHeaderView.m; sourceTree = ""; }; 49 | 286060CD0F13EB64002FD6CC /* ASSectionHeaderView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ASSectionHeaderView.h; sourceTree = ""; }; 50 | 286060CE0F13EB64002FD6CC /* ASSectionHeaderView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ASSectionHeaderView.m; sourceTree = ""; }; 51 | 288765A40DF7441C002DB57D /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 52 | 28A85B760F13AD7D00417936 /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; 53 | 28A85B770F13AD7D00417936 /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; 54 | 28A85BA30F13AF1200417936 /* TableViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TableViewController.h; sourceTree = ""; }; 55 | 28A85BA40F13AF1200417936 /* TableViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TableViewController.m; sourceTree = ""; }; 56 | 28A85C570F13C48C00417936 /* askit-hdr-bck.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "askit-hdr-bck.png"; sourceTree = ""; }; 57 | 28A85E4C0F13E12A00417936 /* TableHeaderView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TableHeaderView.h; sourceTree = ""; }; 58 | 28A85E4D0F13E12A00417936 /* TableHeaderView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TableHeaderView.m; sourceTree = ""; }; 59 | /* End PBXFileReference section */ 60 | 61 | /* Begin PBXFrameworksBuildPhase section */ 62 | 1D60588F0D05DD3D006BFB54 /* Frameworks */ = { 63 | isa = PBXFrameworksBuildPhase; 64 | buildActionMask = 2147483647; 65 | files = ( 66 | 1D60589F0D05DD5A006BFB54 /* Foundation.framework in Frameworks */, 67 | 1DF5F4E00D08C38300B7A737 /* UIKit.framework in Frameworks */, 68 | 288765A50DF7441C002DB57D /* CoreGraphics.framework in Frameworks */, 69 | ); 70 | runOnlyForDeploymentPostprocessing = 0; 71 | }; 72 | /* End PBXFrameworksBuildPhase section */ 73 | 74 | /* Begin PBXGroup section */ 75 | 19C28FACFE9D520D11CA2CBB /* Products */ = { 76 | isa = PBXGroup; 77 | children = ( 78 | 1D6058910D05DD3D006BFB54 /* ASKitDemo.app */, 79 | ); 80 | name = Products; 81 | sourceTree = ""; 82 | }; 83 | 283F8E430F13A75900AD4AF9 /* Classes */ = { 84 | isa = PBXGroup; 85 | children = ( 86 | 28A85B740F13AD7D00417936 /* Controllers */, 87 | 283F8E6C0F13A8D500AD4AF9 /* Classes */, 88 | 283F8E4B0F13A75900AD4AF9 /* Other */, 89 | ); 90 | path = Classes; 91 | sourceTree = ""; 92 | }; 93 | 283F8E4B0F13A75900AD4AF9 /* Other */ = { 94 | isa = PBXGroup; 95 | children = ( 96 | 283F8E4C0F13A75900AD4AF9 /* ASKitDemo_Prefix.pch */, 97 | 283F8E4D0F13A75900AD4AF9 /* main.m */, 98 | ); 99 | path = Other; 100 | sourceTree = ""; 101 | }; 102 | 283F8E520F13A76C00AD4AF9 /* Resources */ = { 103 | isa = PBXGroup; 104 | children = ( 105 | 283F8E530F13A76C00AD4AF9 /* Info.plist */, 106 | ); 107 | path = Resources; 108 | sourceTree = ""; 109 | }; 110 | 283F8E550F13A77200AD4AF9 /* Views */ = { 111 | isa = PBXGroup; 112 | children = ( 113 | 283F8E570F13A77200AD4AF9 /* MainWindow.xib */, 114 | ); 115 | path = Views; 116 | sourceTree = ""; 117 | }; 118 | 283F8E6C0F13A8D500AD4AF9 /* Classes */ = { 119 | isa = PBXGroup; 120 | children = ( 121 | 283F8E790F13A96F00AD4AF9 /* ASKit */, 122 | ); 123 | name = Classes; 124 | sourceTree = ""; 125 | }; 126 | 283F8E790F13A96F00AD4AF9 /* ASKit */ = { 127 | isa = PBXGroup; 128 | children = ( 129 | 283F8E7A0F13A96F00AD4AF9 /* Classes */, 130 | 283F8E860F13A96F00AD4AF9 /* Resources */, 131 | ); 132 | name = ASKit; 133 | path = ../ASKit; 134 | sourceTree = SOURCE_ROOT; 135 | }; 136 | 283F8E7A0F13A96F00AD4AF9 /* Classes */ = { 137 | isa = PBXGroup; 138 | children = ( 139 | 283F8E7F0F13A96F00AD4AF9 /* ASKit.h */, 140 | 283F8E7D0F13A96F00AD4AF9 /* ASInfoCell.h */, 141 | 283F8E7E0F13A96F00AD4AF9 /* ASInfoCell.m */, 142 | 283F8E7B0F13A96F00AD4AF9 /* ASFooterView.h */, 143 | 283F8E7C0F13A96F00AD4AF9 /* ASFooterView.m */, 144 | 283F8E8D0F13AB2A00AD4AF9 /* ASHeaderView.h */, 145 | 283F8E8E0F13AB2A00AD4AF9 /* ASHeaderView.m */, 146 | 283F8E800F13A96F00AD4AF9 /* ASTableViewCell.h */, 147 | 283F8E810F13A96F00AD4AF9 /* ASTableViewCell.m */, 148 | 286060CD0F13EB64002FD6CC /* ASSectionHeaderView.h */, 149 | 286060CE0F13EB64002FD6CC /* ASSectionHeaderView.m */, 150 | 283F8E820F13A96F00AD4AF9 /* ASTableViewCellLabel.h */, 151 | 283F8E830F13A96F00AD4AF9 /* ASTableViewCellLabel.m */, 152 | 283F8E840F13A96F00AD4AF9 /* ASTableViewController.h */, 153 | 283F8E850F13A96F00AD4AF9 /* ASTableViewController.m */, 154 | ); 155 | path = Classes; 156 | sourceTree = ""; 157 | }; 158 | 283F8E860F13A96F00AD4AF9 /* Resources */ = { 159 | isa = PBXGroup; 160 | children = ( 161 | 28A85C570F13C48C00417936 /* askit-hdr-bck.png */, 162 | ); 163 | path = Resources; 164 | sourceTree = ""; 165 | }; 166 | 28A85B740F13AD7D00417936 /* Controllers */ = { 167 | isa = PBXGroup; 168 | children = ( 169 | 28A85B750F13AD7D00417936 /* AppDelegate */, 170 | 28A85B780F13AD7D00417936 /* TableViewController */, 171 | ); 172 | path = Controllers; 173 | sourceTree = ""; 174 | }; 175 | 28A85B750F13AD7D00417936 /* AppDelegate */ = { 176 | isa = PBXGroup; 177 | children = ( 178 | 28A85B760F13AD7D00417936 /* AppDelegate.h */, 179 | 28A85B770F13AD7D00417936 /* AppDelegate.m */, 180 | ); 181 | path = AppDelegate; 182 | sourceTree = ""; 183 | }; 184 | 28A85B780F13AD7D00417936 /* TableViewController */ = { 185 | isa = PBXGroup; 186 | children = ( 187 | 28A85BA30F13AF1200417936 /* TableViewController.h */, 188 | 28A85BA40F13AF1200417936 /* TableViewController.m */, 189 | 28A85E4C0F13E12A00417936 /* TableHeaderView.h */, 190 | 28A85E4D0F13E12A00417936 /* TableHeaderView.m */, 191 | ); 192 | path = TableViewController; 193 | sourceTree = ""; 194 | }; 195 | 29B97314FDCFA39411CA2CEA /* CustomTemplate */ = { 196 | isa = PBXGroup; 197 | children = ( 198 | 283F8E430F13A75900AD4AF9 /* Classes */, 199 | 283F8E550F13A77200AD4AF9 /* Views */, 200 | 283F8E520F13A76C00AD4AF9 /* Resources */, 201 | 29B97323FDCFA39411CA2CEA /* Linked Frameworks */, 202 | 19C28FACFE9D520D11CA2CBB /* Products */, 203 | ); 204 | name = CustomTemplate; 205 | sourceTree = ""; 206 | }; 207 | 29B97323FDCFA39411CA2CEA /* Linked Frameworks */ = { 208 | isa = PBXGroup; 209 | children = ( 210 | 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */, 211 | 1D30AB110D05D00D00671497 /* Foundation.framework */, 212 | 288765A40DF7441C002DB57D /* CoreGraphics.framework */, 213 | ); 214 | name = "Linked Frameworks"; 215 | sourceTree = ""; 216 | }; 217 | /* End PBXGroup section */ 218 | 219 | /* Begin PBXNativeTarget section */ 220 | 1D6058900D05DD3D006BFB54 /* ASKitDemo */ = { 221 | isa = PBXNativeTarget; 222 | buildConfigurationList = 1D6058960D05DD3E006BFB54 /* Build configuration list for PBXNativeTarget "ASKitDemo" */; 223 | buildPhases = ( 224 | 1D60588D0D05DD3D006BFB54 /* Resources */, 225 | 1D60588E0D05DD3D006BFB54 /* Sources */, 226 | 1D60588F0D05DD3D006BFB54 /* Frameworks */, 227 | ); 228 | buildRules = ( 229 | ); 230 | dependencies = ( 231 | ); 232 | name = ASKitDemo; 233 | productName = ASKitDemo; 234 | productReference = 1D6058910D05DD3D006BFB54 /* ASKitDemo.app */; 235 | productType = "com.apple.product-type.application"; 236 | }; 237 | /* End PBXNativeTarget section */ 238 | 239 | /* Begin PBXProject section */ 240 | 29B97313FDCFA39411CA2CEA /* Project object */ = { 241 | isa = PBXProject; 242 | buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "ASKitDemo" */; 243 | compatibilityVersion = "Xcode 3.1"; 244 | hasScannedForEncodings = 1; 245 | mainGroup = 29B97314FDCFA39411CA2CEA /* CustomTemplate */; 246 | projectDirPath = ""; 247 | projectRoot = ""; 248 | targets = ( 249 | 1D6058900D05DD3D006BFB54 /* ASKitDemo */, 250 | ); 251 | }; 252 | /* End PBXProject section */ 253 | 254 | /* Begin PBXResourcesBuildPhase section */ 255 | 1D60588D0D05DD3D006BFB54 /* Resources */ = { 256 | isa = PBXResourcesBuildPhase; 257 | buildActionMask = 2147483647; 258 | files = ( 259 | 283F8E590F13A77200AD4AF9 /* MainWindow.xib in Resources */, 260 | 28A85C580F13C48C00417936 /* askit-hdr-bck.png in Resources */, 261 | ); 262 | runOnlyForDeploymentPostprocessing = 0; 263 | }; 264 | /* End PBXResourcesBuildPhase section */ 265 | 266 | /* Begin PBXSourcesBuildPhase section */ 267 | 1D60588E0D05DD3D006BFB54 /* Sources */ = { 268 | isa = PBXSourcesBuildPhase; 269 | buildActionMask = 2147483647; 270 | files = ( 271 | 283F8E500F13A75900AD4AF9 /* main.m in Sources */, 272 | 283F8E870F13A96F00AD4AF9 /* ASFooterView.m in Sources */, 273 | 283F8E880F13A96F00AD4AF9 /* ASInfoCell.m in Sources */, 274 | 283F8E890F13A96F00AD4AF9 /* ASTableViewCell.m in Sources */, 275 | 283F8E8A0F13A96F00AD4AF9 /* ASTableViewCellLabel.m in Sources */, 276 | 283F8E8B0F13A96F00AD4AF9 /* ASTableViewController.m in Sources */, 277 | 283F8E8F0F13AB2A00AD4AF9 /* ASHeaderView.m in Sources */, 278 | 28A85B7B0F13AD7D00417936 /* AppDelegate.m in Sources */, 279 | 28A85BA50F13AF1200417936 /* TableViewController.m in Sources */, 280 | 28A85E4E0F13E12A00417936 /* TableHeaderView.m in Sources */, 281 | 286060CF0F13EB64002FD6CC /* ASSectionHeaderView.m in Sources */, 282 | ); 283 | runOnlyForDeploymentPostprocessing = 0; 284 | }; 285 | /* End PBXSourcesBuildPhase section */ 286 | 287 | /* Begin XCBuildConfiguration section */ 288 | 1D6058940D05DD3E006BFB54 /* Debug */ = { 289 | isa = XCBuildConfiguration; 290 | buildSettings = { 291 | ALWAYS_SEARCH_USER_PATHS = NO; 292 | COPY_PHASE_STRIP = NO; 293 | GCC_DYNAMIC_NO_PIC = NO; 294 | GCC_OPTIMIZATION_LEVEL = 0; 295 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 296 | GCC_PREFIX_HEADER = Classes/Other/ASKitDemo_Prefix.pch; 297 | INFOPLIST_FILE = Resources/Info.plist; 298 | PRODUCT_NAME = ASKitDemo; 299 | }; 300 | name = Debug; 301 | }; 302 | 1D6058950D05DD3E006BFB54 /* Release */ = { 303 | isa = XCBuildConfiguration; 304 | buildSettings = { 305 | ALWAYS_SEARCH_USER_PATHS = NO; 306 | COPY_PHASE_STRIP = YES; 307 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 308 | GCC_PREFIX_HEADER = Classes/Other/ASKitDemo_Prefix.pch; 309 | INFOPLIST_FILE = Resources/Info.plist; 310 | PRODUCT_NAME = ASKitDemo; 311 | }; 312 | name = Release; 313 | }; 314 | C01FCF4F08A954540054247B /* Debug */ = { 315 | isa = XCBuildConfiguration; 316 | buildSettings = { 317 | ARCHS = "$(ARCHS_STANDARD_32_BIT)"; 318 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 319 | GCC_C_LANGUAGE_STANDARD = c99; 320 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 321 | GCC_WARN_UNUSED_VARIABLE = YES; 322 | ONLY_ACTIVE_ARCH = YES; 323 | PREBINDING = NO; 324 | SDKROOT = iphonesimulator2.2; 325 | }; 326 | name = Debug; 327 | }; 328 | C01FCF5008A954540054247B /* Release */ = { 329 | isa = XCBuildConfiguration; 330 | buildSettings = { 331 | ARCHS = "$(ARCHS_STANDARD_32_BIT)"; 332 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 333 | GCC_C_LANGUAGE_STANDARD = c99; 334 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 335 | GCC_WARN_UNUSED_VARIABLE = YES; 336 | PREBINDING = NO; 337 | SDKROOT = iphonesimulator2.2; 338 | }; 339 | name = Release; 340 | }; 341 | /* End XCBuildConfiguration section */ 342 | 343 | /* Begin XCConfigurationList section */ 344 | 1D6058960D05DD3E006BFB54 /* Build configuration list for PBXNativeTarget "ASKitDemo" */ = { 345 | isa = XCConfigurationList; 346 | buildConfigurations = ( 347 | 1D6058940D05DD3E006BFB54 /* Debug */, 348 | 1D6058950D05DD3E006BFB54 /* Release */, 349 | ); 350 | defaultConfigurationIsVisible = 0; 351 | defaultConfigurationName = Release; 352 | }; 353 | C01FCF4E08A954540054247B /* Build configuration list for PBXProject "ASKitDemo" */ = { 354 | isa = XCConfigurationList; 355 | buildConfigurations = ( 356 | C01FCF4F08A954540054247B /* Debug */, 357 | C01FCF5008A954540054247B /* Release */, 358 | ); 359 | defaultConfigurationIsVisible = 0; 360 | defaultConfigurationName = Release; 361 | }; 362 | /* End XCConfigurationList section */ 363 | }; 364 | rootObject = 29B97313FDCFA39411CA2CEA /* Project object */; 365 | } 366 | --------------------------------------------------------------------------------