105 [super viewDidLoad]; |
106 [super viewDidLoad]; |
106 |
107 |
107 CGSize screenSize = [[UIScreen mainScreen] bounds].size; |
108 CGSize screenSize = [[UIScreen mainScreen] bounds].size; |
108 self.view.frame = CGRectMake(0, 0, screenSize.height, screenSize.width - 44); |
109 self.view.frame = CGRectMake(0, 0, screenSize.height, screenSize.width - 44); |
109 |
110 |
110 if ([self.tableView respondsToSelector:@selector(setBackgroundView:)]) { |
111 if (IS_IPAD()) { |
111 if (IS_IPAD()) |
112 [self.tableView setBackgroundColorForAnyTable:[UIColor darkBlueColorTransparent]]; |
112 [self.tableView setBackgroundView:nil]; |
113 self.tableView.layer.borderColor = [[UIColor darkYellowColor] CGColor]; |
113 else { |
114 self.tableView.layer.borderWidth = 2.7f; |
114 UIImage *backgroundImage = [[UIImage alloc] initWithContentsOfFile:@"background~iphone.png"]; |
115 self.tableView.layer.cornerRadius = 8; |
115 UIImageView *background = [[UIImageView alloc] initWithImage:backgroundImage]; |
116 self.tableView.contentInset = UIEdgeInsetsMake(5, 0, 5, 0); |
116 [backgroundImage release]; |
|
117 [self.tableView setBackgroundView:background]; |
|
118 [background release]; |
|
119 } |
|
120 } else { |
117 } else { |
121 self.view.backgroundColor = [UIColor blackColor]; |
118 UIImage *backgroundImage = [[UIImage alloc] initWithContentsOfFile:@"background~iphone.png"]; |
122 } |
119 UIImageView *background = [[UIImageView alloc] initWithImage:backgroundImage]; |
123 |
120 [backgroundImage release]; |
124 self.tableView.separatorColor = [UIColor darkYellowColor]; |
121 [self.tableView setBackgroundView:background]; |
|
122 [background release]; |
|
123 } |
|
124 |
|
125 self.tableView.indicatorStyle = UIScrollViewIndicatorStyleWhite; |
|
126 self.tableView.separatorColor = [UIColor whiteColor]; |
125 self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone; |
127 self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone; |
126 } |
128 } |
127 |
129 |
128 #pragma mark - |
130 #pragma mark - |
129 #pragma mark Table view data source |
131 #pragma mark Table view data source |