Permalink
Browse files

* Fixed bug @1026: Rename T3* to TT*

  • Loading branch information...
1 parent 9625aaf commit 6394c48dd11728098c559f787ce6bf4d85b85232 @joehewitt joehewitt committed Feb 16, 2009
Showing with 1,707 additions and 1,707 deletions.
  1. 0 resources/{t3images → ttimages}/badge.png
  2. 0 resources/{t3images → ttimages}/darkTab.png
  3. 0 resources/{t3images → ttimages}/lightTab.png
  4. 0 resources/{t3images → ttimages}/nextIcon.png
  5. 0 resources/{t3images → ttimages}/overflowLeft.png
  6. 0 resources/{t3images → ttimages}/overflowRight.png
  7. 0 resources/{t3images → ttimages}/photoDefault.png
  8. 0 resources/{t3images → ttimages}/previousIcon.png
  9. 0 resources/{t3images → ttimages}/tabButton.png
  10. +2 −2 samples/T3Catalog/Classes/ImageTableViewCell.h
  11. +1 −1 samples/T3Catalog/Classes/ImageTableViewCell.m
  12. +1 −1 samples/T3Catalog/Classes/ImageTest1Controller.m
  13. +1 −1 samples/T3Catalog/Classes/ImageTest2Controller.h
  14. +5 −5 samples/T3Catalog/Classes/MockPhotoSource.h
  15. +29 −29 samples/T3Catalog/Classes/MockPhotoSource.m
  16. +1 −1 samples/T3Catalog/Classes/PhotoTest1Controller.h
  17. +1 −1 samples/T3Catalog/Classes/PhotoTest2Controller.h
  18. +1 −1 samples/T3Catalog/Classes/RootViewController.h
  19. +26 −26 samples/T3Catalog/Classes/RootViewController.m
  20. +3 −3 samples/T3Catalog/Classes/ScrollViewTestController.h
  21. +10 −10 samples/T3Catalog/Classes/ScrollViewTestController.m
  22. +1 −1 samples/T3Catalog/Classes/{T3CatalogAppDelegate.h → TTCatalogAppDelegate.h}
  23. +2 −2 samples/T3Catalog/Classes/{T3CatalogAppDelegate.m → TTCatalogAppDelegate.m}
  24. +4 −4 samples/T3Catalog/Classes/TabBarTestController.h
  25. +24 −24 samples/T3Catalog/Classes/TabBarTestController.m
  26. +1 −1 samples/T3Catalog/Classes/TableFieldTestController.h
  27. +23 −23 samples/T3Catalog/Classes/TableFieldTestController.m
  28. +9 −9 samples/T3Catalog/Classes/TextEditTestController.m
  29. +1 −1 samples/T3Catalog/Classes/TextTest1Controller.m
  30. +2 −2 samples/T3Catalog/Classes/YouTubeTestController.h
  31. +1 −1 samples/T3Catalog/Classes/YouTubeTestController.m
  32. +10 −10 samples/T3Catalog/T3Catalog.xcodeproj/project.pbxproj
  33. +1 −1 samples/T3Catalog/T3Catalog_Prefix.pch
  34. +9 −9 src/{T3+UIViewController.m → TT+UIViewController.m}
  35. +18 −18 src/{T3ActivityLabel.m → TTActivityLabel.m}
  36. +23 −23 src/{T3Appearance.m → TTAppearance.m}
  37. +5 −5 src/{T3BackgroundView.m → TTBackgroundView.m}
  38. +36 −36 src/{T3DataSource.m → TTDataSource.m}
  39. +2 −2 src/{T3ErrorView.m → TTErrorView.m}
  40. +22 −22 src/{T3Global.m → TTGlobal.m}
  41. +8 −8 src/{T3ImageView.m → TTImageView.m}
  42. +7 −7 src/{T3LinkView.m → TTLinkView.m}
  43. +12 −12 src/{T3MenuTextField.m → TTMenuTextField.m}
  44. +7 −7 src/{T3MenuViewCell.m → TTMenuViewCell.m}
  45. +51 −51 src/{T3NavigationCenter.m → TTNavigationCenter.m}
  46. +21 −21 src/{T3PhotoView.m → TTPhotoView.m}
  47. +84 −84 src/{T3PhotoViewController.m → TTPhotoViewController.m}
  48. +9 −9 src/{T3ScrollView.m → TTScrollView.m}
  49. +14 −14 src/{T3SearchTextField.m → TTSearchTextField.m}
  50. +2 −2 src/{T3ShinyLabel.m → TTShinyLabel.m}
  51. +47 −47 src/{T3TabBar.m → TTTabBar.m}
  52. +18 −18 src/{T3TableField.m → TTTableField.m}
  53. +82 −82 src/{T3TableFieldCell.m → TTTableFieldCell.m}
  54. +2 −2 src/{T3TableViewCell.m → TTTableViewCell.m}
  55. +24 −24 src/{T3TableViewController.m → TTTableViewController.m}
  56. +7 −7 src/{T3ThumbView.m → TTThumbView.m}
  57. +15 −15 src/{T3ThumbsTableViewCell.m → TTThumbsTableViewCell.m}
  58. +52 −52 src/{T3ThumbsViewController.m → TTThumbsViewController.m}
  59. +10 −10 src/{T3URLCache.m → TTURLCache.m}
  60. +13 −13 src/{T3URLRequest.m → TTURLRequest.m}
  61. +62 −62 src/{T3URLRequestQueue.m → TTURLRequestQueue.m}
  62. +2 −2 src/{T3UnclippedView.m → TTUnclippedView.m}
  63. +37 −37 src/{T3ViewController.m → TTViewController.m}
  64. +2 −2 src/{T3YouTubeView.m → TTYouTubeView.m}
  65. +256 −256 src/Three20.xcodeproj/project.pbxproj
  66. +0 −31 src/Three20/T3ActivityLabel.h
  67. +0 −32 src/Three20/T3ImageView.h
  68. +0 −20 src/Three20/T3Object.h
  69. +0 −33 src/Three20/T3SearchTextField.h
  70. +0 −77 src/Three20/T3TableFieldCell.h
  71. +0 −13 src/Three20/T3TableViewController.h
  72. +0 −15 src/Three20/T3ThumbView.h
  73. +0 −26 src/Three20/T3ThumbsTableViewCell.h
  74. +0 −29 src/Three20/T3ThumbsViewController.h
  75. +2 −2 src/Three20/{T3+UIViewController.h → TT+UIViewController.h}
  76. +31 −0 src/Three20/TTActivityLabel.h
  77. +18 −18 src/Three20/{T3Appearance.h → TTAppearance.h}
  78. +4 −4 src/Three20/{T3BackgroundView.h → TTBackgroundView.h}
  79. +8 −8 src/Three20/{T3DataSource.h → TTDataSource.h}
  80. +2 −2 src/Three20/{T3ErrorView.h → TTErrorView.h}
  81. +32 −32 src/Three20/{T3Global.h → TTGlobal.h}
  82. +32 −0 src/Three20/TTImageView.h
  83. +4 −4 src/Three20/{T3LinkView.h → TTLinkView.h}
  84. +8 −8 src/Three20/{T3MenuTextField.h → TTMenuTextField.h}
  85. +2 −2 src/Three20/{T3MenuViewCell.h → TTMenuViewCell.h}
  86. +30 −30 src/Three20/{T3NavigationCenter.h → TTNavigationCenter.h}
  87. +20 −0 src/Three20/TTObject.h
  88. +24 −24 src/Three20/{T3PhotoSource.h → TTPhotoSource.h}
  89. +8 −8 src/Three20/{T3PhotoView.h → TTPhotoView.h}
  90. +22 −22 src/Three20/{T3PhotoViewController.h → TTPhotoViewController.h}
  91. +24 −24 src/Three20/{T3ScrollView.h → TTScrollView.h}
  92. +33 −0 src/Three20/TTSearchTextField.h
  93. +2 −2 src/Three20/{T3ShinyLabel.h → TTShinyLabel.h}
  94. +23 −23 src/Three20/{T3TabBar.h → TTTabBar.h}
  95. +18 −18 src/Three20/{T3TableField.h → TTTableField.h}
  96. +77 −0 src/Three20/TTTableFieldCell.h
  97. +2 −2 src/Three20/{T3TableViewCell.h → TTTableViewCell.h}
  98. +13 −0 src/Three20/TTTableViewController.h
  99. +15 −0 src/Three20/TTThumbView.h
  100. +26 −0 src/Three20/TTThumbsTableViewCell.h
  101. +29 −0 src/Three20/TTThumbsViewController.h
  102. +5 −5 src/Three20/{T3URLCache.h → TTURLCache.h}
  103. +20 −20 src/Three20/{T3URLRequest.h → TTURLRequest.h}
  104. +7 −7 src/Three20/{T3URLRequestQueue.h → TTURLRequestQueue.h}
  105. +2 −2 src/Three20/{T3UnclippedView.h → TTUnclippedView.h}
  106. +13 −13 src/Three20/{T3ViewController.h → TTViewController.h}
  107. +2 −2 src/Three20/{T3YouTubeView.h → TTYouTubeView.h}
  108. +30 −30 src/Three20/Three20.h
View
0 resources/t3images/badge.png → resources/ttimages/badge.png
File renamed without changes
View
0 resources/t3images/darkTab.png → resources/ttimages/darkTab.png
File renamed without changes
View
0 resources/t3images/lightTab.png → resources/ttimages/lightTab.png
File renamed without changes
View
0 resources/t3images/nextIcon.png → resources/ttimages/nextIcon.png
File renamed without changes
View
0 resources/t3images/overflowLeft.png → resources/ttimages/overflowLeft.png
File renamed without changes
View
0 resources/t3images/overflowRight.png → resources/ttimages/overflowRight.png
File renamed without changes
View
0 resources/t3images/photoDefault.png → resources/ttimages/photoDefault.png
File renamed without changes
View
0 resources/t3images/previousIcon.png → resources/ttimages/previousIcon.png
File renamed without changes
View
0 resources/t3images/tabButton.png → resources/ttimages/tabButton.png
File renamed without changes
View
4 samples/T3Catalog/Classes/ImageTableViewCell.h
@@ -1,9 +1,9 @@
#import <Three20/Three20.h>
-@class T3ImageView;
+@class TTImageView;
@interface ImageTableViewCell : UITableViewCell {
- T3ImageView* imageView;
+ TTImageView* imageView;
}
@property(nonatomic,copy) NSString* imageURL;
View
2 samples/T3Catalog/Classes/ImageTableViewCell.m
@@ -7,7 +7,7 @@ - (id)initWithFrame:(CGRect)frame reuseIdentifier:(NSString *)reuseIdentifier {
self.indentationLevel = 1;
self.indentationWidth = 35;
- imageView = [[T3ImageView alloc] initWithFrame:CGRectMake(0, 0, 70, 70)];
+ imageView = [[TTImageView alloc] initWithFrame:CGRectMake(0, 0, 70, 70)];
imageView.defaultImage = [UIImage imageNamed:@"DefaultAlbum.png"];
[self addSubview:imageView];
}
View
2 samples/T3Catalog/Classes/ImageTest1Controller.m
@@ -7,7 +7,7 @@ @implementation ImageTest1Controller
- (void)loadView {
self.view = [[[UIView alloc] init] autorelease];
- T3ImageView* imageView = [[[T3ImageView alloc] initWithFrame:CGRectMake(30, 30, 0, 0)]
+ TTImageView* imageView = [[[TTImageView alloc] initWithFrame:CGRectMake(30, 30, 0, 0)]
autorelease];
imageView.autoresizesToImage = YES;
imageView.url = @"http://farm4.static.flickr.com/3163/3110335722_7a906f9d8b_m.jpg";
View
2 samples/T3Catalog/Classes/ImageTest2Controller.h
@@ -1,6 +1,6 @@
#import <Three20/Three20.h>
-@interface ImageTest2Controller : T3TableViewController <UITableViewDataSource> {
+@interface ImageTest2Controller : TTTableViewController <UITableViewDataSource> {
NSArray* imageURLs;
}
View
10 samples/T3Catalog/Classes/MockPhotoSource.h
@@ -11,14 +11,14 @@ typedef enum {
///////////////////////////////////////////////////////////////////////////////////////////////////
-@interface MockPhotoSource : NSObject <T3PhotoSource> {
+@interface MockPhotoSource : NSObject <TTPhotoSource> {
MockPhotoSourceType _type;
NSMutableArray* _delegates;
- T3URLRequest* _request;
+ TTURLRequest* _request;
NSString* _title;
NSMutableArray* _photos;
NSArray* _tempPhotos;
- T3InvalidState _isInvalid;
+ TTInvalidState _isInvalid;
NSTimer* _fakeLoadTimer;
}
@@ -29,8 +29,8 @@ typedef enum {
///////////////////////////////////////////////////////////////////////////////////////////////////
-@interface MockPhoto : NSObject<T3Photo> {
- id<T3PhotoSource> _photoSource;
+@interface MockPhoto : NSObject<TTPhoto> {
+ id<TTPhotoSource> _photoSource;
NSString* _thumbURL;
NSString* _smallURL;
NSString* _url;
View
58 samples/T3Catalog/Classes/MockPhotoSource.m
@@ -15,15 +15,15 @@ - (id)initWithType:(MockPhotoSourceType)type title:(NSString*)title photos:(NSAr
_tempPhotos = photos2 ? [photos2 retain] : [photos retain];
for (int i = 0; i < _photos.count; ++i) {
- id<T3Photo> photo = [_photos objectAtIndex:i];
+ id<TTPhoto> photo = [_photos objectAtIndex:i];
if ((NSNull*)photo != [NSNull null]) {
photo.photoSource = self;
photo.index = i;
}
}
if (_type & MockPhotoSourceDelayed || photos2) {
- _isInvalid = T3Invalid;
+ _isInvalid = TTInvalid;
} else {
[self performSelector:@selector(fakeLoadReady)];
}
@@ -42,19 +42,19 @@ - (void)dealloc {
- (void)fakeLoadReady {
_fakeLoadTimer = nil;
- _isInvalid = T3Valid;
+ _isInvalid = TTValid;
if (_type & MockPhotoSourceLoadError) {
[_request.delegate request:_request didFailWithError:nil];
- for (id<T3PhotoSourceDelegate> delegate in _delegates) {
+ for (id<TTPhotoSourceDelegate> delegate in _delegates) {
[delegate photoSource:self didFailWithError:nil];
}
} else {
NSMutableArray* newPhotos = [NSMutableArray array];
for (int i = 0; i < _photos.count; ++i) {
- id<T3Photo> photo = [_photos objectAtIndex:i];
+ id<TTPhoto> photo = [_photos objectAtIndex:i];
if ((NSNull*)photo != [NSNull null]) {
[newPhotos addObject:photo];
}
@@ -68,7 +68,7 @@ - (void)fakeLoadReady {
_photos = [newPhotos retain];
for (int i = 0; i < _photos.count; ++i) {
- id<T3Photo> photo = [_photos objectAtIndex:i];
+ id<TTPhoto> photo = [_photos objectAtIndex:i];
if ((NSNull*)photo != [NSNull null]) {
photo.photoSource = self;
photo.index = i;
@@ -77,7 +77,7 @@ - (void)fakeLoadReady {
[_request.delegate request:_request loadedData:nil media:nil];
- for (id<T3PhotoSourceDelegate> delegate in _delegates) {
+ for (id<TTPhotoSourceDelegate> delegate in _delegates) {
[delegate photoSourceLoaded:self];
}
}
@@ -87,26 +87,26 @@ - (void)fakeLoadReady {
}
///////////////////////////////////////////////////////////////////////////////////////////////////
-// T3Object
+// TTObject
-- (T3InvalidState)isInvalid {
+- (TTInvalidState)isInvalid {
return _isInvalid;
}
-- (void)setIsInvalid:(T3InvalidState)state {
+- (void)setIsInvalid:(TTInvalidState)state {
_isInvalid = state;
}
- (NSString*) viewURL {
return nil;
}
-+ (id<T3Object>)fromURL:(NSURL*)url {
++ (id<TTObject>)fromURL:(NSURL*)url {
return nil;
}
///////////////////////////////////////////////////////////////////////////////////////////////////
-// T3PhotoSource
+// TTPhotoSource
- (NSInteger)numberOfPhotos {
if (_tempPhotos) {
@@ -124,7 +124,7 @@ - (BOOL)loading {
return !!_fakeLoadTimer;
}
-- (id<T3Photo>)photoAtIndex:(NSInteger)index {
+- (id<TTPhoto>)photoAtIndex:(NSInteger)index {
if (index < _photos.count) {
id photo = [_photos objectAtIndex:index];
if (photo == [NSNull null]) {
@@ -137,13 +137,13 @@ - (BOOL)loading {
}
}
-- (void)loadPhotos:(T3URLRequest*)request fromIndex:(NSInteger)fromIndex
+- (void)loadPhotos:(TTURLRequest*)request fromIndex:(NSInteger)fromIndex
toIndex:(NSInteger)toIndex {
- if (request.cachePolicy & T3URLRequestCachePolicyNetwork) {
+ if (request.cachePolicy & TTURLRequestCachePolicyNetwork) {
_request = [request retain];
[_request.delegate requestLoading:_request];
- for (id<T3PhotoSourceDelegate> delegate in _delegates) {
+ for (id<TTPhotoSourceDelegate> delegate in _delegates) {
[delegate photoSourceLoading:self];
}
@@ -152,11 +152,11 @@ - (void)loadPhotos:(T3URLRequest*)request fromIndex:(NSInteger)fromIndex
}
}
-- (void)addDelegate:(id<T3PhotoSourceDelegate>)delegate {
+- (void)addDelegate:(id<TTPhotoSourceDelegate>)delegate {
[_delegates addObject:delegate];
}
-- (void)removeDelegate:(id<T3PhotoSourceDelegate>)delegate {
+- (void)removeDelegate:(id<TTPhotoSourceDelegate>)delegate {
[_delegates removeObject:delegate];
}
@@ -195,34 +195,34 @@ - (void)dealloc {
}
///////////////////////////////////////////////////////////////////////////////////////////////////
-// T3Object
+// TTObject
-- (T3InvalidState)isInvalid {
- return T3Valid;
+- (TTInvalidState)isInvalid {
+ return TTValid;
}
-- (void)setIsInvalid:(T3InvalidState)state {
+- (void)setIsInvalid:(TTInvalidState)state {
}
- (NSString*)viewURL {
return nil;
}
-+ (id<T3Object>)fromURL:(NSURL*)url {
++ (id<TTObject>)fromURL:(NSURL*)url {
return nil;
}
///////////////////////////////////////////////////////////////////////////////////////////////////
-// T3Photo
+// TTPhoto
-- (NSString*)urlForVersion:(T3PhotoVersion)version {
- if (version == T3PhotoVersionLarge) {
+- (NSString*)urlForVersion:(TTPhotoVersion)version {
+ if (version == TTPhotoVersionLarge) {
return _url;
- } else if (version == T3PhotoVersionMedium) {
+ } else if (version == TTPhotoVersionMedium) {
return _url;
- } else if (version == T3PhotoVersionSmall) {
+ } else if (version == TTPhotoVersionSmall) {
return _smallURL;
- } else if (version == T3PhotoVersionThumbnail) {
+ } else if (version == TTPhotoVersionThumbnail) {
return _thumbURL;
} else {
return nil;
View
2 samples/T3Catalog/Classes/PhotoTest1Controller.h
@@ -1,6 +1,6 @@
#import <Three20/Three20.h>
-@interface PhotoTest1Controller : T3PhotoViewController {
+@interface PhotoTest1Controller : TTPhotoViewController {
}
@end
View
2 samples/T3Catalog/Classes/PhotoTest2Controller.h
@@ -1,6 +1,6 @@
#import <Three20/Three20.h>
-@interface PhotoTest2Controller : T3ThumbsViewController {
+@interface PhotoTest2Controller : TTThumbsViewController {
}
@end
View
2 samples/T3Catalog/Classes/RootViewController.h
@@ -1,6 +1,6 @@
#import <Three20/Three20.h>
-@interface RootViewController : T3TableViewController <T3NavigationDelegate> {
+@interface RootViewController : TTTableViewController <TTNavigationDelegate> {
NSArray* controllers;
}
View
52 samples/T3Catalog/Classes/RootViewController.m
@@ -26,10 +26,10 @@ - (void)loadView {
}
- (void)viewDidLoad {
- T3NavigationCenter* nav = [T3NavigationCenter defaultCenter];
+ TTNavigationCenter* nav = [TTNavigationCenter defaultCenter];
nav.mainViewController = self.navigationController;
nav.delegate = self;
- nav.urlSchemes = [NSArray arrayWithObject:@"t3"];
+ nav.urlSchemes = [NSArray arrayWithObject:@"tt"];
nav.supportsShakeToReload = YES;
[nav addController:[PhotoTest1Controller class] forView:@"photoTest1"];
@@ -43,45 +43,45 @@ - (void)viewDidLoad {
[nav addController:[TextTest1Controller class] forView:@"textTest1"];
[nav addController:[ScrollViewTestController class] forView:@"scrollViewTest"];
- self.dataSource = [T3SectionedDataSource dataSourceWithObjects:
+ self.dataSource = [TTSectionedDataSource dataSourceWithObjects:
@"Photos",
- [[[T3TableField alloc] initWithText:@"Photo Browser"
- href:@"t3://photoTest1"] autorelease],
- [[[T3TableField alloc] initWithText:@"Photo Thumbnails"
- href:@"t3://photoTest2"] autorelease],
+ [[[TTTableField alloc] initWithText:@"Photo Browser"
+ href:@"tt://photoTest1"] autorelease],
+ [[[TTTableField alloc] initWithText:@"Photo Thumbnails"
+ href:@"tt://photoTest2"] autorelease],
@"Web Media",
- [[[T3TableField alloc] initWithText:@"Web Image"
- href:@"t3://imageTest1"] autorelease],
- [[[T3TableField alloc] initWithText:@"Web Images in Table"
- href:@"t3://imageTest2"] autorelease],
- [[[T3TableField alloc] initWithText:@"YouTube Player"
- href:@"t3://youTubeTest"] autorelease],
+ [[[TTTableField alloc] initWithText:@"Web Image"
+ href:@"tt://imageTest1"] autorelease],
+ [[[TTTableField alloc] initWithText:@"Web Images in Table"
+ href:@"tt://imageTest2"] autorelease],
+ [[[TTTableField alloc] initWithText:@"YouTube Player"
+ href:@"tt://youTubeTest"] autorelease],
@"Controls",
- [[[T3TableField alloc] initWithText:@"Table Fields"
- href:@"t3://tableFieldTest"] autorelease],
- [[[T3TableField alloc] initWithText:@"Text Editing"
- href:@"t3://textEditTest"] autorelease],
- [[[T3TableField alloc] initWithText:@"Tab Bars"
- href:@"t3://tabBarTest"] autorelease],
- [[[T3TableField alloc] initWithText:@"Shiny Label"
- href:@"t3://textTest1"] autorelease],
- [[[T3TableField alloc] initWithText:@"Scroll View"
- href:@"t3://scrollViewTest"] autorelease],
+ [[[TTTableField alloc] initWithText:@"Table Fields"
+ href:@"tt://tableFieldTest"] autorelease],
+ [[[TTTableField alloc] initWithText:@"Text Editing"
+ href:@"tt://textEditTest"] autorelease],
+ [[[TTTableField alloc] initWithText:@"Tab Bars"
+ href:@"tt://tabBarTest"] autorelease],
+ [[[TTTableField alloc] initWithText:@"Shiny Label"
+ href:@"tt://textTest1"] autorelease],
+ [[[TTTableField alloc] initWithText:@"Scroll View"
+ href:@"tt://scrollViewTest"] autorelease],
nil];
NSIndexPath* indexPath = [NSIndexPath indexPathForRow:1 inSection:2];
[self.tableView touchRowAtIndexPath:indexPath animated:NO];
}
///////////////////////////////////////////////////////////////////////////////////////////////////
-// T3NavigationDelegate
+// TTNavigationDelegate
-- (void)willNavigateToObject:(id<T3Object>)object inView:(NSString*)viewType
+- (void)willNavigateToObject:(id<TTObject>)object inView:(NSString*)viewType
withController:(UIViewController*)viewController {
NSIndexPath* indexPath = self.tableView.indexPathForSelectedRow;
- T3LinkTableField* field = [self.dataSource objectForRowAtIndexPath:indexPath];
+ TTLinkTableField* field = [self.dataSource objectForRowAtIndexPath:indexPath];
viewController.title = field.text;
}
View
6 samples/T3Catalog/Classes/ScrollViewTestController.h
@@ -1,8 +1,8 @@
#import <Three20/Three20.h>
-@interface ScrollViewTestController : T3ViewController
- <T3ScrollViewDelegate, T3ScrollViewDataSource> {
- T3ScrollView* _scrollView;
+@interface ScrollViewTestController : TTViewController
+ <TTScrollViewDelegate, TTScrollViewDataSource> {
+ TTScrollView* _scrollView;
NSArray* objects;
}
View
20 samples/T3Catalog/Classes/ScrollViewTestController.m
@@ -16,7 +16,7 @@ - (void)loadView {
CGRect frame = CGRectMake(0, 0, appFrame.size.width, appFrame.size.height - 44);
self.view = [[[UIView alloc] initWithFrame:frame] autorelease];
- _scrollView = [[T3ScrollView alloc] initWithFrame:self.view.bounds];
+ _scrollView = [[TTScrollView alloc] initWithFrame:self.view.bounds];
_scrollView.delegate = self;
_scrollView.dataSource = self;
_scrollView.backgroundColor = [UIColor blackColor];
@@ -38,23 +38,23 @@ - (void)loadView {
}
///////////////////////////////////////////////////////////////////////////////////////////////////
-// T3ScrollViewDelegate
+// TTScrollViewDelegate
-- (void)scrollView:(T3ScrollView*)scrollView didMoveToPageAtIndex:(NSInteger)pageIndex {
+- (void)scrollView:(TTScrollView*)scrollView didMoveToPageAtIndex:(NSInteger)pageIndex {
}
///////////////////////////////////////////////////////////////////////////////////////////////////
-// T3ScrollViewDataSource
+// TTScrollViewDataSource
-- (NSInteger)numberOfPagesInScrollView:(T3ScrollView*)scrollView {
+- (NSInteger)numberOfPagesInScrollView:(TTScrollView*)scrollView {
return objects.count;
}
-- (UIView*)scrollView:(T3ScrollView*)scrollView pageAtIndex:(NSInteger)pageIndex {
- T3BackgroundView* pageView = (T3BackgroundView*)[_scrollView dequeueReusablePage];
+- (UIView*)scrollView:(TTScrollView*)scrollView pageAtIndex:(NSInteger)pageIndex {
+ TTBackgroundView* pageView = (TTBackgroundView*)[_scrollView dequeueReusablePage];
if (!pageView) {
- pageView = [[[T3BackgroundView alloc] initWithFrame:CGRectZero] autorelease];
- pageView.background = T3BackgroundRoundedRect;
+ pageView = [[[TTBackgroundView alloc] initWithFrame:CGRectZero] autorelease];
+ pageView.background = TTBackgroundRoundedRect;
pageView.strokeRadius = 30;
pageView.strokeColor = [UIColor blueColor];
pageView.fillColor2 = [UIColor colorWithRed:1 green:1 blue:1 alpha:1];
@@ -65,7 +65,7 @@ - (UIView*)scrollView:(T3ScrollView*)scrollView pageAtIndex:(NSInteger)pageIndex
return pageView;
}
-- (CGSize)scrollView:(T3ScrollView*)scrollView sizeOfPageAtIndex:(NSInteger)pageIndex {
+- (CGSize)scrollView:(TTScrollView*)scrollView sizeOfPageAtIndex:(NSInteger)pageIndex {
return CGSizeMake(320, 416);
}
View
2 .../T3Catalog/Classes/T3CatalogAppDelegate.h → .../T3Catalog/Classes/TTCatalogAppDelegate.h
@@ -1,6 +1,6 @@
#import <Three20/Three20.h>
-@interface T3CatalogAppDelegate : NSObject <UIApplicationDelegate> {
+@interface TTCatalogAppDelegate : NSObject <UIApplicationDelegate> {
IBOutlet UIWindow *window;
IBOutlet UINavigationController *navigationController;
}
View
4 .../T3Catalog/Classes/T3CatalogAppDelegate.m → .../T3Catalog/Classes/TTCatalogAppDelegate.m
@@ -1,7 +1,7 @@
-#import "T3CatalogAppDelegate.h"
+#import "TTCatalogAppDelegate.h"
#import "RootViewController.h"
-@implementation T3CatalogAppDelegate
+@implementation TTCatalogAppDelegate
@synthesize window;
@synthesize navigationController;
View
8 samples/T3Catalog/Classes/TabBarTestController.h
@@ -1,9 +1,9 @@
#import <Three20/Three20.h>
-@interface TabBarTestController : T3ViewController {
- T3TabBar* _tabBar1;
- T3TabBar* _tabBar2;
- T3TabBar* _tabBar3;
+@interface TabBarTestController : TTViewController {
+ TTTabBar* _tabBar1;
+ TTTabBar* _tabBar2;
+ TTTabBar* _tabBar3;
}
@end
View
48 samples/T3Catalog/Classes/TabBarTestController.m
@@ -13,52 +13,52 @@ - (void)loadView {
self.view = [[[UIView alloc] initWithFrame:[UIScreen mainScreen].applicationFrame] autorelease];
self.view.backgroundColor = RGBCOLOR(240, 242, 245);
- _tabBar1 = [[T3TabBar alloc] initWithFrame:CGRectMake(0, -1, 320, 43)
- style:T3TabBarStyleButtons];
+ _tabBar1 = [[TTTabBar alloc] initWithFrame:CGRectMake(0, -1, 320, 43)
+ style:TTTabBarStyleButtons];
_tabBar1.delegate = self;
[self.view addSubview:_tabBar1];
_tabBar1.tabItems = [NSArray arrayWithObjects:
- [[[T3TabItem alloc] initWithTitle:@"Item 1"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Item 2"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Item 3"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Item 4"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Item 5"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Item 6"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Item 7"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Item 8"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Item 9"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Item 10"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Item 1"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Item 2"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Item 3"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Item 4"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Item 5"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Item 6"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Item 7"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Item 8"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Item 9"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Item 10"] autorelease],
nil];
- _tabBar2 = [[T3TabBar alloc] initWithFrame:CGRectMake(0, 42, 320, 41)
- style:T3TabBarStyleDark];
+ _tabBar2 = [[TTTabBar alloc] initWithFrame:CGRectMake(0, 42, 320, 41)
+ style:TTTabBarStyleDark];
_tabBar2.delegate = self;
_tabBar2.contentMode = UIViewContentModeScaleToFill;
[self.view addSubview:_tabBar2];
_tabBar2.tabItems = [NSArray arrayWithObjects:
- [[[T3TabItem alloc] initWithTitle:@"Banana"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Cherry"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Orange"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Grape"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Banana"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Cherry"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Orange"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Grape"] autorelease],
nil];
_tabBar2.selectedTabIndex = 2;
- T3TabItem* item = [_tabBar2.tabItems objectAtIndex:1];
+ TTTabItem* item = [_tabBar2.tabItems objectAtIndex:1];
item.badgeNumber = 2;
- _tabBar3 = [[T3TabBar alloc] initWithFrame:CGRectMake(0, 100, 320, 41)
- style:T3TabBarStyleLight];
+ _tabBar3 = [[TTTabBar alloc] initWithFrame:CGRectMake(0, 100, 320, 41)
+ style:TTTabBarStyleLight];
_tabBar3.delegate = self;
_tabBar3.contentMode = UIViewContentModeScaleToFill;
[self.view addSubview:_tabBar3];
_tabBar3.tabItems = [NSArray arrayWithObjects:
- [[[T3TabItem alloc] initWithTitle:@"Red"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Green"] autorelease],
- [[[T3TabItem alloc] initWithTitle:@"Blue"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Red"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Green"] autorelease],
+ [[[TTTabItem alloc] initWithTitle:@"Blue"] autorelease],
nil];
}
View
2 samples/T3Catalog/Classes/TableFieldTestController.h
@@ -1,5 +1,5 @@
#import <Three20/Three20.h>
-@interface TableFieldTestController : T3TableViewController
+@interface TableFieldTestController : TTTableViewController
@end
View
46 samples/T3Catalog/Classes/TableFieldTestController.m
@@ -31,40 +31,40 @@ - (void)loadView {
}
- (void)viewDidLoad {
- self.dataSource = [T3SectionedDataSource dataSourceWithObjects:
+ self.dataSource = [TTSectionedDataSource dataSourceWithObjects:
@"Buttons",
- [[[T3TableField alloc] initWithText:@"T3TableField"
- href:@"t3://tableFieldTest"] autorelease],
- [[[T3TableField alloc] initWithText:@"T3TableField (external)"
+ [[[TTTableField alloc] initWithText:@"TTTableField"
+ href:@"tt://tableFieldTest"] autorelease],
+ [[[TTTableField alloc] initWithText:@"TTTableField (external)"
href:@"http://foo.com"] autorelease],
- [[[T3LinkTableField alloc] initWithText:@"T3LinkTableField"
- href:@"t3://tableFieldTest"] autorelease],
- [[[T3IconTableField alloc] initWithText:@"T3IconTableField" href:@"t3://tableFieldTest"
+ [[[TTLinkTableField alloc] initWithText:@"TTLinkTableField"
+ href:@"tt://tableFieldTest"] autorelease],
+ [[[TTIconTableField alloc] initWithText:@"TTIconTableField" href:@"tt://tableFieldTest"
image:@"bundle://tableIcon.png" ] autorelease],
- [[[T3ImageTableField alloc] initWithText:@"T3ImageTableField" href:@"t3://tableFieldTest"
+ [[[TTImageTableField alloc] initWithText:@"TTImageTableField" href:@"tt://tableFieldTest"
image:@"bundle://person.jpg"] autorelease],
- [[[T3ButtonTableField alloc] initWithText:@"T3ButtonTableField"] autorelease],
- [[[T3TitledTableField alloc] initWithTitle:@"title"
- text:@"T3TitledTableField" href:@"t3://tableFieldTest"] autorelease],
- [[[T3MoreButtonTableField alloc] initWithText:@"T3MoreButtonTableField"
+ [[[TTButtonTableField alloc] initWithText:@"TTButtonTableField"] autorelease],
+ [[[TTTitledTableField alloc] initWithTitle:@"title"
+ text:@"TTTitledTableField" href:@"tt://tableFieldTest"] autorelease],
+ [[[TTMoreButtonTableField alloc] initWithText:@"TTMoreButtonTableField"
subtitle:@"Showing 1 of 100"] autorelease],
@"Static Text",
- [[[T3TableField alloc] initWithText:@"T3TableField"] autorelease],
- [[[T3TitledTableField alloc] initWithTitle:@"title"
- text:@"T3TitledTableField"] autorelease],
- [[[T3SubtextTableField alloc] initWithText:@"T3SubtextTableField"
+ [[[TTTableField alloc] initWithText:@"TTTableField"] autorelease],
+ [[[TTTitledTableField alloc] initWithTitle:@"title"
+ text:@"TTTitledTableField"] autorelease],
+ [[[TTSubtextTableField alloc] initWithText:@"TTSubtextTableField"
subtext:kLoremIpsum] autorelease],
- [[[T3TextTableField alloc] initWithText:kLoremIpsum] autorelease],
- [[[T3GrayTextTableField alloc] initWithText:kLoremIpsum] autorelease],
- [[[T3ActivityTableField alloc] initWithText:@"T3ActivityTableField"] autorelease],
- [[[T3SummaryTableField alloc] initWithText:@"T3SummaryTableField"] autorelease],
+ [[[TTTextTableField alloc] initWithText:kLoremIpsum] autorelease],
+ [[[TTGrayTextTableField alloc] initWithText:kLoremIpsum] autorelease],
+ [[[TTActivityTableField alloc] initWithText:@"TTActivityTableField"] autorelease],
+ [[[TTSummaryTableField alloc] initWithText:@"TTSummaryTableField"] autorelease],
@"Controls",
- [[[T3SwitchTableField alloc] initWithText:@"T3SwitchTableField"] autorelease],
- [[[T3TextFieldTableField alloc] initWithTitle:@"Title" text:@"T3TextFieldTableField"]
+ [[[TTSwitchTableField alloc] initWithText:@"TTSwitchTableField"] autorelease],
+ [[[TTTextFieldTableField alloc] initWithTitle:@"Title" text:@"TTTextFieldTableField"]
autorelease],
- [[[T3TextViewTableField alloc] initWithText:@"T3TextViewTableField"] autorelease],
+ [[[TTTextViewTableField alloc] initWithText:@"TTTextViewTableField"] autorelease],
nil];
}
View
18 samples/T3Catalog/Classes/TextEditTestController.m
@@ -2,33 +2,33 @@
#import "TextEditTestController.h"
#import <Three20/Three20.h>
-@interface TestSearchSource : T3BasicDataSource <T3SearchSource>
+@interface TestSearchSource : TTBasicDataSource <TTSearchSource>
@end
@implementation TestSearchSource
-- (void)textField:(T3SearchTextField*)textField searchForText:(NSString*)text {
+- (void)textField:(TTSearchTextField*)textField searchForText:(NSString*)text {
// _items = [[NSMutableArray alloc] initWithObjects:
-// [[[T3ActivityTableField alloc] initWithText:@"Searching..."] autorelease],
+// [[[TTActivityTableField alloc] initWithText:@"Searching..."] autorelease],
// nil];
[_items release];
if (text.length) {
_items = [[NSMutableArray alloc] initWithObjects:
- [[[T3TableField alloc] initWithText:@"Robert Anderson" href:@"fb://x"] autorelease],
- [[[T3TableField alloc] initWithText:@"Jim James" href:@"fb://x"] autorelease],
+ [[[TTTableField alloc] initWithText:@"Robert Anderson" href:@"fb://x"] autorelease],
+ [[[TTTableField alloc] initWithText:@"Jim James" href:@"fb://x"] autorelease],
nil];
} else {
_items = nil;
}
[textField updateResults];
}
-- (NSString*)textField:(T3SearchTextField*)textField
+- (NSString*)textField:(TTSearchTextField*)textField
labelForRowAtIndexPath:(NSIndexPath*)indexPath {
- T3TableField* field = [self objectForRowAtIndexPath:indexPath];
+ TTTableField* field = [self objectForRowAtIndexPath:indexPath];
return field.text;
}
@@ -51,7 +51,7 @@ - (void)loadView {
_searchSource = [[TestSearchSource alloc] init];
- T3MenuTextField* textField = [[[T3MenuTextField alloc] initWithFrame:
+ TTMenuTextField* textField = [[[TTMenuTextField alloc] initWithFrame:
CGRectMake(0, 0, 320, 0)] autorelease];
textField.searchSource = _searchSource;
textField.visibleLineCount = 2;
@@ -82,6 +82,6 @@ - (void)loadView {
}
///////////////////////////////////////////////////////////////////////////////////////////////////
-// T3SearchSource
+// TTSearchSource
@end
View
2 samples/T3Catalog/Classes/TextTest1Controller.m
@@ -8,7 +8,7 @@ - (void)loadView {
self.view = [[[UIView alloc] init] autorelease];
self.view.backgroundColor = [UIColor blackColor];
- T3ShinyLabel* label = [[[T3ShinyLabel alloc] initWithFrame:CGRectMake(0,150,320,100)] autorelease];
+ TTShinyLabel* label = [[[TTShinyLabel alloc] initWithFrame:CGRectMake(0,150,320,100)] autorelease];
label.text = @"One Shiny Label";
label.font = [UIFont systemFontOfSize:25];
label.textAlignment = UITextAlignmentCenter;
View
4 samples/T3Catalog/Classes/YouTubeTestController.h
@@ -1,7 +1,7 @@
#import <Three20/Three20.h>
-@interface YouTubeTestController : T3ViewController <UIWebViewDelegate> {
- T3YouTubeView* youTubeView;
+@interface YouTubeTestController : TTViewController <UIWebViewDelegate> {
+ TTYouTubeView* youTubeView;
}
@end
View
2 samples/T3Catalog/Classes/YouTubeTestController.m
@@ -11,7 +11,7 @@ - (void)loadView {
self.view = [[[UIView alloc] initWithFrame:[UIScreen mainScreen].applicationFrame] autorelease];
self.view.backgroundColor = [UIColor redColor];
- youTubeView = [[T3YouTubeView alloc] initWithURL:@"http://www.youtube.com/watch?v=g8thp78oXsg"];
+ youTubeView = [[TTYouTubeView alloc] initWithURL:@"http://www.youtube.com/watch?v=g8thp78oXsg"];
youTubeView.center = self.view.center;
[self.view addSubview:youTubeView];
}
View
20 samples/T3Catalog/T3Catalog.xcodeproj/project.pbxproj
@@ -7,7 +7,7 @@
objects = {
/* Begin PBXBuildFile section */
- 1D3623260D0F684500981E51 /* T3CatalogAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 1D3623250D0F684500981E51 /* T3CatalogAppDelegate.m */; };
+ 1D3623260D0F684500981E51 /* TTCatalogAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 1D3623250D0F684500981E51 /* TTCatalogAppDelegate.m */; };
1D60589B0D05DD56006BFB54 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 29B97316FDCFA39411CA2CEA /* main.m */; };
1D60589F0D05DD5A006BFB54 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1D30AB110D05D00D00671497 /* Foundation.framework */; };
1DF5F4E00D08C38300B7A737 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */; };
@@ -26,7 +26,7 @@
BE80E3A70EAF108500743358 /* ImageTest1Controller.m in Sources */ = {isa = PBXBuildFile; fileRef = BE80E3A60EAF108500743358 /* ImageTest1Controller.m */; };
BE80E3B60EAF116700743358 /* Icon.png in Resources */ = {isa = PBXBuildFile; fileRef = BE80E3B50EAF116700743358 /* Icon.png */; };
BE8C0F7D0F2018C600EB0E98 /* YouTubeTestController.m in Sources */ = {isa = PBXBuildFile; fileRef = BE8C0F7C0F2018C600EB0E98 /* YouTubeTestController.m */; };
- BEB5220D0F32AE7100F51876 /* t3images in Resources */ = {isa = PBXBuildFile; fileRef = BEB5220A0F32AE7100F51876 /* t3images */; };
+ BEB5220D0F32AE7100F51876 /* ttimages in Resources */ = {isa = PBXBuildFile; fileRef = BEB5220A0F32AE7100F51876 /* ttimages */; };
BECB1CC20F46AE9600AE5B52 /* person.jpg in Resources */ = {isa = PBXBuildFile; fileRef = BECB1CC10F46AE9600AE5B52 /* person.jpg */; };
BEE0FDDB0EB2A6850052C05F /* PhotoTest1Controller.m in Sources */ = {isa = PBXBuildFile; fileRef = BEE0FDDA0EB2A6850052C05F /* PhotoTest1Controller.m */; };
BEE341B40F480C76008C826E /* TextEditTestController.m in Sources */ = {isa = PBXBuildFile; fileRef = BEE341B30F480C76008C826E /* TextEditTestController.m */; };
@@ -54,8 +54,8 @@
/* Begin PBXFileReference section */
1D30AB110D05D00D00671497 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
- 1D3623240D0F684500981E51 /* T3CatalogAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = T3CatalogAppDelegate.h; sourceTree = "<group>"; };
- 1D3623250D0F684500981E51 /* T3CatalogAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = T3CatalogAppDelegate.m; sourceTree = "<group>"; };
+ 1D3623240D0F684500981E51 /* TTCatalogAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TTCatalogAppDelegate.h; sourceTree = "<group>"; };
+ 1D3623250D0F684500981E51 /* TTCatalogAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TTCatalogAppDelegate.m; sourceTree = "<group>"; };
1D6058910D05DD3D006BFB54 /* T3Catalog.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = T3Catalog.app; sourceTree = BUILT_PRODUCTS_DIR; };
1DF5F4DF0D08C38300B7A737 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
2892E40F0DC94CBA00A64D0F /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
@@ -85,7 +85,7 @@
BE80E3B50EAF116700743358 /* Icon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Icon.png; sourceTree = "<group>"; };
BE8C0F7B0F2018C600EB0E98 /* YouTubeTestController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = YouTubeTestController.h; sourceTree = "<group>"; };
BE8C0F7C0F2018C600EB0E98 /* YouTubeTestController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = YouTubeTestController.m; sourceTree = "<group>"; };
- BEB5220A0F32AE7100F51876 /* t3images */ = {isa = PBXFileReference; lastKnownFileType = folder; name = t3images; path = ../../resources/t3images; sourceTree = SOURCE_ROOT; };
+ BEB5220A0F32AE7100F51876 /* ttimages */ = {isa = PBXFileReference; lastKnownFileType = folder; name = ttimages; path = ../../resources/ttimages; sourceTree = SOURCE_ROOT; };
BECB1CC10F46AE9600AE5B52 /* person.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = person.jpg; sourceTree = "<group>"; };
BEE0FDD90EB2A6850052C05F /* PhotoTest1Controller.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PhotoTest1Controller.h; sourceTree = "<group>"; };
BEE0FDDA0EB2A6850052C05F /* PhotoTest1Controller.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PhotoTest1Controller.m; sourceTree = "<group>"; };
@@ -116,8 +116,8 @@
080E96DDFE201D6D7F000001 /* Classes */ = {
isa = PBXGroup;
children = (
- 1D3623240D0F684500981E51 /* T3CatalogAppDelegate.h */,
- 1D3623250D0F684500981E51 /* T3CatalogAppDelegate.m */,
+ 1D3623240D0F684500981E51 /* TTCatalogAppDelegate.h */,
+ 1D3623250D0F684500981E51 /* TTCatalogAppDelegate.m */,
28C286DF0D94DF7D0034E888 /* RootViewController.h */,
28C286E00D94DF7D0034E888 /* RootViewController.m */,
BEE0FDD90EB2A6850052C05F /* PhotoTest1Controller.h */,
@@ -180,7 +180,7 @@
29B97317FDCFA39411CA2CEA /* Resources */ = {
isa = PBXGroup;
children = (
- BEB5220A0F32AE7100F51876 /* t3images */,
+ BEB5220A0F32AE7100F51876 /* ttimages */,
2899E55F0DE3E45000AC0155 /* RootViewController.xib */,
28AD735F0D9D9599002E5188 /* MainWindow.xib */,
BE80E3B50EAF116700743358 /* Icon.png */,
@@ -281,7 +281,7 @@
2899E5600DE3E45000AC0155 /* RootViewController.xib in Resources */,
BE80E39D0EAF103200743358 /* DefaultAlbum.png in Resources */,
BE80E3B60EAF116700743358 /* Icon.png in Resources */,
- BEB5220D0F32AE7100F51876 /* t3images in Resources */,
+ BEB5220D0F32AE7100F51876 /* ttimages in Resources */,
BE6E4DC00F46A352001CE9B4 /* tableIcon.png in Resources */,
BECB1CC20F46AE9600AE5B52 /* person.jpg in Resources */,
);
@@ -295,7 +295,7 @@
buildActionMask = 2147483647;
files = (
1D60589B0D05DD56006BFB54 /* main.m in Sources */,
- 1D3623260D0F684500981E51 /* T3CatalogAppDelegate.m in Sources */,
+ 1D3623260D0F684500981E51 /* TTCatalogAppDelegate.m in Sources */,
28C286E10D94DF7D0034E888 /* RootViewController.m in Sources */,
BE80E24A0EAEFF6100743358 /* MockPhotoSource.m in Sources */,
BE80E3710EAF0F3000743358 /* ImageTest2Controller.m in Sources */,
View
2 samples/T3Catalog/T3Catalog_Prefix.pch
@@ -1,5 +1,5 @@
//
-// Prefix header for all source files of the 'T3Catalog' target in the 'T3Catalog' project
+// Prefix header for all source files of the 'TTCatalog' target in the 'TTCatalog' project
//
#ifdef __OBJC__
View
18 src/T3+UIViewController.m → src/TT+UIViewController.m
@@ -1,9 +1,9 @@
-#import "Three20/T3Global.h"
-#import "Three20/T3URLRequestQueue.h"
+#import "Three20/TTGlobal.h"
+#import "Three20/TTURLRequestQueue.h"
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation UIViewController (T3Category)
+@implementation UIViewController (TTCategory)
- (void)showNavigationBar:(BOOL)show animated:(BOOL)animated {
if (animated) {
@@ -69,33 +69,33 @@ - (void)showBars:(BOOL)show animated:(BOOL)animated {
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation UINavigationController (T3Category)
+@implementation UINavigationController (TTCategory)
- (void)pushAnimationDidStop {
- [T3URLRequestQueue mainQueue].suspended = NO;
+ [TTURLRequestQueue mainQueue].suspended = NO;
}
- (void)pushViewController:(UIViewController*)controller
withTransition:(UIViewAnimationTransition)transition {
- [T3URLRequestQueue mainQueue].suspended = YES;
+ [TTURLRequestQueue mainQueue].suspended = YES;
[self pushViewController:controller animated:NO];
[UIView beginAnimations:nil context:NULL];
- [UIView setAnimationDuration:T3_FLIP_TRANSITION_DURATION];
+ [UIView setAnimationDuration:TT_FLIP_TRANSITION_DURATION];
[UIView setAnimationDelegate:self];
[UIView setAnimationDidStopSelector:@selector(pushAnimationDidStop)];
[UIView setAnimationTransition:transition forView:self.view.window cache:YES];
[UIView commitAnimations];
}
- (void)popViewControllerWithTransition:(UIViewAnimationTransition)transition {
- [T3URLRequestQueue mainQueue].suspended = YES;
+ [TTURLRequestQueue mainQueue].suspended = YES;
[self popViewControllerAnimated:NO];
[UIView beginAnimations:nil context:NULL];
- [UIView setAnimationDuration:T3_FLIP_TRANSITION_DURATION];
+ [UIView setAnimationDuration:TT_FLIP_TRANSITION_DURATION];
[UIView setAnimationDelegate:self];
[UIView setAnimationDidStopSelector:@selector(pushAnimationDidStop)];
[UIView setAnimationTransition:transition forView:self.view.window cache:YES];
View
36 src/T3ActivityLabel.m → src/TTActivityLabel.m
@@ -1,5 +1,5 @@
-#import "Three20/T3ActivityLabel.h"
-#import "Three20/T3BackgroundView.h"
+#import "Three20/TTActivityLabel.h"
+#import "Three20/TTBackgroundView.h"
///////////////////////////////////////////////////////////////////////////////////////////////////
@@ -11,35 +11,35 @@
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation T3ActivityLabel
+@implementation TTActivityLabel
@synthesize style = _style, centered = _centered, centeredToScreen = _centeredToScreen;
-- (id)initWithFrame:(CGRect)frame style:(T3ActivityLabelStyle)style {
+- (id)initWithFrame:(CGRect)frame style:(TTActivityLabelStyle)style {
return [self initWithFrame:frame style:style text:nil];
}
-- (id)initWithFrame:(CGRect)frame style:(T3ActivityLabelStyle)style text:(NSString*)text {
+- (id)initWithFrame:(CGRect)frame style:(TTActivityLabelStyle)style text:(NSString*)text {
if (self = [super initWithFrame:frame]) {
_style = style;
_centered = YES;
_centeredToScreen = YES;
self.backgroundColor = [UIColor clearColor];
- _bezelView = [[T3BackgroundView alloc] initWithFrame:CGRectZero];
- if (_style == T3ActivityLabelStyleBlackBezel || _style == T3ActivityLabelStyleBlackThinBezel) {
+ _bezelView = [[TTBackgroundView alloc] initWithFrame:CGRectZero];
+ if (_style == TTActivityLabelStyleBlackBezel || _style == TTActivityLabelStyleBlackThinBezel) {
_bezelView.opaque = NO;
- _bezelView.background = T3BackgroundRoundedRect;
+ _bezelView.background = TTBackgroundRoundedRect;
_bezelView.fillColor = [UIColor colorWithRed:0 green:0 blue:0 alpha:0.7];
_bezelView.strokeRadius = 10;
- } else if (_style == T3ActivityLabelStyleWhiteBezel) {
+ } else if (_style == TTActivityLabelStyleWhiteBezel) {
_bezelView.opaque = NO;
- _bezelView.background = T3BackgroundRoundedRect;
+ _bezelView.background = TTBackgroundRoundedRect;
_bezelView.fillColor = [UIColor colorWithRed:1 green:1 blue:1 alpha:1];
_bezelView.strokeColor = [UIColor colorWithRed:0.7 green:0.7 blue:0.7 alpha:1];
_bezelView.strokeRadius = 10;
- } else if (_style == T3ActivityLabelStyleWhiteBox) {
+ } else if (_style == TTActivityLabelStyleWhiteBox) {
_bezelView.backgroundColor = [UIColor whiteColor];
self.backgroundColor = [UIColor whiteColor];
} else {
@@ -54,27 +54,27 @@ - (id)initWithFrame:(CGRect)frame style:(T3ActivityLabelStyle)style text:(NSStri
_textView.lineBreakMode = UILineBreakModeTailTruncation;
_textView.text = text;
- if (_style == T3ActivityLabelStyleWhite) {
+ if (_style == TTActivityLabelStyleWhite) {
_spinner = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:
UIActivityIndicatorViewStyleWhite];
_textView.font = [UIFont systemFontOfSize:17];
_textView.textColor = [UIColor whiteColor];
- } else if (_style == T3ActivityLabelStyleGray
- || _style == T3ActivityLabelStyleWhiteBox
- || _style == T3ActivityLabelStyleWhiteBezel) {
+ } else if (_style == TTActivityLabelStyleGray
+ || _style == TTActivityLabelStyleWhiteBox
+ || _style == TTActivityLabelStyleWhiteBezel) {
_spinner = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:
UIActivityIndicatorViewStyleGray];
_textView.font = [UIFont systemFontOfSize:17];
_textView.textColor = [UIColor grayColor];
- } else if (_style == T3ActivityLabelStyleBlackBezel) {
+ } else if (_style == TTActivityLabelStyleBlackBezel) {
_spinner = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:
UIActivityIndicatorViewStyleWhiteLarge];
_spinner.frame = CGRectMake(0, 0, 24, 24);
_textView.font = [UIFont boldSystemFontOfSize:17];
_textView.textColor = [UIColor whiteColor];
_textView.shadowColor = [UIColor colorWithWhite:0 alpha:0.3];
_textView.shadowOffset = CGSizeMake(1, 1);
- } else if (_style == T3ActivityLabelStyleBlackThinBezel) {
+ } else if (_style == TTActivityLabelStyleBlackThinBezel) {
_spinner = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:
UIActivityIndicatorViewStyleWhite];
_spinner.frame = CGRectMake(0, 0, 20, 20);
@@ -110,7 +110,7 @@ - (void)layoutSubviews {
CGFloat bezelWidth, bezelHeight, y;
- if (_style == T3ActivityLabelStyleBlackThinBezel) {
+ if (_style == TTActivityLabelStyleBlackThinBezel) {
bezelHeight = kThinBezelHeight;
} else {
bezelHeight = kBezelHeight;
View
46 src/T3Appearance.m → src/TTAppearance.m
@@ -1,25 +1,25 @@
-#import "Three20/T3Appearance.h"
+#import "Three20/TTAppearance.h"
///////////////////////////////////////////////////////////////////////////////////////////////////
-static T3Appearance* gAppearance = nil;
+static TTAppearance* gAppearance = nil;
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation T3Appearance
+@implementation TTAppearance
@synthesize linkTextColor = _linkTextColor, navigationBarTintColor = _navigationBarTintColor,
searchTableBackgroundColor = _searchTableBackgroundColor,
searchTableSeparatorColor = _searchTableSeparatorColor;
-+ (T3Appearance*)appearance {
++ (TTAppearance*)appearance {
if (!gAppearance) {
- [self setAppearance:[[[T3Appearance alloc] init] autorelease]];
+ [self setAppearance:[[[TTAppearance alloc] init] autorelease]];
}
return gAppearance;
}
-+ (void)setAppearance:(T3Appearance*)appearance {
++ (void)setAppearance:(TTAppearance*)appearance {
if (gAppearance != appearance) {
[gAppearance release];
gAppearance = [appearance retain];
@@ -124,7 +124,7 @@ - (void)drawRoundedRect:(CGRect)rect fill:(UIColor**)fillColors fillCount:(int)f
stroke:(UIColor*)strokeColor radius:(CGFloat)radius {
CGContextRef context = UIGraphicsGetCurrentContext();
- if (radius == T3_RADIUS_ROUNDED) {
+ if (radius == TT_RADIUS_ROUNDED) {
radius = rect.size.height/2;
}
@@ -147,7 +147,7 @@ - (void)drawRoundedMask:(CGRect)rect fill:(UIColor**)fillColors stroke:(UIColor*
radius:(CGFloat)radius {
CGContextRef context = UIGraphicsGetCurrentContext();
- if (radius == T3_RADIUS_ROUNDED) {
+ if (radius == TT_RADIUS_ROUNDED) {
radius = rect.size.height/2;
}
@@ -191,29 +191,29 @@ - (void)drawInnerShadow:(CGRect)rect {
CGContextRestoreGState(context);
}
-- (void)strokeLines:(CGRect)rect background:(T3Background)background stroke:(UIColor*)strokeColor {
+- (void)strokeLines:(CGRect)rect background:(TTBackground)background stroke:(UIColor*)strokeColor {
CGContextRef context = UIGraphicsGetCurrentContext();
CGContextSaveGState(context);
CGContextSetStrokeColor(context, CGColorGetComponents(strokeColor.CGColor));
CGContextSetLineWidth(context, 1.0);
- if (background == T3BackgroundStrokeTop) {
+ if (background == TTBackgroundStrokeTop) {
CGPoint points[] = {rect.origin.x, rect.origin.y-0.5,
rect.origin.x+rect.size.width, rect.origin.y-0.5};
CGContextStrokeLineSegments(context, points, 2);
}
-// if (background == T3BackgroundStrokeRight) {
+// if (background == TTBackgroundStrokeRight) {
// CGPoint points[] = {rect.origin.x, rect.origin.y+rect.size.height,
// rect.origin.x+rect.size.width, rect.origin.y+rect.size.height};
// CGContextStrokeLineSegments(context, points, 2);
// }
- if (background == T3BackgroundStrokeBottom) {
+ if (background == TTBackgroundStrokeBottom) {
CGPoint points[] = {rect.origin.x, rect.origin.y+rect.size.height-0.5,
rect.origin.x+rect.size.width, rect.origin.y+rect.size.height-0.5};
CGContextStrokeLineSegments(context, points, 2);
}
-// if (background == T3BackgroundStrokeLeft) {
+// if (background == TTBackgroundStrokeLeft) {
// CGPoint points[] = {rect.origin.x, rect.origin.y+rect.size.height,
// rect.origin.x+rect.size.width, rect.origin.y+rect.size.height};
// CGContextStrokeLineSegments(context, points, 2);
@@ -224,33 +224,33 @@ - (void)strokeLines:(CGRect)rect background:(T3Background)background stroke:(UIC
///////////////////////////////////////////////////////////////////////////////////////////////////
-- (void)drawBackground:(T3Background)background rect:(CGRect)rect fill:(UIColor**)fillColors
+- (void)drawBackground:(TTBackground)background rect:(CGRect)rect fill:(UIColor**)fillColors
fillCount:(int)fillCount stroke:(UIColor*)strokeColor radius:(CGFloat)radius {
switch (background) {
- case T3BackgroundRoundedRect:
+ case TTBackgroundRoundedRect:
[self drawRoundedRect:rect fill:fillColors fillCount:fillCount stroke:strokeColor
radius:radius];
break;
- case T3BackgroundRoundedMask:
+ case TTBackgroundRoundedMask:
[self drawRoundedMask:rect fill:fillColors stroke:strokeColor radius:radius];
break;
- case T3BackgroundInnerShadow:
+ case TTBackgroundInnerShadow:
[self drawInnerShadow:rect];
break;
- case T3BackgroundStrokeTop:
- case T3BackgroundStrokeRight:
- case T3BackgroundStrokeBottom:
- case T3BackgroundStrokeLeft:
+ case TTBackgroundStrokeTop:
+ case TTBackgroundStrokeRight:
+ case TTBackgroundStrokeBottom:
+ case TTBackgroundStrokeLeft:
[self strokeLines:rect background:background stroke:strokeColor];
break;
default:
break;
}
}
-- (void)drawBackground:(T3Background)background rect:(CGRect)rect {
+- (void)drawBackground:(TTBackground)background rect:(CGRect)rect {
[self drawBackground:background rect:rect fill:nil fillCount:0 stroke:nil
- radius:T3_RADIUS_ROUNDED];
+ radius:TT_RADIUS_ROUNDED];
}
- (void)drawLine:(CGPoint)from to:(CGPoint)to color:(UIColor*)color {
View
10 src/T3BackgroundView.m → src/TTBackgroundView.m
@@ -1,8 +1,8 @@
-#import "Three20/T3BackgroundView.h"
+#import "Three20/TTBackgroundView.h"
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation T3BackgroundView
+@implementation TTBackgroundView
@synthesize background = _background, fillColor = _fillColor, fillColor2 = _fillColor2,
strokeColor = _strokeColor, strokeRadius = _strokeRadius;
@@ -34,13 +34,13 @@ - (void)drawRect:(CGRect)rect {
if (_background) {
if (_fillColor2 && _fillColor) {
UIColor* fillColors[] = {_fillColor, _fillColor2};
- [[T3Appearance appearance] drawBackground:_background rect:rect fill:fillColors fillCount:2
+ [[TTAppearance appearance] drawBackground:_background rect:rect fill:fillColors fillCount:2
stroke:_strokeColor radius:_strokeRadius];
} else if (_fillColor) {
- [[T3Appearance appearance] drawBackground:_background rect:rect fill:&_fillColor fillCount:1
+ [[TTAppearance appearance] drawBackground:_background rect:rect fill:&_fillColor fillCount:1
stroke:_strokeColor radius:_strokeRadius];
} else {
- [[T3Appearance appearance] drawBackground:_background rect:rect fill:nil fillCount:0
+ [[TTAppearance appearance] drawBackground:_background rect:rect fill:nil fillCount:0
stroke:_strokeColor radius:_strokeRadius];
}
}
View
72 src/T3DataSource.m → src/TTDataSource.m
@@ -1,10 +1,10 @@
-#import "Three20/T3DataSource.h"
-#import "Three20/T3TableField.h"
-#import "Three20/T3TableFieldCell.h"
+#import "Three20/TTDataSource.h"
+#import "Three20/TTTableField.h"
+#import "Three20/TTTableFieldCell.h"
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation T3BaseDataSource
+@implementation TTBaseDataSource
///////////////////////////////////////////////////////////////////////////////////////////////////
// UITableViewDataSource
@@ -25,8 +25,8 @@ - (UITableViewCell *)tableView:(UITableView *)tableView
reuseIdentifier:className] autorelease];
}
- if ([cell isKindOfClass:[T3TableViewCell class]]) {
- [(T3TableViewCell*)cell setObject:object];
+ if ([cell isKindOfClass:[TTTableViewCell class]]) {
+ [(TTTableViewCell*)cell setObject:object];
}
[self decorateCell:cell forRowAtIndexPath:indexPath];
@@ -41,31 +41,31 @@ - (id)objectForRowAtIndexPath:(NSIndexPath*)indexPath {
}
- (Class)cellClassForObject:(id)object {
- if ([object isKindOfClass:[T3TableField class]]) {
- if ([object isKindOfClass:[T3TextTableField class]]) {
- return [T3TextTableFieldCell class];
- } else if ([object isKindOfClass:[T3TitledTableField class]]) {
- return [T3TitledTableFieldCell class];
- } else if ([object isKindOfClass:[T3SubtextTableField class]]) {
- return [T3SubtextTableFieldCell class];
- } else if ([object isKindOfClass:[T3MoreButtonTableField class]]) {
- return [T3MoreButtonTableFieldCell class];
- } else if ([object isKindOfClass:[T3IconTableField class]]) {
- return [T3IconTableFieldCell class];
- } else if ([object isKindOfClass:[T3ImageTableField class]]) {
- return [T3ImageTableFieldCell class];
- } else if ([object isKindOfClass:[T3ActivityTableField class]]) {
- return [T3ActivityTableFieldCell class];
- } else if ([object isKindOfClass:[T3ErrorTableField class]]) {
- return [T3ErrorTableFieldCell class];
- } else if ([object isKindOfClass:[T3TextFieldTableField class]]) {
- return [T3TextFieldTableFieldCell class];
- } else if ([object isKindOfClass:[T3TextViewTableField class]]) {
- return [T3TextViewTableFieldCell class];
- } else if ([object isKindOfClass:[T3SwitchTableField class]]) {
- return [T3SwitchTableFieldCell class];
+ if ([object isKindOfClass:[TTTableField class]]) {
+ if ([object isKindOfClass:[TTTextTableField class]]) {
+ return [TTTextTableFieldCell class];
+ } else if ([object isKindOfClass:[TTTitledTableField class]]) {
+ return [TTTitledTableFieldCell class];
+ } else if ([object isKindOfClass:[TTSubtextTableField class]]) {
+ return [TTSubtextTableFieldCell class];
+ } else if ([object isKindOfClass:[TTMoreButtonTableField class]]) {
+ return [TTMoreButtonTableFieldCell class];
+ } else if ([object isKindOfClass:[TTIconTableField class]]) {
+ return [TTIconTableFieldCell class];
+ } else if ([object isKindOfClass:[TTImageTableField class]]) {
+ return [TTImageTableFieldCell class];
+ } else if ([object isKindOfClass:[TTActivityTableField class]]) {
+ return [TTActivityTableFieldCell class];
+ } else if ([object isKindOfClass:[TTErrorTableField class]]) {
+ return [TTErrorTableFieldCell class];
+ } else if ([object isKindOfClass:[TTTextFieldTableField class]]) {
+ return [TTTextFieldTableFieldCell class];
+ } else if ([object isKindOfClass:[TTTextViewTableField class]]) {
+ return [TTTextViewTableFieldCell class];
+ } else if ([object isKindOfClass:[TTSwitchTableField class]]) {
+ return [TTSwitchTableFieldCell class];
} else {
- return [T3TableFieldCell class];
+ return [TTTableFieldCell class];
}
}
@@ -79,9 +79,9 @@ - (void)decorateCell:(UITableViewCell*)cell forRowAtIndexPath:(NSIndexPath*)inde
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation T3BasicDataSource
+@implementation TTBasicDataSource
-+ (T3BasicDataSource*)dataSourceWithObjects:(id)object,... {
++ (TTBasicDataSource*)dataSourceWithObjects:(id)object,... {
NSMutableArray* items = [NSMutableArray array];
va_list ap;
va_start(ap, object);
@@ -114,7 +114,7 @@ - (void)dealloc {
}
///////////////////////////////////////////////////////////////////////////////////////////////////
-// T3DataSource
+// TTDataSource
- (id)objectForRowAtIndexPath:(NSIndexPath*)indexPath {
return [_items objectAtIndex:indexPath.row];
@@ -131,9 +131,9 @@ - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation T3SectionedDataSource
+@implementation TTSectionedDataSource
-+ (T3SectionedDataSource*)dataSourceWithObjects:(id)object,... {
++ (TTSectionedDataSource*)dataSourceWithObjects:(id)object,... {
NSMutableArray* items = [NSMutableArray array];
NSMutableArray* sections = [NSMutableArray array];
NSMutableArray* section = nil;
@@ -177,7 +177,7 @@ - (void)dealloc {
}
///////////////////////////////////////////////////////////////////////////////////////////////////
-// T3DataSource
+// TTDataSource
- (id)objectForRowAtIndexPath:(NSIndexPath*)indexPath {
NSArray* section = [_items objectAtIndex:indexPath.section];
View
4 src/T3ErrorView.m → src/TTErrorView.m
@@ -1,4 +1,4 @@
-#import "Three20/T3ErrorView.h"
+#import "Three20/TTErrorView.h"
///////////////////////////////////////////////////////////////////////////////////////////////////
@@ -8,7 +8,7 @@
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation T3ErrorView
+@implementation TTErrorView
- (id)initWithTitle:(NSString*)title subtitle:(NSString*)subtitle image:(UIImage*)image {
if (self = [self initWithFrame:CGRectZero]) {
View
44 src/T3Global.m → src/TTGlobal.m
@@ -1,4 +1,4 @@
-#import "Three20/T3Global.h"
+#import "Three20/TTGlobal.h"
///////////////////////////////////////////////////////////////////////////////////////////////////
@@ -9,22 +9,22 @@
const void* RetainNoOp(CFAllocatorRef allocator, const void *value) { return value; }
void ReleaseNoOp(CFAllocatorRef allocator, const void *value) { }
-NSMutableArray* T3CreateNonRetainingArray() {
+NSMutableArray* TTCreateNonRetainingArray() {
CFArrayCallBacks callbacks = kCFTypeArrayCallBacks;
callbacks.retain = RetainNoOp;
callbacks.release = ReleaseNoOp;
return (NSMutableArray*)CFArrayCreateMutable(nil, 0, &callbacks);
}
-BOOL T3EmptyArray(NSObject* object) {
+BOOL TTEmptyArray(NSObject* object) {
return [object isKindOfClass:[NSArray class]] && ![(NSArray*)object count];
}
-BOOL T3EmptyString(NSObject* object) {
+BOOL TTEmptyString(NSObject* object) {
return [object isKindOfClass:[NSString class]] && ![(NSString*)object length];
}
-UIInterfaceOrientation T3DeviceOrientation() {
+UIInterfaceOrientation TTDeviceOrientation() {
UIInterfaceOrientation orient = [UIDevice currentDevice].orientation;
if (!orient) {
return UIInterfaceOrientationPortrait;
@@ -33,29 +33,29 @@ UIInterfaceOrientation T3DeviceOrientation() {
}
}
-CGRect T3ScreenBounds() {
+CGRect TTScreenBounds() {
CGRect bounds = [UIScreen mainScreen].bounds;
- if (UIDeviceOrientationIsLandscape(T3DeviceOrientation())) {
+ if (UIDeviceOrientationIsLandscape(TTDeviceOrientation())) {
CGFloat width = bounds.size.width;
bounds.size.width = bounds.size.height;
bounds.size.height = width;
}
return bounds;
}
-void T3NetworkRequestStarted() {
+void TTNetworkRequestStarted() {
if (gNetworkTaskCount++ == 0) {
[UIApplication sharedApplication].networkActivityIndicatorVisible = YES;
}
}
-void T3NetworkRequestStopped() {
+void TTNetworkRequestStopped() {
if (--gNetworkTaskCount == 0) {
[UIApplication sharedApplication].networkActivityIndicatorVisible = NO;
}
}
-UIImage* T3TransformImage(UIImage* image, CGFloat width, CGFloat height, BOOL rotate) {
+UIImage* TTTransformImage(UIImage* image, CGFloat width, CGFloat height, BOOL rotate) {
CGFloat destW = width;
CGFloat destH = height;
CGFloat sourceW = width;
@@ -97,7 +97,7 @@ void T3NetworkRequestStopped() {
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation NSObject (T3Category)
+@implementation NSObject (TTCategory)
- (id)performSelector:(SEL)selector withObject:(id)p1 withObject:(id)p2 withObject:(id)p3 {
NSMethodSignature *sig = [self methodSignatureForSelector:selector];
@@ -253,14 +253,14 @@ @interface UIEventFake : NSObject {
@implementation UIEventFake
@end
-@interface UITouch (T3Category)
+@interface UITouch (TTCategory)
- (id)initInView:(UIView *)view location:(CGPoint)location;
- (void)changeToPhase:(UITouchPhase)phase;
@end
-@implementation UITouch (T3Category)
+@implementation UITouch (TTCategory)
- (id)initInView:(UIView *)view location:(CGPoint)location {
if (self = [super init]) {
@@ -286,7 +286,7 @@ - (void)changeToPhase:(UITouchPhase)phase {
@end
-@implementation UIEvent (T3Category)
+@implementation UIEvent (TTCategory)
- (id)initWithTouch:(UITouch *)touch {
if (self == [super init]) {
@@ -311,7 +311,7 @@ - (id)initWithTouch:(UITouch *)touch {
@end
-@implementation UIView (T3Category)
+@implementation UIView (TTCategory)
- (CGFloat)x {
return self.frame.origin.x;
@@ -405,12 +405,12 @@ - (CGFloat)screenViewY {
}
- (CGFloat)orientationWidth {
- return UIDeviceOrientationIsPortrait(T3DeviceOrientation())
+ return UIDeviceOrientationIsPortrait(TTDeviceOrientation())
? self.width : self.height;
}
- (CGFloat)orientationHeight {
- return UIDeviceOrientationIsPortrait(T3DeviceOrientation())
+ return UIDeviceOrientationIsPortrait(TTDeviceOrientation())
? self.height : self.width;
}
@@ -488,7 +488,7 @@ - (void)sizeToFitKeyboard:(BOOL)keyboard animated:(BOOL)animated {
}
[UIView beginAnimations:nil context:nil];
- [UIView setAnimationDuration:T3_TRANSITION_DURATION];
+ [UIView setAnimationDuration:TT_TRANSITION_DURATION];
self.frame = frame;
[UIView commitAnimations];
}
@@ -497,7 +497,7 @@ - (void)sizeToFitKeyboard:(BOOL)keyboard animated:(BOOL)animated {
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation UIWebView (T3Category)
+@implementation UIWebView (TTCategory)
- (CGRect)frameOfElement:(NSString*)query {
NSString* result = [self stringByEvaluatingJavaScriptFromString:[NSString stringWithFormat:@"\
@@ -533,7 +533,7 @@ - (void)simulateTapElement:(NSString*)query {
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation UITableView (T3Category)
+@implementation UITableView (TTCategory)
- (UIView*)indexView {
Class indexViewClass = NSClassFromString(@"UITableViewIndex");
@@ -574,7 +574,7 @@ - (void)sizeToFitKeyboard:(BOOL)keyboard atIndexPath:(NSIndexPath*)indexPath
}
[UIView beginAnimations:nil context:nil];
- [UIView setAnimationDuration:T3_TRANSITION_DURATION];
+ [UIView setAnimationDuration:TT_TRANSITION_DURATION];
self.frame = frame;
[UIView commitAnimations];
@@ -588,7 +588,7 @@ - (void)sizeToFitKeyboard:(BOOL)keyboard atIndexPath:(NSIndexPath*)indexPath
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation UIToolbar (T3Category)
+@implementation UIToolbar (TTCategory)
- (UIBarButtonItem*)itemWithTag:(NSInteger)tag {
for (UIBarButtonItem* button in self.items) {
View
16 src/T3ImageView.m → src/TTImageView.m
@@ -1,6 +1,6 @@
-#import "Three20/T3ImageView.h"
+#import "Three20/TTImageView.h"
-@implementation T3ImageView
+@implementation TTImageView
@synthesize delegate = _delegate, url = _url, defaultImage = _defaultImage,
autoresizesToImage = _autoresizesToImage;
@@ -51,17 +51,17 @@ - (void)setImage:(UIImage*)image {
}
//////////////////////////////////////////////////////////////////////////////////////////////////
-// T3URLRequestDelegate
+// TTURLRequestDelegate
-- (void)requestLoading:(T3URLRequest*)request {
+- (void)requestLoading:(TTURLRequest*)request {
_request = [request retain];
if ([_delegate respondsToSelector:@selector(imageViewLoading:)]) {
[_delegate imageViewLoading:self];
}
}
-- (void)request:(T3URLRequest*)request loadedData:(NSData*)data media:(id)media {
+- (void)request:(TTURLRequest*)request loadedData:(NSData*)data media:(id)media {
[_request release];
_request = nil;
@@ -74,7 +74,7 @@ - (void)request:(T3URLRequest*)request loadedData:(NSData*)data media:(id)media
}
}
-- (void)request:(T3URLRequest*)request didFailWithError:(NSError*)error {
+- (void)request:(TTURLRequest*)request didFailWithError:(NSError*)error {
[_request release];
_request = nil;
@@ -83,7 +83,7 @@ - (void)request:(T3URLRequest*)request didFailWithError:(NSError*)error {
}
}
-- (void)requestCancelled:(T3URLRequest*)request {
+- (void)requestCancelled:(TTURLRequest*)request {
[_request release];
_request = nil;
@@ -119,7 +119,7 @@ - (void)reload {
if (_request)
return;
- T3URLRequest* request = [[[T3URLRequest alloc] initWithURL:_url delegate:self] autorelease];
+ TTURLRequest* request = [[[TTURLRequest alloc] initWithURL:_url delegate:self] autorelease];
request.shouldConvertToMedia = YES;
if (_url && ![request send]) {
View
14 src/T3LinkView.m → src/TTLinkView.m
@@ -1,10 +1,10 @@
-#include "Three20/T3LinkView.h"
-#include "Three20/T3NavigationCenter.h"
-#include "Three20/T3BackgroundView.h"
+#include "Three20/TTLinkView.h"
+#include "Three20/TTNavigationCenter.h"
+#include "Three20/TTBackgroundView.h"
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation T3LinkView
+@implementation TTLinkView
@synthesize delegate = _delegate, href = _href, borderRadius = _borderRadius;
@@ -37,7 +37,7 @@ - (void)tapped {
}
if (okToDispatch) {
- [[T3NavigationCenter defaultCenter] displayObject:_href];
+ [[TTNavigationCenter defaultCenter] displayObject:_href];
}
}
@@ -59,8 +59,8 @@ - (BOOL)continueTrackingWithTouch:(UITouch *)touch withEvent:(UIEvent *)event {
- (void)setHighlighted:(BOOL)highlighted {
[super setHighlighted:highlighted];
if (!_screenView) {
- _screenView = [[T3BackgroundView alloc] initWithFrame:self.bounds];
- _screenView.background = T3BackgroundRoundedRect;
+ _screenView = [[TTBackgroundView alloc] initWithFrame:self.bounds];
+ _screenView.background = TTBackgroundRoundedRect;
_screenView.fillColor = [UIColor colorWithRed:0 green:0 blue:0 alpha:0.5];
_screenView.opaque = NO;
_screenView.contentMode = UIViewContentModeRedraw;
View
24 src/T3MenuTextField.m → src/TTMenuTextField.m
@@ -1,5 +1,5 @@
-#import "Three20/T3MenuTextField.h"
-#import "T3MenuViewCell.h"
+#import "Three20/TTMenuTextField.h"
+#import "TTMenuViewCell.h"
///////////////////////////////////////////////////////////////////////////////////////////////////
@@ -15,7 +15,7 @@
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation T3MenuTextField
+@implementation TTMenuTextField
@synthesize cellViews = _cellViews, selectedCell = _selectedCell, lineCount = _lineCount,
visibleLineCount = _visibleLineCount;
@@ -53,7 +53,7 @@ - (CGFloat)layoutCells {
_cursorOrigin.y = marginY;
_lineCount = 1;
- for (T3MenuViewCell* cell in _cellViews) {
+ for (TTMenuViewCell* cell in _cellViews) {
[cell sizeToFit];
CGFloat lineWidth = _cursorOrigin.x + cell.frame.size.width + marginRight;
@@ -135,8 +135,8 @@ - (void)touchesEnded:(NSSet*)touches withEvent:(UIEvent*)event {
if (touch.view == self) {
self.selectedCell = nil;
} else {
- if ([touch.view isKindOfClass:[T3MenuViewCell class]]) {
- self.selectedCell = (T3MenuViewCell*)touch.view;
+ if ([touch.view isKindOfClass:[TTMenuViewCell class]]) {
+ self.selectedCell = (TTMenuViewCell*)touch.view;
}
}
}
@@ -194,7 +194,7 @@ - (CGRect)rightViewRectForBounds:(CGRect)bounds {
}
///////////////////////////////////////////////////////////////////////////////////////////////////
-// T3SearchTextField
+// TTSearchTextField
- (BOOL)empty {
return !self.text.length || [self.text isEqualToString:kEmpty]
@@ -230,14 +230,14 @@ - (void)tableView:(UITableView*)tableView didSelectRowAtIndexPath:(NSIndexPath*)
- (NSArray*)cells {
NSMutableArray* cells = [NSMutableArray array];
- for (T3MenuViewCell* cellView in _cellViews) {
+ for (TTMenuViewCell* cellView in _cellViews) {
[cells addObject:cellView.object ? cellView.object : [NSNull null]];
}
return cells;
}
- (void)addCellWithObject:(id)object label:(NSString*)label {
- T3MenuViewCell* cell = [[[T3MenuViewCell alloc] initWithFrame:CGRectZero] autorelease];
+ TTMenuViewCell* cell = [[[TTMenuViewCell alloc] initWithFrame:CGRectZero] autorelease];
cell.object = object;
cell.label = label;
@@ -255,7 +255,7 @@ - (void)addCellWithObject:(id)object label:(NSString*)label {
- (void)removeCellWithObject:(id)object {
for (int i = 0; i < _cellViews.count; ++i) {
- T3MenuViewCell* cell = [_cellViews objectAtIndex:i];
+ TTMenuViewCell* cell = [_cellViews objectAtIndex:i];
if (cell.object == object) {
[_cellViews removeObjectAtIndex:i];
[cell removeFromSuperview];
@@ -274,15 +274,15 @@ - (void)removeCellWithObject:(id)object {
- (void)removeAllCells {
while (_cellViews.count) {
- T3MenuViewCell* cell = [_cellViews objectAtIndex:0];
+ TTMenuViewCell* cell = [_cellViews objectAtIndex:0];
[cell removeFromSuperview];
[_cellViews removeObjectAtIndex:0];
}
_selectedCell = nil;
}
-- (void)setSelectedCell:(T3MenuViewCell*)cell {
+- (void)setSelectedCell:(TTMenuViewCell*)cell {
if (_selectedCell) {
_selectedCell.selected = NO;
}
View
14 src/T3MenuViewCell.m → src/TTMenuViewCell.m
@@ -1,5 +1,5 @@
-#import "Three20/T3MenuViewCell.h"
-#import "Three20/T3Appearance.h"
+#import "Three20/TTMenuViewCell.h"
+#import "Three20/TTAppearance.h"
///////////////////////////////////////////////////////////////////////////////////////////////////
@@ -9,7 +9,7 @@
///////////////////////////////////////////////////////////////////////////////////////////////////
-@implementation T3MenuViewCell
+@implementation TTMenuViewCell
@synthesize object = _object, selected = _selected;
@@ -45,14 +45,14 @@ - (void)drawRect:(CGRect)rect {
UIColor* fill[] = {RGBACOLOR(79, 144, 255, 1), RGBACOLOR(49, 90, 255, 1)};
UIColor* stroke = RGBACOLOR(53, 94, 255, 1);
- [[T3Appearance appearance] drawBackground:T3BackgroundRoundedRect rect:CGRectInset(rect, 1, 1)
- fill:fill fillCount:2 stroke:stroke radius:T3_RADIUS_ROUNDED];
+ [[TTAppearance appearance] drawBackground:TTBackgroundRoundedRect rect:CGRectInset(rect, 1, 1)
+ fill:fill fillCount:2 stroke:stroke radius:TT_RADIUS_ROUNDED];
} else {
UIColor* fill[] = {RGBACOLOR(221, 231, 248, 1), RGBACOLOR(188, 206, 241, 1)};
UIColor* stroke = RGBACOLOR(121, 133, 217, 1);
- [[T3Appearance appearance] drawBackground:T3BackgroundRoundedRect rect:CGRectInset(rect, 1, 1)
- fill:fill fillCount:2 stroke:stroke radius:T3_RADIUS_ROUNDED];
+ [[TTAppearance appearance] drawBackground:TTBackgroundRoundedRect rect:CGRectInset(rect, 1, 1)
+ fill:fill fillCount:2 stroke:stroke radius:TT_RADIUS_ROUNDED];
}
}