ISRefreshControl
ISRefreshControl copied to clipboard
attributedTitle not visible in ios5
Hi, I am adding refresh control as subview to table as follows
self.refreshControl = [[ISRefreshControl alloc] initWithFrame:tableView.frame]; [refreshControl addTarget:self action:@selector(handleRefresh:) forControlEvents:UIControlEventValueChanged]; [tableView addSubview:refreshControl];
And, setting the attribute title as follows:
self.refreshControl.attributedTitle = [[NSAttributedString alloc]initWithString:@"Refreshing the TableView"]; //set the date and time of refreshing NSDateFormatter *formattedDate = [[NSDateFormatter alloc]init]; [formattedDate setDateFormat:@"MMM d, h:mm a"]; NSString *lastupdated = [NSString stringWithFormat:@"Last Updated on %@",[formattedDate stringFromDate:[NSDate date]]]; self.refreshControl.attributedTitle = [[NSAttributedString alloc]initWithString:lastupdated];
[self.refreshControl endRefreshing];
It , is working fine in ios6 but in iOS 5 attribute title is not visible only the indicator is visible. Also, when we set the attribute the stretch animation of bubble is not shown and directly the refreshing is triggered in ios 6.0.
Sorry, ISRefreshControl.attributedTitle is not supported for now. I will work for this feature as soon as possible.