// // DownloadQueenViewController.m // TumblrDownloader // // Created by HonorLee on 16/1/17. // Copyright © 2016年 HonorLee. All rights reserved. // #import "DownloadQueenViewController.h" @interface DownloadQueenViewController () @end @implementation DownloadQueenViewController @synthesize DownloadTableView; - (void)viewDidLoad { [super viewDidLoad]; // Do any additional setup after loading the view. DownloadTableView.dataSource = self; DownloadTableView.delegate = self; } - (void)didReceiveMemoryWarning { [super didReceiveMemoryWarning]; // Dispose of any resources that can be recreated. } #pragma TableView -(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{ return 1; } -(void)tableView:(UITableView *)tableView performAction:(SEL)action forRowAtIndexPath:(NSIndexPath *)indexPath withSender:(id)sender{ } -(NSInteger)tableView:(UITableView *)tableView sectionForSectionIndexTitle:(NSString *)title atIndex:(NSInteger)index{ return 1; } -(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{ UITableViewCell *cell = [DownloadTableView dequeueReusableCellWithIdentifier:@"DownloadQueenCell"]; [cell setFrame:CGRectMake(0, 0, DownloadTableView.frame.size.width, 40)]; UIProgressView *progressView = [[UIProgressView alloc]initWithFrame:CGRectMake(0, 0, cell.frame.size.width, cell.frame.size.height)]; [cell addSubview:progressView]; [progressView setTransform:CGAffineTransformMakeScale(1, 44)]; [progressView setTintColor:[UIColor colorWithRed:249/255.0 green:249/255.0 blue:249/255.0 alpha:1]]; [progressView setProgressViewStyle:UIProgressViewStyleBar]; [progressView setProgress:0.7 animated:YES]; return cell; } @end