Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 10 additions & 5 deletions Classes/PullRefreshTableViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -67,17 +67,22 @@ - (void)viewDidLoad {
}

- (void)setupStrings{
textPull = [[NSString alloc] initWithString:@"Pull down to refresh..."];
textRelease = [[NSString alloc] initWithString:@"Release to refresh..."];
textLoading = [[NSString alloc] initWithString:@"Loading..."];
textPull = [[NSString alloc] initWithString:NSLocalizedString(@"Pull down to refresh...", @"Pull down to refresh...")];
textRelease = [[NSString alloc] initWithString:NSLocalizedString(@"Release to refresh...", @"Release to refresh...")];
textLoading = [[NSString alloc] initWithString:NSLocalizedString(@"Loading...", @"Loading...")];
}

- (void)addPullToRefreshHeader {
refreshHeaderView = [[UIView alloc] initWithFrame:CGRectMake(0, 0 - REFRESH_HEADER_HEIGHT, 320, REFRESH_HEADER_HEIGHT)];

CGFloat tableWidth = self.tableView.frame.size.width;

refreshHeaderView = [[UIView alloc] initWithFrame:CGRectMake(0, 0 - REFRESH_HEADER_HEIGHT, tableWidth, REFRESH_HEADER_HEIGHT)];
refreshHeaderView.backgroundColor = [UIColor clearColor];
refreshHeaderView.autoresizingMask = UIViewAutoresizingFlexibleWidth;

refreshLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, 320, REFRESH_HEADER_HEIGHT)];
refreshLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, tableWidth, REFRESH_HEADER_HEIGHT)];
refreshLabel.backgroundColor = [UIColor clearColor];
refreshLabel.autoresizingMask = UIViewAutoresizingFlexibleWidth;
refreshLabel.font = [UIFont boldSystemFontOfSize:12.0];
refreshLabel.textAlignment = UITextAlignmentCenter;

Expand Down